From 4ca7815f1881ce6f17a6f72aaf2f5240ddb61ef7 Mon Sep 17 00:00:00 2001 From: elmariachi111 Date: Sun, 8 Oct 2023 22:06:51 +0000 Subject: [PATCH] =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20molecule?= =?UTF-8?q?protocol/test-wagmi-safe-privy@1bd71cc6655caf3e318676f08db31856?= =?UTF-8?q?7c80babf=20=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- 404.html | 43 + .../YxIhfqPcck6EHIlBEsfok/_buildManifest.js | 1 + .../YxIhfqPcck6EHIlBEsfok/_ssgManifest.js | 1 + .../chunks/3ab9597f-c24c44e69c9cede0.js | 2253 +++++++++++++++++ _next/static/chunks/45.f7592c692bffbb36.js | 1 + _next/static/chunks/465.581b3ba67298757a.js | 1 + _next/static/chunks/572.a8d809b8ab002224.js | 1 + _next/static/chunks/723-512addf0df3beac0.js | 291 +++ _next/static/chunks/777.8ebd521a6b67f3bc.js | 22 + _next/static/chunks/864-0aa61a7cd36fb457.js | 25 + _next/static/chunks/905-d2b9c45a6b50b0e1.js | 218 ++ .../chunks/app/_not-found-da24bb006e0d0c60.js | 1 + .../chunks/app/layout-09059e339eda9f17.js | 1 + .../chunks/app/page-b64dabb8be920e63.js | 1 + .../chunks/fd9d1056-024209d9649a7d29.js | 9 + .../chunks/framework-43665103d101a22d.js | 25 + _next/static/chunks/main-762b0ad3716f5b69.js | 1 + .../chunks/main-app-d3011cc106a09a54.js | 1 + .../chunks/pages/_app-6ca4a4ec31e39f3d.js | 1 + .../chunks/pages/_error-9de0d1f4f4d1fcb4.js | 1 + .../chunks/polyfills-c67a75d1b6f99dc8.js | 1 + .../static/chunks/webpack-58164cf1a5e2806c.js | 1 + _next/static/css/e197ba52815ecee3.css | 1 + _next/static/media/05a31a2ca4975f99-s.woff2 | Bin 0 -> 10496 bytes _next/static/media/513657b02c5c193f-s.woff2 | Bin 0 -> 17612 bytes _next/static/media/51ed15f9841b9f9d-s.woff2 | Bin 0 -> 22524 bytes _next/static/media/c9a5bc6a7c948fb0-s.p.woff2 | Bin 0 -> 46552 bytes _next/static/media/d6b16ce4a6175f26-s.woff2 | Bin 0 -> 80044 bytes _next/static/media/ec159349637c90ad-s.woff2 | Bin 0 -> 27316 bytes _next/static/media/fd4db3eb5472fc27-s.woff2 | Bin 0 -> 12768 bytes favicon.ico | Bin 0 -> 25931 bytes index.html | 43 + index.txt | 15 + next.svg | 1 + vercel.svg | 1 + 35 files changed, 2961 insertions(+) create mode 100644 404.html create mode 100644 _next/static/YxIhfqPcck6EHIlBEsfok/_buildManifest.js create mode 100644 _next/static/YxIhfqPcck6EHIlBEsfok/_ssgManifest.js create mode 100644 _next/static/chunks/3ab9597f-c24c44e69c9cede0.js create mode 100644 _next/static/chunks/45.f7592c692bffbb36.js create mode 100644 _next/static/chunks/465.581b3ba67298757a.js create mode 100644 _next/static/chunks/572.a8d809b8ab002224.js create mode 100644 _next/static/chunks/723-512addf0df3beac0.js create mode 100644 _next/static/chunks/777.8ebd521a6b67f3bc.js create mode 100644 _next/static/chunks/864-0aa61a7cd36fb457.js create mode 100644 _next/static/chunks/905-d2b9c45a6b50b0e1.js create mode 100644 _next/static/chunks/app/_not-found-da24bb006e0d0c60.js create mode 100644 _next/static/chunks/app/layout-09059e339eda9f17.js create mode 100644 _next/static/chunks/app/page-b64dabb8be920e63.js create mode 100644 _next/static/chunks/fd9d1056-024209d9649a7d29.js create mode 100644 _next/static/chunks/framework-43665103d101a22d.js create mode 100644 _next/static/chunks/main-762b0ad3716f5b69.js create mode 100644 _next/static/chunks/main-app-d3011cc106a09a54.js create mode 100644 _next/static/chunks/pages/_app-6ca4a4ec31e39f3d.js create mode 100644 _next/static/chunks/pages/_error-9de0d1f4f4d1fcb4.js create mode 100644 _next/static/chunks/polyfills-c67a75d1b6f99dc8.js create mode 100644 _next/static/chunks/webpack-58164cf1a5e2806c.js create mode 100644 _next/static/css/e197ba52815ecee3.css create mode 100644 _next/static/media/05a31a2ca4975f99-s.woff2 create mode 100644 _next/static/media/513657b02c5c193f-s.woff2 create mode 100644 _next/static/media/51ed15f9841b9f9d-s.woff2 create mode 100644 _next/static/media/c9a5bc6a7c948fb0-s.p.woff2 create mode 100644 _next/static/media/d6b16ce4a6175f26-s.woff2 create mode 100644 _next/static/media/ec159349637c90ad-s.woff2 create mode 100644 _next/static/media/fd4db3eb5472fc27-s.woff2 create mode 100644 favicon.ico create mode 100644 index.html create mode 100644 index.txt create mode 100644 next.svg create mode 100644 vercel.svg diff --git a/404.html b/404.html new file mode 100644 index 0000000..9eb6ecb --- /dev/null +++ b/404.html @@ -0,0 +1,43 @@ +404: This page could not be found.Create Next App

Safetest

404

This page could not be found.

\ No newline at end of file diff --git a/_next/static/YxIhfqPcck6EHIlBEsfok/_buildManifest.js b/_next/static/YxIhfqPcck6EHIlBEsfok/_buildManifest.js new file mode 100644 index 0000000..a6a1fe8 --- /dev/null +++ b/_next/static/YxIhfqPcck6EHIlBEsfok/_buildManifest.js @@ -0,0 +1 @@ +self.__BUILD_MANIFEST={__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},"/_error":["static/chunks/pages/_error-9de0d1f4f4d1fcb4.js"],sortedPages:["/_app","/_error"]},self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB(); \ No newline at end of file diff --git a/_next/static/YxIhfqPcck6EHIlBEsfok/_ssgManifest.js b/_next/static/YxIhfqPcck6EHIlBEsfok/_ssgManifest.js new file mode 100644 index 0000000..5b3ff59 --- /dev/null +++ b/_next/static/YxIhfqPcck6EHIlBEsfok/_ssgManifest.js @@ -0,0 +1 @@ +self.__SSG_MANIFEST=new Set([]);self.__SSG_MANIFEST_CB&&self.__SSG_MANIFEST_CB() \ No newline at end of file diff --git a/_next/static/chunks/3ab9597f-c24c44e69c9cede0.js b/_next/static/chunks/3ab9597f-c24c44e69c9cede0.js new file mode 100644 index 0000000..f26a333 --- /dev/null +++ b/_next/static/chunks/3ab9597f-c24c44e69c9cede0.js @@ -0,0 +1,2253 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[269],{7129:function(e,t,i){i.d(t,{Gw:function(){return ah},rB:function(){return Ja},rr:function(){return Wv},sv:function(){return $}});var a=i(18994),s=i(56955),l=i(61127),u=i(2265),p=i(30059),f=i(13593),w=i(52069),y=i(61162),C=i(64775),k=i(57437),A=i(36288),T=i(31095),I=i(37169),L=i(61986),R=i.n(L),W=i(14228),F=i(11490),z=i(37943);i(63895);var G=i(71725),q=i(54887),K=i(88208),J=i(33753),Q=i(96689),X=i(34424),et=i(25587),er=i(52466),ei=i(70432),en=i(10887),ea=i(31706),eo=i(11226),es=i(83179),ec=i.n(es),eh=i(50683),eu=i(54184),ep=i(57548),em=i(36108),ef=i(84209),eg=i(42893),ew=i(49186),ex=i(49863),ey=i(34729),eb=i(32938),eC=i(77150),ej=i(82929),ek=i(91543),e_=i(20387),eE=i(75298),eA=i(92598),eP=i(76303),eS=i(84164),eT=i(39427),eN=i(14941),eI=i(57273),eO=i(58337),eL=i(10375),Cu=(e,t,i)=>{if(!t.has(e))throw TypeError("Cannot "+i)},ds=(e,t,i)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,i)},ps=(e,t,i)=>(Cu(e,t,"access private method"),i),eR=class extends Error{constructor(e,t,i){super(e),t instanceof Error&&(this.cause=t),this.privyErrorCode=i}toString(){return`${this.type}${this.privyErrorCode?`-${this.privyErrorCode}`:""}: ${this.message}${this.cause?` [cause: ${this.cause}]`:""}`}},eW=class extends eR{constructor(e,t,i,a,s){super(i,a,s),this.type=e,this.status=t}},eM=class extends eR{constructor(e,t,i){super(e,t,i),this.type="client_error"}},eU=class extends eM{constructor(){super("Request timed out",void 0,"client_request_timeout")}},eD=class extends eR{constructor(e,t,i){super(e,t,i),this.type="connector_error"}},ee=e=>{if(e instanceof eR)return e;if(!(e instanceof p.F))return De(e);if(!e.response)return new eW("api_error",null,e.message,e);let{type:t,message:i,error:a,code:s}=e.data;return new eW(t||"ApiError",e.response.status,i||a,e,s)},De=e=>e instanceof eR?e:e instanceof Error?new eM(e.message,e):new eM(`Internal error: ${e}`),eF=class extends eM{constructor(){super("Method called before `ready`. Ensure you wait until `ready` is true before calling.")}},eZ=class extends eM{constructor(e="Embedded wallet error",t){super(e,t,"unknown_embedded_wallet_error")}},ez=class extends eM{constructor(e="User must be authenticated"){super(e,void 0,"must_be_authenticated")}},Jr=()=>"/api/v1/sessions",us=()=>"/api/v1/sessions/logout",ms=()=>"/api/v1/sessions/fork",Qr=()=>"/api/v1/sessions/fork/recover",hs=()=>"/api/v1/siwe/init",fs=()=>"/api/v1/siwe/authenticate",ys=()=>"/api/v1/siwe/link",gs=()=>"/api/v1/passwordless/init",vs=()=>"/api/v1/passwordless/authenticate",ws=()=>"/api/v1/passwordless/link",Cs=()=>"/api/v1/passwordless_sms/init",bs=()=>"/api/v1/passwordless_sms/authenticate",Es=()=>"/api/v1/passwordless_sms/link",xs=()=>"/api/v1/oauth/init",Ps=()=>"/api/v1/oauth/authenticate",Ts=()=>"/api/v1/oauth/link",_s=()=>"/api/v1/siwe/unlink",Ss=()=>"/api/v1/passwordless/unlink",As=()=>"/api/v1/passwordless_sms/unlink",ks=()=>"/api/v1/oauth/unlink",Rs=()=>"/api/v1/analytics_events",Ws=()=>"/api/v1/plugins/moonpay_on_ramp/sign",Is=()=>"/api/v1/custom_jwt_account/authenticate",e$=class{constructor(e){this.meta={token:e}}async authenticate(){if(!this.api)throw new eM("Auth flow has no API instance");try{let e=Is(),t=await this.api.post(e,{token:this.meta.token});return{user:t.user,token:t.token,refresh_token:t.refresh_token,is_new_user:t.is_new_user}}catch(e){throw ee(e)}}async link(){throw Error("Unimplemented")}},eB=class{constructor(e,t){this.meta={email:e,captchaToken:t}}async authenticate(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.email||!this.meta.emailCode)throw new eM("Email and email code must be set prior to calling authenticate.");try{let e=vs(),t=await this.api.post(e,{email:this.meta.email,code:this.meta.emailCode});return{user:t.user,token:t.token,refresh_token:t.refresh_token,is_new_user:t.is_new_user}}catch(e){throw ee(e)}}async link(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.email||!this.meta.emailCode)throw new eM("Email and email code must be set prior to calling authenticate.");try{let e=ws();return await this.api.post(e,{email:this.meta.email,code:this.meta.emailCode})}catch(e){throw ee(e)}}async sendCodeEmail(e,t){if(!this.api)throw new eM("Auth flow has no API instance");if(e&&(this.meta.email=e),t&&(this.meta.captchaToken=t),!this.meta.email)throw new eM("Email must be set when initialzing authentication.");try{let e=gs();return await this.api.post(e,{email:this.meta.email,token:this.meta.captchaToken})}catch(e){throw ee(e)}}},eH=class{constructor(e,t,i){this.meta={provider:e},this.meta.authorizationCode=t,this.meta.stateCode=i}isActive(){return!!(this.meta.authorizationCode&&this.meta.stateCode&&this.meta.provider)}async authenticate(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.authorizationCode||!this.meta.stateCode)throw new eM("[OAuth AuthFlow] Authorization and state codes code must be set prior to calling authenticate.");if("undefined"===this.meta.authorizationCode)throw new eM("User denied confirmation during OAuth flow");try{let e=Ps(),t=await this.api.post(e,{authorization_code:this.meta.authorizationCode,state_code:this.meta.stateCode});return{user:t.user,token:t.token,refresh_token:t.refresh_token,is_new_user:t.is_new_user}}catch(t){let e=ee(t);throw e.privyErrorCode?new eM(e.message||"Invalid code during OAuth flow.",void 0,e.privyErrorCode):"User denied confirmation during OAuth flow"===e.message?new eM("Invalid code during oauth flow.",void 0,"oauth_user_denied"):new eM("Invalid code during OAuth flow.",void 0,"unknown_auth_error")}}async link(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.authorizationCode||!this.meta.stateCode)throw new eM("[OAuth AuthFlow] Authorization and state codes code must be set prior to calling link.");if("undefined"===this.meta.authorizationCode)throw new eM("User denied confirmation during OAuth flow");try{let e=Ts();return await this.api.post(e,{authorization_code:this.meta.authorizationCode,state_code:this.meta.stateCode})}catch(e){throw ee(e)}}async getAuthorizationUrl(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.provider)throw new eM("Provider must be set when initialzing OAuth authentication.");try{let e=xs();return await this.api.post(e,{provider:this.meta.provider,redirect_to:window.location.href},{baseURL:this.api?.fallbackApiUrl})}catch(e){throw ee(e)}}},eG=class{constructor(e){this.promise=null,this.fn=e}execute(e){return null===this.promise&&(this.promise=(async()=>{try{return await this.fn(e)}finally{this.promise=null}})()),this.promise}},eq=class{constructor(e){this.createSiweMessage=(e,t,i,a,s,l,u)=>`${i} wants you to sign in with your Ethereum account: +${t} + +${u} + +URI: ${a} +Version: 1 +Chain ID: ${e} +Nonce: ${l} +Issued At: ${s} +Resources: +- https://privy.io`,this.getNonceOnce=new eG(this._getNonceOnce.bind(this)),this.wallet=e}get meta(){return{connectorType:this.wallet.connectorType,walletClientType:this.wallet.walletClientType}}async authenticate(){if(!this.api)throw new eM("Auth flow has no API instance");try{let{message:e,signature:t}=await this.sign(),i=await this.api.post(fs(),{message:e,signature:t,chainId:this.wallet.chainId,walletClientType:this.wallet.walletClientType,connectorType:this.wallet.connectorType});return{user:i.user,token:i.token,refresh_token:i.refresh_token,is_new_user:i.is_new_user}}catch(e){throw ee(e)}}async link(){if(!this.api)throw new eM("Auth flow has no API instance");try{let{message:e,signature:t}=await this.sign();return await this.api.post(ys(),{message:e,signature:t,chainId:this.wallet.chainId,walletClientType:this.wallet.walletClientType,connectorType:this.wallet.connectorType})}catch(e){throw ee(e)}}async sign(){if(!this.api)throw new eM("Auth flow has no API instance");if(await this.buildSiweMessage(),!this.preparedMessage)throw new eM("Could not prepare SIWE message");let e=await this.wallet.sign(this.preparedMessage);return{message:this.preparedMessage,signature:e}}async _getNonceOnce(){if(!this.api)throw new eM("Auth flow has no API instance");let e=this.wallet.address;return(await this.api.post(hs(),{address:e})).nonce}async buildSiweMessage(){if(!this.api)throw new eM("Auth flow has no API instance");let e=this.wallet.address,t=this.wallet.chainId.replace("eip155:","");return this.nonce||(this.nonce=await this.getNonceOnce.execute()),this.preparedMessage=this.prepareMessage(t,e,this.nonce),this.preparedMessage}prepareMessage(e,t,i){let a=window.location.host,s=window.location.origin,l=new Date().toISOString();return this.createSiweMessage(e,t,a,s,l,i,"By signing, you are proving you own this wallet and logging in. This does not initiate a transaction or cost any fees.")}},eV=class{constructor(e,t){this.meta={phoneNumber:e,captchaToken:t}}async authenticate(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.phoneNumber||!this.meta.smsCode)throw new eM("phone number and sms code must be set prior to calling authenticate.");try{let e=bs(),t=await this.api.post(e,{phoneNumber:this.meta.phoneNumber,code:this.meta.smsCode});return{user:t.user,token:t.token,refresh_token:t.refresh_token,is_new_user:t.is_new_user}}catch(e){throw ee(e)}}async link(){if(!this.api)throw new eM("Auth flow has no API instance");if(!this.meta.phoneNumber||!this.meta.smsCode)throw new eM("phone number and sms code must be set prior to calling authenticate.");try{let e=Es();return await this.api.post(e,{phoneNumber:this.meta.phoneNumber,code:this.meta.smsCode})}catch(e){throw ee(e)}}async sendSmsCode(e,t){if(!this.api)throw new eM("Auth flow has no API instance");if(e&&(this.meta.phoneNumber=e),t&&(this.meta.captchaToken=t),!this.meta.phoneNumber)throw new eM("phone nNumber must be set when initialzing authentication.");try{let e=Cs();return await this.api.post(e,{phoneNumber:this.meta.phoneNumber,token:this.meta.captchaToken})}catch(e){throw ee(e)}}};function qe(e){return new Date(1e3*e)}function ct(e,t){return e.sort((e,t)=>t.verifiedAt.getTime()-e.verifiedAt.getTime()),e.find(e=>e.type===t)}var Z=e=>e?.linkedAccounts.find(e=>"wallet"===e.type&&"privy"===e.walletClientType)||null,xu=e=>e.linkedAccounts.filter(e=>"wallet"===e.type),zt=(e,t)=>"all-users"===t&&!Z(e)||"users-without-wallets"===t&&!xu(e)?.length;function _t(e){if(!e)return null;let t=function(e){let t=[];for(let i of e){let e=i.type;switch(i.type){case"wallet":let a={address:i.address,type:i.type,verifiedAt:qe(i.verified_at),chainType:"ethereum",chainId:i.chain_id,walletClient:"privy"===i.wallet_client_type?"privy":"unknown",walletClientType:i.wallet_client_type,connectorType:i.connector_type,recoveryMethod:i.recovery_method};t.push(a);break;case"email":let s={address:i.address,type:i.type,verifiedAt:qe(i.verified_at)};t.push(s);break;case"phone":let l={number:i.phoneNumber,type:i.type,verifiedAt:qe(i.verified_at)};t.push(l);break;case"google_oauth":let u={subject:i.subject,email:i.email,name:i.name,type:i.type,verifiedAt:qe(i.verified_at)};t.push(u);break;case"twitter_oauth":let p={subject:i.subject,username:i.username,name:i.name,type:i.type,verifiedAt:qe(i.verified_at)};t.push(p);break;case"discord_oauth":let f={subject:i.subject,username:i.username,email:i.email,type:i.type,verifiedAt:qe(i.verified_at)};t.push(f);break;case"github_oauth":let w={subject:i.subject,username:i.username,name:i.name,email:i.email,type:i.type,verifiedAt:qe(i.verified_at)};t.push(w);break;case"tiktok_oauth":let y={subject:i.subject,username:i.username,type:i.type,verifiedAt:qe(i.verified_at)};t.push(y);break;case"linkedin_oauth":let C={subject:i.subject,name:i.name,email:i.email,type:i.type,verifiedAt:qe(i.verified_at)};t.push(C);break;case"apple_oauth":let k={subject:i.subject,email:i.email,type:i.type,verifiedAt:qe(i.verified_at)};t.push(k);break;case"custom_auth":t.push({type:i.type,customUserId:i.custom_user_id,verifiedAt:qe(i.verified_at)});break;default:console.warn(`Unrecognized account type: ${e}. Please consider upgrading the Privy SDK.`)}}return t}(e.linked_accounts),i=ct(t,"wallet"),a=ct(t,"email"),s=ct(t,"phone"),l=ct(t,"google_oauth"),u=ct(t,"twitter_oauth"),p=ct(t,"discord_oauth"),f=ct(t,"github_oauth"),w=ct(t,"tiktok_oauth"),y=ct(t,"linkedin_oauth"),C=ct(t,"apple_oauth");return{id:e.id,createdAt:qe(e.created_at),linkedAccounts:t,email:a&&{address:a?.address},phone:s&&{number:s?.number},wallet:i&&{address:i.address,chainType:i.chainType,chainId:i.chainId,walletClient:i.walletClient,walletClientType:i.walletClientType,connectorType:i.connectorType,recoveryMethod:i.recoveryMethod},google:l&&{subject:l.subject,email:l.email,name:l.name},twitter:u&&{subject:u.subject,username:u.username,name:u.name},discord:p&&{subject:p.subject,username:p.username,email:p.email},github:f&&{subject:f.subject,username:f.username,name:f.name,email:f.email},tiktok:w&&{subject:w.subject,username:w.username},linkedin:y&&{subject:y.subject,name:y.name},apple:C&&{subject:C.subject,email:C.email}}}var eK="4df5e2316331463a9130964bd6078dfa",eY="https://auth.privy.io",eJ="privy:token",eQ="privy-token",eX="privy:refresh_token",e0="privy-refresh-token",e1="privy:session_transfer_token",e2="privy:caid",tn=e=>`privy:wallet:${e}`,e3="privy:connectors",e4="privy:connections",e5=1,e6=class{constructor(){this._cache={}}get(e){return this._cache[e]}put(e,t){void 0!==t?this._cache[e]=t:this.del(e)}del(e){delete this._cache[e]}getKeys(){return Object.keys(this._cache)}},e7=class{get(e){let t=localStorage.getItem(e);return null===t?void 0:JSON.parse(t)}put(e,t){void 0!==t?localStorage.setItem(e,JSON.stringify(t)):this.del(e)}del(e){localStorage.removeItem(e)}getKeys(){return Object.entries(localStorage).map(([e])=>e)}},e8="u">typeof window&&window.localStorage?new e7:new e6,rn=()=>{let e=window;if(!e.ethereum)return!1;if(on(window.ethereum,!0))return!0;if(e.ethereum.providers){for(let t of e.ethereum.providers)if(on(t,!0))return!0}return!1},vr=()=>{let e=window;if(!e.ethereum)return!1;if(on(window.ethereum,!1))return!0;if(e.ethereum.providers){for(let t of e.ethereum.providers)if(on(t,!1))return!0}return!!window.ethereum.isZerion},on=(e,t)=>!!e.isMetaMask&&(!!e.isMetaMask&&!t||!(e.isBraveWallet&&!e._events&&!e._state||e.isApexWallet||e.isAvalanche||e.isBitKeep||e.isBlockWallet||e.isKuCoinWallet||e.isMathWallet||e.isOkxWallet||e.isOKExWallet||e.isOneInchIOSWallet||e.isOneInchAndroidWallet||e.isOpera||e.isPhantom||e.isPortal||e.isRabby||e.isRainbow||e.isTokenPocket||e.isTokenary||e.isZerion)),je=()=>!!("phantom"in window&&window?.phantom?.ethereum?.isPhantom),nn=()=>{let e=window;if(!e.ethereum)return!1;if(e.ethereum.isCoinbaseWallet)return!0;if(e.ethereum.providers){for(let t of e.ethereum.providers)if(t.isCoinbaseWallet)return!0}return!1},$s=e=>!!String(e).toLowerCase().match(/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/),Vs=e=>(0,y.t)(String(e),"US"),qs=(e,t)=>{let i=e.slice(0),a=[];for(;i.length;)a.push(i.splice(0,t));return a},$t=(e,t=3,i=4)=>{if(!e)return"";if(t+i+2+3>=e.length)return e;let a=e.slice(0,2+t),s=e.slice(e.length-i,e.length);return`${a}...${s}`},Ii=e=>new Promise(t=>setTimeout(t,e)),js=(e,t={})=>{let i=t.delayMs||150,a=t.maxAttempts||270;return new Promise(async(s,l)=>{let u=!1,p=0;for(;!u&&p{u=!0,s()},(...e)=>{u=!0,l(...e)}),p+=1,await Ii(i)}u||l(Error("Exceeded max attempts before resolving function"))})},an=(e,t,i={})=>{let a=new URL(t,e);for(let[e,t]of Object.entries(i))a.searchParams.set(e,t);return a.href},Ni=e=>e.replace(/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g,""),wr=e=>"string"==typeof e?e:"0x"+e.toString(16);async function Ks(e=3e3){let t=!1,i=window;return new Promise(a=>{i.ethereum?n():(window.addEventListener("ethereum#initialized",n,{once:!0}),setTimeout(()=>{n()},e));function n(){if(t)return;t=!0,window.removeEventListener("ethereum#initialized",n);let e=[];rn()&&e.push("metamask"),je()&&e.push("phantom"),i.ethereum&&i.ethereum.isBraveWallet&&e.push("brave"),a(e)}})}function sn(e){return`eip155:${String(Number(e))}`}var e9,tt=(e,t,i)=>{let a,s=Number(e),l=t.find(e=>e.id===s);if(!l)throw new eD(`Unsupported chainId ${e}`,4901);if(!(a=i.rpcUrls[s]?i.rpcUrls[s]:l.rpcUrls.infura?.http[0]?l.rpcUrls.infura.http[0]+"/"+eK:l.rpcUrls.blast?.http[0]?l.rpcUrls.blast.http[0]+"/fe9c30fc-3bc5-4064-91e2-6ab5887f8f4d":l.rpcUrls.default?.http[0]))throw new eD(`No RPC url found for ${e}`);return a},Ys=(e,t)=>{let i=Number(e),a=t.find(e=>e.id===i);if(!a)throw new eD(`Unsupported chainId ${e}`,4901);return a.blockExplorers?.default.url},pt=({style:e,...t})=>(0,k.jsxs)("svg",{width:"1024",height:"1024",viewBox:"0 0 1024 1024",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{height:"28px",width:"28px",...e},...t,children:[(0,k.jsx)("rect",{width:"1024",height:"1024",fill:"#0052FF",rx:100,ry:100}),(0,k.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M152 512C152 710.823 313.177 872 512 872C710.823 872 872 710.823 872 512C872 313.177 710.823 152 512 152C313.177 152 152 313.177 152 512ZM420 396C406.745 396 396 406.745 396 420V604C396 617.255 406.745 628 420 628H604C617.255 628 628 617.255 628 604V420C628 406.745 617.255 396 604 396H420Z",fill:"white"})]}),te=["eth_sign","eth_populateTransactionRequest","eth_signTransaction","personal_sign","eth_signTypedData_v4"],Qs=e=>te.includes(e),tr=class extends eD{constructor(){super("Wallet timeout"),this.type="wallet_error"}},ta=class extends eD{constructor(){super("User rejected connection"),this.type="wallet_error"}},mt=e=>{if(e instanceof eD)return e;if(e?.code&&e?.reason){let t=new ts(e);return e.code===A.jK.ACTION_REJECTED&&(t.details=tc.E4001_USER_REJECTED_REQUEST),t}return e?.code?new ts(e):new eD("Unknown connector error",e)},to=class extends eR{constructor(e,t,i){super(e),this.type="provider_error",this.code=t,this.data=i}},ts=class extends to{constructor(e){super(e.message,e.code,e.data);let t=Object.values(tc).find(t=>t.eipCode===e.code);this.details=t||tc.UNKNOWN_ERROR,-32002===e.code&&(e.message?.includes("already pending for origin")?e.message?.includes("wallet_requestPermissions")?this.details=tc.E32002_CONNECTION_ALREADY_PENDING:this.details=tc.E32002_REQUEST_ALREADY_PENDING:e.message?.includes("Already processing")&&e.message.includes("eth_requestAccounts")&&(this.details=tc.E32002_WALLET_LOCKED))}},tc={UNKNOWN_ERROR:{eipCode:0,message:"Unknown error",detail:"Unknown error",retryable:!0},E4001_DEFAULT_USER_REJECTED_REQUEST:{eipCode:4001,message:"User Rejected Request",detail:"The user rejected the request.",default:!0,retryable:!0},E4100_DEFAULT_UNAUTHORIZED:{eipCode:4100,message:"Unauthorized",detail:"The requested method and/or account has not been authorized by the user.",default:!0,retryable:!1},E4200_DEFAULT_UNSUPPORTED_METHOD:{eipCode:4200,message:"Unsupported Method",detail:"The Provider does not support the requested method.",default:!0,retryable:!1},E4900_DEFAULT_DISCONNECTED:{eipCode:4900,message:"Disconnected",detail:"The Provider is disconnected from all chains.",default:!0,retryable:!0},E4901_DEFAULT_CHAIN_DISCONNECTED:{eipCode:4901,message:"Chain Disconnected",detail:"The Provider is not connected to the requested chain.",default:!0,retryable:!0},E32700_DEFAULT_PARSE_ERROR:{eipCode:-32700,message:"Parse error",detail:"Invalid JSON",default:!0,retryable:!1},E32600_DEFAULT_INVALID_REQUEST:{eipCode:-32600,message:"Invalid request",detail:"JSON is not a valid request object",default:!0,retryable:!1},E32601_DEFAULT_METHOD_NOT_FOUND:{eipCode:-32601,message:"Method not found",detail:"Method does not exist",default:!0,retryable:!1},E32602_DEFAULT_INVALID_PARAMS:{eipCode:-32602,message:"Invalid params",detail:"Invalid method parameters",default:!0,retryable:!1},E32603_DEFAULT_INTERNAL_ERROR:{eipCode:-32603,message:"Internal error",detail:"Internal JSON-RPC error",default:!0,retryable:!0},E32000_DEFAULT_INVALID_INPUT:{eipCode:-32e3,message:"Invalid input",detail:"Missing or invalid parameters",default:!0,retryable:!1},E32001_DEFAULT_RESOURCE_NOT_FOUND:{eipCode:-32001,message:"Resource not found",detail:"Requested resource not found",default:!0,retryable:!1},E32002_DEFAULT_RESOURCE_UNAVAILABLE:{eipCode:-32002,message:"Resource unavailable",detail:"Requested resource not available",default:!0,retryable:!0},E32003_DEFAULT_TRANSACTION_REJECTED:{eipCode:-32003,message:"Transaction rejected",detail:"Transaction creation failed",default:!0,retryable:!0},E32004_DEFAULT_METHOD_NOT_SUPPORTED:{eipCode:-32004,message:"Method not supported",detail:"Method is not implemented",default:!0,retryable:!1},E32005_DEFAULT_LIMIT_EXCEEDED:{eipCode:-32005,message:"Limit exceeded",detail:"Request exceeds defined limit",default:!0,retryable:!1},E32006_DEFAULT_JSON_RPC_VERSION_NOT_SUPPORTED:{eipCode:-32006,message:"JSON-RPC version not supported",detail:"Version of JSON-RPC protocol is not supported",default:!0,retryable:!1},E32002_CONNECTION_ALREADY_PENDING:{eipCode:-32002,message:"Connection request already pending",detail:"Don’t see your wallet modal? Check your other browser windows.",retryable:!1},E32002_REQUEST_ALREADY_PENDING:{eipCode:-32002,message:"Resource request already pending",detail:"Don’t see your wallet modal? Check your other browser windows.",retryable:!1},E32002_WALLET_LOCKED:{eipCode:-32002,message:"Wallet might be locked",detail:"Don’t see your wallet modal? Check your other browser windows.",retryable:!1},E4001_USER_REJECTED_REQUEST:{eipCode:4001,message:"Signature rejected",detail:"Please try signing again.",retryable:!0}},td={ERROR_USER_EXISTS:{message:"User already exists for this address",detail:"Try another address!",retryable:!1},ERROR_TIMED_OUT:{message:"Wallet request timed out",detail:"Please try connecting again.",retryable:!0},ERROR_WALLET_CONNECTION:{message:"Could not log in with wallet",detail:"Please try connecting again.",retryable:!0},ERROR_USER_REJECTED_CONNECTION:{message:"You rejected the request",detail:"Please try connecting again.",retryable:!0},...tc},th=12e4,Li=(e=new tr,t=th)=>new Promise((i,a)=>setTimeout(()=>{a(e)},t)),tu=class{constructor(e){this.removeListener=(e,t)=>{if(this.walletProvider)try{return this.walletProvider.removeListener(e,t)}catch{console.warn("Unable to remove wallet provider listener")}},this.setWalletProvider=e=>{this.walletProvider&&this._subscriptions.forEach(e=>{this.removeListener(e.eventName,e.listener)}),this.walletProvider=e,this._subscriptions.forEach(e=>{this.walletProvider?.on(e.eventName,e.listener)})},this.walletProvider=e,this._subscriptions=[]}on(e,t){if(this.walletProvider)return this.walletProvider.on(e,t);this._subscriptions.push({eventName:e,listener:t})}async request(e){if(!this.walletProvider)throw new eD(`A wallet request of type ${e.method} was made before setting a wallet provider.`);return Promise.race([this.walletProvider.request(e),Li()]).catch(e=>{throw mt(e)})}},tp=class extends Error{constructor(e,t,i){super(e),this.code=t,this.data=i}},tm=class extends w.Z{constructor(e,t,i,a,s=1){super(),this.walletProxy=e,this.address=t,this.chainId=s,this.rpcConfig=i,this.chains=a,this.provider=new l.c(tt(s,this.chains,i))}async handleSendTransaction(e){if(!e.params||!Array.isArray(e.params))throw new tp(`Invalid params for ${e.method}`,4200);let t=e.params[0];if(!await At()||!this.address)throw new tp("Disconnected",4900);return(await el(t)).transactionHash}handleSwitchEthereumChain(e){let t;if(!e.params||!Array.isArray(e.params))throw new tp(`Invalid params for ${e.method}`,4200);if("string"==typeof e.params[0])t=e.params[0];else if("chainId"in e.params[0]&&"string"==typeof e.params[0].chainId)t=e.params[0].chainId;else throw new tp(`Invalid params for ${e.method}`,4200);this.chainId=Number(t),this.provider=new l.c(tt(this.chainId,this.chains,this.rpcConfig)),this.emit("chainChanged",t)}async handlePersonalSign(e){if(!e.params||!Array.isArray(e.params))throw Error("Invalid params for eth_estimateGas");let t=e.params[0];return await Xs(t)}async handleEstimateGas(e){if(!e.params||!Array.isArray(e.params))throw Error("Invalid params for eth_estimateGas");delete e.params[0].gasPrice,delete e.params[0].maxFeePerGas,delete e.params[0].maxPriorityFeePerGas;let t={...e.params[0],chainId:wr(this.chainId)};try{return await this.provider.send("eth_estimateGas",[t])}catch{return delete t.from,await this.provider.send("eth_estimateGas",[t])}}async request(e){switch(console.debug("Embedded1193Provider.request() called with args",e),e.method){case"eth_accounts":case"eth_requestAccounts":return this.address?[this.address]:[];case"eth_chainId":return wr(this.chainId);case"eth_estimateGas":return this.handleEstimateGas(e);case"eth_sendTransaction":return this.handleSendTransaction(e);case"wallet_switchEthereumChain":return this.handleSwitchEthereumChain(e);case"personal_sign":return this.handlePersonalSign(e)}if(!Qs(e.method))return this.provider.send(e.method,e.params);{let t=await At();if(await tl(),!t||!this.address)throw new tp("Disconnected",4900);try{return(await this.walletProxy.rpc({address:this.address,accessToken:t,request:{method:e.method,params:e.params}})).response.data}catch(e){throw console.error(e),new tp("Disconnected",4900)}}}async connect(){let e=await At();if(!e||!this.address)return null;try{return(await this.walletProxy.connect({address:this.address,accessToken:e})).address}catch(e){return console.error(e),null}}},tf=class extends tu{constructor(e){super(e)}},tg=class extends tu{constructor(e){super(e)}sendAsync(e,t){throw Error("sendAsync is no longer supported by EIP-1193. Use the request method instead.")}},Du=(e,t)=>"coinbase_wallet"===t?e.message.includes("addEthereumChain"):4902===e.code||e.message?.includes("4902"),tw=class extends w.Z{constructor(e,t,i){super(),this.onAccountsChanged=e=>{0===e.length?this.onDisconnect():this.syncAccounts(e)},this.onChainChanged=e=>{this.wallets.forEach(t=>{t.chainId=sn(e),"privy"===this.walletClientType&&e8.put(tn(t.address),e)}),this.emit("walletsUpdated")},this.onDisconnect=()=>{this.connected=!1,this.wallets=[],this.emit("walletsUpdated")},this.onConnect=()=>{this.connected=!0,this.syncAccounts()},this.wallets=[],this.walletClientType=e,this.chains=t,this.defaultChain=i,this.connected=!1,this.initialized=!1}buildConnectedWallet(e,t){let n=async()=>!!this.wallets.find(t=>(0,a.Kn)(t.address)===(0,a.Kn)(e));return{address:(0,a.Kn)(e),chainId:t,switchChain:async i=>{let s,l;if(!n)throw new eD("Wallet is not currently connected.");let u=this.wallets.find(t=>a.Kn(t.address)===a.Kn(e))?.chainId;if(!u)throw new eD("Unable to determine current chainId.");if("number"==typeof i?(s=`0x${i.toString(16)}`,l=i):(s=i,l=Number(i)),u===sn(s))return;let p=this.chains.find(e=>e.id===l);if(!p)throw new eD(`Unsupported chainId: ${i}`);let m=async()=>{await this.proxyProvider.request({method:"wallet_switchEthereumChain",params:[{chainId:s}]})};try{return await m()}catch(e){if(Du(e,this.walletClientType))return await this.proxyProvider.request({method:"wallet_addEthereumChain",params:[{chainId:s,chainName:p.name,nativeCurrency:p.nativeCurrency,rpcUrls:[p.rpcUrls.public?.http[0]??""],blockExplorerUrls:[p.blockExplorers?.default.url??""]}]}),m();throw"rainbow"===this.walletClientType&&e.message?.includes("wallet_switchEthereumChain")?new eD(`Rainbow does not support the chainId ${t}`):e}},connectedAt:Date.now(),walletClientType:this.walletClientType,connectorType:this.connectorType,isConnected:n,getEthereumProvider:async()=>{if(!await n())throw new eD("Wallet is not currently connected.");return this.proxyProvider},getEthersProvider:async()=>{if(!await n())throw new eD("Wallet is not currently connected.");return new s.Q(new tf(this.proxyProvider))},getWeb3jsProvider:async()=>{if(!await n())throw new eD("Wallet is not currently connected.");return new tg(this.proxyProvider)},sign:async e=>{if(!await n())throw new eD("Wallet is not currently connected.");return await this.sign(e)},disconnect:()=>{this.disconnect()}}}async syncAccounts(e){let t=e;if(void 0===t){let e=await this.proxyProvider.request({method:"eth_accounts"});Array.isArray(e)&&(t=e)}if(!t||!Array.isArray(t)||t.length<=0||!t[0])return;let i=t[0],s=(0,a.Kn)(i),l=[],u;if("privy"===this.walletClientType){let e=e8.get(tn(s));this.chains.find(t=>t.id===Number(e))||(e8.del(tn(s)),e=null),u=e||`0x${this.defaultChain.id.toString(16)}`;try{await this.proxyProvider.request({method:"wallet_switchEthereumChain",params:[{chainId:u}]})}catch{console.warn(`Unable to switch embedded wallet to chain ID ${u} on initialization`)}}else try{let e=await this.proxyProvider.request({method:"eth_chainId"});if("string"!=typeof e)throw Error("Invalid chainId returned from provider");u=e}catch(e){console.warn("Failed to get chainId from provider, defaulting to 0x1",e),u="0x1"}let p=sn(u);l.find(e=>(0,a.Kn)(e.address)===s)||l.push(this.buildConnectedWallet((0,a.Kn)(i),p)),cn(l,this.wallets)||(this.wallets=l,this.emit("walletsUpdated"))}async getConnectedWallet(){let e=await this.proxyProvider.request({method:"eth_accounts"});return this.wallets.sort((e,t)=>t.connectedAt-e.connectedAt).find(t=>e.find(e=>(0,a.Kn)(e)===(0,a.Kn)(t.address)))||null}async isConnected(){let e=await this.proxyProvider.request({method:"eth_accounts"});return Array.isArray(e)&&e.length>0}async sign(e){return await this.connect({showPrompt:!1}),new s.Q(new tf(this.proxyProvider)).getSigner().signMessage(e)}subscribeListeners(){this.proxyProvider.on("accountsChanged",this.onAccountsChanged),this.proxyProvider.on("chainChanged",this.onChainChanged),this.proxyProvider.on("disconnect",this.onDisconnect),this.proxyProvider.on("connect",this.onConnect)}unsubscribeListeners(){this.proxyProvider.removeListener("accountsChanged",this.onAccountsChanged),this.proxyProvider.removeListener("chainChanged",this.onChainChanged),this.proxyProvider.removeListener("disconnect",this.onDisconnect),this.proxyProvider.removeListener("connect",this.onConnect)}},Fu=e=>{let t=`https://mainnet.infura.io/v3/${eK}`;return e.makeWeb3Provider(t,1)},tx=class extends tw{constructor(e,t){super("coinbase_wallet",e,t),this.connectorType="coinbase_wallet",this.proxyProvider=new tu,this.subscribeListeners(),e9||(e9=new C.ZP({appName:"Privy",darkMode:!1,headlessMode:!1,enableMobileWalletLink:!0})),this.proxyProvider.setWalletProvider(Fu(e9)),this.syncAccounts().then(()=>{this.emit("initialized"),this.initialized=!0})}async connect(e){return e.showPrompt&&await this.promptConnection(),await this.isConnected()?this.getConnectedWallet():null}disconnect(){e9.disconnect()}get walletBranding(){return{name:"Coinbase Wallet",icon:pt}}async promptConnection(){try{let e=await this.proxyProvider.request({method:"eth_requestAccounts"});if(!e||0===e.length||!e[0])throw new eD("Unable to retrieve accounts");this.connected=!0,await this.syncAccounts([e[0]])}catch(e){throw mt(e)}}},$o=({...e})=>(0,k.jsx)("svg",{width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:(0,k.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M2.37126 11.0323C2.37126 12.696 3.90598 13.4421 5.40654 13.4468C8.91753 13.4468 12.8021 11.2897 12.7819 7.67984C12.7673 5.07728 10.3748 2.86167 7.54357 2.88296C4.8495 2.88296 2.21821 4.6411 2.21803 7.03628C2.21803 7.67951 2.58722 8.30178 3.55231 8.37184C2.74763 9.16826 2.37126 10.1225 2.37126 11.0323ZM7.55283 8.68012C8.11562 8.68012 8.57186 8.13217 8.57186 7.45624C8.57186 6.78032 8.11562 6.23237 7.55283 6.23237C6.99003 6.23237 6.53379 6.78032 6.53379 7.45624C6.53379 8.13217 6.99003 8.68012 7.55283 8.68012ZM10.4747 8.68012C11.0375 8.68012 11.4937 8.13217 11.4937 7.45625C11.4937 6.78032 11.0375 6.23237 10.4747 6.23237C9.91186 6.23237 9.45562 6.78032 9.45562 7.45625C9.45562 8.13217 9.91186 8.68012 10.4747 8.68012Z",fill:e.color||"var(--privy-color-foreground-3)"})}),ty=class extends tw{constructor(e,t,i){super("privy",t,i),this.connectorType="embedded",this.proxyProvider=e,this.subscribeListeners(),this.syncAccounts().then(()=>{this.emit("initialized"),this.initialized=!0})}async connect(e){return await this.isConnected()?(await this.proxyProvider.request({method:"wallet_switchEthereumChain",params:[wr(e?.chainId||"0x1")]}),this.getConnectedWallet()):null}get walletBranding(){return{name:"Privy Wallet",icon:$o}}disconnect(){this.connected=!1}async promptConnection(){}},Ce=({style:e,...t})=>(0,k.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",xmlSpace:"preserve",x:0,y:0,viewBox:"0 0 318.6 318.6",width:"28",height:"28",style:{height:"28px",width:"28px",...e},...t,children:[(0,k.jsx)("style",{children:".s1{stroke-linecap:round;stroke-linejoin:round}.s2{fill:#e4761b;stroke:#e4761b}.s3{fill:#f6851b;stroke:#f6851b}"}),(0,k.jsx)("path",{fill:"#e2761b",stroke:"#e2761b",className:"s1",d:"m274.1 35.5-99.5 73.9L193 65.8z"}),(0,k.jsx)("path",{d:"m44.4 35.5 98.7 74.6-17.5-44.3zm193.9 171.3-26.5 40.6 56.7 15.6 16.3-55.3zm-204.4.9L50.1 263l56.7-15.6-26.5-40.6z",className:"s1 s2"}),(0,k.jsx)("path",{d:"m103.6 138.2-15.8 23.9 56.3 2.5-2-60.5zm111.3 0-39-34.8-1.3 61.2 56.2-2.5zM106.8 247.4l33.8-16.5-29.2-22.8zm71.1-16.5 33.9 16.5-4.7-39.3z",className:"s1 s2"}),(0,k.jsx)("path",{fill:"#d7c1b3",stroke:"#d7c1b3",className:"s1",d:"m211.8 247.4-33.9-16.5 2.7 22.1-.3 9.3zm-105 0 31.5 14.9-.2-9.3 2.5-22.1z"}),(0,k.jsx)("path",{fill:"#233447",stroke:"#233447",className:"s1",d:"m138.8 193.5-28.2-8.3 19.9-9.1zm40.9 0 8.3-17.4 20 9.1z"}),(0,k.jsx)("path",{fill:"#cd6116",stroke:"#cd6116",className:"s1",d:"m106.8 247.4 4.8-40.6-31.3.9zM207 206.8l4.8 40.6 26.5-39.7zm23.8-44.7-56.2 2.5 5.2 28.9 8.3-17.4 20 9.1zm-120.2 23.1 20-9.1 8.2 17.4 5.3-28.9-56.3-2.5z"}),(0,k.jsx)("path",{fill:"#e4751f",stroke:"#e4751f",className:"s1",d:"m87.8 162.1 23.6 46-.8-22.9zm120.3 23.1-1 22.9 23.7-46zm-64-20.6-5.3 28.9 6.6 34.1 1.5-44.9zm30.5 0-2.7 18 1.2 45 6.7-34.1z"}),(0,k.jsx)("path",{d:"m179.8 193.5-6.7 34.1 4.8 3.3 29.2-22.8 1-22.9zm-69.2-8.3.8 22.9 29.2 22.8 4.8-3.3-6.6-34.1z",className:"s3"}),(0,k.jsx)("path",{fill:"#c0ad9e",stroke:"#c0ad9e",className:"s1",d:"m180.3 262.3.3-9.3-2.5-2.2h-37.7l-2.3 2.2.2 9.3-31.5-14.9 11 9 22.3 15.5h38.3l22.4-15.5 11-9z"}),(0,k.jsx)("path",{fill:"#161616",stroke:"#161616",className:"s1",d:"m177.9 230.9-4.8-3.3h-27.7l-4.8 3.3-2.5 22.1 2.3-2.2h37.7l2.5 2.2z"}),(0,k.jsx)("path",{fill:"#763d16",stroke:"#763d16",className:"s1",d:"m278.3 114.2 8.5-40.8-12.7-37.9-96.2 71.4 37 31.3 52.3 15.3 11.6-13.5-5-3.6 8-7.3-6.2-4.8 8-6.1zM31.8 73.4l8.5 40.8-5.4 4 8 6.1-6.1 4.8 8 7.3-5 3.6 11.5 13.5 52.3-15.3 37-31.3-96.2-71.4z"}),(0,k.jsx)("path",{d:"m267.2 153.5-52.3-15.3 15.9 23.9-23.7 46 31.2-.4h46.5zm-163.6-15.3-52.3 15.3-17.4 54.2h46.4l31.1.4-23.6-46zm71 26.4 3.3-57.7 15.2-41.1h-67.5l15 41.1 3.5 57.7 1.2 18.2.1 44.8h27.7l.2-44.8z",className:"s3"})]}),tb=class extends tw{constructor(e,t){super("metamask",e,t),this.connectorType="injected",this.proxyProvider=new tu,this.subscribeListeners();let i=window,a=i.ethereum;for(let e of i.ethereum.providers||[])if(e.isMetaMask){a=e;break}this.proxyProvider.setWalletProvider(a),this.syncAccounts().then(()=>{this.emit("initialized"),this.initialized=!0})}async connect(e){return e.showPrompt&&await this.promptConnection(),await this.isConnected()?this.getConnectedWallet():null}get walletBranding(){return{name:"MetaMask",icon:Ce}}disconnect(){console.warn("Metamask does not support programmatic disconnect.")}async promptConnection(){try{!T.tq&&rn()&&await this.proxyProvider.request({method:"wallet_requestPermissions",params:[{eth_accounts:{}}]});let e=await this.proxyProvider.request({method:"eth_requestAccounts"});if(!e||0===e.length||!e[0])throw new eD("Unable to retrieve accounts");await this.syncAccounts([e[0]])}catch(e){throw mt(e)}}},Ke=({style:e,...t})=>(0,k.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"108",height:"108",viewBox:"0 0 108 108",fill:"none",style:{height:"28px",width:"28px",...e},...t,children:[(0,k.jsx)("rect",{width:"108",height:"108",rx:"23",fill:"#AB9FF2"}),(0,k.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M46.5267 69.9229C42.0054 76.8509 34.4292 85.6182 24.348 85.6182C19.5824 85.6182 15 83.6563 15 75.1342C15 53.4305 44.6326 19.8327 72.1268 19.8327C87.768 19.8327 94 30.6846 94 43.0079C94 58.8258 83.7355 76.9122 73.5321 76.9122C70.2939 76.9122 68.7053 75.1342 68.7053 72.314C68.7053 71.5783 68.8275 70.7812 69.0719 69.9229C65.5893 75.8699 58.8685 81.3878 52.5754 81.3878C47.993 81.3878 45.6713 78.5063 45.6713 74.4598C45.6713 72.9884 45.9768 71.4556 46.5267 69.9229ZM83.6761 42.5794C83.6761 46.1704 81.5575 47.9658 79.1875 47.9658C76.7816 47.9658 74.6989 46.1704 74.6989 42.5794C74.6989 38.9885 76.7816 37.1931 79.1875 37.1931C81.5575 37.1931 83.6761 38.9885 83.6761 42.5794ZM70.2103 42.5795C70.2103 46.1704 68.0916 47.9658 65.7216 47.9658C63.3157 47.9658 61.233 46.1704 61.233 42.5795C61.233 38.9885 63.3157 37.1931 65.7216 37.1931C68.0916 37.1931 70.2103 38.9885 70.2103 42.5795Z",fill:"#FFFDF8"})]}),tC=class extends tw{constructor(e,t){super("phantom",e,t),this.connectorType="injected",this.proxyProvider=new tu,this.subscribeListeners(),this.proxyProvider.setWalletProvider(window.phantom.ethereum),this.syncAccounts().then(()=>{this.emit("initialized"),this.initialized=!0})}async connect(e){return e.showPrompt&&await this.promptConnection(),await this.isConnected()?this.getConnectedWallet():null}get walletBranding(){return{name:"Phantom",icon:Ke}}disconnect(){console.warn("Phantom does not support programmatic disconnect.")}async promptConnection(){try{let e=await this.proxyProvider.request({method:"eth_requestAccounts"});if(!e||0===e.length||!e[0])throw new eD("Unable to retrieve accounts");await this.syncAccounts([e[0]])}catch(e){throw mt(e)}}};function il(e){return(0,k.jsx)("link",{rel:"prefetch",href:e.src})}var x=()=>{throw Error("You need to wrap your application with the initialized with your app id.")},tj="LANDING",tk=(0,u.createContext)({ready:!1,app:null,currentScreen:tj,lastScreen:tj,navigate:x,navigateBack:x,resetNavigation:x,setModalData:x,outerClickRef:null}),ll=e=>{let t=e.appConfig,i=e.authenticated,a=e.visible,[s,l]=(0,u.useState)(e.initialScreen||tj),[p,f]=(0,u.useState)(e.initialScreen||tj);(0,u.useEffect)(()=>{i||l(tj)},[i]),(0,u.useEffect)(()=>{a||(f(tj),l(tj))},[a]),(0,u.useEffect)(()=>{e.initialScreen&&s===tj&&(l(e.initialScreen),f(e.initialScreen))},[e.initialScreen]);let w=e.initialScreen&&s===tj?e.initialScreen:s,y=(0,u.useRef)(null),C={ready:!!t?.id,app:t,data:e.data,setModalData:e.setModalData,currentScreen:w,lastScreen:p,navigate:e=>{f(s),l(e)},navigateBack:()=>{l(p)},resetNavigation:()=>{e.setInitialScreen(null),f(tj),l(tj)},outerClickRef:y};return(0,k.jsxs)(tk.Provider,{value:C,children:[("string"==typeof t?.appearance?.logo||t?.appearance?.logo?.type==="img")&&(0,k.jsx)(il,{src:"string"==typeof t.appearance.logo?t.appearance.logo:t.appearance.logo.props.src}),e.children]})},v=()=>(0,u.useContext)(tk),qo=({style:e,...t})=>{let{app:i}=v();return(0,k.jsxs)("svg",{width:"28",height:"28",viewBox:"0 0 28 28",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{height:"28px",width:"28px",...e},...t,children:[(0,k.jsx)("rect",{width:"28",height:"28",rx:"3",fill:i?.appearance.palette.colorScheme==="dark"?"#3396ff":"#141414"}),(0,k.jsx)("g",{clipPath:"url(#clip0_1765_9946)",children:(0,k.jsx)("path",{d:"M8.09448 10.3941C11.3558 7.20196 16.6442 7.20196 19.9055 10.3941L20.2982 10.7782C20.3369 10.8157 20.3677 10.8606 20.3887 10.9102C20.4097 10.9599 20.4206 11.0132 20.4206 11.0671C20.4206 11.121 20.4097 11.1744 20.3887 11.224C20.3677 11.2737 20.3369 11.3186 20.2982 11.3561L18.9554 12.6702C18.9158 12.7086 18.8628 12.7301 18.8077 12.7301C18.7526 12.7301 18.6996 12.7086 18.66 12.6702L18.1198 12.1415C15.8448 9.91503 12.1557 9.91503 9.88015 12.1415L9.30167 12.7075C9.26207 12.7459 9.20909 12.7673 9.15395 12.7673C9.0988 12.7673 9.04582 12.7459 9.00622 12.7075L7.66346 11.3934C7.62475 11.3559 7.59397 11.3109 7.57295 11.2613C7.55193 11.2117 7.5411 11.1583 7.5411 11.1044C7.5411 11.0505 7.55193 10.9971 7.57295 10.9475C7.59397 10.8979 7.62475 10.8529 7.66346 10.8154L8.09448 10.3941ZM22.6829 13.1115L23.8776 14.2814C23.9163 14.319 23.9471 14.3639 23.9681 14.4135C23.9892 14.4632 24 14.5165 24 14.5704C24 14.6243 23.9892 14.6777 23.9681 14.7273C23.9471 14.777 23.9163 14.8219 23.8776 14.8594L18.4893 20.1332C18.4102 20.2101 18.3042 20.2531 18.1938 20.2531C18.0835 20.2531 17.9775 20.2101 17.8984 20.1332L14.0743 16.3901C14.0545 16.3708 14.0279 16.36 14.0003 16.36C13.9726 16.36 13.9461 16.3708 13.9263 16.3901L10.1021 20.1332C10.023 20.2101 9.91703 20.2531 9.8067 20.2531C9.69636 20.2531 9.59038 20.2101 9.51124 20.1332L4.12236 14.8594C4.08365 14.8219 4.05287 14.777 4.03185 14.7273C4.01083 14.6777 4 14.6243 4 14.5704C4 14.5165 4.01083 14.4632 4.03185 14.4135C4.05287 14.3639 4.08365 14.319 4.12236 14.2814L5.31767 13.1115C5.39678 13.0348 5.50265 12.9919 5.61285 12.9919C5.72305 12.9919 5.82892 13.0348 5.90803 13.1115L9.73216 16.8546C9.75194 16.874 9.7785 16.8848 9.80616 16.8848C9.83381 16.8848 9.86037 16.874 9.88015 16.8546L13.7043 13.1115C13.7834 13.0346 13.8894 12.9916 13.9997 12.9916C14.1101 12.9916 14.216 13.0346 14.2952 13.1115L18.1198 16.8546C18.1396 16.874 18.1662 16.8848 18.1938 16.8848C18.2215 16.8848 18.2481 16.874 18.2678 16.8546L22.092 13.1115C22.1711 13.0346 22.2771 12.9916 22.3874 12.9916C22.4977 12.9916 22.6037 13.0346 22.6829 13.1115Z",fill:"white"})}),(0,k.jsx)("defs",{children:(0,k.jsx)("clipPath",{id:"clip0_1765_9946",children:(0,k.jsx)("rect",{width:"20",height:"12.2531",fill:"white",transform:"translate(4 8)"})})})]})},fn=e=>{let t;try{t=new URL(e).hostname}catch{return}for(let[e,i]of Object.entries(t_))if(i.hostname===t)return{walletClientType:e,entry:i}},t_={metamask:{id:"c57ca95b47569778a828d19178114f4db188b89b763c899ba0be274e97267d96",displayName:"MetaMask",image_id:"5195e9db-94d8-4579-6f11-ef553be95100",hostname:"metamask.io",mobile:{native:"metamask:"}},trust:{id:"4622a2b2d6af1c9844944291e5e7351a6aa24cd7b23099efac1b2fd875da31a0",displayName:"Trust",image_id:"0528ee7e-16d1-4089-21e3-bbfb41933100",hostname:"trustwallet.com",mobile:{universal:"https://link.trustwallet.com"}},safe:{id:"225affb176778569276e484e1b92637ad061b01e13a048b35a9d280c3b58970f",displayName:"Safe",image_id:"a1cb2777-f8f9-49b0-53fd-443d20ee0b00",hostname:"safe.global",mobile:{universal:"https://app.safe.global/"}},rainbow:{id:"1ae92b26df02f0abca6304df07debccd18262fdf5fe82daa81593582dac9a369",displayName:"Rainbow",image_id:"7a33d7f1-3d12-4b5c-f3ee-5cd83cb1b500",hostname:"rainbow.me",mobile:{universal:"https://rnbwapp.com"}},uniswap:{id:"c03dfee351b6fcc421b4494ea33b9d4b92a984f87aa76d1663bb28705e95034a",displayName:"Uniswap",image_id:"bff9cf1f-df19-42ce-f62a-87f04df13c00",hostname:"uniswap.org",mobile:{universal:"https://uniswap.org/app"}},zerion:{id:"ecc4036f814562b41a5268adc86270fba1365471402006302e70169465b7ac18",displayName:"Zerion",image_id:"f216b371-96cf-409a-9d88-296392b85800",hostname:"zerion.io",mobile:{universal:"https://wallet.zerion.io"}},argent:{id:"bc949c5d968ae81310268bf9193f9c9fb7bb4e1283e1284af8f2bd4992535fd6",displayName:"Argent",image_id:"215158d2-614b-49c9-410f-77aa661c3900",hostname:"www.argent.xyz",mobile:{universal:"https://www.argent.xyz/app"}},spot:{id:"74f8092562bd79675e276d8b2062a83601a4106d30202f2d509195e30e19673d",displayName:"Spot",image_id:"1bf33a89-b049-4a1c-d1f6-4dd7419ee400",hostname:"www.spot-wallet.com",mobile:{universal:"https://spot.so"}},omni:{id:"afbd95522f4041c71dd4f1a065f971fd32372865b416f95a0b1db759ae33f2a7",displayName:"Omni",image_id:"2cd67b4c-282b-4809-e7c0-a88cd5116f00",hostname:"omni.app",mobile:{universal:"https://links.omni.app"}},cryptocom:{id:"f2436c67184f158d1beda5df53298ee84abfc367581e4505134b5bcf5f46697d",displayName:"Crypto.com",image_id:"7c5ff577-a68d-49c5-02cd-3d83637b0b00",hostname:"crypto.com",mobile:{universal:"https://wallet.crypto.com"}},blockchain:{id:"84b43e8ddfcd18e5fcb5d21e7277733f9cccef76f7d92c836d0e481db0c70c04",displayName:"Blockchain",image_id:"6f913b80-86c0-46f9-61ca-cc90a1805900",hostname:"www.blockchain.com",mobile:{universal:"https://www.blockchain.com"}},safepal:{id:"0b415a746fb9ee99cce155c2ceca0c6f6061b1dbca2d722b3ba16381d0562150",displayName:"SafePal",image_id:"252753e7-b783-4e03-7f77-d39864530900",hostname:"safepal.com",mobile:{universal:"https://link.safepal.io"}},bitkeep:{id:"38f5d18bd8522c244bdd70cb4a68e0e718865155811c043f052fb9f1c51de662",displayName:"BitKeep",image_id:"3f7075d0-4ab7-4db5-404d-3e4c05e6fe00",hostname:"bitkeep.com",mobile:{universal:"https://bkapp.vip"}},zengo:{id:"9414d5a85c8f4eabc1b5b15ebe0cd399e1a2a9d35643ab0ad22a6e4a32f596f0",displayName:"ZenGo",image_id:"cfc07342-23ea-4f3f-f071-ec9d2cd86b00",hostname:"zengo.com",mobile:{universal:"https://get.zengo.com/"}},"1inch":{id:"c286eebc742a537cd1d6818363e9dc53b21759a1e8e5d9b263d0c03ec7703576",displayName:"1inch",image_id:"52b1da3c-9e72-40ae-5dac-6142addd9c00",hostname:"wallet.1inch.io",mobile:{universal:"https://wallet.1inch.io/wc/"}},binance:{id:"8a0ee50d1f22f6651afcae7eb4253e52a3310b90af5daef78a8c4929a9bb99d4",displayName:"Binance",image_id:"ebac7b39-688c-41e3-7912-a4fefba74600",hostname:"www.binance.com",mobile:{universal:"https://app.binance.com/cedefi"}},exodus:{id:"e9ff15be73584489ca4a66f64d32c4537711797e30b6660dbcb71ea72a42b1f4",displayName:"Exodus",image_id:"4c16cad4-cac9-4643-6726-c696efaf5200",hostname:"exodus.com",mobile:{universal:"https://exodus.com/m"}},mew_wallet:{id:"f5b4eeb6015d66be3f5940a895cbaa49ef3439e518cd771270e6b553b48f31d2",displayName:"MEW wallet",image_id:"e2024511-2c9b-46d7-3111-52df3d241700",hostname:"mewwallet.com",mobile:{universal:"https://mewwallet.com"}},alphawallet:{id:"138f51c8d00ac7b9ac9d8dc75344d096a7dfe370a568aa167eabc0a21830ed98",displayName:"AlphaWallet",image_id:"5b1cddfb-056e-4e78-029a-54de5d70c500",hostname:"alphawallet.com",mobile:{universal:"https://aw.app"}},keyring_pro:{id:"47bb07617af518642f3413a201ec5859faa63acb1dd175ca95085d35d38afb83",displayName:"KEYRING PRO",image_id:"dda0f0fb-34e8-4a57-dcea-b008e7d1ff00",hostname:"keyring.app",mobile:{universal:"https://keyring.app/"}},mathwallet:{id:"7674bb4e353bf52886768a3ddc2a4562ce2f4191c80831291218ebd90f5f5e26",displayName:"MathWallet",image_id:"26a8f588-3231-4411-60ce-5bb6b805a700",hostname:"mathwallet.org",mobile:{universal:"https://www.mathwallet.org"}},unstoppable:{id:"8308656f4548bb81b3508afe355cfbb7f0cb6253d1cc7f998080601f838ecee3",displayName:"Unstoppable",image_id:"4725dda0-4471-4d0f-7adf-6bbe8b929c00",hostname:"unstoppabledomains.com",mobile:{universal:"https://unstoppabledomains.com/mobile"}},obvious:{id:"031f0187049b7f96c6f039d1c9c8138ff7a17fd75d38b34350c7182232cc29aa",displayName:"Obvious",image_id:"61abe2ca-b06d-4a8b-de3e-8326f523e900",hostname:"obvious.technology",mobile:{universal:"https://wallet.obvious.technology"}},ambire:{id:"2c81da3add65899baeac53758a07e652eea46dbb5195b8074772c62a77bbf568",displayName:"Ambire",image_id:"c39b3a16-1a38-4588-f089-cb7aeb584700",hostname:"www.ambire.com",mobile:{universal:"https://mobile.ambire.com"}},internet_money_wallet:{id:"dd43441a6368ec9046540c46c5fdc58f79926d17ce61a176444568ca7c970dcd",displayName:"Internet Money Wallet",image_id:"204b2240-5ce4-4996-6ec4-f06a22726900",hostname:"internetmoney.io",mobile:{universal:"https://internetmoney.io"}},coin98:{id:"2a3c89040ac3b723a1972a33a125b1db11e258a6975d3a61252cd64e6ea5ea01",displayName:"Coin98",image_id:"fc460647-ea95-447a-99f0-1bff8fa4be00",hostname:"coin98.com",mobile:{universal:"https://coin98.services"}},abc_wallet:{id:"b956da9052132e3dabdcd78feb596d5194c99b7345d8c4bd7a47cabdcb69a25f",displayName:"ABC Wallet",image_id:"f9854c79-14ba-4987-42e1-4a82abbf5700",hostname:"myabcwallet.io",mobile:{universal:"https://abcwalletconnect.page.link"}},arculus_wallet:{id:"0e4915107da5b3408b38e248f7a710f4529d54cd30e9d12ff0eb886d45c18e92",displayName:"Arculus Wallet",image_id:"f78dab27-7165-4a3d-fdb1-fcff06c0a700",hostname:"www.getarculus.com",mobile:{universal:"https://gw.arculus.co/app"}},haha:{id:"719bd888109f5e8dd23419b20e749900ce4d2fc6858cf588395f19c82fd036b3",displayName:"HaHa",image_id:"79285c9f-2630-451e-0680-c71b42fb7400",hostname:"www.haha.me",mobile:{universal:"https://haha.me"}},cling_wallet:{id:"942d0e22a7e6b520b0a03abcafc4dbe156a1fc151876e3c4a842f914277278ef",displayName:"Cling Wallet",image_id:"2d8006c3-852b-458a-d6b0-916c5ba76800",hostname:"clingon.io",mobile:{universal:"https://cling.carrieverse.com/apple-app-site-association"}},broearn:{id:"8ff6eccefefa7506339201bc33346f92a43118d6ff7d6e71d499d8187a1c56a2",displayName:"Broearn",image_id:"339b9e9d-e2a7-46eb-4ed3-272321257a00",hostname:"www.broearn.com",mobile:{universal:"https://www.broearn.com/link/wallet/"}},copiosa:{id:"07f99a5d9849bb049d74830012b286f8b238e72b0337933ef22b84947409db80",displayName:"Copiosa",image_id:"cae1be94-9f53-4eba-b915-f6e381d5a500",hostname:"copiosa.io",mobile:{universal:"https://copiosa.io/action/"}},burrito_wallet:{id:"8821748c25de9dbc4f72a691b25a6ddad9d7df12fa23333fd9c8b5fdc14cc819",displayName:"Burrito Wallet",image_id:"7eec7187-3f48-4fda-53bb-b0ad55749a00",hostname:"burritowallet.com",mobile:{universal:"https://burritowallet.com/wc?uri="}},enjin_wallet:{id:"bdc9433ffdaee55d31737d83b931caa1f17e30666f5b8e03eea794bac960eb4a",displayName:"Enjin Wallet",image_id:"add9626b-a5fa-4c12-178c-e5584e6dcd00",hostname:"enjin.io",mobile:{universal:"https://deeplink.wallet.enjin.io/"}},plasma_wallet:{id:"cbe13eb482c76f1fa401ff4c84d9acd0b8bc9af311ca0620a0b192fb28359b4e",displayName:"Plasma Wallet",image_id:"c268e78d-ffb0-4c8b-5cad-04c3add48500",hostname:"plasma-wallet.com",mobile:{universal:"https://plasma-wallet.com"}},avacus:{id:"94f785c0c8fb8c4f38cd9cd704416430bcaa2137f27e1468782d624bcd155a43",displayName:"Avacus",image_id:"a7106965-91cc-4a73-4688-c5c72ae0ed00",hostname:"avacus.cc",mobile:{universal:"https://avacus.app.link"}},bee:{id:"2cca8c1b0bea04ba37dee4017991d348cdb7b826804ab2bd31073254f345b715",displayName:"Bee",image_id:"f90bc33f-f085-40cf-7538-fae5ae84f900",hostname:"www.beewallet.app",mobile:{universal:"https://beewallet.app/wc"}},pitaka:{id:"14e5d957c6eb62d3ee8fc6239703ac2d537d7e3552154836ca0beef775f630bc",displayName:"Pitaka",image_id:"691c0716-5213-4b99-e837-079268313800",hostname:"pitaka.io",mobile:{universal:"https://app.pitaka.io"}},pltwallet:{id:"576c90ceaea34f29ff0104837cf2b2e23d201be43be1433feeb18d375430e1fd",displayName:"PLTwallet",image_id:"a5d9dd15-8cef-42de-8bed-09e01a8b0200",hostname:"pltwallet.io",mobile:{universal:"https://pltwallet.io/"}},minerva:{id:"49bb9d698dbdf2c3d4627d66f99dd9fe90bba1eec84b143f56c64a51473c60bd",displayName:"Minerva",image_id:"b57b2163-1bd8-4f6b-3311-470767e6d200",hostname:"minerva.digital",mobile:{universal:"https://minerva.digital"}},kryptogo:{id:"19418ecfd44963883e4d6abca1adeb2036f3b5ffb9bee0ec61f267a9641f878b",displayName:"KryptoGO",image_id:"3ccbd966-97e8-45a0-1ceb-6141a8978e00",hostname:"kryptogo.com",mobile:{universal:"https://kryptogo.page.link"}},prema:{id:"5b8e33346dfb2a532748c247876db8d596734da8977905a27b947ba1e2cf465b",displayName:"PREMA",image_id:"6487869b-1165-4f30-aa3a-115665be8300",hostname:"premanft.com",mobile:{universal:"https://premanft.com"}},slingshot:{id:"d23de318f0f56038c5edb730a083216ff0cce00c1514e619ab32231cc9ec484b",displayName:"Slingshot",image_id:"10c75467-6612-48ad-b97b-63985e922200",hostname:"slingshot.finance",mobile:{universal:"https://app.slingshot.finance"}},kriptonio:{id:"50df7da345f84e5a79aaf617df5167335a4b6751626df2e8a38f07029b3dde7b",displayName:"Kriptonio",image_id:"363fae03-882a-4d81-a721-6e6f6e9ac500",hostname:"kriptonio.com",mobile:{universal:"https://app.kriptonio.com/mobile"}},timeless:{id:"9751385960bca290c13b443155288f892f62ee920337eda8c5a8874135daaea8",displayName:"Timeless",image_id:"32e89601-0490-42fc-0cc4-8627d62a2000",hostname:"timelesswallet.xyz",mobile:{universal:"https://timelesswallet.xyz"}},secux:{id:"6464873279d46030c0b6b005b33da6be5ed57a752be3ef1f857dc10eaf8028aa",displayName:"SecuX",image_id:"98183be0-3125-45ee-a6b6-fbd47ebefd00",hostname:"secuxtech.com",mobile:{universal:"https://wsweb.secuxtech.com"}},bitizen:{id:"41f20106359ff63cf732adf1f7dc1a157176c9b02fd266b50da6dcc1e9b86071",displayName:"Bitizen",image_id:"75dd1471-77e9-4811-ce57-ec8fc980ec00",hostname:"bitizen.org",mobile:{universal:"https://bitizen.org/wallet"}},blocto:{id:"14e7176536cb3706e221daaa3cfd7b88b7da8c7dfb64d1d241044164802c6bdd",displayName:"Blocto",image_id:"374258d3-c749-4f37-7815-77e61f798c00",hostname:"blocto.io",mobile:{universal:"https://blocto.app"}},safemoon:{id:"a0e04f1086aac204d4ebdd5f985c12ed226cd0006323fd8143715f9324da58d1",displayName:"SafeMoon",image_id:"ea0140c7-787c-43a4-838f-d5ab6a342000",hostname:"safemoon.com",mobile:{universal:"https://safemoon.com/wc"}}},ul=(e,t="md")=>`https://registry.walletconnect.com/v2/logo/${t}/${e}`;function Mi(e){return{name:e.displayName||"",universalLink:e.mobile.universal||"",deepLink:e.mobile.native||""}}function hl(e,t){let i=encodeURIComponent(e);return t.universalLink?`${t.universalLink}/wc?uri=${i}`:t.deepLink?`${t.deepLink}${t.deepLink.endsWith(":")?"//":"/"}wc?uri=${e}`:""}var tE="WALLETCONNECT_DEEPLINK_CHOICE";function cl(e){let t=e.href.split("?")[0];e8.put(tE,{...e,href:t})}var Cr=(e,t)=>{if(!e||T.nI){e8.del(tE);return}if(T.Dt){cl({name:"Unknown",href:t||"wc:"});return}if(T.UA){let i=hl(t||"wc:",Mi(e));cl({name:e?.displayName||"",href:i})}},tA=class extends tw{constructor(e,t,i,a,s){super(s||"unknown",i,a),this.connectorType="wallet_connect_v2",this.walletConnectCloudProjectId=e,this.rpcConfig=t,this.proxyProvider=new tu,this.createProvider().then(e=>{if(this.provider=e,this.proxyProvider.setWalletProvider(e),this.subscribeListeners(),e.session){if(this.walletProvider.session?.peer.metadata.url){let e=fn(this.walletProvider.session?.peer.metadata.url);this.walletEntry=e?.entry,this.walletClientType=e?.walletClientType||"unknown",Cr(this.walletEntry)}this.connected=!0,this.syncAccounts().then(()=>{this.emit("initialized"),this.initialized=!0})}else this.emit("initialized"),this.initialized=!0})}async connect(e){return e.showPrompt&&await this.promptConnection(),this.getConnectedWallet()}async isConnected(){return this.walletProvider.connected}get walletBranding(){return this.walletEntry?{name:this.walletEntry.displayName,icon:"metamask"===this.walletClientType?Ce:ul(this.walletEntry.image_id)}:{name:Ni(this.walletProvider.session?.peer.metadata.name||"")||"WalletConnect",icon:this.walletProvider.session?.peer.metadata.icons?.[0]||qo}}resetConnection(){this.walletProvider&&this.walletProvider.connected&&(this.walletProvider.signer.session=void 0,this.walletEntry=void 0,Cr(void 0),this.onDisconnect())}async promptConnection(){if(this.provider)return new Promise((e,t)=>{this.onQrModalClosed=()=>{t(new ta)},(async()=>{let t="",i=await Promise.race([this.walletProvider.enable(),Li()]);if(i.length>0&&(t=i[0]),!t||""===t)throw new eD("Unable to retrieve address");if(this.walletProvider.session?.peer.metadata.url){let e=fn(this.walletProvider.session?.peer.metadata.url);this.walletEntry=e?.entry,this.walletClientType=e?.walletClientType||"unknown"}this.connected=!0,await this.syncAccounts(i),e()})().catch(e=>{if(e){t(mt(e));return}t(new eD("Unknown error during connection"))}).finally(()=>R().close())})}disconnect(){this.walletProvider.disconnect().then(()=>this.onDisconnect()).catch(()=>console.warn("Unable to disconnect Wallet Connect provider"))}get walletProvider(){return this.proxyProvider.walletProvider}setWalletProvider(e){this.proxyProvider.setWalletProvider(e)}async createProvider(){let e={};for(let t of this.chains){let i=tt(t.id,this.chains,this.rpcConfig);i&&(e[t.id]=i)}let t=await I.Gn.init({projectId:this.walletConnectCloudProjectId,chains:[this.defaultChain.id],optionalChains:this.chains.map(e=>e.id),optionalEvents:I.gy,optionalMethods:I.lI,rpcMap:e,showQrModal:!1});return t.on("display_uri",e=>{if(T.Dt)window.open(e,"_self");else if(T.tq&&this.walletEntry){var t;Cr(this.walletEntry,e);let i=(t=this.walletEntry,T.Dt?e:hl(e,Mi(t)));window.open(i,"_self","noopener,noreferrer")}else{let t;R().open(e,()=>{this.onQrModalClosed&&this.onQrModalClosed()},{mobileLinks:(t="mobile",Object.values(t_).filter(e=>!!e[t].universal||!!e[t].native).map(e=>Mi(e))).map(e=>e.name)})}}),t.on("connect",()=>{if(R().close(),t.session?.peer.metadata.url){let e=fn(t.session?.peer.metadata.url);this.walletEntry=e?.entry,this.walletClientType=e?.walletClientType||"unknown",Cr(this.walletEntry)}}),t}async enableProvider(){return this.walletProvider.connected?Promise.resolve(this.walletProvider.accounts):await this.walletProvider.enable()}},Ui=e=>{let t=localStorage.getItem("-walletlink:https://www.walletlink.org:Addresses");return!!t&&!!e?.linkedAccounts.filter(e=>"wallet"==e.type&&e.address===a.Kn(t)).length},tP=class extends w.Z{constructor(e,t,i,a){super(),this.getEthereumProvider=()=>{let e=this.wallets[0],t=this.walletConnectors.find(t=>t.wallets.find(t=>t.address===e?.address));return e&&t?t.proxyProvider:new tu},this.walletConnectCloudProjectId=e,this.rpcConfig=t,this.chains=i,this.defaultChain=a,this.walletConnectors=[],this.initialized=!1,this.storedConnections=this.loadConnectionHistory()}get wallets(){let e=new Set,t=this.walletConnectors.flatMap(e=>e.wallets).sort((e,t)=>e.connectedAt&&t.connectedAt?t.connectedAt-e.connectedAt:0).filter(t=>{let i=`${t.address}${t.walletClientType}${t.connectorType}`;return!e.has(i)&&(e.add(i),!0)}),i=t.findIndex(e=>e.address===(this.activeWallet?this.activeWallet:"unknown"));return i>=0&&t.unshift(t.splice(i,1)[0]),t}initialize(){this.initialized||(e8.get(e3)&&(e8.getKeys().forEach(e=>{e.startsWith("walletconnect")&&e8.del(e)}),e8.del(e3)),Ks().then(e=>e.forEach(e=>{switch(e){case"metamask":this.createWalletConnector("injected","metamask");break;case"phantom":this.createWalletConnector("injected","phantom")}})),(nn()||e8.getKeys().find(e=>e.startsWith("-walletlink")))&&this.createWalletConnector("coinbase_wallet","coinbase_wallet"),this.createWalletConnector("wallet_connect_v2","unknown"),this.initialized=!0)}findWalletConnector(e,t){return"wallet_connect_v2"===e?this.walletConnectors.find(t=>t.connectorType===e)||null:this.walletConnectors.find(i=>i.connectorType===e&&i.walletClientType===t)||null}onInitialized(e){e.wallets.forEach(e=>{let t=this.storedConnections.find(t=>t.address===e.address&&t.connectorType===e.connectorType&&t.walletClientType===e.walletClientType);t&&(e.connectedAt=t.connectedAt)}),this.saveConnectionHistory(),this.emit("walletsUpdated")}onWalletsUpdated(e){e.initialized&&(this.saveConnectionHistory(),this.emit("walletsUpdated"))}addEmbeddedWalletConnector(e,t,i){if(!this.findWalletConnector("embedded","privy")){let a=new tm(e,t,this.rpcConfig,this.chains,i.id),s=new ty(a,this.chains,i);this.addWalletConnector(s)}}removeEmbeddedWalletConnector(){let e=this.findWalletConnector("embedded","privy");if(e){let t=this.walletConnectors.indexOf(e);this.walletConnectors.splice(t,1),this.saveConnectionHistory(),this.emit("walletsUpdated")}}async createWalletConnector(e,t){let i=this.findWalletConnector(e,t);if(i)return i instanceof tA&&i.resetConnection(),i;let a=(()=>{switch(e){case"injected":if("phantom"===t)return je()?new tC(this.chains,this.defaultChain):null;return vr()?new tb(this.chains,this.defaultChain):null;case"coinbase_wallet":return new tx(this.chains,this.defaultChain);case"wallet_connect_v2":return new tA(this.walletConnectCloudProjectId,this.rpcConfig,this.chains,this.defaultChain)}})();return a&&this.addWalletConnector(a),a||null}addWalletConnector(e){this.walletConnectors.push(e),e.on("initialized",()=>this.onInitialized(e)),e.on("walletsUpdated",()=>this.onWalletsUpdated(e))}loadConnectionHistory(){let o=e=>e&&"string"==typeof e.address&&"string"==typeof e.connectorType&&"string"==typeof e.walletClientType&&"number"==typeof e.connectedAt,e=e8.get(e4);return e&&Array.isArray(e)&&e.map(e=>o(e)).every(Boolean)?e:[]}saveConnectionHistory(){let e=this.wallets.map(e=>({address:e.address,connectorType:e.connectorType,walletClientType:e.walletClientType,connectedAt:e.connectedAt}));e8.put(e4,e)}async activeWalletSign(e){let t=this.wallets,i=t.length>0?t[0]:null;return i?i.sign(e):null}setActiveWallet(e){this.activeWallet=(0,a.Kn)(e),this.emit("walletsUpdated")}};function cn(e,t){if(e.length!==t.length)return!1;for(let i=0;i{let t=new AbortController;return setTimeout(()=>t.abort(),e),t.signal},tO=class{constructor(e,t,i){this.appId=e,this.sdkVersion="1.43.2",this.client=t,this.defaults=i,this.fallbackApiUrl=t.fallbackApiUrl,this.baseFetch=W.Wg.create({baseURL:this.defaults.baseURL,retry:3,retryDelay:500,credentials:"include",onRequest:async({request:e,options:t})=>{let i=new Headers(t.headers);i.set("privy-app-id",this.appId),i.set("privy-client",`react-auth:${this.sdkVersion}`);let a=!tI.includes(e.toString());if(!i.has("authorization")&&a){let e=await this.client.getAccessToken();null!==e&&i.set("authorization",`Bearer ${e}`)}t.headers=i,t.signal||(t.signal=sm(this.defaults.timeout))},onRequestError:({error:e})=>{if(e instanceof DOMException&&"AbortError"===e.name)throw new eU}})}async get(e,t){try{return await this.baseFetch(e,t)}catch(e){throw ee(e)}}async post(e,t,i){try{return await this.baseFetch(e,{method:"POST",...t?{body:t}:{},...i})}catch(e){throw ee(e)}}async delete(e,t){try{return await this.baseFetch(e,{method:"DELETE",...t})}catch(e){throw ee(e)}}},tL=class{static parse(e){try{return new tL(e)}catch{return null}}constructor(e){this.value=e,this._decoded=z.t5(e)}get subject(){return this._decoded.sub}get expiration(){return this._decoded.exp}get issuer(){return this._decoded.iss}get audience(){return this._decoded.aud}isExpired(e=0){return Date.now()>=(this.expiration-e)*1e3}},tR=class{constructor(){this.authenticateOnce=new eG(async e=>this._authenticate(e)),this.linkOnce=new eG(async e=>this._link(e)),this.refreshOnce=new eG(this._refresh.bind(this)),this.destroyOnce=new eG(this._destroy.bind(this)),this.forkSessionOnce=new eG(this._forkSession.bind(this))}get token(){try{let e=e8.get(eJ);return"string"==typeof e?new tL(e).value:null}catch(e){return console.error(e),this.destroyLocalState(),null}}get refreshToken(){try{let e=e8.get(eX);return"string"==typeof e?e:null}catch(e){return console.error(e),this.destroyLocalState(),null}}get forkedToken(){try{let e=e8.get(e1);return"string"==typeof e?e:null}catch(e){return console.error(e),this.destroyLocalState(),null}}get mightHaveServerCookies(){try{let e=F.Z.get("privy-session");return void 0!==e&&e.length>0}catch(e){console.error(e)}return!1}hasRefreshCredentials(){return this.mightHaveServerCookies||"string"==typeof this.token&&"string"==typeof this.refreshToken}hasRecoveryCredentials(){return"string"==typeof this.forkedToken}hasActiveToken(){let e=tL.parse(this.token);return null!==e&&!e.isExpired(30)}authenticate(e){return this.authenticateOnce.execute(e)}link(e){return this.linkOnce.execute(e)}refresh(){return this.refreshOnce.execute()}forkSession(){return this.forkSessionOnce.execute()}destroy(){return this.destroyOnce.execute()}async _authenticate(e){try{let{token:t,refresh_token:i,user:a,is_new_user:s}=await e.authenticate();this.storeToken(t),this.storeRefreshToken(i);let l=e instanceof eB?"email":e instanceof eV?"sms":e instanceof eq?"siwe":e instanceof e$?"custom_auth":e instanceof eH?e.meta.provider:null;return l&&this.client&&this.client.createAnalyticsEvent("sdk_authenticate",{method:l,isNewUser:s}),"siwe"===l&&this.client&&this.client.createAnalyticsEvent("sdk_authenticate_siwe",{connectorType:e.meta.connectorType,walletClientType:e.meta.walletClientType}),{user:_t(a),isNewUser:s}}catch(e){throw console.warn("Error authenticating session"),De(e)}}async _link(e){try{let t=await e.link();return _t(t)}catch(e){throw console.warn("Error linking account"),De(e)}}async _refresh(){if(!this.api)throw new eM("Session has no API instance");if(!this.client)throw new eM("Session has no PrivyClient instance");await this.client.getAccessToken({disableAutoRefresh:!0});let e=this.token,t=this.refreshToken,i=this.forkedToken;try{let a;if(e&&t||this.mightHaveServerCookies){let s={};e&&(s.authorization=`Bearer ${e}`);let l=t?{refresh_token:t}:{};a=await this.api.post(Jr(),l,{headers:s}),i&&this.clearForkedToken()}else{if(!i)return null;a=await this.api.post(Qr(),{refresh_token:i}),this.clearForkedToken()}return this.storeToken(a.token),this.storeRefreshToken(a.refresh_token),_t(a.user)}catch(e){if(e instanceof eW&&"missing_or_invalid_token"===e.privyErrorCode)return console.warn("Unable to refresh tokens - token is missing or no longer valid"),this.destroyLocalState(),null;throw De(e)}}async _destroy(){try{await this.api?.post(us(),{refresh_token:this.refreshToken})}catch{console.warn("Error destroying session")}this.destroyLocalState()}async _forkSession(){if(!this.api)throw new eM("Session has no API instance");let e=this.refreshToken;try{let t=await this.api.post(ms(),{refresh_token:e});return this.storeToken(t.token),this.storeRefreshToken(t.refresh_token),t.new_session_refresh_token}catch(e){throw De(e)}}destroyLocalState(){this.storeToken(null),this.storeRefreshToken(null),this.clearForkedToken()}storeToken(e){if("string"==typeof e){if(e8.put(eJ,e),!this.client?.useServerCookies){let t=tL.parse(e)?.expiration;F.Z.set(eQ,e,{sameSite:"Strict",secure:!0,expires:t?new Date(1e3*t):void 0})}}else e8.del(eJ),F.Z.remove(eQ)}storeRefreshToken(e){"string"==typeof e?(e8.put(eX,e),this.client?.useServerCookies||F.Z.set(e0,e,{sameSite:"Strict",secure:!0,expires:30})):(e8.del(eX),F.Z.remove(e0))}clearForkedToken(){e8.del(e1)}},tW=class{constructor(e){ds(this,tT),this.apiUrl=e.apiUrl||eY,this.fallbackApiUrl=this.apiUrl,this.useServerCookies=!1,this.timeout=e.timeout||2e4,this.appId=e.appId,this.clientAnalyticsId=ps(this,tT,tN).call(this),tS||(tS=new tR),this.session=tS,this.api=this.generateApi(),this.session.client=this}initializeConnectorManager(e,t,i,a){this.connectors||(this.connectors=new tP(e,t,i,a))}generateApi(){let e=new tO(this.appId,this,{baseURL:this.apiUrl,timeout:this.timeout});return this.session.api=e,e}updateApiUrl(e){this.apiUrl=e||this.fallbackApiUrl,this.api=this.generateApi(),e&&(this.useServerCookies=!0)}authenticate(){if(!this.authFlow)throw new eM("No auth flow in progress.");return this.session.authenticate(this.authFlow)}link(){if(!this.authFlow)throw new eM("No auth flow in progress.");return this.session.link(this.authFlow)}async logout(){await this.session.destroy(),this.authFlow=void 0}startAuthFlow(e){e.api=this.api,this.authFlow=e}async unlinkEmail(e){try{let t=await this.api.post(Ss(),{address:e});return _t(t)}catch(e){throw De(e)}}async unlinkPhone(e){try{let t=await this.api.post(As(),{phoneNumber:e});return _t(t)}catch(e){throw De(e)}}async unlinkWallet(e){try{let t=await this.api.post(_s(),{address:e});return _t(t)}catch(e){throw De(e)}}async unlinkOAuth(e,t){try{let i=await this.api.post(ks(),{provider:e,subject:t});return _t(i)}catch(e){throw De(e)}}async createAnalyticsEvent(e,t,i){if(!(typeof window>"u"))try{this.clientAnalyticsId||console.warn("No client analytics id set, refusing to send analytics event"),await this.api.post(Rs(),{event_name:e,client_id:this.clientAnalyticsId,payload:{...t||{},clientTimestamp:i?i.toISOString():new Date().toISOString()}})}catch{}}async signMoonpayOnRampUrl(e){try{return this.api.post(Ws(),e)}catch(e){throw De(e)}}async getAuthenticatedUser(){return this.session.hasRefreshCredentials()||this.session.hasRecoveryCredentials()?this.session.refresh():null}async getAccessToken(e){return this.session.hasActiveToken()?tL.parse(this.session.token)?.audience!==this.appId?(await this.logout(),null):this.session.token:!e?.disableAutoRefresh&&this.session.hasRefreshCredentials()?(await this.session.refresh(),this.session.token):null}async getServerConfig(){try{let e=await this.api.get(`/api/v1/apps/${this.appId}`,{baseURL:this.fallbackApiUrl});return{id:e.id,name:e.name,verificationKey:e.verification_key,logoUrl:e.logo_url||void 0,accentColor:e.accent_color||void 0,showWalletLoginFirst:e.show_wallet_login_first,allowlistConfig:{errorTitle:e.allowlist_config.error_title,errorDetail:e.allowlist_config.error_detail,errorCtaText:e.allowlist_config.cta_text,errorCtaLink:e.allowlist_config.cta_link},walletAuth:e.wallet_auth,emailAuth:e.email_auth,smsAuth:e.sms_auth,googleOAuth:e.google_oauth,twitterOAuth:e.twitter_oauth,discordOAuth:e.discord_oauth,githubOAuth:e.github_oauth,tiktokOAuth:e.tiktok_oauth,linkedinOAuth:e.linkedin_oauth,appleOAuth:e.apple_oauth,termsAndConditionsUrl:e.terms_and_conditions_url,embeddedWalletConfig:{createOnLogin:e.embedded_wallet_config?.create_on_login,requireUserPasswordOnCreate:e.embedded_wallet_config?.require_user_password_on_create},privacyPolicyUrl:e.privacy_policy_url,customApiUrl:e.custom_api_url,walletConnectCloudProjectId:e.wallet_connect_cloud_project_id,fiatOnRampEnabled:e.fiat_on_ramp_enabled,captchaEnabled:e.captcha_enabled,twitterOAuthOnMobileEnabled:e.twitter_oauth_on_mobile_enabled,createdAt:new Date(1e3*e.created_at),updatedAt:new Date(1e3*e.updated_at)}}catch(e){throw De(e)}}async getUsdTokenPrice(e){try{return(await this.api.get(`/api/v1/token_price?chainId=${e.id}&tokenSymbol=${e.nativeCurrency.symbol}`)).usd}catch{console.error(`Unable to fetch token price for chain with id ${e.id}`);return}}async forkSession(){return await this.session.forkSession()}};tT=new WeakSet,tN=function(){if(typeof window>"u")return null;try{let e=e8.get(e2);if("string"==typeof e&&e.length>0)return e}catch{}let e=(0,f.Z)();try{return e8.put(e2,e),e}catch{return e}};var tM=(0,u.createContext)({isNewUserThisSession:!1,isLinking:!1,linkingHint:null,walletConnectionStatus:null,rpcConfig:{rpcUrls:{}},chains:[],nativeTokenSymbolForChainId:x,captchaData:{enabled:!1,ready:!1,execute:x,remove:x,token:void 0,error:void 0},initializeWalletProxy:x,getAuthMeta:x,getAuthFlow:x,closePrivyModal:x,connectWallet:x,initLoginWithWallet:x,loginWithWallet:x,loginWithCode:x,initLoginWithEmail:x,initLoginWithSms:x,resendEmailCode:x,resendSmsCode:x,initLoginWithOAuth:x,loginWithOAuth:x,refreshUser:x,walletProxy:null,createAnalyticsEvent:x,getUsdTokenPrice:x,recoverEmbeddedWallet:x,getFiatOnRampConfig:x,updateWallets:x}),_=()=>(0,u.useContext)(tM),tU=(0,u.createContext)({ready:!1,authenticated:!1,user:null,walletConnectors:null,connectWallet:x,login:x,linkEmail:x,linkPhone:x,linkWallet:x,linkGoogle:x,linkTwitter:x,linkDiscord:x,linkGithub:x,linkTiktok:x,linkLinkedIn:x,linkApple:x,logout:x,getAccessToken:x,getEthereumProvider:x,getEthersProvider:x,getWeb3jsProvider:x,unlinkEmail:x,unlinkPhone:x,unlinkWallet:x,unlinkGoogle:x,unlinkTwitter:x,unlinkDiscord:x,unlinkGithub:x,unlinkTiktok:x,unlinkLinkedIn:x,unlinkApple:x,setActiveWallet:x,forkSession:x,createWallet:x,signMessage:x,sendTransaction:x,exportWallet:x,setWalletPassword:x}),$=()=>(0,u.useContext)(tU),wn=({success:e,fail:t})=>(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(tD,{className:e?"success":t?"fail":""}),(0,k.jsx)(tF,{className:e?"success":t?"fail":""})]}),tD=K.ZP.span` + && { + width: 82px; + height: 82px; + border-width: 4px; + border-style: solid; + border-color: ${e=>e.color??"var(--privy-color-accent)"}; + border-bottom-color: transparent; + border-radius: 50%; + display: inline-block; + box-sizing: border-box; + animation: rotation 1.2s linear infinite; + transition: border-color 800ms; + } + + @keyframes rotation { + 0% { + transform: rotate(0deg); + } + 100% { + transform: rotate(360deg); + } + } + + &&&.success { + border-color: var(--privy-color-success); + border-bottom-color: var(--privy-color-success); + } + + &&&.fail { + border-color: var(--privy-color-error); + border-bottom-color: var(--privy-color-error); + } +`,tF=(0,K.ZP)(tD)` + && { + border-bottom-color: ${e=>e.color??"var(--privy-color-accent)"}; + animation: none; + opacity: 0.5; + } +`,jt=e=>(0,k.jsx)(tZ,{color:e.color||"var(--privy-color-foreground-3)"}),tZ=(0,K.ZP)(tD)` + && { + height: 0.9rem; + width: 0.9rem; + border-width: 1.5px; + + /* Override default Loader to match button transitions */ + transition: border-color 200ms ease; + } +`,tz=K.ZP.button` + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + user-select: none; + & { + height: 44px; + width: 100%; + /* Off by one because of internal border in designs and otherwise looks off */ + padding: 7px 11px; + cursor: pointer; + font-size: 14px; + font-weight: 600; + border-radius: var(--privy-border-radius-md); + } + + &&:disabled { + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); + cursor: not-allowed; + } +`,V=({children:e,loading:t,disabled:i,loadingText:a="Loading...",...s})=>(0,k.jsx)(tH,{disabled:t||i,...s,children:t?(0,k.jsxs)("span",{children:[(0,k.jsx)(jt,{}),a?(0,k.jsx)("span",{children:a}):null]}):e}),t$=((0,K.ZP)(V)` + ${e=>e.hideAnimations&&K.iv` + && { + transition: none; + } + `} +`,({children:e,loading:t,disabled:i,annotation:a,loadingText:s="Loading...",...l})=>(0,k.jsxs)(tH,{as:"a",disabled:t||i,...l,children:[!!a&&(0,k.jsx)("div",{style:{position:"absolute",top:"-1.5rem"},children:(0,k.jsx)(tB,{children:a})}),t?(0,k.jsxs)("span",{children:[(0,k.jsx)(jt,{}),s?(0,k.jsx)("span",{children:s}):null]}):e]})),tB=K.ZP.span` + color: var(--privy-color-foreground-3); + text-align: center; + font-size: 0.625rem; + font-style: normal; + font-weight: 400; + line-height: 140%; /* 0.875rem */ +`,tH=(0,K.ZP)(tz)` + position: relative; + + && { + background-color: ${e=>e.warn?"var(--privy-color-error)":"var(--privy-color-accent)"}; + color: var(--privy-color-foreground-accent); + + transition: background-color 200ms ease; + } + + &:hover { + background-color: ${e=>e.warn?"var(--privy-color-error)":"var(--privy-color-accent-dark)"}; + } + + &:active { + background-color: ${e=>e.warn?"var(--privy-color-error)":"var(--privy-color-accent-dark)"}; + } + + &:hover:disabled, + &:active:disabled { + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); + cursor: not-allowed; + } + + /* If an anchor tag, :disabled isn't a thing, so manually set state */ + ${e=>e.disabled?K.iv` + &&&, + &&&:hover, + &&&:active { + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); + cursor: not-allowed; + pointer-events: none; + } + `:""} + + > span { + display: flex; + align-items: center; + gap: 8px; + + opacity: 1; + animation: fadein 200ms ease; + } +`,xn=({children:e,loading:t,disabled:i,loadingText:a="Loading...",...s})=>(0,k.jsx)(tG,{disabled:t||i,...s,children:t?(0,k.jsxs)("span",{children:[(0,k.jsx)(jt,{}),a?(0,k.jsx)("span",{children:a}):null]}):e}),tG=(0,K.ZP)(tz)` + && { + border-width: 1px; + border-color: ${e=>e.warn?"var(--privy-color-error)":"var(--privy-color-foreground-4)"}; + color: var(--privy-color-foreground); + + transition: border-color 200ms ease; + } + + &:hover, + &:active { + border-color: ${e=>e.warn?"var(--privy-color-error)":"var(--privy-color-foreground-3)"}; + } + + &:hover:disabled, + &:active:disabled { + border-color: var(--privy-color-foreground-accent); + color: var(--privy-color-foreground-3); + cursor: not-allowed; + } + + > span { + display: flex; + align-items: center; + gap: 8px; + + opacity: 1; + animation: fadein 200ms ease; + } +`,tq=K.ZP.button` + && { + padding: 12px 16px; + font-weight: 500; + text-align: center; + color: var(--privy-color-foreground-accent); + background-color: var(--privy-color-accent); + border-radius: var(--privy-border-radius-sm); + min-width: 144px; + opacity: ${e=>e.invisible?"0":"1"}; + transition: opacity 200ms ease, background-color 200ms ease, color 200ms ease; + user-select: none; + + ${e=>e.invisible&&K.iv` + pointer-events: none; + `} + + &:hover { + background-color: var(--privy-color-accent-dark); + } + &:active { + background-color: var(--privy-color-accent-dark); + } + + &:hover:disabled, + &:active:disabled { + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); + cursor: not-allowed; + } + } +`,tV=K.ZP.div` + /* Set to match height of SoftCtaButton to avoid reflow if conditionally rendered */ + height: 44px; +`,tK=K.ZP.button` + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + & { + height: 44px; + cursor: pointer; + font-size: 14px; + font-weight: 600; + border-radius: 0px var(--privy-border-radius-sm) var(--privy-border-radius-sm) 0px; + } + + && { + padding-left: 15px; + padding-right: 15px; + border: 1px solid var(--privy-color-foreground-4); + /* Prevent duplicate with input field */ + border-left: none; + background-color: var(--privy-color-accent); + color: var(--privy-color-foreground-accent); + transition: background-color 200ms ease; + + &:focus { + border-left: 1px solid var(--privy-color-accent-light); + } + } + + &:hover { + background-color: var(--privy-color-accent-dark); + } + + &&:disabled, + &&:hover:disabled { + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); + cursor: not-allowed; + } +`,tY=K.ZP.span` + && { + width: 82px; + height: 82px; + border-width: 4px; + border-style: solid; + border-color: ${e=>e.color??"var(--privy-color-accent)"}; + border-bottom-color: transparent; + border-radius: 50%; + display: inline-block; + box-sizing: border-box; + animation: rotation 1.2s linear infinite; + transition: border-color 800ms; + border-color: var(--privy-color-accent); + border-bottom-color: var(--privy-color-accent); + } +`,tJ=K.ZP.div` + display: flex; + flex-direction: column; + align-items: flex-start; + justify-content: flex-end; + margin-top: auto; + gap: 16px; + flex-grow: 100; +`,tQ=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + flex-grow: 1; + width: 100%; +`,tX=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + width: 100%; +`,t0=(0,K.ZP)(tQ)` + gap: 16px; +`,t1=K.ZP.div` + display: flex; + flex-direction: column; + width: 100%; +`,t2=K.ZP.div` + display: flex; + flex-direction: column; + gap: 8px; + min-height: 76px; +`,t3=(K.ZP.div` + display: flex; + flex-direction: column; + justify-content: space-between; + height: 100%; +`,K.ZP.div` + display: flex; + flex-direction: column; + justify-content: flex-start; + align-items: flex-start; + text-align: left; + gap: 8px; + padding: 16px; + margin-top: 16px; + margin-bottom: 16px; + width: 100%; + background: var(--privy-color-background-2); + border-radius: var(--privy-border-radius-md); + && h4 { + color: var(--privy-color-foreground-3); + font-size: 14px; + text-decoration: underline; + font-weight: medium; + } + && p { + color: var(--privy-color-foreground-3); + font-size: 14px; + } +`),t4=K.ZP.div` + height: 16px; +`,t5=K.ZP.div` + height: 12px; +`,t6=K.ZP.div` + position: relative; +`,t7=K.ZP.div` + background-color: var(--privy-color-accent); + display: flex; + justify-content: center; + align-items: center; + border-radius: 50%; + border-color: white; + border-width: 2px !important; +`,t8=K.ZP.div` + margin-top: 16px; + font-size: 12px; + text-align: center; + color: var(--privy-color-foreground-3); + + && > a { + color: var(--privy-color-accent); + } +`;function _n(e){let{legal:{privacyPolicyUrl:t,termsAndConditionsUrl:i}}=e.app,a=!!t,s=!!i,l=a&&s;return a||s?(0,k.jsxs)(t8,{children:["By logging in I agree to the"," ",s&&(0,k.jsx)("a",{href:i,target:"_blank",children:l?"Terms":"Terms of Service"}),l&&" & ",a&&(0,k.jsx)("a",{href:t,target:"_blank",children:"Privacy Policy"})]}):null}var O=({protectedByPrivy:e})=>(0,k.jsx)(t9,{children:e?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)($o,{className:"hide-on-mobile"}),(0,k.jsx)("span",{className:"hide-on-mobile",children:(0,k.jsx)("a",{href:"https://www.privy.io/",target:"_blank",children:"Protected by Privy"})})]}):null}),t9=K.ZP.div` + display: flex; + align-items: center; + justify-content: center; + padding-top: 6px; + padding-bottom: 12px; + gap: 2px; + + font-size: 12px; + line-height: 19px; + font-weight: 300; + + && svg { + height: 14px; + width: 14px; + margin-bottom: 2px; + opacity: 0.5; + } + + && a { + color: var(--privy-color-foreground-3); + &:hover { + text-decoration: underline; + } + } + + @media all and (display-mode: standalone) { + padding-bottom: 30px; + } +`,kl=()=>(0,k.jsx)("div",{}),Pm=({backFn:e})=>(0,k.jsx)("div",{children:(0,k.jsx)(J.Z,{height:"16px",width:"16px",strokeWidth:2,onClick:e})}),Tm=e=>(0,k.jsx)("div",{children:(0,k.jsx)("div",{children:(0,k.jsx)(Q.Z,{height:"16px",width:"16px",strokeWidth:2,onClick:e.onClose})})}),P=({backFn:e,onClose:t,title:i,closeable:a=!0})=>{let{closePrivyModal:s}=_(),{app:l}=v();return(0,k.jsxs)(re,{children:[e?(0,k.jsx)(Pm,{backFn:e}):(0,k.jsx)(kl,{}),i&&(0,k.jsx)(rt,{children:i}),l?.render.inDialog&&a?(0,k.jsx)(Tm,{onClose:t||(()=>s())}):(0,k.jsx)(kl,{})]})},re=K.ZP.div` + padding-top: 16px; + display: flex; + align-items: center; + justify-content: space-between; + + h2 { + font-size: 16px; + line-height: 24px; + font-weight: 600; + color: var(--privy-color-foreground); + } + + > :first-child { + flex: 1; + text-align: left; + svg { + cursor: pointer; + margin-right: auto; + color: var(--privy-color-foreground); + } + opacity: 0.6; + } + + > :first-child:hover { + opacity: 1; + } + + > :last-child { + flex: 1; + text-align: right; + > div { + cursor: pointer; + margin-left: auto; + display: flex; + opacity: 0.6; + + background-color: var(--privy-color-background-2); + border-radius: var(--privy-border-radius-full); + height: 24px; + width: 24px; + + > svg { + margin: auto; + color: var(--privy-color-foreground); + } + } + > div:hover { + opacity: 1; + } + } + + /* Mobile */ + @media (max-width: 440px) { + height: 30px; + margin-bottom: 10px; + } +`,rt=K.ZP.div` + overflow: hidden; + white-space: nowrap; + max-width: 100%; + text-overflow: ellipsis; + text-align: center; + color: var(--privy-color-foreground-2); +`,Il=({style:e,...t})=>(0,k.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",style:{height:"1.5rem",width:"1.5rem",...e},...t,children:(0,k.jsx)("path",{fillRule:"evenodd",d:"M12 1.5a5.25 5.25 0 00-5.25 5.25v3a3 3 0 00-3 3v6.75a3 3 0 003 3h10.5a3 3 0 003-3v-6.75a3 3 0 00-3-3v-3c0-2.9-2.35-5.25-5.25-5.25zm3.75 8.25v-3a3.75 3.75 0 10-7.5 0v3h7.5z",clipRule:"evenodd"})}),rr=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin-left: 27px; + margin-right: 27px; + gap: 24px; +`,ro=K.ZP.div` + display: flex; + flex-direction: column; + gap: 8px; +`,rs=K.ZP.div` + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + width: 100%; + height: 82px; + + > div { + position: relative; + } + + > div > span { + position: absolute; + left: -41px; + top: -41px; + } + + > div > svg { + position: absolute; + left: -19px; + top: -19px; + } +`,vt=({title:e,description:t,children:i,...a})=>(0,k.jsx)(rc,{...a,children:(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)("h3",{children:e}),"string"==typeof t?(0,k.jsx)("p",{children:t}):t,i]})}),rl=(0,K.ZP)(vt)` + margin-bottom: 24px; +`,fe=({title:e,description:t,icon:i,children:a,...s})=>(0,k.jsxs)(rd,{...s,children:[i||null,(0,k.jsx)("h3",{children:e}),"string"==typeof t?(0,k.jsx)("p",{children:t}):t,a]}),rc=K.ZP.div` + display: flex; + flex-direction: column; + justify-content: flex-start; + align-items: flex-start; + text-align: left; + gap: 8px; + width: 100%; + margin-bottom: 24px; + + && h3 { + font-size: 17px; + color: var(--privy-color-foreground); + } + + /* Sugar assuming children are paragraphs. Otherwise, handling styling on your own */ + && p { + color: var(--privy-color-foreground-2); + font-size: 14px; + } +`,rd=(0,K.ZP)(rc)` + align-items: center; + text-align: center; + gap: 16px; + + h3 { + margin-bottom: 24px; + } +`,rh=Array(6).fill(""),rm=K.ZP.div` + display: flex; + flex-direction: column; + align-items: flex-start; + justify-content: center; + margin: auto; + gap: 16px; + flex-grow: 1; +`,rf=K.ZP.div` + display: flex; + flex-direction: column; + width: 100%; + gap: 8px; + + > div:last-child { + display: flex; + justify-content: space-between; + width: 100%; + border-radius: var(--privy-border-radius-md); + + > input { + border: 1px solid var(--privy-color-foreground-4); + background: var(--privy-color-background); + border-radius: var(--privy-border-radius-md); + padding: 8px 10px; + height: 58px; + width: 46px; + text-align: center; + font-size: 18px; + } + + > input:focus { + border: 1px solid var(--privy-color-accent); + } + + > input:invalid { + border: 1px solid var(--privy-color-error); + } + + > input.success { + border: 1px solid var(--privy-color-success); + } + + > input.fail { + border: 1px solid var(--privy-color-error); + animation: shake 180ms; + animation-iteration-count: 2; + } + } + + @keyframes shake { + 0% { + transform: translate(1px, 0px); + } + 33% { + transform: translate(-1px, 0px); + } + 67% { + transform: translate(-1px, 0px); + } + 100% { + transform: translate(1px, 0px); + } + } +`,rg=K.ZP.div` + line-height: 20px; + height: 20px; + font-size: 13px; + color: ${e=>e.success?"var(--privy-color-success)":e.fail?"var(--privy-color-error)":"var(--privy-color-foreground-3)"}; + display: flex; + justify-content: flex-end; + width: 100%; +`,rw=K.ZP.div` + font-size: 13px; + color: var(--privy-color-foreground-3); + display: flex; + justify-content: space-between; + width: 100%; + margin-top: 16px; + // Equal opposing size buffer to account for auto margining when the + // success/fail text does not show up + padding-bottom: 32px; + + > button { + text-decoration: underline; + } +`,rx=K.ZP.span` + font-weight: 500; + word-break: break-all; +`,rv=K.ZP.span` + @media (max-width: 440px) { + display: none; + } +`,Zt=({connectOnly:e})=>{let{navigate:t}=v(),{initLoginWithWallet:i,connectWallet:a}=_();return(0,k.jsxs)(rb,{children:[(0,k.jsxs)(rC,{onClick:()=>{vr()?e?(a("injected","metamask"),t("AWAITING_CONNECT_ONLY_CONNECTION")):(i("injected","metamask"),t("AWAITING_CONNECTION")):T.tq?e?(a("wallet_connect_v2","metamask"),t("AWAITING_CONNECT_ONLY_CONNECTION")):(i("wallet_connect_v2","metamask"),t("AWAITING_CONNECTION")):t("INSTALL_METAMASK_SCREEN")},children:[(0,k.jsx)(Ce,{}),(0,k.jsx)("span",{children:"MetaMask"}),(0,k.jsx)("span",{children:vr()?"Connect":"Install"})]}),(0,k.jsxs)(rC,{onClick:()=>{e?(a("coinbase_wallet","coinbase_wallet"),t("AWAITING_CONNECT_ONLY_CONNECTION")):(i("coinbase_wallet","coinbase_wallet"),t("AWAITING_CONNECTION"))},children:[(0,k.jsx)(pt,{}),(0,k.jsxs)("span",{children:["Coinbase",(0,k.jsx)(rv,{children:" Wallet"})]}),(0,k.jsx)("span",{children:"Connect"})]}),(T.tq||je())&&(0,k.jsxs)(rC,{id:"privy-phantom-button",onClick:()=>{je()?e?(a("injected","phantom"),t("AWAITING_CONNECT_ONLY_CONNECTION")):(i("injected","phantom"),t("AWAITING_CONNECTION")):t(T.tq?"PHANTOM_INTERSTITIAL_SCREEN":"INSTALL_PHANTOM_SCREEN")},children:[(0,k.jsx)(Ke,{}),(0,k.jsx)("span",{children:"Phantom"}),(0,k.jsx)("span",{children:je()?"Connect":"Install"})]}),(0,k.jsxs)(rC,{onClick:()=>{e?(a("wallet_connect_v2","unknown"),t("AWAITING_CONNECT_ONLY_CONNECTION")):(i("wallet_connect_v2","unknown"),t("AWAITING_CONNECTION"))},children:[(0,k.jsx)(qo,{}),(0,k.jsx)("span",{children:"WalletConnect"}),(0,k.jsx)("span",{children:"Connect"})]})]})},rb=K.ZP.div` + display: flex; + flex-direction: column; + align-items: flex-start; + gap: 8px; + width: 100%; +`,rC=K.ZP.button` + display: flex; + flex-direction: row; + align-items: center; + gap: 12px; + width: 100%; + height: 44px; + + -webkit-user-select: none; + -ms-user-select: none; + user-select: none; + + font-size: 14px; + font-weight: 500; + color: var(--privy-color-foreground); + + && { + font-weight: 600; + padding: 7px 11px; + border: 1px solid var(--privy-color-foreground-4); + border-radius: var(--privy-border-radius-sm); + } + + flex: none; + order: 0; + align-self: stretch; + flex-grow: 0; + + > svg { + border-radius: var(--privy-border-radius-sm); + } + + /* Show "Connect" on hover */ + > :last-child { + font-weight: 500; + text-align: right; + flex: none; + order: 2; + flex-grow: 1; + color: var(--privy-color-accent); + opacity: 0; + transition: opacity 0.1s ease-out; + } + + :hover > :last-child { + opacity: 1; + } + + @media (max-width: 440px) { + > :last-child { + display: none; + } + } +`,Xt=()=>{let{navigate:e}=v();return(0,k.jsxs)(rj,{children:[(0,k.jsx)("span",{children:"Don’t have a wallet? "}),(0,k.jsx)("button",{onClick:()=>{e("WALLET_EDUCATION")},children:"Create one now."})]})},rj=K.ZP.div` + font-size: 13px; + color: var(--privy-color-foreground-3); + + > button { + text-decoration: underline; + } + + @media (max-width: 440px) { + margin-top: 4px; + } +`,Rn=()=>{let{app:e}=v(),t=e?.appearance?.logo,i=`${e?.name} logo`,a={maxHeight:"50px"},s="100%",l="auto";return t?"string"==typeof t?(0,k.jsx)("div",{children:(0,k.jsx)("img",{height:s,width:l,src:t,alt:i,style:a})}):"svg"===t.type||"img"===t.type?u.cloneElement(t,{height:s,width:l,alt:i,style:a}):(console.warn("`config.appearance.logo` must be a string, or an SVG / IMG element. Nothing will be rendered."),null):null},rk=K.ZP.div` + font-weight: 600; + color: 'var(--privy-color-foreground)'; + display: flex; + justify-content: center; + align-items: center; +`,r_=K.ZP.div` + display: flex; + flex-direction: column; + align-items: flex-start; + /* 1px helps with the input ring getting hidden by padding, despite it being + * annoying that it's not perfectly lined up + */ + padding: '1px'; + gap: 12px; + width: 100%; + max-height: '400px'; + transition-property: border-color, max-height; + transition-duration: 0.25s; + transition-timing-function: ease-in; + overflow: hidden; + && { + background: var(--privy-color-background); + border: 'none'; + border-radius: '0'; + } + cursor: 'inherit'; +`,rE=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + height: 100%; + padding: 45px 10px 45px; + @media (max-width: 440px) { + padding: 10px 10px 20px; + } +`,rA={metamask:{name:"MetaMask",component:Ce},phantom:{name:"Phantom",component:Ke},coinbase_wallet:{name:"Coinbase Wallet",component:pt},wallet_connect:{name:"WalletConnect",component:qo},embedded:{name:"Privy Wallet",component:$o}},oa=e=>e?.privyErrorCode==="linked_to_another_user"?td.ERROR_USER_EXISTS:e instanceof ts&&!e.details.default?e.details:e instanceof tr?td.ERROR_TIMED_OUT:e instanceof ta?td.ERROR_USER_REJECTED_CONNECTION:td.ERROR_WALLET_CONNECTION,rP=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin-left: 27px; + margin-right: 27px; + gap: 24px; +`,rS=K.ZP.div` + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + width: 100%; + height: 82px; + + > div { + position: relative; + } + + > div > span { + position: absolute; + left: -41px; + top: -41px; + } + + > div > :last-child { + position: absolute; + left: -19px; + top: -19px; + } +`,ra=e=>{let t=e.walletLogo;return(0,k.jsx)(k.Fragment,{children:(0,k.jsx)(rS,{children:(0,k.jsxs)("div",{children:[(0,k.jsx)(wn,{success:e.success,fail:e.fail}),"string"==typeof t?(0,k.jsx)("span",{style:{background:`url('${t}')`,height:"38px",width:"38px",borderRadius:"6px",margin:"auto",backgroundSize:"cover"}}):(0,k.jsx)(t,{style:{width:"38px",height:"38px"}})]})})})},rT=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin-left: 27px; + margin-right: 27px; + gap: 24px; +`,Yo=({children:e})=>(0,k.jsx)(rN,{children:(0,k.jsxs)(rI,{children:[e,(0,k.jsx)(rO,{}),(0,k.jsx)(rL,{})]})}),rN=K.ZP.div` + height: 100%; + display: flex; + justify-content: center; + align-items: center; + flex-grow: 1; + + margin: 12px; + + @media all and (display-mode: standalone) { + margin-bottom: 30px; + } +`,rI=K.ZP.div` + position: relative; + height: 140px; + width: 140px; + + opacity: 1; + animation: fadein 200ms ease; +`,rO=K.ZP.div` + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + width: 140px; + height: 140px; + + && { + border: 4px solid var(--privy-color-accent-light); + border-radius: 50%; + } +`,rL=K.ZP.div` + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + width: 140px; + height: 140px; + animation: spin 1200ms linear infinite; + + && { + border: 4px solid; + border-color: var(--privy-color-accent) transparent transparent transparent; + border-radius: 50%; + } + + @keyframes spin { + from { + transform: rotate(0deg); + } + to { + transform: rotate(360deg); + } + } +`,rR=["error","invalid_request_arguments","wallet_not_on_device","invalid_recovery_pin","insufficient_funds"],rW=class extends Error{constructor(e,t){super(t),this.type=e}};function aa(e){let t=e.type;return"string"==typeof t&&rR.includes(t)}function Jo(e){return aa(e)&&"wallet_not_on_device"===e.type}var rM=K.ZP.div` + display: flex; + height: 100%; + flex-direction: column; + flex-grow: 1; +`,cc=({style:e,...t})=>(0,k.jsxs)("svg",{width:"320",height:"144",viewBox:"0 0 320 144",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{width:320,height:144,...e},...t,children:[(0,k.jsx)("rect",{x:"214.681",y:"51.6852",width:"40",height:"40",rx:"20",fill:"var(--privy-color-background-2)"}),(0,k.jsx)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M229.848 64.9512C228.001 65.1452 226.643 66.726 226.643 68.5829V75.414C226.643 77.2883 228.026 78.8767 229.891 79.0615C231.417 79.2127 233.21 79.3518 234.643 79.3518C236.862 79.3518 239.95 79.0176 241.563 78.8225C242.183 78.7474 242.643 78.2196 242.643 77.5948V69.7756C242.643 69.1508 242.183 68.6229 241.563 68.5479C239.955 68.3534 236.883 68.0207 234.665 68.0185L234.643 68.0185L234.622 68.0185C233.219 68.0199 231.475 68.1534 229.975 68.3005C229.636 68.3007 229.346 68.0433 229.312 67.6989C229.277 67.3325 229.544 67.0063 229.911 66.9703C231.423 66.8219 233.203 66.6852 234.643 66.6852C236.246 66.6852 238.275 66.855 239.887 67.0221C240.412 67.0765 240.896 67.1309 241.309 67.1796V66.4289C241.309 65.8099 240.858 65.2851 240.244 65.2046C238.746 65.0083 235.977 64.6852 233.976 64.6852C232.734 64.6852 231.195 64.8098 229.848 64.9512ZM240.309 74.6852C240.862 74.6852 241.309 74.2375 241.309 73.6852C241.309 73.1329 240.862 72.6852 240.309 72.6852C239.757 72.6852 239.309 73.1329 239.309 73.6852C239.309 74.2375 239.757 74.6852 240.309 74.6852Z",fill:"var(--privy-color-accent)"}),(0,k.jsx)("path",{d:"M92.6426 74.2969H89.5743M76.6426 74.2969H85.5085M77.5837 78.2687L87.1555 61.6852M84.7273 65.9017L82.2897 61.6852M91.8614 78.2687L86.6849 69.2993",stroke:"var(--privy-color-accent)","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}),(0,k.jsx)("rect",{x:"65.6426",y:"52.6852",width:"38",height:"38",rx:"19",stroke:"var(--privy-color-background-2","stroke-width":"2"}),(0,k.jsx)("path",{d:"M103.162 71.6852H213.662",stroke:"var(--privy-color-background-2","stroke-width":"2","stroke-dasharray":"4 4"}),(0,k.jsx)("path",{d:"M270.544 116.469C272.146 116.469 273.445 115.175 273.445 113.577C273.445 111.98 272.146 110.685 270.544 110.685C268.942 110.685 267.643 111.98 267.643 113.577C267.643 115.175 268.942 116.469 270.544 116.469Z",fill:"var(--privy-color-accent-light"}),(0,k.jsx)("path",{d:"M157.878 48.3615C160.282 48.3615 162.231 46.4193 162.231 44.0234C162.231 41.6274 160.282 39.6852 157.878 39.6852C155.475 39.6852 153.526 41.6274 153.526 44.0234C153.526 46.4193 155.475 48.3615 157.878 48.3615Z",fill:"var(--privy-color-accent-dark)"}),(0,k.jsx)("path",{d:"M35.0825 96.1749C36.8852 96.1749 38.3466 94.7182 38.3466 92.9212C38.3466 91.1243 36.8852 89.6676 35.0825 89.6676C33.2797 89.6676 31.8184 91.1243 31.8184 92.9212C31.8184 94.7182 33.2797 96.1749 35.0825 96.1749Z",fill:"var(--privy-color-accent-dark)"}),(0,k.jsx)("path",{d:"M164.407 103.673C166.41 103.673 168.034 102.055 168.034 100.058C168.034 98.0616 166.41 96.443 164.407 96.443C162.404 96.443 160.78 98.0616 160.78 100.058C160.78 102.055 162.404 103.673 164.407 103.673Z",fill:"var(--privy-color-accent-light"}),(0,k.jsx)("path",{d:"M292.664 33.277C294.267 33.277 295.566 31.9822 295.566 30.3849C295.566 28.7876 294.267 27.4928 292.664 27.4928C291.062 27.4928 289.763 28.7876 289.763 30.3849C289.763 31.9822 291.062 33.277 292.664 33.277Z",fill:"var(--privy-color-accent-light"}),(0,k.jsx)("path",{d:"M104 12.6997C105.302 12.6997 106.357 11.6476 106.357 10.3498C106.357 9.05206 105.302 8 104 8C102.698 8 101.643 9.05206 101.643 10.3498C101.643 11.6476 102.698 12.6997 104 12.6997Z",fill:"var(--privy-color-accent-light"}),(0,k.jsx)("path",{d:"M7.99998 68.6997C9.30194 68.6997 10.3574 67.6476 10.3574 66.3498C10.3574 65.0521 9.30194 64 7.99998 64C6.69802 64 5.64258 65.0521 5.64258 66.3498C5.64258 67.6476 6.69802 68.6997 7.99998 68.6997Z",fill:"var(--privy-color-accent-light"}),(0,k.jsx)("path",{d:"M312 60.6997C313.302 60.6997 314.357 59.6476 314.357 58.3498C314.357 57.0521 313.302 56 312 56C310.698 56 309.643 57.0521 309.643 58.3498C309.643 59.6476 310.698 60.6997 312 60.6997Z",fill:"var(--privy-color-accent-light"}),(0,k.jsx)("path",{d:"M35.544 42.4694C37.1464 42.4694 38.4454 41.1746 38.4454 39.5773C38.4454 37.98 37.1464 36.6852 35.544 36.6852C33.9416 36.6852 32.6426 37.98 32.6426 39.5773C32.6426 41.1746 33.9416 42.4694 35.544 42.4694Z",fill:"var(--privy-color-accent-light"})]});function Ch(e){let[t,i]=(0,u.useState)(e.dimensions.width),[a,s]=(0,u.useState)(void 0),l=(0,u.useRef)(null);return(0,u.useEffect)(()=>{if(l.current&&void 0===t){let{width:e}=l.current.getBoundingClientRect();i(e)}let e=getComputedStyle(document.documentElement);s({background2:e.getPropertyValue("--privy-color-background-2"),foreground3:e.getPropertyValue("--privy-color-foreground-3"),foregroundAccent:e.getPropertyValue("--privy-color-foreground-accent"),accent:e.getPropertyValue("--privy-color-accent"),accentDark:e.getPropertyValue("--privy-color-accent-dark"),success:e.getPropertyValue("--privy-color-success")})},[]),(0,k.jsx)("div",{ref:l,children:t&&(0,k.jsxs)(r$,{children:[(0,k.jsx)("iframe",{style:{position:"absolute",zIndex:1},width:t,height:e.dimensions.height,allow:"clipboard-write self *",src:an(e.origin,`/apps/${e.appId}/embedded-wallets/export`,{token:e.accessToken,address:e.address,width:`${t}px`,...a})}),(0,k.jsx)(rB,{children:"Loading..."})]})})}function bh(e){return(0,k.jsx)("svg",{width:"16",height:"17",viewBox:"0 0 16 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:e.style,children:(0,k.jsx)("path",{d:"M14 8.81335C14 7.98493 13.3284 7.31335 12.5 7.31335H10C10 8.41792 9.10457 9.31335 8 9.31335C6.89543 9.31335 6 8.41792 6 7.31335H3.5C2.67157 7.31335 2 7.98493 2 8.81335M14 8.81335V12.8134C14 13.6418 13.3284 14.3134 12.5 14.3134H3.5C2.67157 14.3134 2 13.6418 2 12.8134V8.81335M14 8.81335V6.81335M2 8.81335V6.81335M14 6.81335C14 5.98493 13.3284 5.31335 12.5 5.31335H3.5C2.67157 5.31335 2 5.98493 2 6.81335M14 6.81335V4.81335C14 3.98493 13.3284 3.31335 12.5 3.31335H3.5C2.67157 3.31335 2 3.98493 2 4.81335V6.81335",stroke:"var(--privy-color-foreground-3)",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})}var rU=K.ZP.div` + display: flex; + height: 100%; + flex-direction: column; + text-align: left; +`,rD=K.ZP.div` + display: flex; + align-items: center; + justify-content: space-between; + margin-bottom: 8px; +`,rF=K.ZP.div` + display: flex; + flex-direction: column; + gap: 24px; + padding-bottom: 16px; + margin-top: 16px; + margin-left: 11px; + border-left: 1px solid var(--privy-color-foreground-4) !important; +`,rZ=K.ZP.div` + display: flex; + align-items: top; + gap: 8px; + + && a { + color: var(--privy-color-accent); + &:hover { + text-decoration: underline; + } + } +`,rz=K.ZP.div` + display: flex; + align-items: center; + justify-content: center; + margin-left: -12px; + flex-shrink: 0; + width: 24px; + height: 24px; + border: 1px solid var(--privy-color-foreground-4) !important; + font-size: 12px; + font-weight: 900; + border-radius: 100%; + background: var(--privy-color-background); + color: var(--privy-color-accent); +`,r$=K.ZP.div` + position: relative; + height: 44px; +`,rB=K.ZP.div` + position: absolute; + display: flex; + align-items: center; + justify-content: center; + width: 100%; + height: 100%; + font-size: 16px; + font-weight: 500; + border-radius: var(--privy-border-radius-md); + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); +`,rH=K.ZP.div` + display: flex; + align-items: center; + padding-top: 1px; + padding-bottom: 1px; + padding-left: 8px; + padding-right: 8px; + background-color: var(--privy-color-background-2); + color: var(--privy-color-foreground-3); + border-radius: var(--privy-border-radius-md); + font-size: 12px; + font-weight: 500; +`,rG=K.ZP.div` + border: 2px solid var(--privy-color-background-2) !important; + border-radius: var(--privy-border-radius-md); + padding: 16px; + padding-top: 24px; + margin-top: -12px; + + && > h4 { + color: var(--privy-color-error); + } +`,rq=K.iv` + font-size: 14px; + font-style: normal; + font-weight: 400; + line-height: 20px; + letter-spacing: -0.008px; + text-align: left; + transition: color 0.1s ease-in; +`,rV=K.ZP.span` + ${rq} + transition: color 0.1s ease-in; + color: ${({error:e})=>e?"var(--privy-color-error)":"var(--privy-color-foreground-3)"}; + text-transform: ${({error:e})=>e?"":"capitalize"}; + + &[aria-hidden='true'] { + visibility: hidden; + } +`,rK=K.ZP.div` + display: flex; + flex-direction: column; + justify-content: center; + flex-grow: 1; +`,rY=(0,K.ZP)(V)` + ${e=>e.hideAnimations&&K.iv` + && { + transition: none; + } + `} +`,rJ=K.iv` + && { + width: 100%; + border-width: 1px; + border-radius: var(--privy-border-radius-md); + border-color: var(--privy-color-foreground-3); + background: var(--privy-color-background); + color: var(--privy-color-foreground); + + padding: 12px; + font-size: 16px; + font-style: normal; + font-weight: 300; + line-height: 22px; /* 137.5% */ + } +`,rQ=K.ZP.input` + ${rJ} + + &::placeholder { + color: var(--privy-color-foreground-3); + font-style: italic; + } +`,rX=K.ZP.div` + ${rJ} +`,r0=K.ZP.div` + position: relative; + width: 100%; + display: flex; + align-items: center; + justify-content: ${({centered:e})=>e?"center":"space-between"}; +`,r1=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin: 32px 0; + gap: 4px; + + & h3 { + font-size: 18px; + font-style: normal; + font-weight: 600; + line-height: 24px; + } + + & p { + max-width: 300px; + font-size: 14px; + font-style: normal; + font-weight: 400; + line-height: 20px; + } +`,r2=K.ZP.div` + display: flex; + flex-direction: column; + gap: 10px; + padding-bottom: 1rem; +`,r3=K.ZP.div` + display: flex; + text-align: left; + align-items: center; + + gap: 8px; + max-width: 300px; + + font-size: 14px; + font-style: normal; + font-weight: 400; + line-height: 20px; + letter-spacing: -0.008px; + + margin: 0 8px; + color: var(--privy-color-foreground-2); + + > :first-child { + min-width: 24px; + } +`,r4=K.ZP.div` + height: var(--privy-height-modal-full); + + @media (max-width: 440px) { + height: var(--privy-height-modal-compact); + } +`,r5=(0,K.ZP)(tz)` + display: flex; + flex: 1; + gap: 4px; + justify-content: center; + + && { + background: var(--privy-color-background); + border-radius: var(--privy-border-radius-md); + border-color: var(--privy-color-foreground-3); + border-width: 1px; + } +`,r6=(0,K.ZP)(ea.Z)` + position: absolute; + right: 12px; + height: 24px; + width: 24px; + stroke: var(--privy-color-accent); + cursor: pointer; + + :active { + stroke: var(--privy-color-accent-light); + } +`,r7=K.ZP.progress` + height: 4px; + width: 100%; + margin: 8px 0; + + /* border-radius: 9999px; */ + ::-webkit-progress-bar { + border-radius: 8px; + background: var(--privy-color-foreground-4); + } + + ::-webkit-progress-value { + border-radius: 8px; + transition: all 0.1s ease-out; + background: ${({label:e})=>"Strong"===e&&"#78dca6"||"Medium"===e&&"var(--privy-color-warn)"||"var(--privy-color-error)"}; + } +`,Cc=({buttonHideAnimations:e,buttonLoading:t,password:i,onSubmit:a,onBack:s})=>{let[l,p]=(0,u.useState)(!1),[f,w]=(0,u.useState)(""),y=i===f;return(0,u.useEffect)(()=>{f&&!l&&p(!0)},[f]),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{title:"Confirm Password",closeable:!1,backFn:s}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rK,{children:[(0,k.jsxs)(r1,{children:[(0,k.jsx)(en.Z,{height:48,width:48,stroke:"var(--privy-color-background)",fill:"var(--privy-color-accent)"}),(0,k.jsx)("h3",{style:{color:"var(--privy-color-foreground)"},children:"Confirm your password"}),(0,k.jsx)("p",{style:{color:"var(--privy-color-foreground-2)"},children:"Please re-enter your password below to continue."})]}),(0,k.jsx)(r0,{children:(0,k.jsx)(rQ,{value:f,onChange:e=>w(e.target.value),onBlur:()=>p(!0),placeholder:"confirm your password"})}),(0,k.jsx)(rV,{"aria-hidden":!l||y,error:!0,children:"Passwords do not match"})]}),(0,k.jsx)(rY,{onClick:a,loading:t,disabled:!y,hideAnimations:e,children:"Continue"}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},bc=({className:e,checked:t,color:i="var(--privy-color-accent)",...a})=>(0,k.jsx)("label",{children:(0,k.jsxs)(r8,{className:e,children:[(0,k.jsx)(ie,{checked:t,...a}),(0,k.jsx)(it,{color:i,checked:t,children:(0,k.jsx)(r9,{viewBox:"0 0 24 24",children:(0,k.jsx)("polyline",{points:"20 6 9 17 4 12"})})})]})}),r8=K.ZP.div` + display: inline-block; + vertical-align: middle; +`,r9=K.ZP.svg` + fill: none; + stroke: white; + stroke-width: 3px; +`,ie=K.ZP.input.attrs({type:"checkbox"})` + border: 0; + clip: rect(0 0 0 0); + clippath: inset(50%); + height: 1px; + margin: -1px; + overflow: hidden; + padding: 0; + position: absolute; + white-space: nowrap; + width: 1px; +`,it=K.ZP.div` + display: inline-block; + width: 18px; + height: 18px; + transition: all 150ms; + cursor: pointer; + border-color: ${e=>e.color}; + border-radius: 3px; + background: ${e=>e.checked?e.color:"var(--privy-color-background)"}; + + && { + /* This is necessary to override css reset for border width */ + border-width: 1px; + } + + ${ie}:focus + & { + box-shadow: 0 0 0 1px ${e=>e.color}; + } + + ${r9} { + visibility: ${e=>e.checked?"visible":"hidden"}; + } +`,Pc=({buttonHideAnimations:e,buttonLoading:t,onSubmit:i,onBack:a,config:s})=>{let[l,p]=(0,u.useState)(!1);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{title:"Confirm Password",closeable:!1,backFn:a}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rK,{children:[(0,k.jsxs)(r1,{children:[(0,k.jsx)(en.Z,{height:48,width:48,stroke:"var(--privy-color-background)",fill:"var(--privy-color-error)"}),(0,k.jsx)("h3",{style:{color:"var(--privy-color-foreground)"},children:"Confirm you have saved"}),(0,k.jsx)("p",{style:{color:"var(--privy-color-foreground-2)"},children:"Losing access to your password means you will lose access to your account."})]}),(0,k.jsx)(r2,{children:(0,k.jsxs)(r3,{style:{color:"var(--privy-color-error)"},children:[(0,k.jsx)(bc,{color:"var(--privy-color-error)",checked:l,onChange:()=>p(e=>!e)}),"I understand losing my password means losing my account."]})})]}),(0,k.jsxs)(ir,{children:["user"===s.initiatedBy&&(0,k.jsx)(xn,{onClick:s.onCancel,disabled:t,children:"Cancel"}),(0,k.jsx)(rY,{onClick:i,loading:t,hideAnimations:e,disabled:!l,children:"Set Password"})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},ir=K.ZP.div` + display: flex; + gap: 10px; +`,ii=/[a-z]/,ia=/[A-Z]/,io=/[0-9]/,ic="!@#$%^&*()\\-_+.",ih=`a-zA-Z0-9${ic}`,iu=RegExp(`[${ic}]`),im=RegExp(`[${ih}]`),iw=RegExp(`^[${ih}]{6,}$`),kc=(e="")=>{let t=e.split("").filter(e=>!im.test(e)).map(e=>e.replace(" ","SPACE"));return[...new Set(t)]},Dn=()=>eh.OW(4,eu.k),Nc=({buttonHideAnimations:e,buttonLoading:t,password:i="",config:a,onSubmit:s,onClose:l,onPasswordChange:p,onPasswordGenerate:f})=>{let[w,y]=(0,u.useState)(!1);(0,u.useEffect)(()=>{i&&!w&&y(!0)},[i]);let C=(0,u.useMemo)(()=>w?6>(i?.length||0)?"Password must be at least 6 characters":iw.test(i||"")?null:`Invalid characters used ( ${kc(i).join(" ")} )`:null,[i,w]),A=(0,u.useMemo)(()=>C?{value:0,label:"Weak"}:function(e=""){let t=function(e=""){return(.3*function(e){if(e.length<8)return 0;let t=0;return ii.test(e)&&(t+=1),ia.test(e)&&(t+=1),io.test(e)&&(t+=1),iu.test(e)&&(t+=1),Math.max(0,Math.min(1,t/3))}(e)+ec()(e)/95)/2}(e);return{value:t,label:t>.9?"Strong":t>.5?"Medium":"Weak"}}(i),[i,C]),T=(0,u.useMemo)(()=>!!(!i?.length||C),[C,i]);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:l,title:"Secure your account",closeable:"user"===a.initiatedBy}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rK,{children:[(0,k.jsxs)(r1,{children:[(0,k.jsx)(eo.Z,{height:48,width:48,stroke:"var(--privy-color-accent)"}),(0,k.jsx)("h3",{style:{color:"var(--privy-color-foreground)"},children:"Set your password"}),(0,k.jsx)("p",{style:{color:"var(--privy-color-foreground-2)"},children:"Select a strong, memorable password to secure your account."})]}),(0,k.jsxs)(r0,{children:[(0,k.jsx)(rQ,{value:i,onChange:e=>p(e.target.value),placeholder:"enter or generate a strong password"}),(0,k.jsx)(r6,{onClick:f})]}),(0,k.jsx)(r7,{value:0===A.value?.01:A.value,label:A.label}),(0,k.jsx)(rV,{error:!!C,children:C||`Password Strength: ${w?A.label:"--"}`}),(0,k.jsxs)(iy,{children:[(0,k.jsx)(ix,{children:(0,k.jsxs)(r2,{children:[(0,k.jsxs)(r3,{children:[(0,k.jsx)(ei.Z,{width:24,height:24,fill:"var(--privy-color-accent)"}),"This password is used to secure your account."]}),(0,k.jsxs)(r3,{children:[(0,k.jsx)(ei.Z,{width:24,height:24,fill:"var(--privy-color-accent)"}),"You will only be asked to enter it when signing on to a new device."]})]})}),(0,k.jsx)(rY,{onClick:s,loading:t,disabled:T,hideAnimations:e,children:"Continue"})]})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},ix=(0,K.ZP)(r2)` + flex: 1; + padding-top: 1rem; +`,iy=K.ZP.div` + display: flex; + flex-direction: column; + height: 100%; +`,Oc=({buttonHideAnimations:e,buttonLoading:t,appName:i,password:a,onSubmit:s,onBack:l})=>{let[p,f]=(0,u.useState)(!1),w=(0,u.useCallback)(()=>{f(!0),a&&navigator.clipboard.writeText(a)},[a]),y=(0,u.useCallback)(()=>{let e=document.createElement("a"),t=i.toLowerCase().replace(/[^a-z\s]/g,"").replace(/\s/g,"-"),s=new Blob([yf(i,a)],{type:"text/plain"}),l=URL.createObjectURL(s);e.href=l,e.target="_blank",e.download=`${t}-privy-wallet-recovery.txt`,document.body.appendChild(e),e.click(),setTimeout(()=>{e.remove(),URL.revokeObjectURL(l)},5e3)},[a]);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:l,title:"Save Password",closeable:!1}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rK,{children:[(0,k.jsxs)(r1,{children:[(0,k.jsx)(en.Z,{height:48,width:48,stroke:"var(--privy-color-background)",fill:"var(--privy-color-accent)"}),(0,k.jsx)("h3",{style:{color:"var(--privy-color-foreground)"},children:"Save your password"}),(0,k.jsx)("p",{style:{color:"var(--privy-color-foreground-2)"},children:"For your security, this password cannot be reset if you lose your device. Make sure to secure it to keep your assets safe."})]}),(0,k.jsx)(r0,{centered:!0,children:(0,k.jsx)(rX,{children:a})}),(0,k.jsxs)("div",{style:{display:"flex",margin:"12px 0",gap:"12px"},children:[(0,k.jsx)(r5,{onClick:w,children:p?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(ep.Z,{style:{width:24,height:24},stroke:"var(--privy-color-accent)"}),"Copied"]}):(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(em.Z,{style:{width:24,height:24},stroke:"var(--privy-color-accent)"}),"Copy"]})}),(0,k.jsxs)(r5,{onClick:y,children:[(0,k.jsx)(ef.Z,{style:{width:24,height:24},stroke:"var(--privy-color-accent)"}),"Download"]})]})]}),(0,k.jsx)(rY,{onClick:s,loading:t,hideAnimations:e,children:"Continue"}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},yf=(e,t)=>`Your wallet recovery password for ${e} is + +${t} + +You will need this password to access your ${e} wallet on a new device. Please keep it somewhere safe.`,Mc=({error:e,onClose:t})=>(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{closeable:!1}),(0,k.jsx)(t4,{}),e?(0,k.jsxs)(t0,{children:[(0,k.jsx)(eg.Z,{stroke:"var(--privy-color-error)",width:"64px",height:"64px"}),(0,k.jsx)(fe,{title:"Something went wrong",description:e})]}):(0,k.jsxs)(t0,{children:[(0,k.jsx)(ew.Z,{stroke:"var(--privy-color-success)",width:"64px",height:"64px"}),(0,k.jsx)(fe,{title:"Success"})]}),(0,k.jsx)(V,{onClick:t,children:"Close"}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]}),bf=(e,t)=>{switch(e){case"creating":return"back"===t?e:"saving";case"saving":return"back"===t?"creating":"confirming";case"confirming":return"back"===t?"saving":"finalizing";case"finalizing":return"back"===t?"confirming":"done";default:return e}},Dc=()=>{let[e,t]=(0,u.useReducer)(bf,"creating");return{send:t,state:e}},Un=({onSubmit:e,...t})=>{let{send:i,state:a}=Dc(),s=(0,u.useCallback)(async()=>{"finalizing"===a&&await e(),i("next")},[a,i,e]);(0,u.useEffect)(()=>{let e;return"done"===a&&"automatic"===t.config.initiatedBy&&(e=setTimeout(()=>t.onClose?.(),1400)),()=>{e&&clearTimeout(e)}},[a,t.config.initiatedBy,t.onClose]);let l=(0,u.useCallback)(()=>{i("back")},[i]);return"creating"===a?(0,k.jsx)(Nc,{...t,onSubmit:s}):"saving"===a?(0,k.jsx)(Oc,{...t,onSubmit:s,onBack:l}):"confirming"===a?(0,k.jsx)(Cc,{...t,onSubmit:s,onBack:l}):"finalizing"===a?(0,k.jsx)(Pc,{...t,onSubmit:s,onBack:l}):"done"===a?(0,k.jsx)(Mc,{...t,onSubmit:s}):null},iv=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin: 20px 0; + gap: 4px; + + & h3 { + font-size: 18px; + font-style: normal; + font-weight: 600; + line-height: 24px; + } + + & p { + max-width: 300px; + font-size: 14px; + font-style: normal; + font-weight: 400; + line-height: 20px; + } +`,ib=K.ZP.div` + display: flex; + height: 100%; + flex-direction: column; + justify-content: space-between; +`,iC=K.ZP.div` + line-height: 20px; + height: 20px; + font-size: 13px; + color: var(--privy-color-error); + text-align: left; + margin-top: 0.5rem; +`,ij=(0,K.ZP)(V)` + ${e=>e.hideAnimations&&K.iv` + && { + // Remove animations because the recoverWallet task on the iframe partially + // blocks the renderer, so the animation stutters and doesn't look good + transition: none; + } + `} +`,zn=({size:e=61,...t})=>(0,k.jsx)("svg",{width:e,height:e,viewBox:"0 0 61 61",fill:"none",xmlns:"http://www.w3.org/2000/svg",...t,children:(0,k.jsxs)("g",{id:"moonpay_symbol_wht 2",children:[(0,k.jsx)("rect",{x:"1.3374",y:"1",width:"59",height:"59",rx:"11.5",fill:"#7715F5"}),(0,k.jsx)("path",{id:"Vector",d:"M43.8884 23.3258C45.0203 23.3258 46.1268 22.9901 47.068 22.3613C48.0091 21.7324 48.7427 20.8386 49.1759 19.7928C49.6091 18.747 49.7224 17.5962 49.5016 16.4861C49.2807 15.3759 48.7357 14.3561 47.9353 13.5557C47.1349 12.7553 46.1151 12.2102 45.0049 11.9893C43.8947 11.7685 42.7439 11.8819 41.6982 12.3151C40.6524 12.7482 39.7585 13.4818 39.1297 14.423C38.5008 15.3641 38.1651 16.4707 38.1651 17.6026C38.165 18.3542 38.3131 19.0985 38.6007 19.7929C38.8883 20.4873 39.3098 21.1182 39.8413 21.6496C40.3728 22.1811 41.0037 22.6027 41.6981 22.8903C42.3925 23.1778 43.1367 23.3259 43.8884 23.3258ZM26.3395 49.1017C23.5804 49.1017 20.8832 48.2836 18.5891 46.7507C16.295 45.2178 14.5069 43.039 13.4511 40.49C12.3952 37.9409 12.1189 35.1359 12.6572 32.4298C13.1955 29.7237 14.5241 27.238 16.4751 25.287C18.4262 23.336 20.9118 22.0074 23.6179 21.4691C26.324 20.9308 29.129 21.2071 31.6781 22.2629C34.2272 23.3189 36.406 25.1069 37.9389 27.401C39.4717 29.6952 40.2899 32.3923 40.2899 35.1514C40.2899 36.9835 39.9291 38.7975 39.2281 40.49C38.527 42.1826 37.4994 43.7205 36.204 45.0159C34.9086 46.3113 33.3707 47.3389 31.6781 48.04C29.9856 48.741 28.1715 49.1018 26.3395 49.1017Z",fill:"white"})]})}),va=({title:e,desc:t,icon:i})=>(0,k.jsxs)(iP,{children:[(0,k.jsx)(iT,{children:i}),(0,k.jsxs)(iS,{children:[(0,k.jsx)(iE,{children:e}),(0,k.jsx)(iA,{children:t})]})]}),$c=({app:e,signedUrl:t,onContinue:i})=>(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(ik,{children:[(0,k.jsx)(zn,{size:"3.75rem"}),(0,k.jsxs)(i_,{children:[e?.name," uses ",(0,k.jsx)("span",{style:{fontWeight:"bold"},children:"Moonpay"})," to fund your account"]}),(0,k.jsxs)(iN,{children:[(0,k.jsx)(va,{icon:(0,k.jsx)(eC.Z,{width:"1rem"}),title:"Purchase assets to fund your account",desc:(0,k.jsxs)(k.Fragment,{children:["Connect a payment method (",(0,k.jsx)("strong",{children:"debit card recommended"}),") to purchase digital assets."]})}),(0,k.jsx)(va,{icon:(0,k.jsx)(ej.Z,{width:"1rem"}),title:"Compliance takes time",desc:"Funding a new account may take a few hours. You'll be good to go thereafter."}),(0,k.jsx)(va,{icon:(0,k.jsx)(ek.Z,{width:"1rem"}),title:"Your data belongs to you",desc:"MoonPay does not sell your data and will only use it with your permission."})]}),(0,k.jsx)(iI,{className:"mobile-only"})]}),(0,k.jsx)(tJ,{children:(0,k.jsx)(t$,{href:t,target:"_blank",rel:"noopener noreferrer",annotation:"By clicking continue, you will be taken to MoonPay in a new tab",onClick:i,children:"Continue to Moonpay"})})]}),ik=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding-top: 2rem; +`,i_=K.ZP.span` + color: var(--privy-color-foreground); + text-align: center; + font-size: 1.125rem; + font-weight: 500; + line-height: 1.25rem; /* 111.111% */ + margin: 1.5rem 0; + text-align: center; + max-width: 19.5rem; +`,iE=K.ZP.span` + color: var(--privy-color-foreground); + font-size: 0.875rem; + font-weight: 500; + line-height: 1.225rem; + width: 100%; +`,iA=K.ZP.span` + color: var(--privy-color-foreground-2); + font-size: 0.875rem; + font-weight: 400; + line-height: 1.225rem; +`,iP=K.ZP.div` + display: flex; + align-items: flex-start; + gap: 0.5rem; + align-self: stretch; +`,iS=K.ZP.div` + display: flex; + flex-direction: column; + gap: 0.25rem; + align-items: flex-start; + text-align: left; + flex: 1 0 0; +`,iT=K.ZP.div` + padding-top: 2px; +`,iN=K.ZP.div` + display: flex; + flex-direction: column; + gap: 1.25rem; + margin: 0 0.5rem; +`,iI=K.ZP.div` + margin: 30px 0; +`,iO="moonpay",iL="sdk_fiat_on_ramp_completed_with_status";async function qc(e,t,i,a,s=!1){let l=i.currencyCode?{}:{defaultCurrencyCode:"ETH_ETHEREUM"},u=i.uiConfig||{accentColor:a.accent,theme:a.colorScheme};return e.signMoonpayOnRampUrl({address:t,useSandbox:s,config:{...i,...l,...u}})}async function ry(e,t){return(0,W.Wg)(`https://api.moonpay.com/v1/transactions/ext/${e}`,{query:{apiKey:t?"pk_test_fqWjXZMSFwloh7orvJsRfjiUHXJqFzI":"pk_live_hirbpu0cVcLHrjktC9l7fbc9ctjv0SL"}})}var dy=e=>{switch(e){case"completed":return{title:"You've funded your account!",body:"It may take a few minutes for the assets to appear.",cta:"Continue"};case"failed":return{title:"Something went wrong!",body:(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)("p",{children:["It looks like there was an issue with your payment. Please contact"," ",(0,k.jsx)("a",{href:"https://support.moonpay.com/hc/en-gb",target:"_blank",rel:"noreferrer noopener",style:{textDecoration:"underline"},children:"Moonpay support"})," ","for assistance."]}),(0,k.jsx)("p",{style:{fontStyle:"italic"},children:"Note that debit cards typically work better than credit cards here."})]}),cta:"Done"};case"serviceFailure":return{title:"Something went wrong!",body:"MoonPay ran into an error when processing your transaction. Try again?",cta:"Done"};case"waitingAuthorization":return{title:"Processing payment",body:"This may take up to a few hours. You will receive an email when the purchase is complete.",cta:"Continue"};default:return{title:"In Progress",body:"Go back to MoonPay to finish funding your account.",cta:""}}},py=({status:e,onClickCta:t})=>{let{title:i,body:a,cta:s}=(0,u.useMemo)(()=>dy(e),[e]);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(iW,{style:{height:"100%",gap:0},children:[(0,k.jsx)(hy,{status:e}),(0,k.jsxs)(t2,{children:[(0,k.jsx)("h3",{children:i}),(0,k.jsx)(iR,{children:a})]})]}),s&&(0,k.jsx)(tJ,{children:(0,k.jsx)(V,{onClick:t,children:s})})]})},uy=e=>e?({completed:"var(--privy-color-success)",failed:"var(--privy-color-error)",serviceFailure:"var(--privy-color-error)",waitingAuthorization:"var(--privy-color-accent)",pending:"var(--privy-color-foreground-4)"})[e]:"var(--privy-color-foreground-4)",my=e=>{switch(e){case"serviceFailure":case"failed":return er.Z;case"completed":return ei.Z;case"waitingAuthorization":return()=>(0,k.jsx)(e_.Z,{width:"3rem",height:"3rem",style:{backgroundColor:"var(--privy-color-foreground-4)",color:"var(--privy-color-background)",borderRadius:"100%",padding:"0.5rem",margin:"0.5rem"}});default:return}},hy=({status:e})=>{if(!e||"pending"===e){let e="var(--privy-color-foreground-4)";return(0,k.jsxs)("div",{style:{position:"relative"},children:[(0,k.jsx)(tD,{color:e,style:{position:"absolute"}}),(0,k.jsx)(tF,{color:e}),(0,k.jsx)(zn,{size:"3rem",style:{position:"absolute",top:"1rem",left:"1rem"}})]})}let t=my(e),i=uy(e);return(0,k.jsx)("div",{style:{borderColor:i,display:"flex",justifyContent:"center",alignItems:"center",borderRadius:"100%",borderWidth:2,padding:"0.5rem",marginBottom:"0.5rem"},children:t&&(0,k.jsx)(t,{width:"4rem",height:"4rem",color:i})})},iR=K.ZP.p` + font-size: 1rem; + color: var(--privy-color-foreground-3); + margin-bottom: 1rem; + display: flex; + flex-direction: column; + gap: 1rem; +`,iW=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin-left: 1.75rem; + margin-right: 1.75rem; +`,Zc=({style:e,...t})=>(0,k.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",width:"17",height:"17",viewBox:"0 0 17 17",style:{height:"1.25rem",width:"1.25rem",...e},...t,children:(0,k.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",fillRule:"evenodd",clipRule:"evenodd",d:"M16.5 8.67993C16.5 9.82986 15.853 10.8287 14.9032 11.3322C15.2188 12.3599 14.97 13.5237 14.1569 14.3368C13.3437 15.1499 12.18 15.3987 11.1523 15.0831C10.6488 16.0329 9.64993 16.6799 8.5 16.6799C7.35007 16.6799 6.35126 16.0329 5.84771 15.0831C4.82003 15.3987 3.65627 15.1499 2.84314 14.3368C2.03001 13.5237 1.78124 12.3599 2.09681 11.3322C1.14699 10.8287 0.5 9.82986 0.5 8.67993C0.5 7.53 1.14699 6.53119 2.0968 6.02764C1.78125 4.99996 2.03003 3.83621 2.84315 3.02309C3.65627 2.20997 4.82002 1.96119 5.8477 2.27675C6.35125 1.32692 7.35007 0.679932 8.5 0.679932C9.64992 0.679932 10.6487 1.32691 11.1523 2.27672C12.18 1.96115 13.3437 2.20993 14.1569 3.02305C14.97 3.83618 15.2188 4.99996 14.9032 6.02764C15.853 6.53119 16.5 7.53 16.5 8.67993ZM12.2659 6.68856C12.5654 6.40238 12.5761 5.92763 12.29 5.62818C12.0038 5.32873 11.529 5.31797 11.2296 5.60416C9.73022 7.03711 8.40877 8.65489 7.3018 10.4211L5.78033 8.89963C5.48744 8.60673 5.01256 8.60673 4.71967 8.89963C4.42678 9.19252 4.42678 9.66739 4.71967 9.96029L6.92031 12.1609C7.08544 12.3261 7.31807 12.4048 7.54957 12.374C7.78106 12.3432 7.98499 12.2064 8.1012 12.0038C9.23027 10.0356 10.6362 8.24613 12.2659 6.68856Z",fill:"var(--privy-color-accent)"})}),iM=K.ZP.div` + display: flex; + flex-direction: column; + justify-content: flex-start; + gap: 4px; +`,iU=K.ZP.div` + &&& { + margin-left: 7px; /* TODO: This is a total hack */ + border-left: 2px solid var(--privy-color-foreground-4); + height: 12px; + } +`,bt=({children:e})=>(0,k.jsxs)(iD,{children:[(0,k.jsx)(Zc,{style:{width:"16px",height:"16px"}}),e]}),iD=K.ZP.div` + display: flex; + justify-content: flex-start; + justify-items: center; + text-align: left; + gap: 8px; + + && { + a { + text-decoration: underline; + color: var(--privy-color-accent); + } + + svg { + margin-top: auto; + margin-bottom: auto; + } + } +`,ba=(e,t,i,a,s)=>{for(let l=t;l{let t=eE.create(e,{errorCorrectionLevel:"high"}).modules,i=qs(Array.from(t.data),t.size);return i=ba(i,0,0,7,7),i=ba(i,i.length-7,0,7,7),i=ba(i,0,i.length-7,7,7)},xy=({x:e,y:t,cellSize:i,bgColor:a,fgColor:s})=>(0,k.jsx)(k.Fragment,{children:[0,1,2].map(l=>(0,k.jsx)("circle",{r:i*(7-2*l)/2,cx:e+7*i/2,cy:t+7*i/2,fill:l%2!=0?a:s},`finder-${e}-${t}-${l}`))}),Py=({cellSize:e,matrixSize:t,bgColor:i,fgColor:a})=>(0,k.jsx)(k.Fragment,{children:[[0,0],[(t-7)*e,0],[0,(t-7)*e]].map(([t,s])=>(0,k.jsx)(xy,{x:t,y:s,cellSize:e,bgColor:i,fgColor:a}))}),Ty=({matrix:e,cellSize:t,color:i})=>(0,k.jsx)(k.Fragment,{children:e.map((e,a)=>e.map((e,s)=>e?(0,k.jsx)("circle",{r:t/2.5,cx:a*t+t/2,cy:s*t+t/2,fill:i},`circle-${a}-${s}`):(0,k.jsx)(k.Fragment,{})))}),Xc=(e,t)=>e-e%t,_y=({outputSize:e,cellSize:t,element:i,size:a,padding:s,bgColor:l})=>{if(!i)return(0,k.jsx)(k.Fragment,{});let u=a||40,p=s||4,f=e/2-u/2-p;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)("rect",{x:Xc(f,t),y:Xc(f,t),width:u+2*p+(f%t?t+.5:.5),height:u+2*p+(f%t?t+.5:.5),fill:l}),(0,k.jsx)(i,{x:e/2-u/2,y:e/2-u/2,height:u,width:u})]})},Sy=e=>{let t=e.outputSize,i=Ey(e.url),a=t/i.length;return(0,k.jsxs)("svg",{height:e.outputSize,width:e.outputSize,viewBox:`0 0 ${e.outputSize} ${e.outputSize}`,style:{height:"100%",width:"100%"},children:[(0,k.jsx)(Ty,{matrix:i,cellSize:a,color:e.fgColor}),(0,k.jsx)(Py,{cellSize:a,matrixSize:i.length,fgColor:e.fgColor,bgColor:e.bgColor}),(0,k.jsx)(_y,{outputSize:e.outputSize,cellSize:a,element:e.logo?.element,bgColor:e.bgColor})]})},iF=K.ZP.div` + display: flex; + justify-content: center; + align-items: center; + height: ${e=>`${e.size}px`}; + width: ${e=>`${e.size}px`}; + padding: 5px; + margin: auto; + background-color: ${e=>e.bgColor}; + + && { + border-width: 2px; + border-color: ${e=>e.fgColor}; + border-radius: var(--privy-border-radius-md); + } +`,ed=e=>{let t=e.bgColor||"#FFFFFF",i=e.fgColor||"#000000",a=e.size||160;return(0,k.jsx)(iF,{size:a,bgColor:t,fgColor:i,children:(0,k.jsx)(Sy,{url:e.url,logo:{element:e.squareLogoElement},outputSize:a,bgColor:t,fgColor:i})})},od=({size:e})=>(0,k.jsx)(ed,{url:"https://coinbase-wallet.onelink.me/q5Sx/fdb9b250",squareLogoElement:pt,size:e,fgColor:"#1F1F1F"}),nd=e=>(0,k.jsx)("svg",{width:"160",height:"160",viewBox:"0 0 160 160",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:(0,k.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M68.853 62.127c-5.174.517-8.978 4.95-8.978 10.149v15.336c0 5.248 3.873 9.7 9.098 10.196 3.623.344 7.71.64 11.027.64 5.445 0 12.964-.799 17.098-1.294a3.445 3.445 0 0 0 3.027-3.436v-19.05c0-1.75-1.29-3.228-3.027-3.436-3.657-.438-9.961-1.113-15.136-1.264a66.647 66.647 0 0 0-1.965-.03c-.72 0-1.478.013-2.262.04-3.046.1-6.453.373-9.467.669a1.677 1.677 0 0 1-.174-3.347c3.804-.373 8.282-.717 11.903-.717 4.034 0 9.137.427 13.193.847 1.322.137 2.54.274 3.58.397v-1.582c0-1.734-1.264-3.203-2.983-3.426-3.83-.497-10.563-1.267-15.464-1.267-2.848 0-6.314.26-9.47.575Zm25.399 24.581a2.516 2.516 0 1 0 0-5.031 2.516 2.516 0 0 0 0 5.031Z",fill:"var(--privy-color-accent)"})}),id=({style:e,...t})=>(0,k.jsxs)("svg",{width:"286",height:"183",viewBox:"0 0 286 183",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{height:"1.25rem",width:"1.25rem",...e},...t,children:[(0,k.jsx)("rect",{x:"198.5",y:"133",width:"50",height:"50",rx:"25",fill:"#E1E7EF"}),(0,k.jsx)(Ce,{x:"206",y:"140",width:"36",height:"36"}),(0,k.jsx)("rect",{x:"192",y:"30",width:"50",height:"50",rx:"25",fill:"#0C5BFF"}),(0,k.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M205 55C205 61.6274 210.373 67 217 67C223.627 67 229 61.6274 229 55C229 48.3726 223.627 43 217 43C210.373 43 205 48.3726 205 55ZM213.933 51.1333C213.491 51.1333 213.133 51.4915 213.133 51.9333V58.0667C213.133 58.5085 213.491 58.8667 213.933 58.8667H220.067C220.508 58.8667 220.867 58.5085 220.867 58.0667V51.9333C220.867 51.4915 220.508 51.1333 220.067 51.1333H213.933Z",fill:"white"}),(0,k.jsx)("rect",{x:"39.5",y:"18",width:"50",height:"50",rx:"50",fill:"#AB9FF2"}),(0,k.jsx)(Ke,{x:"44.5",y:"23",width:"40",height:"40"}),(0,k.jsx)("rect",{x:"46.5",y:"124",width:"50",height:"50",rx:"25",fill:"#141414"}),(0,k.jsx)("g",{clipPath:"url(#clip0_428_81)",children:(0,k.jsx)("path",{d:"M62.1497 143.578C67.3134 138.585 75.6867 138.585 80.8505 143.578L81.4722 144.179C81.5335 144.238 81.5822 144.308 81.6155 144.386C81.6488 144.463 81.666 144.547 81.666 144.631C81.666 144.715 81.6488 144.799 81.6155 144.876C81.5822 144.954 81.5335 145.024 81.4722 145.083L79.3462 147.139C79.2835 147.199 79.1996 147.232 79.1123 147.232C79.025 147.232 78.9411 147.199 78.8784 147.139L78.0232 146.311C74.421 142.829 68.58 142.829 64.977 146.311L64.0611 147.197C63.9984 147.257 63.9145 147.29 63.8272 147.29C63.7399 147.29 63.656 147.257 63.5933 147.197L61.4672 145.141C61.4059 145.083 61.3572 145.012 61.3239 144.935C61.2906 144.857 61.2735 144.774 61.2735 144.689C61.2735 144.605 61.2906 144.521 61.3239 144.444C61.3572 144.366 61.4059 144.296 61.4672 144.237L62.1497 143.578ZM85.248 147.829L87.1397 149.659C87.201 149.718 87.2497 149.788 87.283 149.865C87.3163 149.943 87.3334 150.027 87.3334 150.111C87.3334 150.195 87.3163 150.279 87.283 150.356C87.2497 150.434 87.201 150.504 87.1397 150.563L78.6081 158.812C78.4828 158.933 78.315 159 78.1403 159C77.9656 159 77.7978 158.933 77.6725 158.812L71.6177 152.957C71.5864 152.927 71.5443 152.91 71.5005 152.91C71.4567 152.91 71.4147 152.927 71.3833 152.957L65.3285 158.812C65.2032 158.933 65.0354 159 64.8607 159C64.686 159 64.5182 158.933 64.3929 158.812L55.8605 150.563C55.7992 150.504 55.7505 150.434 55.7172 150.356C55.6839 150.279 55.6667 150.195 55.6667 150.111C55.6667 150.027 55.6839 149.943 55.7172 149.865C55.7505 149.788 55.7992 149.718 55.8605 149.659L57.7531 147.829C57.8783 147.709 58.0459 147.642 58.2204 147.642C58.3949 147.642 58.5625 147.709 58.6878 147.829L64.7427 153.684C64.774 153.714 64.816 153.731 64.8598 153.731C64.9036 153.731 64.9457 153.714 64.977 153.684L71.0319 147.829C71.1572 147.709 71.325 147.641 71.4997 147.641C71.6743 147.641 71.8422 147.709 71.9675 147.829L78.0232 153.684C78.0545 153.714 78.0965 153.731 78.1403 153.731C78.1841 153.731 78.2262 153.714 78.2575 153.684L84.3124 147.829C84.4377 147.709 84.6055 147.641 84.7802 147.641C84.9549 147.641 85.1227 147.709 85.248 147.829Z",fill:"white"})}),(0,k.jsx)("rect",{x:"103.5",y:"58",width:"78",height:"78",rx:"39",fill:"var(--privy-color-foreground-accent)"}),(0,k.jsx)(nd,{x:"63",y:"17"}),(0,k.jsx)("rect",{x:"103.5",y:"58",width:"78",height:"78",rx:"39",stroke:"#E1E7EF",strokeWidth:"2"}),(0,k.jsx)("path",{fill:"var(--privy-color-accent)",d:"M269.405 111c8.865 0 16.052-7.163 16.052-16s-7.187-16-16.052-16c-8.865 0-16.051 7.163-16.051 16s7.186 16 16.051 16ZM133.971 24c6.649 0 12.039-5.373 12.039-12s-5.39-12-12.039-12-12.039 5.373-12.039 12 5.39 12 12.039 12ZM15.592 112c4.986 0 9.029-4.029 9.029-9 0-4.97-4.043-9-9.03-9-4.986 0-9.028 4.03-9.028 9 0 4.971 4.042 9 9.029 9Z"}),(0,k.jsx)("path",{fill:"var(--privy-color-accent-light)",d:"M152.029 177c5.541 0 10.032-4.477 10.032-10s-4.491-10-10.032-10-10.032 4.477-10.032 10 4.491 10 10.032 10ZM263.386 21c4.432 0 8.026-3.582 8.026-8s-3.594-8-8.026-8c-4.433 0-8.026 3.582-8.026 8s3.593 8 8.026 8ZM7.064 36c3.602 0 6.521-2.91 6.521-6.5s-2.92-6.5-6.52-6.5C3.462 23 .542 25.91.542 29.5S3.463 36 7.064 36Z"}),(0,k.jsx)("defs",{children:(0,k.jsx)("clipPath",{id:"clip0_428_81",children:(0,k.jsx)("rect",{width:"31.6667",height:"19.1667",fill:"white",transform:"translate(55.6667 139.833)"})})})]}),xa=()=>{let{navigate:e}=v(),t="https://chrome.google.com/webstore/detail/metamask/nkbihfbeogaeaoehlefnkodbefgpgknn?hl=en";return T.vU&&(t="https://addons.mozilla.org/en-US/firefox/addon/ether-metamask/"),(0,k.jsxs)(iV,{children:[(0,k.jsx)(vt,{title:"Create a MetaMask wallet",description:"Follow the instructions below to get started."}),(0,k.jsx)(iK,{children:(0,k.jsx)(Ce,{style:{width:"152px",height:"152px"}})}),(0,k.jsxs)(iM,{children:[(0,k.jsx)(bt,{children:(0,k.jsxs)("div",{children:[(0,k.jsx)("span",{children:"Install the "}),(0,k.jsx)("a",{href:t,target:"_blank",children:"MetaMask browser extension"})]})}),(0,k.jsx)(iU,{}),(0,k.jsx)(bt,{children:"Set up your first wallet"}),(0,k.jsx)(iU,{}),(0,k.jsx)(bt,{children:"Store your recovery phrase in a safe place!"})]}),(0,k.jsx)(tq,{onClick:()=>e("LANDING"),children:"Done! I have my wallet"})]})},Pa=()=>{let{navigate:e}=v(),t="https://chrome.google.com/webstore/detail/phantom/bfnaelmomeimhlpmgjnjophhpkkoljpa?hl=en";return T.vU&&(t="https://addons.mozilla.org/en-US/firefox/addon/phantom-app/"),(0,k.jsxs)(iV,{children:[(0,k.jsx)(vt,{title:"Create a Phantom wallet",description:"Follow the instructions below to get started."}),(0,k.jsx)(iK,{children:(0,k.jsx)(Ke,{style:{width:"152px",height:"152px"}})}),(0,k.jsxs)(iM,{children:[(0,k.jsx)(bt,{children:(0,k.jsxs)("div",{children:[(0,k.jsx)("span",{children:"Install the "}),(0,k.jsx)("a",{href:t,target:"_blank",children:"Phantom browser extension"})]})}),(0,k.jsx)(iU,{}),(0,k.jsx)(bt,{children:"Set up your first wallet"}),(0,k.jsx)(iU,{}),(0,k.jsx)(bt,{children:"Store your recovery phrase in a safe place!"})]}),(0,k.jsx)(tq,{onClick:()=>e("LANDING"),children:"Done! I have my wallet"})]})},Ta=()=>{let{navigate:e}=v();return(0,k.jsxs)(iV,{children:[(0,k.jsx)(vt,{title:"Create a Coinbase wallet",description:"Follow the instructions below to get started."}),(0,k.jsx)(iK,{style:{marginTop:"-24px"},children:(0,k.jsx)(od,{size:200})}),(0,k.jsxs)(iM,{children:[(0,k.jsx)(bt,{children:"Scan the QR code with your camera"}),(0,k.jsx)(iU,{}),(0,k.jsx)(bt,{children:"Set up your first wallet"}),(0,k.jsx)(iU,{}),(0,k.jsx)(bt,{children:"Store your seed phrase in a safe place!"})]}),(0,k.jsx)(tq,{onClick:()=>e("LANDING"),children:"Done! I have my wallet"})]})},iZ=K.ZP.div` + display: flex; + flex-direction: column; + height: 100%; + flex-grow: 1; + + > svg { + @media (max-width: 440px) { + display: none; + } + } +`,iz=K.ZP.div` + display: flex; + flex-direction: column; + align-items: flex-start; + justify-content: flex-start; + text-align: left; + gap: 20px; +`,i$=K.ZP.div` + display: flex; + flex-direction: column; + width: 100%; + gap: 8px; +`,iB=K.ZP.button` + display: flex; + flex-direction: row; + align-items: center; + gap: 12px; + cursor: pointer; + + width: 100%; + + && { + padding: 12px 16px; + + border: 1px solid var(--privy-color-foreground-4); + border-radius: var(--privy-border-radius-sm); + transition: all 200ms ease-in-out; + } + + > svg { + border-radius: var(--privy-border-radius-sm); + } + + -webkit-user-select: none; + -ms-user-select: none; + user-select: none; + + flex: none; + order: 0; + align-self: stretch; + flex-grow: 0; + + :hover { + border: 1px solid var(--privy-color-accent-light); + } +`,iH=K.ZP.div` + text-align: left; + + p { + font-style: italic; + font-size: 12px; + } +`,iG=K.ZP.div` + margin-top: auto; + display: flex; + align-items: flex-end; + flex-grow: 1; + width: 100%; +`,iq=(0,K.ZP)(V)` + && { + margin-top: 14px; + } +`,iV=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + width: 100%; + gap: 30px; + flex-grow: 1; + + > :first-child > svg { + margin-top: 20px; + } +`,iK=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + width: 100%; +`,iY=K.ZP.div` + display: flex; + justify-content: center; + flex-grow: 1; +`,jn=e=>{let[t,i]=(0,u.useState)(""),[a,s]=(0,u.useState)(!1),[l,p]=(0,u.useState)(null),{isLinking:f,initLoginWithEmail:w,captchaData:y}=_(),{app:C,navigate:A}=v(),T=C?.loginMethods.wallet??!1;(0,u.useEffect)(()=>{document.querySelector("#email-input")?.focus()},[]);let I=$s(t),b=()=>{s(!0),w(t,y.token).then(()=>{y.enabled&&y.remove(),A("AWAITING_PASSWORDLESS_CODE")}).catch(e=>{e?.status===422?p(e.message):e?.privyErrorCode==="allowlist_rejected"?A("ALLOWLIST_REJECTION_SCREEN"):(console.error(e),p("Issue submitting email")),s(!1)})},L="Get started without a wallet.";l?L=l:f?L="​":T||(L="Get started quickly with email");let R=y.enabled&&!y.token&&!y.error,W=void 0!==y.error;return(0,u.useEffect)(()=>{y.error&&p("Issue verifying you are a human")},[y.error]),(0,u.useEffect)(()=>{y.ready&&y.execute()},[y.ready]),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(iJ,{stacked:e.stacked,children:[(0,k.jsxs)(iQ,{standalone:e.stacked,children:[(0,k.jsx)(X.Z,{}),(0,k.jsx)("input",{id:"email-input",type:"email",placeholder:"your@email.com",onChange:e=>i(e.target.value),onKeyUp:e=>{"Enter"===e.key&&b()},value:t,autoComplete:"email"})]}),e.stacked?null:(0,k.jsx)(tK,{disabled:a||!I||R||W,onClick:b,children:a||R?(0,k.jsx)(jt,{}):"Submit"})]}),y.enabled&&(0,k.jsx)("div",{id:"cf-turnstile"}),(0,k.jsx)(iX,{fail:!!l,children:L}),e.stacked?(0,k.jsx)(V,{loading:a||R,loadingText:null,disabled:a||!I||R||W,onClick:b,children:"Submit"}):null]})},iJ=K.ZP.div` + width: 100%; + height: ${e=>e.stacked?"100%":"auto"}; + + display: flex; + align-content: center; + align-items: center; + flex-grow: 1; + + @media (max-width: 440px) { + margin-top: 20px; + } +`,iQ=K.ZP.label` + display: flex; + flex-direction: row; + align-items: center; + position: relative; + width: 100%; + height: ${e=>e.standalone?"64px":"44px"}; + background: var(--privy-color-background); + + > svg { + z-index: 2; + margin-left: 8px; + height: 20px !important; + width: 20px !important; + color: var(--privy-color-foreground-3); + } + + && > input { + position: absolute; + padding-left: 40px; + line-height: 20px; + + /* Mirror parent to handle embedded logo on left */ + border-radius: ${e=>e.standalone?"var(--privy-border-radius-sm)":"var(--privy-border-radius-sm) 0px 0px var(--privy-border-radius-sm)"}; + height: 100%; + width: 100%; + border: 1px solid var(--privy-color-foreground-4); + background: var(--privy-color-background); + } + + /* Mobile */ + @media (max-width: 440px) { + && > input { + font-size: 16px; + line-height: 24px; + } + } +`,iX=K.ZP.div` + line-height: 20px; + height: 20px; + font-size: 13px; + color: ${e=>e.success?"var(--privy-color-success)":e.fail?"var(--privy-color-error)":"var(--privy-color-foreground-3)"}; + display: flex; + justify-content: space-between; + width: 100%; + + > button, + > a { + text-decoration: underline; + } +`,Kn=e=>{let[t,i]=(0,u.useState)(""),[a,s]=(0,u.useState)(!1),[l,p]=(0,u.useState)(null),{isLinking:f,initLoginWithSms:w,captchaData:y}=_(),{app:C,navigate:A}=v(),T=C?.loginMethods.wallet??!1;(0,u.useEffect)(()=>{document.querySelector("#phone-number-input")?.focus()},[]);let I=Vs(t),b=()=>{s(!0),w(t,y.token).then(()=>{y.enabled&&y.remove(),A("AWAITING_PASSWORDLESS_CODE")}).catch(e=>{e?.status===422?p(e.message):e?.privyErrorCode==="allowlist_rejected"?A("ALLOWLIST_REJECTION_SCREEN"):(console.error(e),p("Issue submitting phone number")),s(!1)})},L="Get started without a wallet.";l?L=l:f?L="​":T||(L="Get started quickly with your phone");let R=y.enabled&&!y.token&&!y.error,W=void 0!==y.error;return(0,u.useEffect)(()=>{y.error&&p("Issue verifying you are a human")},[y.error]),(0,u.useEffect)(()=>{y.ready&&y.execute()},[y.ready]),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(i0,{stacked:e.stacked,children:[(0,k.jsxs)(i1,{standalone:e.stacked,children:[(0,k.jsx)(et.Z,{}),(0,k.jsx)("input",{id:"phone-number-input",type:"tel",placeholder:"555 555 5555",onChange:e=>{i(e.target.value)},onKeyUp:e=>{"Enter"===e.key&&b()},value:t,autoComplete:"tel"})]}),e.stacked?null:(0,k.jsx)(tK,{disabled:a||!I||R||W,onClick:b,children:a||R?(0,k.jsx)(jt,{}):"Submit"})]}),y.enabled&&(0,k.jsx)("div",{id:"cf-turnstile"}),(0,k.jsx)(i2,{fail:!!l,children:L}),e.stacked?(0,k.jsx)(V,{loading:a||R,loadingText:null,disabled:a||!I||R||W,onClick:b,children:"Submit"}):null]})},i0=K.ZP.div` + display: flex; + border: 1px solid var(--privy-color-foreground-4); + width: 100%; + + height: ${e=>e.stacked?"100%":"auto"}; + display: flex; + align-content: center; + align-items: center; + flex-grow: 1; + + @media (max-width: 440px) { + margin-top: 20px; + } +`,i1=K.ZP.label` + display: flex; + flex-direction: row; + align-items: center; + position: relative; + width: 100%; + height: ${e=>e.standalone?"64px":"44px"}; + background: var(--privy-color-background); + + > svg { + z-index: 2; + margin-left: 8px; + height: 20px !important; + width: 20px !important; + color: var(--privy-color-foreground-3); + } + + && > input { + position: absolute; + padding-left: 40px; + line-height: 20px; + + /* Mirror parent to handle embedded logo on left */ + border-radius: ${e=>e.standalone?"var(--privy-border-radius-sm)":"var(--privy-border-radius-sm) 0px 0px var(--privy-border-radius-sm)"}; + height: 100%; + width: 100%; + border: 1px solid var(--privy-color-foreground-4); + background: var(--privy-color-background); + } + + /* Mobile */ + @media (max-width: 440px) { + && > input { + font-size: 16px; + line-height: 24px; + } + } +`,i2=K.ZP.div` + line-height: 20px; + height: 20px; + font-size: 13px; + color: ${e=>e.success?"var(--privy-color-success)":e.fail?"var(--privy-color-error)":"var(--privy-color-foreground-3)"}; + display: flex; + justify-content: space-between; + width: 100%; + + > button, + > a { + text-decoration: underline; + } +`,Yn=({style:e,...t})=>(0,k.jsxs)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:"0 0 24 24",style:{height:"24px",...e},...t,children:[(0,k.jsx)("path",{d:"M17.0722 11.6888C17.0471 8.90571 19.3263 7.56847 19.429 7.50274C18.1466 5.60938 16.153 5.35154 15.4417 5.3212C13.7461 5.14678 12.1306 6.32982 11.269 6.32982C10.4074 6.32982 9.08004 5.34648 7.67246 5.37429C5.82158 5.40209 4.11595 6.45874 3.16171 8.13218C1.24068 11.4942 2.6708 16.4817 4.54423 19.2143C5.46091 20.549 6.55041 22.0531 7.98554 21.9975C9.36803 21.9419 9.88905 21.095 11.5571 21.095C13.2251 21.095 13.696 21.9975 15.1537 21.9697C16.6389 21.9393 17.5806 20.6046 18.4897 19.2648C19.5392 17.7153 19.9725 16.2137 19.9975 16.1354C19.965 16.1228 17.1022 15.0155 17.0722 11.6888Z",fill:"currentColor"}),(0,k.jsx)("path",{d:"M14.3295 3.51373C15.0909 2.58347 15.6043 1.28921 15.4641 0C14.3671 0.0455014 13.0396 0.738135 12.2532 1.66838C11.5494 2.48994 10.9307 3.80695 11.0986 5.07089C12.3183 5.16694 13.5681 4.44145 14.3295 3.51373Z",fill:"currentColor"})]}),Jn=({style:e,...t})=>(0,k.jsxs)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:"0 0 71 55",style:{height:"24px",...e},...t,children:[(0,k.jsx)("g",{clipPath:"url(#clip0)",children:(0,k.jsx)("path",{d:"M60.1045 4.8978C55.5792 2.8214 50.7265 1.2916 45.6527 0.41542C45.5603 0.39851 45.468 0.440769 45.4204 0.525289C44.7963 1.6353 44.105 3.0834 43.6209 4.2216C38.1637 3.4046 32.7345 3.4046 27.3892 4.2216C26.905 3.0581 26.1886 1.6353 25.5617 0.525289C25.5141 0.443589 25.4218 0.40133 25.3294 0.41542C20.2584 1.2888 15.4057 2.8186 10.8776 4.8978C10.8384 4.9147 10.8048 4.9429 10.7825 4.9795C1.57795 18.7309 -0.943561 32.1443 0.293408 45.3914C0.299005 45.4562 0.335386 45.5182 0.385761 45.5576C6.45866 50.0174 12.3413 52.7249 18.1147 54.5195C18.2071 54.5477 18.305 54.5139 18.3638 54.4378C19.7295 52.5728 20.9469 50.6063 21.9907 48.5383C22.0523 48.4172 21.9935 48.2735 21.8676 48.2256C19.9366 47.4931 18.0979 46.6 16.3292 45.5858C16.1893 45.5041 16.1781 45.304 16.3068 45.2082C16.679 44.9293 17.0513 44.6391 17.4067 44.3461C17.471 44.2926 17.5606 44.2813 17.6362 44.3151C29.2558 49.6202 41.8354 49.6202 53.3179 44.3151C53.3935 44.2785 53.4831 44.2898 53.5502 44.3433C53.9057 44.6363 54.2779 44.9293 54.6529 45.2082C54.7816 45.304 54.7732 45.5041 54.6333 45.5858C52.8646 46.6197 51.0259 47.4931 49.0921 48.2228C48.9662 48.2707 48.9102 48.4172 48.9718 48.5383C50.038 50.6034 51.2554 52.5699 52.5959 54.435C52.6519 54.5139 52.7526 54.5477 52.845 54.5195C58.6464 52.7249 64.529 50.0174 70.6019 45.5576C70.6551 45.5182 70.6887 45.459 70.6943 45.3942C72.1747 30.0791 68.2147 16.7757 60.1968 4.9823C60.1772 4.9429 60.1437 4.9147 60.1045 4.8978ZM23.7259 37.3253C20.2276 37.3253 17.3451 34.1136 17.3451 30.1693C17.3451 26.225 20.1717 23.0133 23.7259 23.0133C27.308 23.0133 30.1626 26.2532 30.1066 30.1693C30.1066 34.1136 27.28 37.3253 23.7259 37.3253ZM47.3178 37.3253C43.8196 37.3253 40.9371 34.1136 40.9371 30.1693C40.9371 26.225 43.7636 23.0133 47.3178 23.0133C50.9 23.0133 53.7545 26.2532 53.6986 30.1693C53.6986 34.1136 50.9 37.3253 47.3178 37.3253Z",fill:"#5865F2"})}),(0,k.jsx)("defs",{children:(0,k.jsx)("clipPath",{id:"clip0",children:(0,k.jsx)("rect",{width:"71",height:"55",fill:"white"})})})]}),Qn=({style:e,...t})=>(0,k.jsx)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",x:"24",y:"24",viewBox:"0 0 98 96",style:{height:"24px",...e},...t,children:(0,k.jsx)("path",{d:"M48.854 0C21.839 0 0 22 0 49.217c0 21.756 13.993 40.172 33.405 46.69 2.427.49 3.316-1.059 3.316-2.362 0-1.141-.08-5.052-.08-9.127-13.59 2.934-16.42-5.867-16.42-5.867-2.184-5.704-5.42-7.17-5.42-7.17-4.448-3.015.324-3.015.324-3.015 4.934.326 7.523 5.052 7.523 5.052 4.367 7.496 11.404 5.378 14.235 4.074.404-3.178 1.699-5.378 3.074-6.6-10.839-1.141-22.243-5.378-22.243-24.283 0-5.378 1.94-9.778 5.014-13.2-.485-1.222-2.184-6.275.486-13.038 0 0 4.125-1.304 13.426 5.052a46.97 46.97 0 0 1 12.214-1.63c4.125 0 8.33.571 12.213 1.63 9.302-6.356 13.427-5.052 13.427-5.052 2.67 6.763.97 11.816.485 13.038 3.155 3.422 5.015 7.822 5.015 13.2 0 18.905-11.404 23.06-22.324 24.283 1.78 1.548 3.316 4.481 3.316 9.126 0 6.6-.08 11.897-.08 13.526 0 1.304.89 2.853 3.316 2.364 19.412-6.52 33.405-24.935 33.405-46.691C97.707 22 75.788 0 48.854 0z",fill:"currentColor"})}),Xn=({style:e,...t})=>(0,k.jsxs)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{height:"26px",width:"26px",...e},...t,children:[(0,k.jsx)("path",{d:"M22.56 12.25C22.56 11.47 22.49 10.72 22.36 10H12V14.255H17.92C17.665 15.63 16.89 16.795 15.725 17.575V20.335H19.28C21.36 18.42 22.56 15.6 22.56 12.25Z",fill:"#4285F4"}),(0,k.jsx)("path",{d:"M12 23C14.97 23 17.46 22.015 19.28 20.335L15.725 17.575C14.74 18.235 13.48 18.625 12 18.625C9.13504 18.625 6.71004 16.69 5.84504 14.09H2.17004V16.94C3.98004 20.535 7.70004 23 12 23Z",fill:"#34A853"}),(0,k.jsx)("path",{d:"M5.845 14.09C5.625 13.43 5.5 12.725 5.5 12C5.5 11.275 5.625 10.57 5.845 9.91V7.06H2.17C1.4 8.59286 0.999321 10.2846 1 12C1 13.775 1.425 15.455 2.17 16.94L5.845 14.09Z",fill:"#FBBC05"}),(0,k.jsx)("path",{d:"M12 5.375C13.615 5.375 15.065 5.93 16.205 7.02L19.36 3.865C17.455 2.09 14.965 1 12 1C7.70004 1 3.98004 3.465 2.17004 7.06L5.84504 9.91C6.71004 7.31 9.13504 5.375 12 5.375Z",fill:"#EA4335"})]});function ti({style:e,...t}){return(0,k.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0,0,256,256",style:{height:"26px",width:"26px",...e},...t,children:(0,k.jsx)("g",{fill:"#0077b5",strokeWidth:"1",strokeLinecap:"butt",strokeLinejoin:"miter",strokeMiterlimit:"10",style:{mixBlendMode:"normal"},children:(0,k.jsx)("g",{transform:"scale(5.12,5.12)",children:(0,k.jsx)("path",{d:"M41,4h-32c-2.76,0 -5,2.24 -5,5v32c0,2.76 2.24,5 5,5h32c2.76,0 5,-2.24 5,-5v-32c0,-2.76 -2.24,-5 -5,-5zM17,20v19h-6v-19zM11,14.47c0,-1.4 1.2,-2.47 3,-2.47c1.8,0 2.93,1.07 3,2.47c0,1.4 -1.12,2.53 -3,2.53c-1.8,0 -3,-1.13 -3,-2.53zM39,39h-6c0,0 0,-9.26 0,-10c0,-2 -1,-4 -3.5,-4.04h-0.08c-2.42,0 -3.42,2.06 -3.42,4.04c0,0.91 0,10 0,10h-6v-19h6v2.56c0,0 1.93,-2.56 5.81,-2.56c3.97,0 7.19,2.73 7.19,8.26z"})})})})}function oi(e){return(0,k.jsxs)("svg",{xmlns:"http://www.w3.org/2000/svg",fillRule:"evenodd",clipRule:"evenodd",imageRendering:"optimizeQuality",shapeRendering:"geometricPrecision",textRendering:"geometricPrecision",viewBox:"0 0 293768 333327",width:24,height:24,...e,children:[(0,k.jsx)("path",{fill:"#26f4ee",d:"M204958 0c5369 45832 32829 78170 77253 81022v43471l-287 27V87593c-44424-2850-69965-30183-75333-76015l-47060-1v192819c6791 86790-60835 89368-86703 56462 30342 18977 79608 6642 73766-68039V0h58365zM78515 319644c-26591-5471-50770-21358-64969-44588-34496-56437-3401-148418 96651-157884v54345l-164 27v-40773C17274 145544 7961 245185 33650 286633c9906 15984 26169 27227 44864 33011z"}),(0,k.jsx)("path",{fill:"#fb2c53",d:"M218434 11587c3505 29920 15609 55386 35948 70259-27522-10602-43651-34934-47791-70262l11843 3zm63489 82463c3786 804 7734 1348 11844 1611v51530c-25770 2537-48321-5946-74600-21749l4034 88251c0 28460 106 41467-15166 67648-34260 58734-95927 63376-137628 35401 54529 22502 137077-4810 136916-103049v-96320c26279 15803 48830 24286 74600 21748V94050zm-171890 37247c5390-1122 11048-1985 16998-2548v54345c-21666 3569-35427 10222-41862 22528-20267 38754 5827 69491 35017 74111-33931 5638-73721-28750-49999-74111 6434-12304 18180-18959 39846-22528v-51797zm64479-119719h1808-1808z"}),(0,k.jsx)("path",{d:"M206590 11578c5369 45832 30910 73164 75333 76015v51528c-25770 2539-48321-5945-74600-21748v96320c206 125717-135035 135283-173673 72939-25688-41449-16376-141089 76383-155862v52323c-21666 3569-33412 10224-39846 22528-39762 76035 98926 121273 89342-1225V11577l47060 1z",fill:"currentColor"})]})}var ri=({style:e,...t})=>(0,k.jsx)("svg",{width:"24",height:"20",viewBox:"0 0 24 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{height:"26px",width:"26px",...e},...t,children:(0,k.jsx)("path",{d:"M7.54311 19.7551C16.5973 19.7551 21.5516 12.2467 21.5516 5.74656C21.5516 5.53533 21.5516 5.32409 21.542 5.11286C22.5021 4.42156 23.3375 3.54783 24 2.55888C23.1166 2.95254 22.1661 3.21178 21.1675 3.3366C22.1853 2.73171 22.963 1.76196 23.3375 0.609788C22.3869 1.17627 21.3308 1.57953 20.2074 1.80037C19.3049 0.840223 18.0279 0.244934 16.6165 0.244934C13.8993 0.244934 11.6909 2.45326 11.6909 5.17047C11.6909 5.55453 11.7389 5.92898 11.8157 6.29384C7.72554 6.09221 4.09619 4.12391 1.66703 1.14747C1.24457 1.87718 1.00453 2.72211 1.00453 3.62464C1.00453 5.3337 1.87826 6.84112 3.19366 7.72445C2.38714 7.69565 1.62862 7.47481 0.966125 7.10996C0.966125 7.12916 0.966125 7.14837 0.966125 7.17717C0.966125 9.55833 2.66558 11.5554 4.91232 12.0067C4.49945 12.1219 4.06739 12.1795 3.61612 12.1795C3.29927 12.1795 2.99203 12.1507 2.69438 12.0931C3.31848 14.0518 5.14275 15.4728 7.29347 15.5112C5.60362 16.8362 3.4817 17.6235 1.17736 17.6235C0.783698 17.6235 0.390039 17.6043 0.00598145 17.5563C2.17591 18.9389 4.76829 19.7551 7.54311 19.7551Z",fill:"#1da1f2"})}),wd=({showGoogle:e,showTwitter:t,showDiscord:i,showGithub:a,showTiktok:s,showLinkedIn:l,showApple:p})=>{let[f,w]=(0,u.useState)(!1),{initLoginWithOAuth:y}=_(),{app:C}=v(),A=C?.appearance.palette.colorScheme;return(0,k.jsxs)(i3,{children:[e&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("google")},disabled:f,children:(0,k.jsx)(Xn,{})}),t&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("twitter")},disabled:f,children:(0,k.jsx)(ri,{})}),i&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("discord")},disabled:f,children:(0,k.jsx)(Jn,{})}),a&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("github")},disabled:f,children:(0,k.jsx)(Qn,{style:{color:"light"===A?"#000":"#fff"}})}),s&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("tiktok")},disabled:f,children:(0,k.jsx)(oi,{style:{color:"light"===A?"#000":"#fff"}})}),l&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("linkedin")},disabled:f,children:(0,k.jsx)(ti,{})}),p&&(0,k.jsx)(i4,{onClick:()=>{w(!0),y("apple")},disabled:f,children:(0,k.jsx)(Yn,{style:{color:"light"===A?"#000":"#fff"}})})]})},i3=K.ZP.div` + display: flex; + justify-content: space-between; + width: 100%; + gap: 4px; +`,i4=K.ZP.button` + && { + border-radius: var(--privy-border-radius-sm); + cursor: pointer; + height: 44px; + flex: 1; + background-color: var(--privy-color-background); + border: 1px solid var(--privy-color-foreground-4) !important; + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + transition: background-color 200ms ease; + + &:hover { + background-color: var(--privy-color-background-2); + } + &:disabled { + cursor: pointer; + background-color: var(--privy-color-background-2); + } + } +`;function ig(e){return(0,k.jsxs)(i6,{active:e.active,onClick:e.onClick,isOnlySection:e.isOnlySection,tabIndex:e.tabIndex,children:[(0,k.jsx)(i5,{active:e.active,children:(0,k.jsx)("h4",{children:"Connect Wallet"})}),e.active&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(Zt,{connectOnly:e.connectOnly}),(0,k.jsx)(Xt,{})]})]})}function ag(e){let t=!T.tq||e.twitterOAuthOnMobileEnabled&&T.tq,i=e.google||e.discord||e.github||e.tiktok||e.linkedin||e.twitter&&t||e.apple,a=e.email?"Email":"Phone";return(0,k.jsxs)(i6,{active:e.active,onClick:e.onClick,isOnlySection:e.isOnlySection,tabIndex:e.tabIndex,children:[e.isOnlySection?null:(0,k.jsx)(i5,{active:e.active,children:(0,k.jsx)("h4",{children:i?`${a} & Social`:a})}),e.active&&e.email&&(0,k.jsx)(jn,{}),e.active&&e.sms&&!e.email&&(0,k.jsx)(Kn,{}),e.active&&i&&(0,k.jsx)(sg,{google:e.google,twitter:e.twitter&&t,discord:e.discord,github:e.github,tiktok:e.tiktok,linkedin:e.linkedin,apple:e.apple})]})}function sg(e){return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(i7,{children:[(0,k.jsx)(i8,{}),(0,k.jsx)("p",{children:" Or "}),(0,k.jsx)(i8,{})]}),(0,k.jsx)(wd,{showGoogle:e.google,showDiscord:e.discord,showGithub:e.github,showLinkedIn:e.linkedin,showTwitter:e.twitter,showTiktok:e.tiktok,showApple:e.apple})]})}var i5=K.ZP.div` + font-weight: ${e=>e.active?600:500}; + color: ${e=>e.active?"var(--privy-color-foreground)":"var(--privy-color-foreground-2)"}; + display: flex; + justify-content: center; + align-items: center; +`,i6=K.ZP.div.attrs({role:"button"})` + display: flex; + flex-direction: column; + align-items: flex-start; + /* 1px helps with the input ring getting hidden by padding, despite it being + * annoying that it's not perfectly lined up + */ + padding: ${e=>e.isOnlySection?"1px":"12px"}; + margin-top: ${e=>e.isOnlySection?"12px":0}; + gap: 12px; + width: 100%; + max-height: ${e=>e.active?"400px":"52px"}; + + transition-property: border-color, max-height; + transition-duration: 0.25s; + transition-timing-function: ease-in; + overflow: hidden; + + && { + background: var(--privy-color-background); + + border: ${e=>e.isOnlySection?"none":e.active?"1px solid var(--privy-color-accent-light);":"1px solid var(--privy-color-foreground-4);"}; + border-radius: ${e=>e.isOnlySection?"0":"var(--privy-border-radius-md)"}; + } + + cursor: ${e=>e.active?"inherit":"pointer"}; +`,i7=K.ZP.div` + display: flex; + justify-content: center; + align-items: center; + width: 100%; + + && > p { + color: var(--privy-color-foreground-3); + } +`,i8=K.ZP.hr` + width: 50%; + && { + border-top: 1px solid var(--privy-color-foreground-4); + margin: 0px 8px; + } +`,i9=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + height: 100%; + padding: ${e=>`${80-(e.hasTerms?20:0)}px`} 10px + ${e=>`${e.hasOnlyOneSection?60:10}px`}; + + @media (max-width: 440px) { + padding: 10px 10px 20px; + } +`,ne=(0,K.ZP)(tJ)` + flex-direction: ${e=>e.reverse?"column-reverse":"column"}; +`,Rd=({style:e,...t})=>(0,k.jsxs)("svg",{width:"164",height:"164",viewBox:"0 0 164 164",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:{height:"26px",width:"26px",...e},...t,children:[(0,k.jsx)("circle",{cx:"82",cy:"82",r:"80",stroke:"#EC6351","stroke-width":"4","stroke-linecap":"round"}),(0,k.jsx)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M81.9999 100.788C93.3288 100.788 102.513 91.6043 102.513 80.2754C102.513 68.9465 93.3288 59.7626 81.9999 59.7626C70.671 59.7626 61.4871 68.9465 61.4871 80.2754C61.4871 91.6043 70.671 100.788 81.9999 100.788ZM88.3236 71.8304C88.9093 71.2446 89.8591 71.2446 90.4449 71.8304C91.0307 72.4161 91.0307 73.3659 90.4449 73.9517L84.121 80.2756L90.445 86.5996C91.0308 87.1854 91.0308 88.1351 90.445 88.7209C89.8592 89.3067 88.9095 89.3067 88.3237 88.7209L81.9997 82.3969L75.6756 88.7209C75.0899 89.3067 74.1401 89.3067 73.5543 88.7209C72.9685 88.1351 72.9685 87.1854 73.5543 86.5996L79.8783 80.2756L73.5544 73.9517C72.9686 73.3659 72.9686 72.4161 73.5544 71.8304C74.1402 71.2446 75.09 71.2446 75.6758 71.8304L81.9997 78.1543L88.3236 71.8304Z",fill:"#EC6351"})]}),nt={google:{name:"Google",component:Xn},discord:{name:"Discord",component:Jn},github:{name:"Github",component:Qn},linkedin:{name:"LinkedIn",component:ti},twitter:{name:"Twitter",component:ri},tiktok:{name:"Tiktok",component:oi},apple:{name:"Apple",component:Yn}},ni=()=>{let e=new URL(window.location.href);e.searchParams.delete("privy_oauth_code"),e.searchParams.delete("privy_oauth_provider"),e.searchParams.delete("privy_oauth_state"),window.history.pushState({},"",e)},nr=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin-left: 27px; + margin-right: 27px; + gap: 24px; +`,na=K.ZP.div` + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + width: 100%; + height: 82px; + + > div { + position: relative; + } + + > div > span { + position: absolute; + left: -41px; + top: -41px; + } + + > div > svg { + position: absolute; + left: -19px; + top: -19px; + } +`,Ud=(e,t)=>{let i=encodeURIComponent(new URL(window.location.href).href.replace(/\/$/g,"")+`?privy_token=${e}&privy_connector=injected&privy_wallet_client=phantom`);if(!je()&&T.tq)return`${t?"phantom://":"https://phantom.app/ul/"}browse/${i}?ref=${i}`},no=(0,K.ZP)(tQ)` + margin: 16px auto; +`,ai=({label:e,children:t,valueStyles:i})=>(0,k.jsxs)(ns,{children:[(0,k.jsx)("div",{children:e}),(0,k.jsx)(nl,{style:{...i},children:t})]}),ns=K.ZP.div` + display: flex; + align-items: center; + justify-content: space-between; + width: 100%; + + > :first-child { + color: var(--privy-color-foreground-3); + text-align: left; + } + + > :last-child { + color: var(--privy-color-foreground-2); + text-align: right; + } +`,nl=K.ZP.div` + font-size: 14px; + line-height: 100%; + display: flex; + align-items: center; + justify-content: center; + border-radius: var(--privy-border-radius-full); + background-color: var(--privy-color-background-2); + padding: 4px 8px; +`,Or=(e,t)=>(t*parseFloat((0,eP.dF)(e))).toFixed(2),Wo=(e,t=6)=>parseFloat((0,eP.dF)(e)).toFixed(t).replace(/0+$/,"").replace(/\.$/,""),Vd=(e,t)=>{let{chains:i}=_(),a=`https://etherscan.io/address/${t}`,s=`${Ys(e,i)}/address/${t}`;if(!s)return a;try{new URL(s)}catch{return a}return s},Ie=e=>eA.O$.from(e),Kd=({weiQuantities:e,tokenPrice:t})=>{let i=Or(e.map(Ie).reduce((e,t)=>e.add(t),eA.O$.from(0)).toHexString(),t);return(0,k.jsx)(nc,{children:"0.00"===i?"<$0.01":`$${i}`})},Ba=({weiQuantities:e,tokenPrice:t})=>{let i=Or(e.map(Ie).reduce((e,t)=>e.add(t),eA.O$.from(0)).toHexString(),t);return(0,k.jsxs)(nc,{children:[(0,k.jsx)(nh,{children:"USD"}),"0.00"===i?(0,k.jsxs)(nm,{children:[(0,k.jsx)(nu,{children:"<"}),"$0.01"]}):`$${i}`]})},nc=K.ZP.span` + font-size: 14px; + line-height: 140%; + display: flex; + gap: 4px; + align-items: center; +`,nh=K.ZP.span` + font-size: 12px; + line-height: 12px; + color: var(--privy-color-foreground-3); +`,nu=K.ZP.span` + font-size: 10px; +`,nm=K.ZP.span` + display: flex; + align-items: center; +`,Jd=({transactionData:e,gas:t,tokenPrice:i})=>{let{nativeTokenSymbolForChainId:a}=_(),s=a(e.chainId)||"ETH";return(0,k.jsxs)(t1,{style:{paddingBottom:"12px"},children:[(0,k.jsxs)(nf,{children:[(0,k.jsx)(nw,{children:"Est. Fees"}),(0,k.jsx)("div",{children:(0,k.jsx)(Ba,{weiQuantities:[t],tokenPrice:i})})]}),(0,k.jsx)(ng,{children:`${Wo(Ie(t).toHexString())} ${s}`})]})},Qd=({transactionData:e,gas:t,tokenPrice:i})=>{let{nativeTokenSymbolForChainId:a}=_(),s=a(e.chainId)||"ETH";return(0,k.jsxs)(t1,{children:[(0,k.jsxs)(nf,{children:[(0,k.jsx)(nw,{children:"Total (including fees)"}),(0,k.jsx)("div",{children:(0,k.jsx)(Ba,{weiQuantities:[e.value||0,t],tokenPrice:i})})]}),(0,k.jsx)(ng,{children:e.value?`${Wo(Ie(e.value).add(Ie(t)).toHexString())} ${s}`:null})]})},nf=K.ZP.div` + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; + padding-top: 4px; +`,ng=K.ZP.div` + display: flex; + flex-direction: row; + height: 12px; + + font-size: 12px; + line-height: 12px; + color: var(--privy-color-foreground-3); + font-weight: 400; +`,nw=K.ZP.div` + font-size: 14px; + line-height: 22.4px; + font-weight: 400; +`,nx=(0,u.createContext)(void 0),ny=(0,u.createContext)(void 0),rp=({defaultValue:e,children:t})=>{let[i,a]=(0,u.useState)(e||null);return(0,k.jsx)(nx.Provider,{value:{activePanel:i,togglePanel:e=>{a(i===e?null:e)}},children:(0,k.jsx)(nv,{children:t})})},np=({value:e,children:t})=>{let{activePanel:i,togglePanel:a}=(0,u.useContext)(nx),s=i===e;return(0,k.jsx)(ny.Provider,{value:{onToggle:()=>a(e),value:e},children:(0,k.jsx)(nk,{isActive:s,"data-open":s,children:t})})},ip=({children:e})=>{let{activePanel:t}=(0,u.useContext)(nx),{onToggle:i,value:a}=(0,u.useContext)(ny),s=t===a;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(nb,{onClick:i,"data-open":s,children:[(0,k.jsx)(nj,{children:e}),(0,k.jsx)(nA,{isactive:s,children:(0,k.jsx)(eS.Z,{height:"16px",width:"16px",strokeWidth:"2"})})]}),(0,k.jsx)(nC,{})]})},ap=({children:e})=>{let{activePanel:t}=(0,u.useContext)(nx),{value:i}=(0,u.useContext)(ny);return(0,k.jsx)(n_,{"data-open":t===i,children:(0,k.jsx)(nE,{children:e})})},sp=({children:e})=>{let{activePanel:t}=(0,u.useContext)(nx),{value:i}=(0,u.useContext)(ny);return(0,k.jsx)(nE,{children:"function"==typeof e?e({isActive:t===i}):e})},nv=K.ZP.div` + display: flex; + flex-direction: column; + width: 100%; + gap: 8px; +`,nb=K.ZP.div` + display: flex; + justify-content: space-between; + align-items: center; + width: 100%; + cursor: pointer; + padding-bottom: 8px; +`,nC=K.ZP.div` + width: 100%; + + && { + border-top: 1px solid; + border-color: var(--privy-color-foreground-4); + } + padding-bottom: 12px; +`,nj=K.ZP.div` + font-size: 14px; + font-weight: 500; + line-height: 19.6px; + width: 100%; + padding-right: 8px; +`,nk=K.ZP.div` + display: flex; + flex-direction: column; + width: 100%; + overflow: hidden; + padding: 12px; + + && { + border: 1px solid; + border-color: var(--privy-color-foreground-4); + border-radius: var(--privy-border-radius-md); + } +`,n_=K.ZP.div` + position: relative; + overflow: hidden; + transition: max-height 0.35s ease-in-out; + + &[data-open='true'] { + max-height: 700px; + } + + &[data-open='false'] { + max-height: 0; + } +`,nE=K.ZP.div` + display: flex; + flex-direction: column; + gap: 12px; + flex: 1 1 auto; + min-height: 1px; +`,nA=K.ZP.div` + transform: ${e=>e.isactive?"rotate(180deg)":"rotate(0deg)"}; +`,Ga=({walletAddress:e,chainId:t=e5})=>(0,k.jsx)(nP,{href:Vd(t,e),target:"_blank",children:$t(e)}),nP=K.ZP.a` + &:hover { + text-decoration: underline; + } +`,ci=({from:e,to:t,txn:i,transactionInfo:a,tokenPrice:s,gas:l})=>{let u=i?.value||0;return(0,k.jsx)(rp,{children:(0,k.jsxs)(np,{value:"details",children:[(0,k.jsx)(ip,{children:(0,k.jsxs)(nS,{children:[(0,k.jsx)("div",{children:a?.title||a?.actionDescription||"Details"}),s?(0,k.jsx)(nT,{children:(0,k.jsx)(Kd,{weiQuantities:[u],tokenPrice:s})}):null]})}),(0,k.jsxs)(ap,{children:[(0,k.jsx)(ai,{label:"From",children:(0,k.jsx)(Ga,{walletAddress:e,chainId:i.chainId||e5})}),(0,k.jsx)(ai,{label:"To",children:(0,k.jsx)(Ga,{walletAddress:t,chainId:i.chainId||e5})}),a&&a.action&&(0,k.jsx)(ai,{label:"Action",children:a.action}),l&&s?(0,k.jsx)(Jd,{transactionData:i,gas:l,tokenPrice:s}):null]}),(0,k.jsx)(sp,{children:({isActive:e})=>(0,k.jsx)(k.Fragment,{children:s&&(0,k.jsx)(Qd,{transactionData:i,displayFee:e,gas:l||"0x0",tokenPrice:s})})})]})})},nS=K.ZP.div` + display: flex; + flex-direction: row; + justify-content: space-between; +`,nT=K.ZP.div` + flex-shrink: 0; + padding-left: 8px; +`,$a=({description:e,contractInfo:t})=>(0,k.jsxs)(nN,{children:[t.imgUrl&&(0,k.jsx)(nI,{size:t.imgSize||"sm",src:t.imgUrl,alt:t.imgAltText||`${t.name} image`}),t.url&&(0,k.jsx)(nO,{children:(0,k.jsx)("a",{href:t.url,target:"_blank",rel:"noopener noreferrer",children:t.url.replace(/^(https?:\/\/)(www\.)?/,"")})}),t.name&&(0,k.jsx)(nL,{children:t.name}),(0,k.jsx)(nR,{children:e||t.actionText})]}),nN=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + margin-bottom: 8px; +`,nI=K.ZP.img` + height: ${e=>"sm"===e.size?"65px":"140px"}; + width: ${e=>"sm"===e.size?"65px":"140px"}; + border-radius: 16px; + margin-bottom: 12px; +`,nO=K.ZP.div` + font-size: 12px; + line-height: 12px; + padding: 7px; + + && a { + font-weight: 400; + color: var(--privy-color-foreground-3); + + &:hover { + text-decoration: underline; + } + } +`,nL=K.ZP.div` + font-size: 18px; + line-height: 18px; + font-weight: 500; + overflow: hidden; + white-space: nowrap; + max-width: 275px; + text-overflow: ellipsis; +`,nR=K.ZP.div` + font-size: 16px; + line-height: 140%; + font-weight: 400; + color: var(--privy-color-foreground-1); + overflow: hidden; + white-space: nowrap; + max-width: 275px; + text-overflow: ellipsis; +`,nW={id:137,name:"Polygon Mainnet",network:"matic",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{alchemy:{http:["https://polygon-mainnet.g.alchemy.com/v2"],webSocket:["wss://polygon-mainnet.g.alchemy.com/v2"]},infura:{http:["https://polygon-mainnet.infura.io/v3"],webSocket:["wss://polygon-mainnet.infura.io/ws/v3"]},default:{http:["https://polygon-rpc.com"]},public:{http:["https://polygon-rpc.com"]}},blockExplorers:{etherscan:{name:"PolygonScan",url:"https://polygonscan.com"},default:{name:"PolygonScan",url:"https://polygonscan.com"}}},nM={id:80001,name:"Mumbai",network:"maticmum",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{alchemy:{http:["https://polygon-mumbai.g.alchemy.com/v2"],webSocket:["wss://polygon-mumbai.g.alchemy.com/v2"]},infura:{http:["https://polygon-mumbai.infura.io/v3"],webSocket:["wss://polygon-mumbai.infura.io/ws/v3"]},default:{http:["https://matic-mumbai.chainstacklabs.com"]},public:{http:["https://matic-mumbai.chainstacklabs.com"]}},blockExplorers:{etherscan:{name:"PolygonScan",url:"https://mumbai.polygonscan.com"},default:{name:"PolygonScan",url:"https://mumbai.polygonscan.com"}},testnet:!0},nU=[nW.id,nM.id],Va=e=>({maxPriorityFee:(0,eP.vz)(e.maxPriorityFee.toString(),"gwei").toHexString(),maxFee:(0,eP.vz)(e.maxFee.toString(),"gwei").toHexString()}),n1=e=>({safeLow:Va(e.safeLow),standard:Va(e.standard),fast:Va(e.fast)}),up=async e=>{let t="";switch(e){case nW.id:t="https://gasstation.polygon.technology/v2";break;case nM.id:t="https://gasstation-testnet.polygon.technology/v2";break;default:throw Error(`chainId ${e} does not support polygon gas stations`)}return n1(await (0,W.Wg)(t))};function ar(e){if("number"==typeof e||"bigint"==typeof e||"string"==typeof e)return e;if("function"==typeof e.toHexString)return e.toHexString();throw Error(`Expected numeric value but received ${e}`)}async function di(e,t,i){var a;let s;t.chainId=Number(t.chainId),hp(t);let l=new eN.b(e,i);if(delete t.gas,nU.includes(t.chainId)&&(!t.maxPriorityFeePerGas||!t.maxFeePerGas))try{let{standard:e}=await up(t.chainId);t.maxPriorityFeePerGas||(t.maxPriorityFeePerGas=e.maxPriorityFee),t.maxFeePerGas||(t.maxFeePerGas=e.maxFee)}catch{throw Error("Unable to get current gas prices from Polygon gas station.")}return s={},void 0!==(a=await l.populateTransaction(t)).to&&(s.to=a.to),void 0!==a.data&&(s.data=a.data),void 0!==a.chainId&&(s.chainId=a.chainId),void 0!==a.type&&(s.type=a.type),void 0!==a.accessList&&(s.accessList=a.accessList),void 0!==a.nonce&&(s.nonce=ar(a.nonce)),void 0!==a.gasLimit&&(s.gasLimit=ar(a.gasLimit)),void 0!==a.gasPrice&&(s.gasPrice=ar(a.gasPrice)),void 0!==a.value&&(s.value=ar(a.value)),void 0!==a.maxFeePerGas&&(s.maxFeePerGas=ar(a.maxFeePerGas)),void 0!==a.maxPriorityFeePerGas&&(s.maxPriorityFeePerGas=ar(a.maxPriorityFeePerGas)),s}async function pi(e,t,i,a,s){var l;hp(a=Object.assign({chainId:e5},a));let u=(await i.rpc({address:t,accessToken:e,request:{method:"eth_signTransaction",params:[a]}})).response.data;return{to:(l=await (await s.sendTransaction(u)).wait()).to,from:l.from,contractAddress:l.contractAddress,transactionIndex:l.transactionIndex,root:l.root,logsBloom:l.logsBloom,blockHash:l.blockHash,transactionHash:l.transactionHash,logs:l.logs,blockNumber:l.blockNumber,confirmations:l.confirmations,byzantium:l.byzantium,type:l.type,status:l.status,gasUsed:l.gasUsed.toHexString(),cumulativeGasUsed:l.cumulativeGasUsed.toHexString(),effectiveGasPrice:l.effectiveGasPrice?l.effectiveGasPrice.toHexString():void 0}}async function ui(e,t,i){let a=await i.getBalance(e),s=t.value||0,l=a.sub(Ie(s));return{balance:a,hasSufficientFunds:!l.isNegative()&&!l.isZero()}}async function mp(e,t){return delete e.from,await t.estimateGas(e)}function hp(e){for(let t of["gasLimit","gasPrice","value","maxPriorityFeePerGas","maxFeePerGas"]){let i=e[t];if(!(typeof i>"u")&&!function(e){let t="number"==typeof e,i="bigint"==typeof e,a="string"==typeof e&&/^-?0x[a-f0-9]+$/i.test(e);return t||i||a}(i))throw Error(`Transaction request property '${t}' must be a valid number, bigint, or hex string representing a quantity`)}if("number"!=typeof e.chainId)throw Error("Transaction request property 'chainId' must be a number")}var yp=({wallet:e,txn:t,provider:i})=>{let[a,s]=(0,u.useState)(),[l,p]=(0,u.useState)(!1),[f,w]=(0,u.useState)(!1),{nativeTokenSymbolForChainId:y}=_(),C=y(t.chainId)||"ETH";return(0,u.useEffect)(()=>{(async e=>{try{let{balance:a,hasSufficientFunds:l}=await ui(e,t,i);w(!0),p(!1===l),s(a.toHexString())}catch(e){console.warn(`Failed to fetch wallet balance with error: ${e}`)}})(e.address)},[e,t]),(0,k.jsxs)(nD,{children:[(0,k.jsxs)(nF,{children:[(0,k.jsx)(eT.Z,{strokeWidth:"2",width:"16px",height:"16px"}),(0,k.jsx)("div",{children:$t(e?.address)})]}),(0,k.jsxs)(nZ,{displayBalanceColor:f,hasFunds:!l,children:[a?Wo(a):0," ",C," available"]})]})},nD=K.ZP.div` + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; + padding: 9px 12px; + height: 40px; + color: var(--privy-color-foreground-3); + + && { + border: 1px solid var(--privy-color-foreground-4); + border-radius: var(--privy-border-radius-md); + } +`,nF=K.ZP.div` + display: flex; + flex-direction: row; + align-items: center; + gap: 8px; +`,nZ=K.ZP.div` + display: flex; + align-items: center; + justify-content: center; + font-size: 12px; + line-height: 100%; + border-radius: 16px; + background-color: var(--privy-color-background-2); + padding: 5px 8px; + color: ${e=>e.displayBalanceColor?e.hasFunds?"var(--privy-color-success-dark)":"var(--privy-color-error)":"inherit"}; +`,mi=e=>{let{getUsdTokenPrice:t,chains:i,rpcConfig:a}=_(),[s,p]=(0,u.useState)(!1),[f,w]=(0,u.useState)(!1),[y,C]=(0,u.useState)(void 0),[k,A]=(0,u.useState)(void 0),[T,I]=(0,u.useState)(null),L=(0,u.useMemo)(()=>new l.c(tt(e.chainId||e5,i,a)),[e.chainId,i,a]);return(0,u.useEffect)(()=>{let a=e.chainId||e5,s=i.find(e=>e.id===Number(a));if(!s)throw new eD(`Unsupported chain: ${a}`);(async()=>{try{p(!0);let e=await t(s);e?A(e):C(Error(`Unable to fetch token price on chain id ${s.id}`))}catch(e){C(e)}finally{p(!1)}})()},[e.chainId]),(0,u.useEffect)(()=>{(async()=>{try{w(!0);let t=await mp(e,L);I(t.toBigInt())}catch(e){C(e)}finally{w(!1)}})()},[e]),{tokenPrice:k,estimatedGas:T,isLoading:s||f,error:y}},Cp=e=>{let{tokenPrice:t}=mi(e.txn),{nativeTokenSymbolForChainId:i}=_(),a=i(e.txn.chainId)||"ETH",s=Wo(Ie(e.txn.value||0).toHexString());return(0,k.jsxs)(nz,{children:[(0,k.jsx)(n$,{children:(()=>{if(!t)return"--";let i=Or(Ie(e.txn.value||0).toHexString(),t);return"0.00"===i?"<$0.01":`$${i}`})()}),(0,k.jsxs)(nB,{children:[s," ",a]}),(0,k.jsx)(nH,{children:e.description})]})},nz=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + margin-bottom: 20px; +`,n$=K.ZP.h2` + && { + font-size: 48px; + line-height: 48px; + margin: 8px auto; + } +`,nB=K.ZP.p` + margin-bottom: 12px; + && { + font-size: 17px; + line-height: 17px; + color: var(--privy-color-foreground-3); + } +`,nH=K.ZP.div` + font-size: 16px; + line-height: 22.4px; + font-weight: 400; + overflow: hidden; + white-space: nowrap; + max-width: 275px; + text-overflow: ellipsis; +`,nG=(0,u.createContext)({wallets:[]});function Ja(){return(0,u.useContext)(nG)}var xp=({txn:e,receipt:t,transactionInfo:i,onClose:a,tokenPrice:s})=>(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:a}),(0,k.jsxs)(nq,{children:[(0,k.jsxs)("div",{children:[(0,k.jsx)(vt,{title:"Transaction complete!",description:"You're all set."}),(0,k.jsx)(ci,{tokenPrice:s,from:t.from,to:t.to,gas:t.gasUsed,txn:e,transactionInfo:i})]}),(0,k.jsx)("div",{children:(0,k.jsx)(nV,{loading:!1,onClick:a,children:"All Done"})})]}),(0,k.jsx)(t9,{})]}),nq=K.ZP.div` + display: flex; + height: 100%; + flex-direction: column; + justify-content: space-between; + flex-grow: 1; +`,nV=(0,K.ZP)(V)` + margin-top: 24px; + transition: color 350ms ease, background-color 350ms ease; +`,S1=({txn:e,txnFamily:t,uiOptions:i})=>{if("CONTRACT_CALL"===t){if(i.transactionInfo?.contractInfo)return(0,k.jsx)($a,{contractInfo:i.transactionInfo.contractInfo,description:i.description});if(i.senderInfo)return(0,k.jsx)($a,{contractInfo:i.senderInfo,description:i.description||i.senderInfo.actionText})}return(0,k.jsx)(k.Fragment,{children:(0,k.jsx)(Cp,{description:i.description||i.transactionInfo?.description||"",txn:e})})},nK=K.ZP.div` + display: flex; + height: 100%; + flex-direction: column; + justify-content: space-between; + flex-grow: 1; +`,nY=K.ZP.div` + line-height: 15px; + font-size: 13px; + color: var(--privy-color-error); + width: 100%; + margin-top: 1px; +`,nJ=K.ZP.div` + display: flex; + direction: row; + justify-content: space-between; + align-items: center; + gap: 8px; +`,nQ=(0,K.ZP)(V)` + transition: color 350ms ease, background-color 350ms ease; +`,nX=K.ZP.div` + height: 100%; + display: flex; + flex-direction: column; + justify-content: space-evenly; + flex-grow: 1; +`,n0=K.ZP.div` + display: flex; + flex-direction: column; + gap: 8px; +`,kp=({style:e,color:t,...i})=>(0,k.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:t||"currentColor",style:{height:"1.5rem",width:"1.5rem",...e},...i,children:(0,k.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4.5 12.75l6 6 9-13.5"})}),D1=e=>{if(!(0,eI.A7)(e))return e;try{return(0,eO.ZN)(e)}catch{return e}},n2=K.ZP.div` + display: flex; + height: 100%; + flex-direction: column; + justify-content: space-between; + flex-grow: 1; +`,n3=K.ZP.div` + background-color: var(--privy-color-background-2); + border-radius: var(--privy-border-radius-md); + padding: 12px; + text-align: left; + max-height: 310px; + overflow: scroll; + white-space: pre-wrap; + + // hide the scrollbars + -ms-overflow-style: none; /* Internet Explorer 10+ */ + scrollbar-width: none; /* Firefox */ + + &::-webkit-scrollbar { + display: none; /* Safari and Chrome */ + } +`,n4=K.ZP.div` + line-height: 20px; + height: 20px; + font-size: 13px; + color: ${e=>e.fail?"var(--privy-color-error)":"var(--privy-color-foreground-3)"}; + display: flex; + justify-content: flex-start; + width: 100%; + margin-top: 4px; +`,n5=K.ZP.span` + display: flex; + align-items: center; + gap: 8px; +`,n6=(0,K.ZP)(V)` + transition: color 350ms ease, background-color 350ms ease; + + ${e=>e.success&&K.iv` + &&&& { + background-color: var(--privy-color-success); + color: #ffffff; + } + `} +`,n7=` + *, + ::before, + ::after { + box-sizing: border-box; + border-width: 0; + border-style: solid; + } + + line-height: 1.15; + -webkit-text-size-adjust: 100%; + -moz-tab-size: 4; + tab-size: 4; + font-feature-settings: normal; + + margin: 0; + font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, + 'Apple Color Emoji', 'Segoe UI Emoji'; + + hr { + height: 0; + color: inherit; + border-top-width: 1px; + } + + abbr:where([title]) { + text-decoration: underline dotted; + } + + h1, + h2, + h3, + h4, + h5, + h6 { + font-size: inherit; + font-weight: inherit; + font-family: system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, + 'Apple Color Emoji', 'Segoe UI Emoji'; + display: inline; + } + + a { + color: inherit; + text-decoration: inherit; + } + + b, + strong { + font-weight: bolder; + } + + code, + kbd, + samp, + pre { + font-family: ui-monospace, SFMono-Regular, Consolas, 'Liberation Mono', Menlo, monospace; + font-size: 1em; + } + + small { + font-size: 80%; + } + + sub, + sup { + font-size: 75%; + line-height: 0; + position: relative; + vertical-align: baseline; + } + + sub { + bottom: -0.25em; + } + + sup { + top: -0.5em; + } + + table { + text-indent: 0; + border-color: inherit; + border-collapse: collapse; + } + + button, + input, + optgroup, + select, + textarea { + font-family: inherit; + font-size: 100%; + font-weight: inherit; + line-height: inherit; + color: inherit; + margin: 0; + padding: 0; + } + + button, + select { + text-transform: none; + } + + button, + [type='button'], + [type='reset'], + [type='submit'] { + -webkit-appearance: button; + background-color: transparent; + background-image: none; + } + + ::-moz-focus-inner { + border-style: none; + padding: 0; + } + + :-moz-focusring { + outline: 1px dotted ButtonText; + } + + :-moz-ui-invalid { + box-shadow: none; + } + + legend { + padding: 0; + } + + progress { + vertical-align: baseline; + } + + ::-webkit-inner-spin-button, + ::-webkit-outer-spin-button { + height: auto; + } + + [type='search'] { + -webkit-appearance: textfield; + outline-offset: -2px; + } + + ::-webkit-search-decoration { + -webkit-appearance: none; + } + + ::-webkit-file-upload-button { + -webkit-appearance: button; + font: inherit; + } + + summary { + display: list-item; + } + + blockquote, + dl, + dd, + h1, + h2, + h3, + h4, + h5, + h6, + hr, + figure, + p, + pre { + margin: 0; + } + + fieldset { + margin: 0; + padding: 0; + } + + legend { + padding: 0; + } + + ol, + ul, + menu { + list-style: none; + margin: 0; + padding: 0; + } + + textarea { + resize: vertical; + } + + input::placeholder, + textarea::placeholder { + opacity: 1; + color: theme('colors.gray.400', #9ca3af); + } + + button, + [role='button'] { + cursor: pointer; + } + + :disabled { + cursor: default; + } + + img, + svg, + video, + canvas, + audio, + iframe, + embed, + object { + display: block; + } + + img, + video { + max-width: 100%; + height: auto; + } + + [hidden] { + display: none; + } +`,n8=K.vJ` + :root { + // Borders + --privy-border-radius-sm: 6px; + --privy-border-radius-md: 12px; + --privy-border-radius-lg: 24px; + --privy-border-radius-full: 9999px; + + // Colors + --privy-color-background: ${e=>e.theme.background}; + --privy-color-background-2: ${e=>e.theme.background2}; + + --privy-color-foreground: ${e=>e.theme.foreground}; + --privy-color-foreground-2: ${e=>e.theme.foreground2}; + --privy-color-foreground-3: ${e=>e.theme.foreground3}; + --privy-color-foreground-4: ${e=>e.theme.foreground4}; + --privy-color-foreground-accent: ${e=>e.theme.foregroundAccent}; + + --privy-color-accent: ${e=>e.theme.accent}; + --privy-color-accent-light: ${e=>e.theme.accentLight}; + --privy-color-accent-dark: ${e=>e.theme.accentDark}; + + --privy-color-success: ${e=>e.theme.success}; + --privy-color-success-dark: ${e=>e.theme.successDark}; + --privy-color-error: ${e=>e.theme.error}; + --privy-color-warn: ${e=>e.theme.warn}; + + // Space + --privy-height-modal-full: 620px; + --privy-height-modal-compact: 480px; + }; +`,n9=K.ZP.div` + // css normalize only the privy application to avoid conflicts + // with consuming application + ${n7} + + // Privy styles + color: var(--privy-color-foreground-2); + + h3 { + font-size: 16px; + line-height: 24px; + font-weight: 500; + color: var(--privy-color-foreground-2); + } + + h4 { + font-size: 14px; + line-height: 20px; + font-weight: 500; + color: var(--privy-color-foreground); + } + + p { + font-size: 13px; + line-height: 20px; + color: var(--privy-color-foreground-2); + } + + button:focus, + input:focus, + optgroup:focus, + select:focus, + textarea:focus { + outline: none; + border-color: var(--privy-color-accent-light); + box-shadow: 0 0 0 1px var(--privy-color-accent-light); + } + + /* Utilities when you can't add an additional span tag for mobile formatting */ + + .hide-on-mobile { + @media (max-width: 440px) { + display: none; + } + } + + .mobile-only { + @media (min-width: 441px) { + display: none; + } + } + + /* Animations */ + + @keyframes fadein { + 0% { + opacity: 0; + } + 100% { + opacity: 1; + } + } +`,ae={LANDING:()=>{let{app:e,outerClickRef:t}=v(),{captchaData:i,closePrivyModal:a}=_(),s=e?.loginMethods.email??!1,l=e?.loginMethods.sms??!1,p=e?.loginMethods.wallet??!1,f=e?.loginMethods.google??!1,w=e?.loginMethods.twitter??!1,y=e?.loginMethods.discord??!1,C=e?.loginMethods.github??!1,A=e?.loginMethods.tiktok??!1,T=e?.loginMethods.linkedin??!1,I=e?.loginMethods.apple??!1,L=!e?.appearance.showWalletLoginFirst,R=p&&e?.appearance.showWalletLoginFirst?0:1,[W,F]=(0,u.useState)(R),z=s||l,G=p!==z,M=()=>{i.enabled&&i.remove(),a()};return t&&(t.current=M),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:M},"header"),e?.appearance.logo?(0,k.jsx)(i9,{hasOnlyOneSection:G,hasTerms:!!(e?.legal.privacyPolicyUrl||e?.legal.termsAndConditionsUrl),children:(0,k.jsx)(Rn,{})}):null,(0,k.jsxs)(ne,{reverse:L,children:[p&&(0,k.jsx)(ig,{active:0==W||G,connectOnly:!1,tabIndex:L?1:0,onClick:()=>{i.enabled&&i.remove(),F(0)},isOnlySection:!z}),z&&(0,k.jsx)(ag,{active:1==W||G,onClick:()=>F(1),email:s,sms:l,google:f,twitter:w,twitterOAuthOnMobileEnabled:e?.loginConfig.twitterOAuthOnMobileEnabled??!1,discord:y,github:C,tiktok:A,linkedin:T,apple:I,tabIndex:L?0:1,isOnlySection:!p})]}),e&&(0,k.jsx)(_n,{app:e}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},AWAITING_PASSWORDLESS_CODE:()=>{let{app:e,navigate:t,setModalData:i}=v(),{closePrivyModal:a,resendEmailCode:s,resendSmsCode:l,getAuthMeta:p,loginWithCode:f,updateWallets:w}=_(),{authenticated:y,user:C}=$(),[A,I]=(0,u.useState)(rh),[L,R]=(0,u.useState)(!1),[W,F]=(0,u.useState)(null),[z,G]=(0,u.useState)(null),q=p()?.email?0:1,K=e?.render.inDialog?1400:0,J=e?.render.inDialog?K-500:0;(0,u.useEffect)(()=>{if(y&&L&&C){if(zt(C,e?.embeddedWallets?.createOnLogin)){let e=setTimeout(()=>{i({createWallet:{onSuccess:()=>{},onFailure:e=>console.error(e),callAuthOnSuccessOnClose:!0}}),t("EMBEDDED_WALLET_ON_ACCOUNT_CREATE_SCREEN")},J);return()=>clearTimeout(e)}{w();let e=setTimeout(a,K);return()=>clearTimeout(e)}}},[y,L,C]),(0,u.useEffect)(()=>{if(W&&0===z){let e=setTimeout(()=>{I(rh),F(null),document.querySelector("input[name=code-0]")?.focus()},1400);return()=>clearTimeout(e)}},[W]);let N=e=>{let t=e.currentTarget.value.replace(" ","");if(""===t)return;if(isNaN(Number(t))){F("Code should be numeric"),G(1);return}F(null),G(null);let i=Number(e.currentTarget.name?.charAt(5)),a=[...t||[""]].slice(0,6-i),s=[...A.slice(0,i),...a,...A.slice(i+a.length)];I(s);let l=Math.min(Math.max(i+a.length,0),5);isNaN(Number(e.currentTarget.value))||document.querySelector(`input[name=code-${l}]`)?.focus(),s.every(e=>e&&!isNaN(+e))&&(document.querySelector(`input[name=code-${l}]`)?.blur(),f(s.join("")).then(()=>R(!0)).catch(e=>{e?.status===422?F("Invalid or expired verification code"):F("Issue verifying code"),G(0)})),e.preventDefault()},M=e=>{1===z&&(F(null),G(null)),I([...A.slice(0,e),"",...A.slice(e+1)]),e>0&&document.querySelector(`input[name=code-${e-1}]`)?.focus()},Q=0==q?(0,k.jsx)(X.Z,{color:"var(--privy-color-accent)",strokeWidth:2,height:"48px",width:"48px"}):(0,k.jsx)(et.Z,{color:"var(--privy-color-accent)",strokeWidth:2,height:"40px",width:"40px"}),er=0==q?(0,k.jsxs)("p",{children:["Please check ",(0,k.jsx)(rx,{children:p()?.email})," for an email from privy.io and enter your code below."]}):(0,k.jsxs)("p",{children:["Please check ",(0,k.jsx)(rx,{children:p()?.phoneNumber})," for a message from ",e?.name||"Privy"," and enter your code below."]});return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsxs)(rm,{children:[(0,k.jsx)(fe,{title:"Enter confirmation code",description:er,icon:Q}),(0,k.jsxs)(tX,{children:[(0,k.jsxs)(rf,{children:[(0,k.jsx)(rg,{fail:!!W,success:L,children:(0,k.jsx)("span",{children:W||(L?"Success!":"")})}),(0,k.jsx)("div",{children:A.map((e,t)=>(0,k.jsx)("input",{name:`code-${t}`,type:"text",value:A[t],onChange:N,onKeyUp:e=>{"Backspace"===e.key&&M(t)},inputMode:"numeric",autoFocus:0===t,pattern:"[0-9]",className:`${L?"success":""} ${W?"fail":""}`,autoComplete:T.tq?"one-time-code":"off"},t))})]}),(0,k.jsx)(rw,{children:0==q?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)("span",{children:"Didn't get an email?"}),(0,k.jsx)("button",{onClick:s,children:"Resend Code"})]}):(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)("span",{children:"Didn't get a message?"}),(0,k.jsx)("button",{onClick:l,children:"Resend Code"})]})})]})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},WALLET_EDUCATION:()=>{let[e,t]=(0,u.useState)("WHAT_IS_A_WALLET"),{navigateBack:i}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:"WHAT_IS_A_WALLET"===e?i:"PICK_A_NEW_WALLET"===e?()=>t("WHAT_IS_A_WALLET"):()=>t("PICK_A_NEW_WALLET")},"header"),(0,k.jsx)(t4,{}),(0,k.jsxs)(iZ,{children:["WHAT_IS_A_WALLET"===e&&(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(iY,{children:(0,k.jsx)(id,{style:{width:"240px",height:"auto",borderRadius:"var(--privy-border-radius-sm)",marginBottom:"32px"}})}),(0,k.jsxs)(fe,{title:"Get started with a new wallet",children:[(0,k.jsx)("p",{children:"Wallets help you store, send, and receive digital assets and collectibles. They are also a new\xa0way\xa0to\xa0log\xa0in."}),(0,k.jsx)("p",{children:"Instead of creating new accounts and passwords for every app, you just connect your wallet and bring your\xa0data\xa0with\xa0you."})]}),(0,k.jsx)(iG,{children:(0,k.jsx)(iq,{onClick:()=>{t("PICK_A_NEW_WALLET")},children:"Create a wallet"})})]}),"PICK_A_NEW_WALLET"===e&&(0,k.jsx)(k.Fragment,{children:(0,k.jsxs)(iz,{children:[(0,k.jsx)(vt,{title:"Create a new wallet",description:"Select one of the wallet providers below to get started."}),(0,k.jsxs)(i$,{children:[(0,k.jsxs)(iB,{onClick:()=>{T.gn?window.location.href="https://apps.apple.com/us/app/metamask-blockchain-wallet/id1438144202":T.Dt?window.location.href="https://play.google.com/store/apps/details?id=io.metamask":t("CREATE_METAMASK_WALLET")},children:[(0,k.jsx)(Ce,{}),(0,k.jsxs)(iH,{children:[(0,k.jsx)("h4",{children:"MetaMask"}),(0,k.jsx)("p",{children:"Get a browser-based wallet"})]})]}),(0,k.jsxs)(iB,{onClick:()=>{T.gn?window.location.href="https://apps.apple.com/us/app/coinbase-wallet-nfts-crypto/id1278383455":T.Dt?window.location.href="https://play.google.com/store/apps/details?id=org.toshi":t("CREATE_COINBASE_WALLET")},children:[(0,k.jsx)(pt,{}),(0,k.jsxs)(iH,{children:[(0,k.jsx)("h4",{children:"Coinbase Wallet"}),(0,k.jsx)("p",{children:"Get a mobile app wallet"})]})]})]})]})}),"CREATE_COINBASE_WALLET"===e&&(0,k.jsx)(Ta,{}),"CREATE_METAMASK_WALLET"===e&&(0,k.jsx)(xa,{}),"CREATE_PHANTOM_WALLET"===e&&(0,k.jsx)(Pa,{})]}),(0,k.jsx)(t5,{}),(0,k.jsxs)(t9,{children:[(0,k.jsx)("span",{children:"Still not sure? "}),(0,k.jsx)("a",{target:"_blank",href:"https://ethereum.org/en/wallets/",children:"Learn more"}),"."]})]})},AWAITING_CONNECTION:()=>{let[e,t]=(0,u.useState)(!1),[i,a]=(0,u.useState)(!1),[s,l]=(0,u.useState)(void 0),{app:p,navigate:f,navigateBack:w,lastScreen:y,currentScreen:C,setModalData:A}=v(),{getAuthFlow:I,walletConnectionStatus:L,closePrivyModal:R,loginWithWallet:W,updateWallets:F}=_(),{walletConnectors:z}=$(),[G,q]=(0,u.useState)(0),{user:K}=$(),[J]=(0,u.useState)(K?.linkedAccounts.length||0),Q=T.tq&&L?.connector?.connectorType==="wallet_connect_v2"||T.tq&&L?.connector?.connectorType==="coinbase_wallet"||T.tq&&L?.connector?.connectorType==="injected"&&L?.connector?.walletClientType==="phantom",X=L?.status==="connected",et=L?.status==="switching_to_supported_chain";(0,u.useEffect)(()=>{let e=I();if(e&&Q&&X&&!e.preparedMessage){e.buildSiweMessage();return}e&&!Q&&X&&(async()=>{a(!0),l(void 0);try{L?.connector?.connectorType==="wallet_connect_v2"&&L?.connector?.walletClientType==="metamask"&&await Ii(2500),await j()}catch(e){console.warn("Auto-prompted signature failed",e)}finally{a(!1)}})()},[G,X]),(0,u.useEffect)(()=>{if(K&&e){let e;if(zt(K,p?.embeddedWallets?.createOnLogin)){let t=p?.render.inDialog?1400:0;e=setTimeout(()=>{A({createWallet:{onSuccess:()=>{},onFailure:e=>console.error(e),callAuthOnSuccessOnClose:!0}}),f("EMBEDDED_WALLET_ON_ACCOUNT_CREATE_SCREEN")},p?.render.inDialog?t-500:0)}else F(),e=setTimeout(R,1400);return()=>clearTimeout(e)}},[K,e]);let H=e=>{if(e?.privyErrorCode==="allowlist_rejected"){f("ALLOWLIST_REJECTION_SCREEN");return}l(oa(e))};async function j(){try{if(await W(),!p?.render.inDialog)return R();t(!0)}catch(e){H(e)}finally{a(!1)}}(0,u.useEffect)(()=>{L?.connectError&&H(L?.connectError)},[L]);let er=L?.connector?.connectorType||"metamask",ei=L?.connector?.walletClientType||"metamask",en=L?.connector?.walletBranding.name||rA[ei]?.name||"MetaMask",ea=L?.connector?.walletBranding.icon||rA[ei]?.component||(e=>(0,k.jsx)(Ce,{...e})),eo;eo=e?`Successfully connected with ${en}`:s?s.message:et?"Switching networks":X?i&&Q?"Signing":"Sign to verify":`Waiting for ${en}`;let es="Don’t see your wallet modal? Check your other browser windows.";e?es=J===(K?.linkedAccounts.length||0)?"Wallet was already linked.":"You’re good to go!":G>=2&&s?es="Unable to connect wallet":s?es=s.detail:et?es="Switch your wallet to the requested network.":X&&Q?es="Sign the message in your wallet to verify it belongs to you.":"metamask"===ei?es="For the best experience, connect only one wallet at a time.":"wallet_connect"===er?es="Open your mobile wallet app to continue":"coinbase_wallet"===er&&(nn()||(es=Ui(K)?"Continue with the Coinbase app. Not the right wallet? Reset your connection below.":"Open the Coinbase app on your phone to continue."));let ec=z?.walletConnectors?.find(e=>"coinbase_wallet"===e.walletClientType),eh="coinbase_wallet"===ei&&(Ui(K)||s===td.ERROR_USER_EXISTS);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:C===y?void 0:w}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rP,{children:[(0,k.jsx)(ra,{walletLogo:ea,success:e,fail:!!s}),(0,k.jsxs)(t2,{children:[(0,k.jsx)("h3",{children:eo}),(0,k.jsx)("p",{children:es})]}),(0,k.jsx)(tV,{children:eh?(0,k.jsx)(tq,{onClick:()=>ec&&ec?.disconnect(),invisible:e,disabled:e,children:"Use a different wallet"}):s==td.ERROR_USER_EXISTS&&C!==y?(0,k.jsx)(tq,{onClick:w,children:"Use a different wallet"}):X&&!e&&Q?(0,k.jsx)(tq,{onClick:()=>{a(!0),j()},disabled:i,children:i?"Signing":"Sign with your wallet"}):!e&&s?.retryable&&G<2?(0,k.jsx)(tq,{onClick:()=>{q(G+1),l(void 0),X?(a(!0),j()):L?.connectRetry()},invisible:e||!s?.retryable||G>=2,disabled:!e&&(!s?.retryable||G>=2),children:"Retry"}):null})]}),(0,k.jsx)(t9,{})]})},AWAITING_CONNECT_ONLY_CONNECTION:()=>{let{navigateBack:e,lastScreen:t,currentScreen:i}=v(),{walletConnectionStatus:a,closePrivyModal:s}=_(),[l,p]=(0,u.useState)(void 0),[f,w]=(0,u.useState)(0),y=a?.status==="connected",C=a?.status==="switching_to_supported_chain";(0,u.useEffect)(()=>{if(y){let e=setTimeout(s,1400);return()=>clearTimeout(e)}},[y]);let h=e=>{p(oa(e))};(0,u.useEffect)(()=>{a?.connectError&&h(a?.connectError)},[a]);let A=a?.connector?.connectorType||"metamask",T=a?.connector?.walletClientType||"metamask",I=a?.connector?.walletBranding.name||rA[T]?.name||"MetaMask",L=a?.connector?.walletBranding.icon||rA[T]?.component||(e=>(0,k.jsx)(Ce,{...e})),R;R=y?`Successfully connected with ${I}`:l?l.message:C?"Switching networks":`Waiting for ${I}`;let W="Don’t see your wallet modal? Check your other browser windows.";return y?W="You’re good to go!":f>=2&&l?W="Unable to connect wallet":l?W=l.detail:C?W="Switch your wallet to the requested network.":"metamask"===T?W="For the best experience, connect only one wallet at a time.":"wallet_connect_v2"===A?W="Open your mobile wallet app to continue":"coinbase_wallet"===A&&(W="Open the Coinbase app on your phone to continue."),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:i===t?void 0:e}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rT,{children:[(0,k.jsx)(ra,{walletLogo:L,success:y,fail:!!l}),(0,k.jsxs)(t2,{children:[(0,k.jsx)("h3",{children:R}),(0,k.jsx)("p",{children:W})]}),(0,k.jsx)(tV,{children:l==td.ERROR_USER_EXISTS?(0,k.jsx)(tq,{onClick:e,children:"Use a different wallet"}):!y&&l?.retryable&&f<2?(0,k.jsx)(tq,{onClick:()=>{w(f+1),p(void 0),a?.connectRetry()},invisible:y||!l?.retryable||f>=2,disabled:!y&&(!l?.retryable||f>=2),children:"Retry"}):null})]}),(0,k.jsx)(t9,{})]})},PHANTOM_INTERSTITIAL_SCREEN:()=>{let{forkSession:e,ready:t,authenticated:i}=$(),[a,s]=(0,u.useState)(""),[l,p]=(0,u.useState)(!1);(0,u.useEffect)(()=>{t&&i&&e().then(s)},[t,i]);let f=Ud(a,!l),w={title:"Redirecting to Phantom Mobile Wallet",description:"We'll take you to the Phantom Mobile Wallet app to continue your login experience.",footnote:""};return t&&(w.description="For the best experience, we'll automatically log you into the Phantom Mobile Wallet in-app browser.",w.footnote="Once you're done, you can always return here and refresh to view your updated account."),l&&(w.title="Still here?",w.description="You may need to install the Phantom mobile app.",w.footnote="Once you're done, you can return here or connect via Phantom's in-app browser."),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(rl,{title:w.title,description:w.description}),(0,k.jsxs)(tJ,{children:[(0,k.jsx)(no,{children:(0,k.jsx)(Ke,{style:{width:"72px",height:"72px"}})}),(0,k.jsx)(t$,{href:f,onClick:()=>{setTimeout(()=>p(!0),1e3)},loading:t&&!f,children:l?"Go to App Store":"Continue"}),w.footnote?(0,k.jsx)("p",{children:w.footnote}):null]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},LOGIN_FAILED_SCREEN:()=>{let{closePrivyModal:e}=_(),{navigate:t}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(Rd,{style:{width:"160px",height:"160px",margin:"0 auto 20px"}}),(0,k.jsx)(rl,{title:"Could not connect with wallet",description:"Please check that Phantom multichain is enabled and try again.",style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center"}}),(0,k.jsxs)(tJ,{children:[(0,k.jsx)(V,{onClick:()=>t("LANDING"),children:"Try again"}),(0,k.jsx)(xn,{onClick:()=>e(),children:"Cancel"})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},AWAITING_OAUTH_SCREEN:()=>{let{user:e,authenticated:t}=$(),{app:i,setModalData:a,navigate:s,resetNavigation:l,data:p}=v(),{getAuthMeta:f,initLoginWithOAuth:w,loginWithOAuth:y,updateWallets:C,closePrivyModal:A}=_(),[T,I]=(0,u.useState)(!1),[L,R]=(0,u.useState)(void 0),W=f()?.provider||"google",F=nt[W].name,z=nt[W].component,G=i?.render.inDialog?1400:0;(0,u.useEffect)(()=>{y().then(()=>{ni(),I(!0)}).catch(e=>{let t={retryable:!1,message:"Authentication failed"};if(e?.privyErrorCode==="allowlist_rejected"){R(void 0),l(),s("ALLOWLIST_REJECTION_SCREEN"),ni();return}e?.privyErrorCode==="linked_to_another_user"?t.detail="This account has already been linked to another user.":e?.privyErrorCode==="invalid_credentials"?(t.retryable=!0,t.detail="Something went wrong. Try again."):"oauth_user_denied"===e.privyErrorCode&&(t.detail=`Retry and check ${W.charAt(0).toUpperCase()+W.slice(1)} to finish connecting your account.`,t.retryable=!0),ni(),R(t)}).finally(()=>{p?.finishOauthFlow?.onComplete?.()})},[]),(0,u.useEffect)(()=>{if(t&&T&&e){if(zt(e,i?.embeddedWallets?.createOnLogin)){let e=setTimeout(()=>{a({createWallet:{onSuccess:()=>{},onFailure:e=>console.error(e),callAuthOnSuccessOnClose:!0}}),s("EMBEDDED_WALLET_ON_ACCOUNT_CREATE_SCREEN")},G);return()=>clearTimeout(e)}{let e=setTimeout(A,G);return C(),()=>clearTimeout(e)}}},[t,T,e]);let q=T?`Successfully connected with ${F}`:L?L.message:`Verifying connection to ${F}`,K="";return K=T?"You’re good to go!":L?L.detail:"Just a few moments more",(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{}),(0,k.jsx)(t4,{}),(0,k.jsxs)(nr,{children:[(0,k.jsx)(na,{children:(0,k.jsxs)("div",{children:[(0,k.jsx)(wn,{success:T,fail:!!L}),(0,k.jsx)(z,{style:{width:"38px",height:"38px"}})]})}),(0,k.jsxs)(t2,{children:[(0,k.jsx)("h3",{children:q}),(0,k.jsx)("p",{children:K})]}),L&&L?.retryable?(0,k.jsx)(tq,{onClick:()=>{ni(),w(W),R(void 0)},disabled:!T&&!L?.retryable,children:"Retry"}):null]}),(0,k.jsx)(t9,{})]})},ALLOWLIST_REJECTION_SCREEN:()=>{let{navigate:e,app:t}=v(),i=t?.allowlistConfig.errorTitle||"You don't have access to this app",a=t?.allowlistConfig.errorDetail||"Have you been invited?",s=t?.allowlistConfig.errorCtaText||"Try another account";return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rr,{children:[(0,k.jsx)(rs,{children:(0,k.jsxs)("div",{children:[(0,k.jsx)(tY,{}),(0,k.jsx)(Il,{style:{width:"38px",height:"38px",strokeWidth:"1",stroke:"var(--privy-color-accent)",fill:"var(--privy-color-accent)"}})]})}),(0,k.jsxs)(ro,{children:["string"==typeof i?(0,k.jsx)("h3",{children:i}):(0,k.jsx)(k.Fragment,{children:i}),"string"==typeof a?(0,k.jsx)("p",{children:a}):(0,k.jsx)(k.Fragment,{children:a})]}),t?.allowlistConfig.errorCtaLink?(0,k.jsx)(tq,{as:"a",href:t.allowlistConfig.errorCtaLink,children:s}):(0,k.jsx)(tq,{onClick:()=>{e("LANDING")},children:s})]}),(0,k.jsx)(t9,{})]})},INSTALL_METAMASK_SCREEN:()=>{let{navigateBack:e}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:e},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(xa,{}),(0,k.jsx)(t5,{}),(0,k.jsxs)(t9,{children:[(0,k.jsx)("span",{children:"Still not sure? "}),(0,k.jsx)("a",{target:"_blank",href:"https://ethereum.org/en/wallets/",children:"Learn more"})]})]})},INSTALL_PHANTOM_SCREEN:()=>{let{navigateBack:e}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:e},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(Pa,{}),(0,k.jsx)(t5,{}),(0,k.jsxs)(t9,{children:[(0,k.jsx)("span",{children:"Still not sure? "}),(0,k.jsx)("a",{target:"_blank",href:"https://ethereum.org/en/wallets/",children:"Learn more"})]})]})},INSTALL_COINBASE_WALLET_SCREEN:()=>{let{navigateBack:e}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{backFn:e},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(Ta,{}),(0,k.jsx)(t5,{}),(0,k.jsxs)(t9,{children:[(0,k.jsx)("span",{children:"Still not sure? "}),(0,k.jsx)("a",{target:"_blank",href:"https://ethereum.org/en/wallets/",children:"Learn more"})]})]})},LINK_EMAIL_SCREEN:()=>{let{app:e}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(fe,{title:"Connect your email",description:`Add your email to your ${e?.name} account`,icon:(0,k.jsx)(X.Z,{color:"var(--privy-color-accent)",strokeWidth:2,height:"48px",width:"48px"})}),(0,k.jsx)(tJ,{children:(0,k.jsx)(jn,{stacked:!0})}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},LINK_PHONE_SCREEN:()=>{let{app:e}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(fe,{title:"Connect your phone",description:`Add your number to your ${e?.name} account`,icon:(0,k.jsx)(et.Z,{color:"var(--privy-color-accent)",strokeWidth:2,height:"40px",width:"40px"})}),(0,k.jsx)(tJ,{children:(0,k.jsx)(Kn,{stacked:!0})}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},LINK_WALLET_SCREEN:()=>{let{linkingHint:e}=_(),{app:t}=v(),i=e?`Select the wallet with ${$t(e)} and follow the instructions to reconnect your wallet${t?.name?` to ${t.name}.`:"."}`:`Link a wallet to your ${t?.name} account`;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(rl,{title:`${e?"Reconnect":"Connect"} your wallet`,description:i}),(0,k.jsxs)(tJ,{children:[(0,k.jsx)(Zt,{connectOnly:!1}),(0,k.jsx)(Xt,{})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},CONNECT_ONLY_LANDING_SCREEN:()=>{let{app:e}=v();return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),e?.appearance.logo?(0,k.jsx)(rE,{children:(0,k.jsx)(Rn,{})}):null,(0,k.jsxs)(r_,{children:[(0,k.jsx)(rk,{children:(0,k.jsx)("h4",{children:"Connect Wallet"})}),(0,k.jsx)(Zt,{connectOnly:!0}),(0,k.jsx)(Xt,{})]}),e&&(0,k.jsx)(_n,{app:e}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},CONNECT_ONLY_AUTHENTICATED_SCREEN:()=>{let{app:e}=v(),t=`Connect a wallet to ${e?.name}`;return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(rl,{title:"Connect your wallet",description:t}),(0,k.jsxs)(tJ,{children:[(0,k.jsx)(Zt,{connectOnly:!0}),(0,k.jsx)(Xt,{})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_ON_ACCOUNT_CREATE_SCREEN:()=>{let{app:e,navigate:t,data:i,outerClickRef:a}=v(),[s,l]=(0,u.useState)(""),[p,f]=(0,u.useState)(!1),[w,y]=(0,u.useState)(),[C,A]=(0,u.useState)(null),T=(0,u.useRef)(!1),{authenticated:I,getAccessToken:L}=$(),{walletProxy:R,refreshUser:W,closePrivyModal:F,createAnalyticsEvent:z,isNewUserThisSession:G}=_(),{onSuccess:q,onFailure:K,callAuthOnSuccessOnClose:J}=i.createWallet,Q=e?.embeddedWallets.requireUserPasswordOnCreate===!0,X=!!(!s||T.current)&&!Q,et=new eG(async()=>B());(0,u.useEffect)(()=>{if(!I){t("LANDING"),K(Error("User must be authenticated before creating a Privy wallet"));return}Q||p||T.current||(f(!0),et.execute().finally(()=>f(!1)))},[Q,I]),a&&(a.current=()=>({closeModal:!1}));let B=async function(){let e=await L();if(e)try{if(z("embedded_wallet_creation_started"),!await R?.create({accessToken:e,recoveryPassword:w}))throw z("embedded_wallet_creation_failed",{}),Error("Unable to create wallet");let i=await W(),a=Z(i);if(!a)throw z("embedded_wallet_creation_failed",{}),Error("Unable to create wallet");A(a),z("embedded_wallet_creation_completed",{walletAddress:a.address}),l(""),T.current=!0,Q?t("EMBEDDED_WALLET_CREATED_SCREEN"):G?t("EMBEDDED_WALLET_CREATED_SCREEN"):a&&(q(a),F({shouldCallAuthOnSuccess:J}))}catch(e){if(T.current)return;l("An error has occurred, please try again."),console.warn(e)}},Y=async()=>Q?(f(!0),et.execute().then(()=>new Promise(e=>setTimeout(e,250))).finally(()=>f(!1))):F({shouldCallAuthOnSuccess:J});return X?(0,k.jsx)(r4,{children:(0,k.jsx)(Yo,{})}):(0,k.jsx)(Un,{config:{initiatedBy:"automatic"},appName:e?.name||"privy",loading:X||!R,buttonLoading:p,buttonHideAnimations:!C&&p,error:s,password:w||"",onClose:()=>{Q&&C&&C?.recoveryMethod!=="user-passcode"?K(new eZ("User created a wallet but failed to set a password for it")):C?q(C):K(new eZ("User wallet creation failed")),F({shouldCallAuthOnSuccess:J})},onPasswordChange:y,onPasswordGenerate:()=>y(Dn()),onSubmit:Y})},EMBEDDED_WALLET_CREATED_SCREEN:()=>{let{user:e}=$(),{closePrivyModal:t,isNewUserThisSession:i,updateWallets:a}=_(),{app:s,data:l,outerClickRef:p}=v(),{onSuccess:f,onFailure:w,callAuthOnSuccessOnClose:y}=l.createWallet,m=()=>{let i=Z(e);i?(a(),f(i),t({shouldCallAuthOnSuccess:y})):w(Error("Failed to create wallet"))};return(0,u.useEffect)(()=>{let e=setTimeout(m,2500);return()=>clearTimeout(e)},[]),p&&(p.current=m),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:m}),(0,k.jsx)(t4,{}),(0,k.jsxs)(t0,{children:[(0,k.jsx)(ei.Z,{fill:"var(--privy-color-accent)",stroke:"white",strokeWidth:".25px",width:"64px",height:"64px"}),(0,k.jsx)(fe,{title:i?`Welcome${s?.name?` to ${s?.name}`:""}`:"All set!",description:i?"You’ve successfully created an account.":"Your account is secured."})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_CONNECTING_SCREEN:()=>{let{authenticated:e,user:t,getAccessToken:i}=$(),{closePrivyModal:a,createAnalyticsEvent:s,walletProxy:l}=_(),{navigate:p,data:f,setModalData:w,outerClickRef:y}=v(),C=(0,u.useMemo)(()=>Date.now(),[]),[A,T]=(0,u.useState)(!1),{onCompleteNavigateTo:I,onFailure:L}=f?.connectWallet,S=e=>{A||(T(!0),L("string"==typeof e?Error(e):e))};(0,u.useEffect)(()=>{let u=Z(t),y;return e&&u?l?((async()=>{let e=await i();if(!e)return S("User must be authenticated and have a Privy wallet before it can be connected");try{await l.connect({accessToken:e,address:u.address});let t=(Date.now()-C)/1e3;"EMBEDDED_WALLET_KEY_EXPORT_SCREEN"===I&&t<1?y=setTimeout(()=>{p(I)},(1-t)*1e3):p(I)}catch(e){if(Jo(e)&&"privy"===u.recoveryMethod){let e=await i();if(!e)return S("User must be authenticated and have a Privy wallet before it can be recovered");try{s("embedded_wallet_pinless_recovery_started",{walletAddress:u.address}),(await l?.recover({address:u.address,accessToken:e}))?.address||S(Error("Unable to recover wallet")),I?p(I):a({shouldCallAuthOnSuccess:!1}),s("embedded_wallet_recovery_completed",{walletAddress:u.address}),p(I)}catch{S("An error has occurred, please try again.")}}else Jo(e)?(w({...f,recoverWallet:{privyWallet:u,onCompleteNavigateTo:I,onFailure:L}}),p("EMBEDDED_WALLET_RECOVERY_SCREEN")):S(e)}})(),()=>clearTimeout(y)):void 0:S("User must be authenticated and have a Privy wallet before it can be connected")},[e,t,l]);let E=()=>{a({shouldCallAuthOnSuccess:!1}),S("User exited before wallet could be connected")};return y&&(y.current=E),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:E}),(0,k.jsx)(t4,{}),(0,k.jsx)(rM,{children:A?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsxs)(t0,{children:[(0,k.jsx)(er.Z,{fill:"var(--privy-color-error)",stroke:"white",strokeWidth:".25px",width:"64px",height:"64px"}),(0,k.jsx)(fe,{title:"Something went wrong",description:"We’re on it. Please try again later."})]}),(0,k.jsx)(V,{onClick:()=>a({shouldCallAuthOnSuccess:!1}),children:"Close"})]}):(0,k.jsx)(Yo,{})}),(0,k.jsx)(t5,{})]})},EMBEDDED_WALLET_RECOVERY_SCREEN:()=>{let{authenticated:e,getAccessToken:t}=$(),{walletProxy:i,closePrivyModal:a,createAnalyticsEvent:s}=_(),{navigate:l,data:p,outerClickRef:f}=v(),[w,y]=(0,u.useState)(void 0),[C,A]=(0,u.useState)(""),[T,I]=(0,u.useState)(!1),{privyWallet:L,onCompleteNavigateTo:R,onSuccess:W,onFailure:F}=p.recoverWallet,g=(e="User exited before their wallet could be recovered")=>{a({shouldCallAuthOnSuccess:!1}),F("string"==typeof e?new eZ(e):e)};f&&(f.current=()=>g()),(0,u.useEffect)(()=>{if(!e||!L)return g("User must be authenticated and have a Privy wallet before it can be recovered")},[e]);let D=e=>{e&&y(e)};return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:g}),(0,k.jsx)(t4,{}),(0,k.jsxs)(ib,{children:[(0,k.jsxs)(iv,{children:[(0,k.jsx)(eb.Z,{height:48,width:48,stroke:"var(--privy-color-accent)"}),(0,k.jsx)("h3",{style:{color:"var(--privy-color-foreground)"},children:"Load your account"}),(0,k.jsx)("p",{style:{color:"var(--privy-color-foreground-2)"},children:"Please provision your account on this new device. To continue, enter your recovery password."})]}),(0,k.jsxs)("div",{children:[(0,k.jsx)(rQ,{onChange:e=>D(e.target.value),disabled:T}),!!C&&(0,k.jsx)(iC,{children:C})]}),(0,k.jsxs)("div",{children:[(0,k.jsxs)(t3,{children:[(0,k.jsx)("h4",{children:"Why is this necessary?"}),(0,k.jsx)("p",{children:"You previously set a password for this wallet. This helps ensure only you can access it"})]}),(0,k.jsx)(ij,{loading:T||!i,disabled:!w,onClick:async()=>{I(!0);let e=await t();if(!e||!L||null===w)return g("User must be authenticated and have a Privy wallet before it can be recovered");try{s("embedded_wallet_recovery_started",{walletAddress:L.address}),await i?.recover({address:L.address,accessToken:e,recoveryPin:w}),A(""),R?l(R):a({shouldCallAuthOnSuccess:!1}),W?.(L),s("embedded_wallet_recovery_completed",{walletAddress:L.address})}catch(e){aa(e)&&("invalid_recovery_pin"===e.type||"invalid_request_arguments"===e.type)?A("Invalid recovery password, please try again."):A("An error has occurred, please try again.")}finally{I(!1)}},warn:!1,hideAnimations:!L&&T,children:"Recover your account"})]})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_KEY_EXPORT_SCREEN:()=>{let[e,t]=(0,u.useState)(null),{authenticated:i,user:a,getAccessToken:s}=$(),{closePrivyModal:l,createAnalyticsEvent:p}=_(),{data:f,outerClickRef:w}=v(),y=Z(a)?.address,{onFailure:C,onSuccess:A,origin:T,appId:I}=f.keyExport,b=e=>{l({shouldCallAuthOnSuccess:!1}),C("string"==typeof e?Error(e):e)},S=()=>{l({shouldCallAuthOnSuccess:!1}),A(),p("embedded_wallet_key_export_completed",{walletAddress:y})};return(0,u.useEffect)(()=>{let e=Z(a);if(!i||!e)return b("User must be authenticated before exporting their wallet");s().then(t,b)},[i,a]),w&&(w.current=S),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:S}),(0,k.jsx)(t4,{}),(0,k.jsxs)(rU,{children:[(0,k.jsx)(cc,{}),(0,k.jsxs)(rD,{children:[(0,k.jsx)("h3",{children:"Transfer"}),(0,k.jsxs)(rH,{children:[(0,k.jsx)(bh,{style:{marginRight:6}}),$t(y)]})]}),(0,k.jsx)("p",{children:"You can take your account with you to another site using an external wallet!"}),(0,k.jsxs)(rF,{children:[(0,k.jsxs)(rZ,{children:[(0,k.jsx)(rz,{children:"1"}),(0,k.jsxs)("span",{children:[(0,k.jsx)("a",{href:"https://privy-io.notion.site/Transferring-your-account-9dab9e16c6034a7ab1ff7fa479b02828",target:"blank",rel:"noopener noreferrer",children:"Follow the guide"})," ","to transfer your account to your wallet of choice."]})]}),(0,k.jsxs)(rZ,{children:[(0,k.jsx)(rz,{children:"2"}),(0,k.jsx)("span",{children:"Copy this key into your other wallet"})]})]}),(0,k.jsx)("div",{style:{width:"100%"},children:e&&(0,k.jsx)(Ch,{origin:T,appId:I,accessToken:e,address:y,dimensions:{height:"44px"}})}),(0,k.jsxs)(rG,{children:[(0,k.jsx)("h4",{children:"WARNING"}),(0,k.jsx)("p",{children:"Never share your private key with anyone! It controls your account."})]})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_SIGN_REQUEST_SCREEN:()=>{let{authenticated:e}=$(),{walletProxy:t,closePrivyModal:i}=_(),{navigate:a,data:s,outerClickRef:l}=v(),[p,f]=(0,u.useState)(""),[w,y]=(0,u.useState)(),[C,A]=(0,u.useState)(null),T=null!==C;(0,u.useEffect)(()=>{e||a("LANDING")},[e]);let{message:I,confirmAndSignMessage:L,onSuccess:R,onFailure:W,uiOptions:F}=s.signMessage,z={title:F.title||"Sign message",description:F.description||"Signing this message will not cost you any fees.",buttonText:F.buttonText||"Sign and continue"},U=e=>{e?R(e):W(w||new ts(new to("The user rejected the request.",tc.E4001_USER_REJECTED_REQUEST.eipCode))),i({shouldCallAuthOnSuccess:!1}),A(null),f(""),y(void 0)};return l&&(l.current=()=>U(C)),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:()=>U(C)}),(0,k.jsx)(t4,{}),(0,k.jsxs)(n2,{children:[(0,k.jsxs)("div",{children:[(0,k.jsx)(vt,{title:z.title,description:z.description}),(0,k.jsx)(n3,{children:D1(I)}),(0,k.jsx)(n4,{fail:!0,children:p})]}),(0,k.jsx)(n6,{success:T,loading:!t,disabled:T,onClick:async()=>{try{let e=await L();A(e),f(""),setTimeout(()=>{U(e)},1400)}catch{f("An error has occurred, please try again."),y(new ts(new to(p,tc.E32603_DEFAULT_INTERNAL_ERROR.eipCode)))}},children:T?(0,k.jsxs)(n5,{children:[(0,k.jsx)(kp,{style:{height:"0.9rem",width:"0.9rem"},strokeWidth:2})," ",(0,k.jsx)("span",{children:"Success"})]}):z.buttonText})]}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_SEND_TRANSACTION_SCREEN:()=>{let{authenticated:e,getAccessToken:t}=$(),{wallets:i}=Ja(),{walletProxy:a,closePrivyModal:s,getFiatOnRampConfig:p,rpcConfig:f,chains:w,nativeTokenSymbolForChainId:y}=_(),{app:C,navigate:A,data:T,outerClickRef:I,setModalData:L}=v(),{transactionRequest:R,onSuccess:W,onFailure:F,uiOptions:z,fundWalletConfig:G}=T.sendTransaction,[q,K]=(0,u.useState)(null),[J,Q]=(0,u.useState)(""),[X,et]=(0,u.useState)(),[er,ei]=(0,u.useState)(!1),[en,ea]=(0,u.useState)(!0),[eo,es]=(0,u.useState)(!1),[ec,eh]=(0,u.useState)(R),{tokenPrice:eu,estimatedGas:ep}=mi(ec),em=y(R.chainId)||"ETH";(0,u.useEffect)(()=>{e||(A("LANDING"),F(Error("User must be authenticated before transacting with a Privy wallet")))},[e]);let ef=(0,u.useMemo)(()=>i.find(e=>"privy"===e.walletClientType),[i]),ur=async()=>{if(!ef)return console.warn("No privy wallet found, cannot fund wallet.");let{signedUrl:e,externalTransactionId:t}=await p(ef.address,{config:G?.config||{}});L({fiatOnRampPrompt:{signedUrl:e},fiatOnRampStatus:{externalTransactionId:t}}),A("FIAT_ON_RAMP_PROMPT_SCREEN")},eg=(0,u.useMemo)(()=>new l.c(tt(ec.chainId,w,f)),[ec.chainId,f]);(0,u.useEffect)(()=>{(async function(){return await t()&&a&&ef?di(ef.address,ec,eg):ec})().then(e=>{ea(!1),eh(e)},async e=>{ea(!0);let t=!1;if(aa(e)&&"insufficient_funds"===e.type||"INSUFFICIENT_FUNDS"===e.code)t=!0;else if("UNPREDICTABLE_GAS_LIMIT"===e.code)try{let{hasSufficientFunds:e}=await ui(ef.address,ec,eg);t=!1===e}catch(e){console.warn(`Cannot accurately determine if wallet has sufficient funds with error: ${e}`)}let i="";t?(i="Wallet has insufficient funds for this transaction",C?.fiatOnRamp.enabled&&ei(!0)):(i="There was an error preparing your transaction",console.error(e)),Q(i),et(new ts(new to(i,tc.E32603_DEFAULT_INTERNAL_ERROR.eipCode)))})},[a]);let ew=ec.to&&ec.data?"CONTRACT_CALL":ec.to&&ec.value?"SEND":"UNKNOWN",ex="SEND"===ew?`Send ${em}`:"Review transaction",ey={modalTitle:z.header||z.modalTitle||ex,buttonText:z.buttonText||"Submit"},Ft=()=>{eo||(q?W(q):F(X||new ts(new to("The user rejected the request",tc.E4001_USER_REJECTED_REQUEST.eipCode))),s({shouldCallAuthOnSuccess:!1}))};return I&&(I.current=Ft),void 0===eu?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{title:ey.modalTitle,onClose:Ft}),(0,k.jsx)(t4,{}),(0,k.jsx)(nK,{children:(0,k.jsx)(Yo,{})}),(0,k.jsx)(t5,{})]}):null!==q?(0,k.jsx)(xp,{txn:ec,onClose:Ft,receipt:q,transactionInfo:z.transactionInfo,tokenPrice:eu}):(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{title:ey.modalTitle,onClose:Ft}),(0,k.jsxs)(nK,{children:[(0,k.jsxs)(nX,{children:[(0,k.jsx)(S1,{txn:ec,txnFamily:ew,uiOptions:z}),ef?(0,k.jsx)(ci,{from:ef.address,to:ec.to,txn:ec,transactionInfo:z.transactionInfo,gas:ep?Ie(ep).toHexString():void 0,tokenPrice:eu}):null]}),(0,k.jsxs)(n0,{children:[(0,k.jsx)(nY,{children:J}),ef?(0,k.jsx)(yp,{txn:ec,wallet:ef,provider:eg}):null,(0,k.jsxs)(nJ,{children:[er&&(0,k.jsx)(V,{onClick:ur,children:"Add Funds"}),(0,k.jsx)(nQ,{disabled:en||eo,loading:!a||eo,loadingText:eo?"Submitting (may take a few minutes)...":"Loading...",onClick:async()=>{es(!0);let e=await t();if(e&&!eo&&ef)try{let t=await pi(e,ef.address,a,ec,eg);K(t),Q("")}catch(t){let e="";"processing response error"===t.reason?(console.warn({transaction:ec,error:t}),e="An error has occurred, please contact support."):e=t.reason||"An error has occurred, please try again.",Q(e),et(new ts(new to(e,tc.E32603_DEFAULT_INTERNAL_ERROR.eipCode)))}finally{es(!1)}},children:ey.buttonText})]})]})]}),(0,k.jsx)(t9,{})]})},FIAT_ON_RAMP_PROMPT_SCREEN:()=>{let{app:e,data:t,navigate:i}=v(),{createAnalyticsEvent:a}=_(),{signedUrl:s}=t.fiatOnRampPrompt;return e&&s?(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{title:"Fund account"},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)($c,{app:e,signedUrl:s,onContinue:()=>{a("sdk_fiat_on_ramp_started",{provider:iO}),i("FIAT_ON_RAMP_STATUS_SCREEN")}}),(0,k.jsx)(O,{protectedByPrivy:!0})]}):null},FIAT_ON_RAMP_STATUS_SCREEN:()=>{let{app:e,data:t}=v(),{closePrivyModal:i}=_(),{externalTransactionId:a}=t?.fiatOnRampStatus,s=function(e,t=!1){let[i,a]=(0,u.useState)(null),{createAnalyticsEvent:s}=_(),l=(0,u.useRef)(0);return(0,u.useEffect)(()=>{let i=setInterval(async()=>{if(e)try{let[l]=await ry(e,t),u="waitingAuthorization"===l.status&&"credit_debit_card"===l.paymentMethod?"pending":l.status;a(u),["failed","completed","awaitingAuthorization"].includes(u)&&(s(iL,{status:u,provider:iO,paymentMethod:l.paymentMethod,cardPaymentType:l.cardPaymentType,currency:l.currency?.code,baseCurrencyAmount:l.baseCurrencyAmount,quoteCurrencyAmount:l.quoteCurrencyAmount,feeAmount:l.feeAmount,extraFeeAmount:l.extraFeeAmount,networkFeeAmount:l.networkFeeAmount}),clearInterval(i))}catch(e){e.response?.status!==404&&(l.current+=1),l.current>=3&&(a("serviceFailure"),s(iL,{status:"serviceFailure",provider:iO}),clearInterval(i))}},3e3);return()=>clearInterval(i)},[e,l]),i}(a||null,e.fiatOnRamp.useSandbox);return(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{title:"Fund account"},"header"),(0,k.jsx)(t4,{}),(0,k.jsx)(py,{status:s,onClickCta:i}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_PASSWORD_UPDATE_SPLASH_SCREEN:()=>{let{user:e}=$(),{closePrivyModal:t,createAnalyticsEvent:i}=_(),{data:a,setModalData:s,navigate:l,outerClickRef:p}=v(),{onSuccess:f,onFailure:w}=a.setWalletPassword,c=()=>{w(new eZ("Exited before password was added to wallet")),t({shouldCallAuthOnSuccess:!1})};return(0,u.useEffect)(()=>{p&&(p.current=c)},[]),(0,k.jsxs)(k.Fragment,{children:[(0,k.jsx)(P,{onClose:c}),(0,k.jsx)(t4,{}),(0,k.jsxs)(t0,{children:[(0,k.jsxs)(t6,{children:[(0,k.jsx)(ex.Z,{stroke:"var(--privy-color-accent)",width:"64px",height:"64px"}),(0,k.jsx)(t7,{style:{width:24,height:24,position:"absolute",bottom:0,right:0},children:(0,k.jsx)(ey.Z,{width:"12px",height:"12px",fill:"white"})})]}),(0,k.jsxs)(fe,{title:"Secure Your Account",children:["Please set a password to secure your account.",(0,k.jsx)("p",{children:"Losing this password will make your account inaccessible on new devices. You will only be asked for it when you log on to a new device."})]})]}),(0,k.jsx)(V,{onClick:()=>{let t=Z(e);i("embedded_wallet_set_password_started",{walletAddress:t?.address}),s({createWallet:{onFailure:w,onSuccess:f,callAuthOnSuccessOnClose:!1,addPasswordToExistingWallet:!0}}),l("EMBEDDED_WALLET_PASSWORD_UPDATE_SCREEN")},children:"Add password"}),(0,k.jsx)(t5,{}),(0,k.jsx)(O,{protectedByPrivy:!0})]})},EMBEDDED_WALLET_PASSWORD_UPDATE_SCREEN:()=>{let[e,t]=(0,u.useState)(null),[i,a]=(0,u.useState)(!1),[s,l]=(0,u.useState)(null),[p,f]=(0,u.useState)(""),{authenticated:w,getAccessToken:y,user:C}=$(),{walletProxy:A,refreshUser:T,closePrivyModal:I,createAnalyticsEvent:L}=_(),{app:R,navigate:W,data:F,outerClickRef:z}=v(),{onSuccess:G,onFailure:q}=F.createWallet,K=Z(C),J=e?.recoveryMethod==="user-passcode";(0,u.useEffect)(()=>{w||(W("LANDING"),q(new ez("User must be authenticated before setting a password on a Privy wallet")))},[w]);let M=()=>{if(s){q(s),I({shouldCallAuthOnSuccess:!1});return}if(!J){q(new eZ("Exited before password was added to wallet")),I({shouldCallAuthOnSuccess:!1});return}G(e),I({shouldCallAuthOnSuccess:!1})};z&&(z.current=()=>(M(),{closeModal:!J}));let ue=async()=>{let e=await y();if(e&&K?.address&&p&&A)try{if(L("embedded_wallet_set_password_started",{walletAddress:K.address}),!(await A.setRecoveryPassword({accessToken:e,address:K.address,recoveryPassword:p})).address){l(new eZ("Error setting password on privy wallet")),L("embedded_wallet_set_password_failed",{walletAddress:K.address,reason:"error setting password"});return}let i=await T(),a=Z(i);if(!a){l(new eZ("Error setting password on privy wallet")),L("embedded_wallet_set_password_failed",{walletAddress:K.address,reason:"wallet disconnected"});return}t(a),L("embedded_wallet_set_password_completed",{walletAddress:K.address})}catch(e){console.warn(e),l(e instanceof Error?e:Error("Error setting password on privy wallet")),L("embedded_wallet_set_password_failed",{walletAddress:K.address,reason:e})}},H=async()=>{J?(G(e),I({shouldCallAuthOnSuccess:!1})):(a(!0),l(null),await ue(),a(!1))};return(0,k.jsx)(Un,{appName:R?.name||"privy",config:{initiatedBy:"user",onCancel:M},error:s?"An error has occurred, please try again.":void 0,buttonLoading:i,buttonHideAnimations:!1,password:p,onPasswordGenerate:()=>f(Dn()),onPasswordChange:f,onSubmit:H,onClose:M})}},at={AWAITING_CONNECTION:"compact",AWAITING_CONNECT_ONLY_CONNECTION:"compact",CONNECT_ONLY_LANDING_SCREEN:"compact",CONNECT_ONLY_AUTHENTICATED_SCREEN:"compact",AWAITING_OAUTH_SCREEN:"compact",ALLOWLIST_REJECTION_SCREEN:"compact",WALLET_EDUCATION:"full",EMBEDDED_WALLET_SIGN_REQUEST_SCREEN:"full",EMBEDDED_WALLET_RECOVERY_SCREEN:"compact"},ev=(e,t,i)=>"LANDING"===e&&t?"compact":at[e]||(i?"medium":"full"),tv=()=>{let{ready:e}=$(),{isLinking:t}=_(),{ready:i,currentScreen:a,app:s}=v(),l=ev(a,!!s?.loginMethods.wallet!=!!(s?.loginMethods.email||s?.loginMethods.sms),t);if((!e||!i)&&"AWAITING_OAUTH_SCREEN"!==a)return(0,k.jsxs)(al,{"data-height":l,children:[(0,k.jsx)(P,{}),(0,k.jsx)(t4,{}),(0,k.jsx)(ac,{children:(0,k.jsx)(tD,{})}),(0,k.jsx)(t5,{}),(0,k.jsx)(t9,{})]});let u=ae[a];return u?(0,k.jsx)(al,{"data-height":l,children:(0,k.jsx)(u,{})}):null},Mp=()=>{let{closePrivyModal:e}=_(),{app:t,outerClickRef:i}=v(),r=()=>{if(!i?.current)return e();{let{closeModal:t}=i.current()||{closeModal:!0};t&&(e(),i.current=null)}},a=(0,u.useCallback)(e=>{"Escape"===e.key&&t?.render.inDialog&&r()},[t?.render.inDialog]);(0,u.useEffect)(()=>(document.addEventListener("keydown",a,!1),()=>{document.removeEventListener("keydown",a,!1)}),[a]);let s=(0,k.jsx)(n9,{onClick:e=>e.stopPropagation(),children:(0,k.jsx)(tv,{})}),l=t?.render.inDialog?(0,k.jsx)(ao,{id:"privy-dialog",onClick:()=>r(),children:s}):s;return q.createPortal(l,t?.render.inParentNodeId&&document.getElementById(t.render.inParentNodeId)||document.body)},ao=(0,K.ZP)(({children:e,...t})=>{let i=(0,u.useRef)(null);return(0,u.useEffect)(()=>{document?.activeElement?.blur();let e=document?.getElementById("root")||document?.getElementById("__next");if(e)return e.setAttribute("inert","true"),(0,G.Qp)(i?.current),()=>{let e=document?.getElementById("root")||document?.getElementById("__next");e&&(e.removeAttribute("inert"),(0,G.tP)())}},[t.open,t.onClose]),(0,k.jsx)("dialog",{open:!0,role:"dialog",...t,ref:i,children:e})})` + position: fixed; + top: 0; + left: 0; + width: 100vw; + height: 100%; + display: flex; + justify-content: center; + align-items: center; + background: none; + padding: 0; + border: 0; + z-index: 999999; + -webkit-backdrop-filter: blur(3px); + backdrop-filter: blur(3px); +`,al=K.ZP.div` + display: flex; + flex-direction: column; + text-align: center; + font-size: 14px; + line-height: 20px; + width: 360px; + height: auto; + background: var(--privy-color-background); + box-shadow: 0px 8px 36px rgba(55, 65, 81, 0.15); + border-radius: var(--privy-border-radius-lg); + padding: 0 16px; + + &&[data-height='full'] { + height: 620px; + } + + &&[data-height='medium'] { + min-height: 480px; + } + + /* Mobile */ + @media (max-width: 440px) { + &&& { + border-radius: 24px 24px 0 0; + height: auto; + position: fixed; + bottom: 0; + left: 0; + width: 100%; + /* Same as above, but move y offset to 0 to help differentiate top from + white backgrounds on mobile. */ + box-shadow: 0px 0px 36px rgba(55, 65, 81, 0.15); + /* Always override on mobile if min-height is set */ + min-height: 0; + } + } +`,ac=K.ZP.div` + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + height: 100%; +`,Dp=({onLoad:e})=>{let t=window;return(0,u.useEffect)(()=>{if(null!==document.getElementById("cf-script")||t.turnstile)return;t.onloadTurnstileCallback=e;let i=document.createElement("script");i.setAttribute("src","https://challenges.cloudflare.com/turnstile/v0/api.js?onload=onloadTurnstileCallback&render=explicit"),i.setAttribute("id","cf-script"),i.setAttribute("async","true"),document.body.appendChild(i)},[]),(0,k.jsx)(k.Fragment,{})},ad={id:1,network:"homestead",name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-mainnet.g.alchemy.com/v2"],webSocket:["wss://eth-mainnet.g.alchemy.com/v2"]},infura:{http:["https://mainnet.infura.io/v3"],webSocket:["wss://mainnet.infura.io/ws/v3"]},default:{http:["https://cloudflare-eth.com"]},public:{http:["https://cloudflare-eth.com"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://etherscan.io"},default:{name:"Etherscan",url:"https://etherscan.io"}}},ah=[{id:42161,name:"Arbitrum One",network:"arbitrum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://arb-mainnet.g.alchemy.com/v2"],webSocket:["wss://arb-mainnet.g.alchemy.com/v2"]},infura:{http:["https://arbitrum-mainnet.infura.io/v3"],webSocket:["wss://arbitrum-mainnet.infura.io/ws/v3"]},default:{http:["https://arb1.arbitrum.io/rpc"]},public:{http:["https://arb1.arbitrum.io/rpc"]}},blockExplorers:{etherscan:{name:"Arbiscan",url:"https://arbiscan.io"},default:{name:"Arbiscan",url:"https://arbiscan.io"}}},{id:421613,name:"Arbitrum Goerli",network:"arbitrum-goerli",nativeCurrency:{name:"Goerli Ether",symbol:"AGOR",decimals:18},rpcUrls:{alchemy:{http:["https://arb-goerli.g.alchemy.com/v2"],webSocket:["wss://arb-goerli.g.alchemy.com/v2"]},infura:{http:["https://arbitrum-goerli.infura.io/v3"],webSocket:["wss://arbitrum-goerli.infura.io/ws/v3"]},default:{http:["https://goerli-rollup.arbitrum.io/rpc"]},public:{http:["https://goerli-rollup.arbitrum.io/rpc"]}},blockExplorers:{etherscan:{name:"Arbiscan",url:"https://goerli.arbiscan.io/"},default:{name:"Arbiscan",url:"https://goerli.arbiscan.io/"}},testnet:!0},{id:5,network:"goerli",name:"Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-goerli.g.alchemy.com/v2"],webSocket:["wss://eth-goerli.g.alchemy.com/v2"]},infura:{http:["https://goerli.infura.io/v3"],webSocket:["wss://goerli.infura.io/ws/v3"]},default:{http:["https://rpc.ankr.com/eth_goerli"]},public:{http:["https://rpc.ankr.com/eth_goerli"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://goerli.etherscan.io"},default:{name:"Etherscan",url:"https://goerli.etherscan.io"}},testnet:!0},{id:11155111,network:"sepolia",name:"Sepolia",nativeCurrency:{name:"Sepolia Ether",symbol:"SEP",decimals:18},rpcUrls:{alchemy:{http:["https://eth-sepolia.g.alchemy.com/v2"],webSocket:["wss://eth-sepolia.g.alchemy.com/v2"]},infura:{http:["https://sepolia.infura.io/v3"],webSocket:["wss://sepolia.infura.io/ws/v3"]},default:{http:["https://rpc.sepolia.org"]},public:{http:["https://rpc.sepolia.org"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://sepolia.etherscan.io"},default:{name:"Etherscan",url:"https://sepolia.etherscan.io"}},testnet:!0},ad,{id:10,name:"OP Mainnet",network:"optimism",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://opt-mainnet.g.alchemy.com/v2"],webSocket:["wss://opt-mainnet.g.alchemy.com/v2"]},infura:{http:["https://optimism-mainnet.infura.io/v3"],webSocket:["wss://optimism-mainnet.infura.io/ws/v3"]},default:{http:["https://mainnet.optimism.io"]},public:{http:["https://mainnet.optimism.io"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://optimistic.etherscan.io"},default:{name:"Optimism Explorer",url:"https://explorer.optimism.io"}}},{id:420,name:"Optimism Goerli Testnet",network:"optimism-goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://opt-goerli.g.alchemy.com/v2"],webSocket:["wss://opt-goerli.g.alchemy.com/v2"]},infura:{http:["https://optimism-goerli.infura.io/v3"],webSocket:["wss://optimism-goerli.infura.io/ws/v3"]},default:{http:["https://goerli.optimism.io"]},public:{http:["https://goerli.optimism.io"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://goerli-optimism.etherscan.io"},default:{name:"Etherscan",url:"https://goerli-optimism.etherscan.io"}},testnet:!0},nW,nM,{id:42220,name:"Celo Mainnet",network:"celo",nativeCurrency:{decimals:18,name:"CELO",symbol:"CELO"},rpcUrls:{default:{http:["https://forno.celo.org"]},infura:{http:["https://celo-mainnet.infura.io/v3"]},public:{http:["https://forno.celo.org"]}},blockExplorers:{default:{name:"Celo Explorer",url:"https://explorer.celo.org/mainnet"},etherscan:{name:"CeloScan",url:"https://celoscan.io"}},testnet:!1},{id:44787,name:"Celo Alfajores Testnet",network:"celo-alfajores",nativeCurrency:{decimals:18,name:"CELO",symbol:"CELO"},rpcUrls:{default:{http:["https://alfajores-forno.celo-testnet.org"]},infura:{http:["https://celo-alfajores.infura.io/v3"]},public:{http:["https://alfajores-forno.celo-testnet.org"]}},blockExplorers:{default:{name:"Celo Explorer",url:"https://explorer.celo.org/alfajores"},etherscan:{name:"CeloScan",url:"https://alfajores.celoscan.io/"}},testnet:!0},{id:314,name:"Filecoin - Mainnet",network:"filecoin-mainnet",nativeCurrency:{decimals:18,name:"filecoin",symbol:"FIL"},rpcUrls:{default:{http:["https://api.node.glif.io/rpc/v1"]},public:{http:["https://api.node.glif.io/rpc/v1"]}},blockExplorers:{default:{name:"Filfox",url:"https://filfox.info/en"},filscan:{name:"Filscan",url:"https://filscan.io"},filscout:{name:"Filscout",url:"https://filscout.io/en"},glif:{name:"Glif",url:"https://explorer.glif.io"}}},{id:314159,name:"Filecoin - Calibration testnet",network:"filecoin-calibration",nativeCurrency:{decimals:18,name:"testnet filecoin",symbol:"tFIL"},rpcUrls:{default:{http:["https://api.calibration.node.glif.io/rpc/v1"]},public:{http:["https://api.calibration.node.glif.io/rpc/v1"]}},blockExplorers:{default:{name:"Filscan",url:"https://calibration.filscan.io"}}},{id:8453,network:"base",name:"Base",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{blast:{http:["https://base-mainnet.blastapi.io"],webSocket:["wss://base-mainnet.blastapi.io"]},default:{http:["https://mainnet.base.org"]},public:{http:["https://mainnet.base.org"]}},blockExplorers:{etherscan:{name:"Basescan",url:"https://basescan.org"},default:{name:"Basescan",url:"https://basescan.org"}},testnet:!0},{id:84531,network:"base-goerli",name:"Base Goerli Testnet",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{blast:{http:["https://base-goerli.blastapi.io"],webSocket:["wss://base-goerli.blastapi.io"]},default:{http:["https://goerli.base.org"]},public:{http:["https://goerli.base.org"]}},blockExplorers:{etherscan:{name:"Basescan",url:"https://goerli.basescan.org"},default:{name:"Basescan",url:"https://goerli.basescan.org"}},testnet:!0},{id:59144,network:"linea-mainnet",name:"Linea Mainnet",nativeCurrency:{name:"Linea Ether",symbol:"ETH",decimals:18},rpcUrls:{infura:{http:["https://linea-mainnet.infura.io/v3"],webSocket:["wss://linea-mainnet.infura.io/ws/v3"]},default:{http:["https://rpc.linea.build"],webSocket:["wss://rpc.linea.build"]},public:{http:["https://rpc.linea.build"],webSocket:["wss://rpc.linea.build"]}},blockExplorers:{default:{name:"Etherscan",url:"https://lineascan.build"},etherscan:{name:"Etherscan",url:"https://lineascan.build"}},testnet:!1},{id:59140,network:"linea-testnet",name:"Linea Goerli Testnet",nativeCurrency:{name:"Linea Ether",symbol:"ETH",decimals:18},rpcUrls:{infura:{http:["https://linea-goerli.infura.io/v3"],webSocket:["wss://linea-goerli.infura.io/ws/v3"]},default:{http:["https://rpc.goerli.linea.build"],webSocket:["wss://rpc.goerli.linea.build"]},public:{http:["https://rpc.goerli.linea.build"],webSocket:["wss://rpc.goerli.linea.build"]}},blockExplorers:{default:{name:"Etherscan",url:"https://goerli.lineascan.build"},etherscan:{name:"Etherscan",url:"https://goerli.lineascan.build"}},testnet:!0},{id:43114,name:"Avalanche",network:"avalanche",nativeCurrency:{decimals:18,name:"Avalanche",symbol:"AVAX"},rpcUrls:{default:{http:["https://api.avax.network/ext/bc/C/rpc"]},public:{http:["https://api.avax.network/ext/bc/C/rpc"]}},blockExplorers:{etherscan:{name:"SnowTrace",url:"https://snowtrace.io"},default:{name:"SnowTrace",url:"https://snowtrace.io"}}},{id:43113,name:"Avalanche Fuji",network:"avalanche-fuji",nativeCurrency:{decimals:18,name:"Avalanche Fuji",symbol:"AVAX"},rpcUrls:{default:{http:["https://api.avax-test.network/ext/bc/C/rpc"]},public:{http:["https://api.avax-test.network/ext/bc/C/rpc"]}},blockExplorers:{etherscan:{name:"SnowTrace",url:"https://testnet.snowtrace.io"},default:{name:"SnowTrace",url:"https://testnet.snowtrace.io"}},testnet:!0}];ah.map(e=>e.id);var au="#FFFFFF";function po(e,t){let i=Math.max(0,Math.min(1,e.toHsl().l+t));return(0,eL.Z)({...e.toHsl(),l:i})}var am={appearance:{theme:"light",accentColor:"#676FFF"},walletConnectCloudProjectId:"34357d3c125c2bcf2ce2bc3309d98715",rpcConfig:{rpcUrls:{}},captchaEnabled:!1,_render:{inDialog:!0,inParentNodeId:null},fiatOnRamp:{useSandbox:!1}};function vi(e,t){let i=["google","twitter","discord","tiktok","linkedin","github","apple"],a=t?.loginMethods?.filter(e=>i.includes(e)),s=a?.slice(0,5),l,u,p,f,w,y,C,k,A,T;if(t?.loginMethods?(l=t.loginMethods.includes("email"),u=t.loginMethods.includes("sms"),p=t.loginMethods.includes("wallet"),f=s?.includes("google"),w=s?.includes("twitter"),y=s?.includes("discord"),C=s?.includes("tiktok"),A=s?.includes("github"),k=s?.includes("linkedin"),T=s?.includes("apple")):(l=e.emailAuth,u=e.smsAuth,p=e.walletAuth,f=e.googleOAuth,w=e.twitterOAuth,y=e.discordOAuth,A=e.githubOAuth,C=e.tiktokOAuth,k=e.linkedinOAuth,T=e.appleOAuth),l&&u&&(console.warn("Enabling both email and SMS passwordless is not currently supported. Disabling SMS."),u=!1),!l&&!u&&[f,w,y,A,C,k,T].some(e=>e))throw Error("To enable social logins you must also enable either SMS or Email login");if(![l,u,p,f,w,y,A,C,k,T].some(e=>e))throw Error("You must enable at least one login method");let{chains:I,defaultChain:L}=function(e,t,i){let a;if(e&&t&&console.warn("You should only specify one of `additionalChains` or `supportedChains`. Using `supportedChains`."),t){if(0===t.length)throw Error("`supportedChains` must contain at least one chain");a=t}else a=ah.concat(e??[]);let s=t?a[0]:ad,l=i??s;if(!a.find(e=>e.id===l.id))throw Error("`defaultChain` must be included in `supportedChains`");return{chains:a,defaultChain:l}}(t?.additionalChains,t?.supportedChains,t?.defaultChain);a&&a.length>5&&console.warn("Max number of social logins allowed is 5. Any more have been removed.");let R=t?.customAuth?.getCustomAccessToken&&t?.customAuth?.enabled!==!1;return{id:e.id,name:e.name,allowlistConfig:e.allowlistConfig,appearance:{logo:t?.appearance?.logo??e.logoUrl,palette:function({backgroundTheme:e,accentHex:t,successHex:i="#51BA81",warnHex:a="#FFB74D",errorHex:s="#EC6351",whiteHex:l=au,blackHex:u="#000000"}){var p;let f;switch(e){case"light":f=au;break;case"dark":f="#1E1E1D";break;default:f=e}let w=(0,eL.Z)(f),y=(0,eL.Z)(t),C=(0,eL.Z)(i),k=(0,eL.Z)(a),A=(0,eL.Z)(s),T=((p=w.getLuminance())<.8&&p>.2&&console.warn("Background color is not light or dark enough, which could lead to accessibility issues."),p>.5?"light":"dark"),I=po(w,"light"===T?-.04:.11),L=po(w,"light"===T?-.88:.87),R=po(w,"light"===T?-.77:.75),W=po(w,"light"===T?-.43:.45).desaturate("light"===T?60:20),F=po(w,"light"===T?-.08:.25).desaturate("light"===T?60:20),z=po(y,.15),G=po(y,-.06),q=(0,eL.Z)(y.getLuminance()>.5?u:l),K=po(C,-.16);return{colorScheme:T,background:w.toHslString(),background2:I.toHslString(),foreground:L.toHslString(),foreground2:R.toHslString(),foreground3:W.toHslString(),foreground4:F.toHslString(),accent:y.toHslString(),accentLight:z.toHslString(),accentDark:G.toHslString(),foregroundAccent:q.toHslString(),success:C.toHslString(),successDark:K.toHslString(),error:A.toHslString(),warn:k.toHslString()}}({backgroundTheme:t?.appearance?.theme??am.appearance.theme,accentHex:t?.appearance?.accentColor??e.accentColor??am.appearance.accentColor}),showWalletLoginFirst:t?.appearance?.showWalletLoginFirst??e.showWalletLoginFirst},loginMethods:{wallet:p,email:l,sms:u,google:f,twitter:w,discord:y,github:A,tiktok:C,linkedin:k,apple:T},legal:{termsAndConditionsUrl:t?.legal?.termsAndConditionsUrl??e.termsAndConditionsUrl,privacyPolicyUrl:t?.legal?.privacyPolicyUrl??e.privacyPolicyUrl},walletConnectCloudProjectId:t?.walletConnectCloudProjectId??e.walletConnectCloudProjectId??am.walletConnectCloudProjectId,rpcConfig:t?.rpcConfig??am.rpcConfig,chains:I,defaultChain:L,captchaEnabled:e.captchaEnabled??am.captchaEnabled,embeddedWallets:{...e.embeddedWalletConfig,...R?{createOnLogin:"all-users",requireUserPasswordOnCreate:!1,noPromptOnSignature:!0}:{},...t?.embeddedWallets},customAuth:R?{enabled:!0,...t.customAuth}:void 0,fiatOnRamp:{enabled:e.fiatOnRampEnabled,useSandbox:t?.fiatOnRamp?.useSandbox??am.fiatOnRamp.useSandbox},loginConfig:{twitterOAuthOnMobileEnabled:e.twitterOAuthOnMobileEnabled??!1},render:{inDialog:t?._render?.inDialog??am._render.inDialog,inParentNodeId:t?._render?.inParentNodeId??am._render.inParentNodeId}}}var af=class{constructor(){this.callbacks={}}enqueue(e,t){this.callbacks[e]=t}dequeue(e,t){let i=this.callbacks[t];if(!i)throw Error(`cannot dequeue ${e} event: no event found for id ${t}`);switch(delete this.callbacks[t],e){case"privy:iframe:ready":case"privy:wallet:create":case"privy:wallet:connect":case"privy:wallet:recover":case"privy:wallet:rpc":case"privy:wallet:set-recovery-password":return i;default:throw Error(`invalid wallet event type ${e}`)}}},aw=(aC=0,()=>`id-${aC++}`);function dr(e){return void 0!==e.error}var ax=new af,ay=new Map,wv=(e,t)=>"bigint"==typeof t?t.toString():t,Cv=(e,t)=>`${e}${JSON.stringify(t,wv)}`;function pr(e,t,i){let a=i.contentWindow;if(!a)throw Error("iframe not initialized");let s=Cv(e,t);if("privy:wallet:create"===e){let e=ay.get(s);if(e)return e}let l=new Promise((i,s)=>{let l=aw();ax.enqueue(l,{resolve:i,reject:s}),a.postMessage({id:l,event:e,data:t},"*")}).finally(()=>{ay.delete(s)});return ay.set(s,l),l}function ru(e){let t=(0,u.useRef)(null);return(0,u.useEffect)(()=>{let i=t.current;if(!i)return;function r(t){var i;t&&t.origin===e.origin&&"string"==typeof(i=t.data).event&&/^privy:.+/.test(i.event)&&function(e){switch(e.event){case"privy:iframe:ready":let t=ax.dequeue(e.event,e.id);return dr(e)?t.reject(new rW(e.error.type,e.error.message)):t.resolve(e.data);case"privy:wallet:create":let i=ax.dequeue(e.event,e.id);return dr(e)?i.reject(new rW(e.error.type,e.error.message)):i.resolve(e.data);case"privy:wallet:connect":let a=ax.dequeue(e.event,e.id);return dr(e)?a.reject(new rW(e.error.type,e.error.message)):a.resolve(e.data);case"privy:wallet:recover":let s=ax.dequeue(e.event,e.id);return dr(e)?s.reject(new rW(e.error.type,e.error.message)):s.resolve(e.data);case"privy:wallet:rpc":let l=ax.dequeue(e.event,e.id);return dr(e)?l.reject(new rW(e.error.type,e.error.message)):l.resolve(e.data);case"privy:wallet:set-recovery-password":let u=ax.dequeue(e.event,e.id);return dr(e)?u.reject(new rW(e.error.type,e.error.message)):u.resolve(e.data);default:console.warn("Unsupported wallet proxy method:",e)}}(t.data)}let a={create:e=>pr("privy:wallet:create",e,i),connect:e=>pr("privy:wallet:connect",e,i),recover:e=>pr("privy:wallet:recover",e,i),rpc:e=>pr("privy:wallet:rpc",e,i),setRecoveryPassword:e=>pr("privy:wallet:set-recovery-password",e,i)};window.addEventListener("message",r);let s=new AbortController;return js(()=>pr("privy:iframe:ready",{},i),{abortSignal:s.signal}).then(()=>e.onLoad(a),(...t)=>{console.warn("Privy iframe failed to load: ",...t),e.onLoadFailed()}),()=>{window.removeEventListener("message",r),s.abort()}},[t.current]),(0,k.jsx)("iframe",{ref:t,width:"0",height:"0",style:{display:"none",height:"0px",width:"0px"},src:an(e.origin,`/apps/${e.appId}/embedded-wallets`)})}var av={login:{onComplete:[],onError:[]},logout:{onSuccess:[]},connectWallet:{onSuccess:[],onError:[]},createWallet:{onSuccess:[],onError:[]}},ab=(0,u.createContext)(void 0);function se(e,t,i,...a){for(let s of e.current[t][i])s(...a)}function At(){return aj?aj.getAccessToken():Promise.resolve(e8.get(eJ)||null)}var aC,aj,ak,a_,aE,Xs=(e,t)=>ak(e,t),el=(e,t)=>a_(e,t),tl=()=>aE(),Rv=()=>{let e=new URLSearchParams(window.location.search).get("privy_token");if(!e)return;e8.put(e1,e);let t=new URL(window.location.href);t.searchParams.delete("privy_token"),window.history.pushState({},"",t)},Wv=({config:e,...t})=>{var i;if(!("string"==typeof(i=t.appId)&&25===i.length))throw new eM("Cannot initialize the Privy provider with an invalid Privy app ID");aj||(aj=new tW({appId:t.appId,apiUrl:t.apiUrl||eY}));let a=Object.assign({},e);return void 0!==t.createPrivyWalletOnLogin&&a.embeddedWallets?.createOnLogin===void 0&&(a.embeddedWallets||(a.embeddedWallets={}),a.embeddedWallets.createOnLogin=t.createPrivyWalletOnLogin?"users-without-wallets":"off"),void 0!==t.createPrivyWalletOnLogin&&e?.embeddedWallets?.createOnLogin&&console.warn("Both `createPrivyWalletOnLogin` and `config.embeddedWallets.createOnLogin` are set. `createPrivyWalletOnLogin` is deprecated and should be removed."),(0,k.jsx)(Iv,{...t,config:a,client:aj})},Iv=e=>{let t=e.client,[i,p]=(0,u.useState)(!1),[f,w]=(0,u.useState)(!1),[y,C]=(0,u.useState)(!1),[A,T]=(0,u.useState)(null),[I,L]=(0,u.useState)(!1),[R,W]=(0,u.useState)([]),F=(0,u.useRef)(R),[z,G]=(0,u.useState)(!1),[q,K]=(0,u.useState)(null),[J,Q]=(0,u.useState)(!1),[X,et]=(0,u.useState)({status:"disconnected",connectError:null,connector:null,connectRetry:x}),[er,ei]=(0,u.useState)(null),[en,ea]=(0,u.useState)(null),[eo,es]=(0,u.useState)({showWalletLoginFirst:!0,allowlistConfig:{errorTitle:null,errorDetail:null,errorCtaText:null,errorCtaLink:null},walletAuth:!0,emailAuth:!0,smsAuth:!1,googleOAuth:!1,twitterOAuth:!1,discordOAuth:!1,githubOAuth:!1,linkedinOAuth:!1,appleOAuth:!1,termsAndConditionsUrl:null,privacyPolicyUrl:null,embeddedWalletConfig:{createOnLogin:"off",requireUserPasswordOnCreate:!1},fiatOnRampEnabled:!1,captchaEnabled:!1}),[ec,eh]=(0,u.useState)(()=>{var i,a;let s=(i=e.config,a=e.createPrivyWalletOnLogin,i?.appearance?.logo&&"object"==typeof i.appearance.logo&&(i.appearance.logo="component"),{...i,legacyCreateEmbeddedWalletFlag:a});return t.createAnalyticsEvent("sdk_initialize",s),vi(eo,e.config)}),[eu,ep]=(0,u.useState)(!0),[em,ef]=(0,u.useState)({}),[eg,ew]=(0,u.useState)(null),[ex,ey]=(0,u.useState)(null),[eb,eC]=(0,u.useState)(!1),[ej,ek]=(0,u.useState)(),[e_,eE]=(0,u.useState)(),[eA,eP]=(0,u.useState)(),[eS,eT]=(0,u.useState)(!1),eN=(0,u.useRef)(av),Se=e=>{e&&K(e),p(!0),t.createAnalyticsEvent("modal_open",{initialScreen:e})},Vr=e=>{"off"!==ec.embeddedWallets.createOnLogin&&ep(!0),Se(e)};(0,u.useEffect)(()=>{if(!en||!A){t.connectors?.removeEmbeddedWalletConnector();return}let e=A?.linkedAccounts.filter(e=>"wallet"===e.type&&"privy"===e.walletClient);if(e&&e.length>0){let i=e[0].address;t.connectors?.addEmbeddedWalletConnector(en,i,ec.defaultChain)}},[en,A]),(0,u.useEffect)(()=>{en&&ex?.(en)},[en]),(0,u.useEffect)(()=>{(async()=>{if(!ec.customAuth?.enabled)return;ep(!0);let{getCustomAccessToken:e,isLoading:i}=ec.customAuth;if(!(!f||i))try{let i=await e();if(!i){await eI.logout();return}if(y)return;t.startAuthFlow(new e$(i));let{user:a,isNewUser:s}=await t.authenticate();a||await eI.logout(),T(a||null),G(s||!1),C(!0),eT(!0)}catch(e){console.warn(e),y&&await eI.logout()}})()},[ec.customAuth?.enabled,ec.customAuth?.getCustomAccessToken,ec.customAuth?.isLoading,f,y]),(0,u.useEffect)(()=>{eS&&en&&A&&zt(A,e.config?.embeddedWallets?.createOnLogin)&&(eT(!1),ls(A,3e4).catch(console.error))},[eS&&en&&A]),(0,u.useEffect)(()=>{async function d(){let i=await t.getServerConfig();es(i);let a=vi(i,e.config);eh(a),i.customApiUrl&&t.updateApiUrl(i.customApiUrl),t.initializeConnectorManager(a.walletConnectCloudProjectId,a.rpcConfig,a.chains,a.defaultChain),t.connectors?.initialize();let s=du();Rv();let l=await t.getAuthenticatedUser();e.config?.customAuth?.enabled||(C(!!l),l&&se(eN,"login","onComplete",l,!1,!0),T(l)),s||(w(!0),eg?.()),s&&l&&L(!0),pu()}f||d()},[t,eg,f]),(0,u.useEffect)(()=>{eh(vi(eo,e.config))},[e.config]);let du=()=>{let e=new URLSearchParams(window.location.search),i=e.get("privy_oauth_code"),a=e.get("privy_oauth_state"),s=e.get("privy_oauth_provider");return!!i&&!!a&&!!s&&(t.startAuthFlow(new eH(s,i,a)),Vr("AWAITING_OAUTH_SCREEN"),ef({finishOauthFlow:{onComplete:()=>{w(!0),eg?.()}}}),!0)},Ei=async(e,i,a)=>{is(await t.connectors?.createWalletConnector(e,i)||null,a)};async function is(e,t){if(!e)return et({status:"disconnected",connectError:new eD("Unable to connect to wallet."),connector:null,connectRetry:x}),t?.(null);et({connector:e,status:"connecting",connectError:null,connectRetry:()=>is(e,t)});try{let i=await e.connect({showPrompt:!0});if(!ec.chains.find(e=>e.id===Number(i?.chainId))){et(t=>({...t,connector:e,status:"switching_to_supported_chain",connectError:null,connectRetry:x}));try{await i?.switchChain(ec.defaultChain.id)}catch{console.warn(`Unable to switch to default chain: ${ec.defaultChain.id}`)}}return et(e=>({...e,status:"connected",connectError:null,connectRetry:x})),i&&!J&&se(eN,"connectWallet","onSuccess",i),t?.(i)}catch(e){return e instanceof eR?(console.warn(e.cause?e.cause:e.message),J||se(eN,"connectWallet","onError",e.privyErrorCode||"generic_connect_wallet_error")):(console.warn(e),J||se(eN,"connectWallet","onError","unknown_connect_wallet_error")),et(t=>({...t,status:"disconnected",connectError:e})),t?.(null)}}let xi=e=>{null!==e&&t.startAuthFlow(new eq(e))},pu=()=>{let e=new URLSearchParams(window.location.search),i=e.get("privy_connector"),a=e.get("privy_wallet_client");if(!i||!a)return;if("phantom"!==a||je()||Vr("LOGIN_FAILED_SCREEN"),!t.connectors)throw new eM("Connector not initialized");Se("AWAITING_CONNECTION");let s=new URL(window.location.href);s.searchParams.delete("privy_connector"),s.searchParams.delete("privy_wallet_client"),window.history.pushState({},"",s),Ei(i,a,xi)};(0,u.useEffect)(()=>{f&&y&&null===A&&t.getAuthenticatedUser().then(T)},[f,y,A,t]);let as=()=>{L(!0),Se("LINK_WALLET_SCREEN")},uu=e=>{if(!y||!A)return!1;for(let t of A.linkedAccounts)if("wallet"===t.type&&t.address===e.address)return!0;return!1},mu=async e=>{if(!t.connectors)throw new eM("Connector not initialized");let i=t.connectors.findWalletConnector(e.connectorType,e.walletClientType)||null;et(e=>({...e,connector:i,status:"connected",connectError:null,connectRetry:x})),xi(e),Vr("AWAITING_CONNECTION")},hu=async(e,i)=>{if(!t.connectors)throw new eM("Connector not initialized");await Ei(e,i,xi)},ss=async(e,i)=>{if(!ec.fiatOnRamp.enabled)throw new eM("Fiat on-ramp is not enabled");if(i&&i.provider&&"moonpay"!==i.provider)throw new eM("Unsupported fund provider. Currently supported option is `moonpay`.");{let{signedUrl:a,externalTransactionId:s}=await qc(t,e,i?.config??{},ec.appearance.palette,ec.fiatOnRamp.useSandbox);return{signedUrl:a,externalTransactionId:s}}},qr=()=>{W(e=>{let i=t.connectors?.wallets.map(e=>({...e,linked:uu(e),loginOrLink:async()=>{if(!await e.isConnected())throw new eM("Wallet is not connected");if("embedded"===e.connectorType&&"privy"===e.walletClientType)throw new eM("Cannot link or login with embedded wallet");mu(e)},fund:async t=>{let{signedUrl:i,externalTransactionId:a}=await ss(e.address,t);ef({fiatOnRampPrompt:{signedUrl:i},fiatOnRampStatus:{externalTransactionId:a}}),Se("FIAT_ON_RAMP_PROMPT_SCREEN")},unlink:async()=>{if(!y)throw new eM("User is not authenticated.");if("embedded"===e.connectorType&&"privy"===e.walletClientType)throw new eM("Cannot unlink an embedded wallet");T(await t.unlinkWallet(e.address))}}))||[];return cn(e,i)?e:i})};(0,u.useEffect)(()=>{qr()},[A?.linkedAccounts,y,f]),(0,u.useEffect)(()=>{if(f){if(!t.connectors)throw new eM("Connector not initialized");qr(),t.connectors.on("walletsUpdated",qr)}},[f]),(0,u.useEffect)(()=>{if(!R[0])return;let e=R[0],t=F.current.find(t=>t.address===e.address),i=A?.linkedAccounts.find(t=>"wallet"===t.type&&t.address===e.address);if(!t&&i){let e=Object.assign({},A);e.wallet=i&&{address:i.address,chainType:i.chainType,chainId:i.chainId,walletClient:i.walletClient,walletClientType:i.walletClientType,connectorType:i.connectorType},T(e)}F.current=R},[R]);let ls=async(t,i)=>{if(Z(t))throw se(eN,"createWallet","onError","embedded_wallet_already_exists"),Error("Only one Privy wallet per user is currently allowed");let[a,s]=await Promise.all([eO.initializeWalletProxy(i),At()]);if(!a&&e.config?.customAuth?.enabled)throw se(eN,"createWallet","onError","unknown_embedded_wallet_error"),Error("Failed to connect to wallet proxy");if(!a||!s||e.config?.embeddedWallets?.requireUserPasswordOnCreate)return new Promise((e,t)=>{ep(!0),ef({createWallet:{onSuccess:t=>{se(eN,"createWallet","onSuccess",t),e(t)},onFailure:e=>{se(eN,"createWallet","onError","unknown_embedded_wallet_error"),t(e)},callAuthOnSuccessOnClose:!1}}),Se("EMBEDDED_WALLET_ON_ACCOUNT_CREATE_SCREEN")});{await a.create({accessToken:s});let e=Z(await eO.refreshUser());if(!e)throw se(eN,"createWallet","onError","unknown_embedded_wallet_error"),Error("Failed to create wallet");return se(eN,"createWallet","onSuccess",e),e}},yu=e=>{if(!ec.chains.map(e=>e.id).includes(e))throw new eD(`Chain ID ${e} is not supported. It must be added to the config.supportedChains property of the PrivyProvider.`,"unsupported_chain_id")},eI={ready:f,authenticated:y,user:A,walletConnectors:t.connectors||null,connectWallet:()=>{Se(y?"CONNECT_ONLY_AUTHENTICATED_SCREEN":"CONNECT_ONLY_LANDING_SCREEN")},linkWallet:as,linkEmail:()=>{if(A?.email)throw new eM("User already has an email linked to their account.");L(!0),Se("LINK_EMAIL_SCREEN")},linkPhone:()=>{if(A?.phone)throw new eM("User already has a phone number linked to their account.");L(!0),Se("LINK_PHONE_SCREEN")},linkGoogle:async()=>{if(A?.google)throw new eM("User already has a Google account linked to their account.");await eO.initLoginWithOAuth("google")},linkTwitter:async()=>{if(A?.twitter)throw new eM("User already has a Twitter account linked to their account.");await eO.initLoginWithOAuth("twitter")},linkDiscord:async()=>{if(A?.discord)throw new eM("User already has a Discord account linked to their account.");await eO.initLoginWithOAuth("discord")},linkGithub:async()=>{if(A?.github)throw new eM("User already has a Github account linked to their account.");await eO.initLoginWithOAuth("github")},linkTiktok:async()=>{if(A?.tiktok)throw new eM("User already has a Tiktok account linked to their account.");await eO.initLoginWithOAuth("tiktok")},linkLinkedIn:async()=>{if(A?.linkedin)throw new eM("User already has a LinkedIn account linked to their account.");await eO.initLoginWithOAuth("linkedin")},linkApple:async()=>{await eO.initLoginWithOAuth("apple")},login:async()=>{if(f||(await new Promise(e=>{ew(()=>e)}),ew(null)),y){console.warn("Attempted to log in, but user is already logged in. Use a `link` helper instead.");return}Q(!0),Vr()},logout:async()=>{await t.logout(),T(null),C(!1),K(null),se(eN,"logout","onSuccess"),L(!1),p(!1),e8.del(e2)},getAccessToken:()=>t.getAccessToken(),getEthereumProvider:()=>{if(!A||!A.wallet)return new tu;let e=R.find(e=>A.wallet&&e.address===A.wallet.address),i=t.connectors?.walletConnectors.find(t=>t.wallets.find(t=>t.address===e?.address));return e&&i?i.proxyProvider:new tu},getEthersProvider:()=>{if(!A||!A.wallet)return new s.Q(new tf(new tu));let e=R.find(e=>A.wallet&&e.address===A.wallet.address),i=t.connectors?.walletConnectors.find(t=>t.wallets.find(t=>t.address===e?.address));return new s.Q(new tf(e&&i?i.proxyProvider:new tu))},getWeb3jsProvider:()=>{if(!A||!A.wallet)return new tg(new tu);let e=R.find(e=>A.wallet&&e.address===A.wallet.address),i=t.connectors?.walletConnectors.find(t=>t.wallets.find(t=>t.address===e?.address));return new tg(e&&i?i.proxyProvider:new tu)},unlinkWallet:async e=>{let i=await t.unlinkWallet(e);return T(i),i},unlinkEmail:async e=>{let i=await t.unlinkEmail(e);return T(i),i},unlinkPhone:async e=>{let i=await t.unlinkPhone(e);return T(i),i},unlinkGoogle:async e=>{let i=await t.unlinkOAuth("google",e);return T(i),i},unlinkTwitter:async e=>{let i=await t.unlinkOAuth("twitter",e);return T(i),i},unlinkDiscord:async e=>{let i=await t.unlinkOAuth("discord",e);return T(i),i},unlinkGithub:async e=>{let i=await t.unlinkOAuth("github",e);return T(i),i},unlinkTiktok:async e=>{let i=await t.unlinkOAuth("tiktok",e);return T(i),i},unlinkLinkedIn:async e=>{let i=await t.unlinkOAuth("linkedin",e);return T(i),i},unlinkApple:async e=>{let i=await t.unlinkOAuth("apple",e);return T(i),i},setActiveWallet:async e=>{let t=R.find(t=>(0,a.Kn)(t.address)===(0,a.Kn)(e)),i=A?.linkedAccounts.find(t=>"wallet"===t.type&&a.Kn(t.address)===a.Kn(e));if(t&&await t.isConnected()){if(t.linked){let e=Object.assign({},A);e.wallet=i&&{address:i.address,chainType:i.chainType,chainId:i.chainId,walletClient:i.walletClient,walletClientType:i.walletClientType,connectorType:i.connectorType},T(e)}else t.loginOrLink()}else ei(e),as()},forkSession:()=>t.forkSession(),createWallet:async()=>{if(!y||!A)throw se(eN,"createWallet","onError","must_be_authenticated"),Error("User must be authenticated before creating a Privy wallet");return ls(A,15e3)},setWalletPassword:()=>new Promise((e,t)=>{if(!y||!A){t(Error("User must be authenticated before adding password to Privy wallet"));return}let i=Z(A);if(!i||!en){t(Error("Must have a Privy wallet to add a password"));return}if("user-passcode"===i.recoveryMethod){t(Error("Cannot set password. Embedded wallet already has a password."));return}ep(!0),ef({setWalletPassword:{onSuccess:e,onFailure:t,callAuthOnSuccessOnClose:!1},connectWallet:{onCompleteNavigateTo:"EMBEDDED_WALLET_PASSWORD_UPDATE_SPLASH_SCREEN",onFailure:t}}),Se("EMBEDDED_WALLET_CONNECTING_SCREEN")}),signMessage:(e,i)=>new Promise(async(a,s)=>{if(!y||!A){s(Error("User must be authenticated before signing with a Privy wallet"));return}let l=Z(A);if(!l){s(Error("Must have a Privy wallet before signing"));return}if("string"!=typeof e||e.length<1){s(Error("Message must be a non-empty string"));return}ep(!0);let me=async()=>{if(!y)return s(Error("User must be authenticated before signing with a Privy wallet")),null;let i=await At();if(!en||!i)return null;try{if(!await eO.recoverEmbeddedWallet())return s(Error("Unable to connect to wallet")),null;t.createAnalyticsEvent("embedded_wallet_sign_message_started",{walletAddress:l.address});let{response:a}=await en.rpc({accessToken:i,address:l.address,request:{method:"personal_sign",params:[e,l.address]}}),u=a.data;return t.createAnalyticsEvent("embedded_wallet_sign_message_completed",{walletAddress:l.address}),u}catch(e){return s(e),null}};if(ec.embeddedWallets.noPromptOnSignature){i&&console.warn("uiOptions defined with `noPromptOnSignature` set to true in app config");let e=await me();e?a(e):s(new ts("Unable to sign message"))}else ef({signMessage:{message:e,confirmAndSignMessage:me,onSuccess:e=>{a(e)},onFailure:e=>{s(e)},uiOptions:i||{}},connectWallet:{onCompleteNavigateTo:"EMBEDDED_WALLET_SIGN_REQUEST_SCREEN",onFailure:s}}),Se("EMBEDDED_WALLET_CONNECTING_SCREEN")}),sendTransaction:(e,i,a)=>new Promise(async(s,u)=>{if(!y||!A){u(Error("User must be authenticated before signing with a Privy wallet"));return}let p=Z(A);if(!p){u(Error("Must have a Privy wallet before signing"));return}ep(!0);let f=t.connectors?.findWalletConnector("embedded","privy")?.proxyProvider,w=e.chainId||f.chainId;yu(w);let C=Object.assign({},e,{chainId:w}),hr=async()=>{let e=await At();if(!e||!en){u(Error("Must have valid access token and Privy wallet to send transaction"));return}try{if(!await eO.recoverEmbeddedWallet()){u(Error("Unable to connect to wallet"));return}let t=new l.c(tt(C.chainId,ec.chains,ec.rpcConfig)),i=await di(p.address,C,t),a=await pi(e,p.address,en,i,t);s(a)}catch(e){u(e)}};ec.embeddedWallets.noPromptOnSignature?(i&&console.warn("uiOptions defined with `noPromptOnSignature` set to true in app config"),hr()):(ef({connectWallet:{onCompleteNavigateTo:"EMBEDDED_WALLET_SEND_TRANSACTION_SCREEN",onFailure:u},sendTransaction:{transactionRequest:C,onSuccess:s,onFailure:u,uiOptions:i||{},fundWalletConfig:a}}),Se("EMBEDDED_WALLET_CONNECTING_SCREEN"))}),exportWallet:()=>new Promise((i,a)=>{if(!y||!A){a(Error("User must be authenticated before exporting their Privy wallet"));return}if(!Z(A)){a(Error("Must have a Privy wallet before exporting"));return}ep(!0),ef({keyExport:{appId:e.appId,origin:t.apiUrl,onSuccess:i,onFailure:a},connectWallet:{onCompleteNavigateTo:"EMBEDDED_WALLET_KEY_EXPORT_SCREEN",onFailure:a}}),Se("EMBEDDED_WALLET_CONNECTING_SCREEN")})};ak=eI.signMessage,a_=eI.sendTransaction;let eO={isNewUserThisSession:z,isLinking:I,linkingHint:er,walletConnectionStatus:X,rpcConfig:ec.rpcConfig,chains:ec.chains,nativeTokenSymbolForChainId:e=>ec.chains.find(t=>t.id===Number(e))?.nativeCurrency.symbol,captchaData:{ready:eb,enabled:ec.captchaEnabled,execute:()=>{let e=window.turnstile;if(!e)return;let t=e.render("#cf-turnstile",{sitekey:"0x4AAAAAAAJFhr_rDU7HKpyw",action:ec.id,callback:ek,"error-callback":eE,"expired-callback":()=>{try{e.reset(eA),eE(void 0),ek(void 0)}catch{eE("expired_and_failed_reset")}},"unsupported-callback":()=>{console.warn("Browser does not support Turnstile.")}});t||console.warn("Failed to render challenge."),eP(t)},remove:()=>{let e=window.turnstile;e?.remove&&eA&&(e.remove(eA),eP(void 0),eE(void 0),ek(void 0))},token:ej,error:e_},initializeWalletProxy:async e=>{if(en)return en;let t=new Promise(e=>{ey(()=>t=>e(t))}),i=new Promise(t=>setTimeout(()=>t(null),e)),a=await Promise.race([t,i]);return ey(null),a},getAuthFlow:()=>t.authFlow,getAuthMeta:()=>t.authFlow?.meta,closePrivyModal:(i={shouldCallAuthOnSuccess:!0})=>{let a=f&&y&&A;i.shouldCallAuthOnSuccess&&a?(se(eN,"login","onComplete",A,z,!1),e.onSuccess?.(A,z)):J&&se(eN,"login","onError","exited_auth_flow"),t.authFlow=void 0,ei(null),K(null),Q(!1),L(!1),G(!1),p(!1),t.createAnalyticsEvent("modal_closed")},connectWallet:Ei,initLoginWithWallet:hu,loginWithWallet:async()=>{let e,i;if(!f)throw new eF;if(!(t.authFlow instanceof eq))throw new eM("Must initialize SIWE flow first.");if(y)e=await t.link();else try{({user:e,isNewUser:i}=await t.authenticate())}catch(e){throw se(eN,"login","onError",e.privyErrorCode||"generic_connect_wallet_error"),e}T(e||A||null),G(i||!1),C(!0)},initLoginWithOAuth:async e=>{t.startAuthFlow(new eH(e));let i=await t.authFlow.getAuthorizationUrl();i&&i.url&&window.location.assign(i.url)},loginWithOAuth:async()=>{let e,i;if(!(t.authFlow instanceof eH))throw new eM("Must initialize OAuth flow before calling loginWithOAuth");if(y)e=await t.link();else try{({user:e,isNewUser:i}=await t.authenticate())}catch(e){throw se(eN,"login","onError",e.privyErrorCode||"unknown_auth_error"),e}T(e),G(i||!1),C(!0)},initLoginWithEmail:async(e,i)=>{let a=new eB(e,i);t.startAuthFlow(a);try{await a.sendCodeEmail()}catch(e){throw se(eN,"login","onError",e.privyErrorCode||"unknown_auth_error"),e}},initLoginWithSms:async(e,i)=>{let a=new eV(e,i);t.startAuthFlow(a);try{await a.sendSmsCode()}catch(e){throw se(eN,"login","onError",e.privyErrorCode||"unknown_auth_error"),e}},resendEmailCode:async()=>{await t.authFlow?.sendCodeEmail()},resendSmsCode:async()=>{await t.authFlow?.sendSmsCode()},loginWithCode:async e=>{let i,a;if(!f)throw new eF;if(t.authFlow instanceof eB)t.authFlow.meta.emailCode=e.trim();else if(t.authFlow instanceof eV)t.authFlow.meta.smsCode=e.trim();else throw new eM("Must initialize a passwordless code flow first");y?i=await t.link():{user:i,isNewUser:a}=await t.authenticate(),T(i||A||null),G(a||!1),C(!0)},refreshUser:async()=>{let e=await t.getAuthenticatedUser();return T(e),e},walletProxy:en,createAnalyticsEvent:(e,i,a)=>t.createAnalyticsEvent(e,i,a),getUsdTokenPrice:e=>t.getUsdTokenPrice(e),recoverEmbeddedWallet:async()=>new Promise(async(e,i)=>{let a=A?.linkedAccounts.find(e=>"wallet"===e.type&&"privy"===e.walletClientType),s=await At();if(!s||!en||!a){i(Error("Must have valid access token and Privy wallet to recover wallet"));return}ep(!0);try{await en.connect({accessToken:s,address:a.address}),e(!0)}catch(l){Jo(l)&&"privy"===a.recoveryMethod?(t.createAnalyticsEvent("embedded_wallet_pinless_recovery_started",{walletAddress:a.address}),(await en.recover({address:a.address,accessToken:s})).address||i(Error("Unable to recover wallet")),t.createAnalyticsEvent("embedded_wallet_recovery_completed",{walletAddress:a.address}),e(!0)):Jo(l)?(ef({recoverWallet:{privyWallet:a,onFailure:i,onSuccess:()=>e(!0)}}),Se("EMBEDDED_WALLET_RECOVERY_SCREEN")):i(l)}}),getFiatOnRampConfig:ss,updateWallets:()=>qr()};aE=eO.recoverEmbeddedWallet;let eL=(0,u.useMemo)(()=>({wallets:R}),[R]);return(0,k.jsx)(tU.Provider,{value:eI,children:(0,k.jsx)(ab.Provider,{value:eN,children:(0,k.jsxs)(nG.Provider,{value:eL,children:[e.children,(0,k.jsxs)(tM.Provider,{value:eO,children:[(0,k.jsx)(n8,{theme:{...ec.appearance.palette||{}}}),(0,k.jsx)(ll,{appConfig:ec,data:em,setModalData:ef,setInitialScreen:K,initialScreen:q,visible:i,authenticated:y,children:i?(0,k.jsx)(Mp,{}):null}),eu&&eo.id?(0,k.jsx)(ru,{appId:e.appId,origin:t.apiUrl,onLoad:ea,onLoadFailed:()=>null}):null]}),ec.captchaEnabled&&(0,k.jsx)(Dp,{onLoad:()=>eC(!0)})]})})})}}}]); \ No newline at end of file diff --git a/_next/static/chunks/45.f7592c692bffbb36.js b/_next/static/chunks/45.f7592c692bffbb36.js new file mode 100644 index 0000000..33b057a --- /dev/null +++ b/_next/static/chunks/45.f7592c692bffbb36.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[45],{50045:function(A,e,t){let r,C;function read_compressed_payload(A){var e;let t;return e=function(A){let e=0;function u16(){return A[e++]<<8|A[e++]}let t=u16(),r=1,C=[0,1];for(let A=1;A>--l&1}let w=2147483648-1,n=0;for(let A=0;A<31;A++)n=n<<1|read_bit();let a=[],c=0,s=2147483648;for(;;){let A=Math.floor(((n-c+1)*r-1)/s),e=0,g=t;for(;g-e>1;){let t=e+g>>>1;A>>1|read_bit(),o=o<<1^1073741824,l=(1073741824^l)<<1|1073741825;c=o,s=1+l-o}let f=t-4;return a.map(e=>{switch(e-f){case 3:return f+65792+(A[o++]<<16|A[o++]<<8|A[o++]);case 2:return f+256+(A[o++]<<8|A[o++]);case 1:return f+A[o++];default:return e-1}})}(function(A){let e=[];[..."ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"].forEach((A,t)=>e[A.charCodeAt(0)]=t);let t=A.length,r=new Uint8Array(6*t>>3);for(let C=0,g=0,o=0,l=0;C=8&&(r[g++]=l>>(o-=8));return r}(A)),t=0,()=>e[t++]}function read_sorted(A,e=0){let t=[];for(;;){let r=A(),C=A();if(!C)break;e+=r;for(let A=0;A{let e=read_sorted(A);if(e.length)return e})}function read_mapped(A){let e=[];for(;;){let t=A();if(0==t)break;e.push(function(A,e){let t=1+e(),r=e(),C=read_array_while(e);return read_transposed(C.length,1+A,e).flatMap((A,e)=>{let[g,...o]=A;return Array(C[e]).fill().map((A,e)=>{let C=e*r;return[g+e*t,o.map(A=>A+C)]})})}(t,A))}for(;;){let t=A()-1;if(t<0)break;e.push(read_transposed(1+A(),1+t,A).map(A=>[A[0],A.slice(1)]))}return e.flat()}function read_array_while(A){let e=[];for(;;){let t=A(e.length);if(!t)break;e.push(t)}return e}function read_transposed(A,e,t){let r=Array(A).fill().map(()=>[]);for(let C=0;C>1:r>>1}return t})(A,t).forEach((A,e)=>r[e].push(A));return r}t.d(e,{normalize:function(){return normalize}});var g=read_compressed_payload("AEITLAk1DSsBxwKEAQMBOQDpATAAngDUAHsAoABoAM4AagCNAEQAhABMAHIAOwA9ACsANgAmAGIAHgAvACgAJwAXAC0AGgAjAB8ALwAUACkAEgAeAAkAGwARABkAFgA5ACgALQArADcAFQApABAAHgAiABAAGAAeABMAFwAXBOcF2QEXE943ygXaALgArkYBbgCsCAPMAK6GNjY2NgE/rgwQ8gAEB0YG6zgFXgVfAD0yOQf2vRgFDc/IABUDz546AswKNgKOqAKG3z+Vb5ACxdICg/kBJuYQAPK0AUgCNJQKRpYA6gDpChwAHtvAzxMSRKQEIn4BBAJAGMQP8hAGMPAMBIhuDSIHNACyAHCY76ychgBiBpoCKgbwACIAQgyaFwKqAspCINYIwjADuBRCAPc0cqoAqIQfAB4ELALeHQEkAMAZ1AUBECBTPgmeCY8lIlZgTOqDSQAaABMAHAAVclsAKAAVAE71HN89+gI5X8qc5jUKFyRfVAJfPfMAGgATABwAFXIgY0CeAMPyACIAQAzMFsKqAgHavwViBekC0KYCxLcCClMjpGwUehp0TPwAwhRuAugAEjQ0kBfQmAKBggETIgDEFG4C6AASNAFPUCyYTBEDLgIFLxDecB60Ad5KAHgyEn4COBYoAy4uwD5yAEDoAfwsAM4O0rwBImqIALgMAAwCAIraUAUi3HIeAKgu2AGoBgYGBgYrNAOiAG4BCiA+9Dd7BB8eALEBzgIoAgDmMhJ6OvpQtzOoLjVPBQAGAS4FYAVftr8FcDtkQhlBWEiee5pmZqH/EhoDzA4s+H4qBKpSAlpaAnwisi4BlqqsPGIDTB4EimgQANgCBrJGNioCBzACQGQAcgFoJngAiiQgAJwBUL4ALnAeAbbMAz40KEoEWgF2YAZsAmwA+FAeAzAIDABQSACyAABkAHoAMrwGDvr2IJSGBgAQKAAwALoiTgHYAeIOEjiXf4HvABEAGAA7AEQAPzp3gNrHEGYQYwgFTRBMc0EVEgKzD60L7BEcDNgq0tPfADSwB/IDWgfyA1oDWgfyB/IDWgfyA1oDWgNaA1ocEfAh2scQZg9PBHQFlQWSBN0IiiZQEYgHLwjZVBR0JRxOA0wBAyMsSSM7mjMSJUlME00KCAM2SWyufT8DTjGyVPyQqQPSMlY5cwgFHngSpwAxD3ojNbxOhXpOcacKUk+1tYZJaU5uAsU6rz//CigJmm/Cd1UGRBAeJ6gQ+gw2AbgBPg3wS9sE9AY+BMwfgBkcD9CVnwioLeAM8CbmLqSAXSP4KoYF8Ev3POALUFFrD1wLaAnmOmaBUQMkARAijgrgDTwIcBD2CsxuDegRSAc8A9hJnQCoBwQLFB04FbgmE2KvCww5egb+GvkLkiayEyx6/wXWGiQGUAEsGwIA0i7qhbNaNFwfT2IGBgsoI8oUq1AjDShAunhLGh4HGCWsApRDc0qKUTkeliH5PEANaS4WUX8H+DwIGVILhDyhRq5FERHVPpA9SyJMTC8EOIIsMieOCdIPiAy8fHUBXAkkCbQMdBM0ERo3yAg8BxwwlycnGAgkRphgnQT6ogP2E9QDDgVCCUQHFgO4HDATMRUsBRCBJ9oC9jbYLrYCklaDARoFzg8oH+IQU0fjDuwIngJoA4Yl7gAwFSQAGiKeCEZmAGKP21MILs4IympvI3cDahTqZBF2B5QOWgeqHDYVwhzkcMteDoYLKKayCV4BeAmcAWIE5ggMNV6MoyBEZ1aLWxieIGRBQl3/AjQMaBWiRMCHewKOD24SHgE4AXYHPA0EAnoR8BFuEJgI7oYHNbgz+zooBFIhhiAUCioDUmzRCyom/Az7bAGmEmUDDzRAd/FnrmC5JxgABxwyyEFjIfQLlU/QDJ8axBhFVDEZ5wfCA/Ya9iftQVoGAgOmBhY6UDPxBMALbAiOCUIATA6mGgfaGG0KdIzTATSOAbqcA1qUhgJykgY6Bw4Aag6KBXzoACACqgimAAgA0gNaADwCsAegABwAiEQBQAMqMgEk6AKSA5YINM4BmDIB9iwEHsYMGAD6Om5NAsO0AoBtZqUF4FsCkQJMOAFQKAQIUUpUA7J05ADeAE4GFuJKARiuTc4d5kYB4nIuAMoA/gAIOAcIRAHQAfZwALoBYgs0CaW2uAFQ7CwAhgAYbgHaAowA4AA4AIL0AVYAUAVc/AXWAlJMARQ0Gy5aZAG+AyIBNgEQAHwGzpCozAoiBHAH1gIQHhXkAu8xB7gEAyLiE9BCyAK94VgAMhkKOwqqCqlgXmM2CTR1PVMAER+rPso/UQVUO1Y7WztWO1s7VjtbO1Y7WztWO1sDmsLlwuUKb19IYe4MqQ3XRMs6TBPeYFRgNRPLLboUxBXRJVkZQBq/Jwgl51UMDwct1mYzCC80eBe/AEIpa4NEY4keMwpOHOpTlFT7LR4AtEulM7INrxsYREMFSnXwYi0WEQolAmSEAmJFXlCyAF43IwKh+gJomwJmDAKfhzgeDgJmPgJmKQRxBIIDfxYDfpU5CTl6GjmFOiYmAmwgAjI5OA0CbcoCbbHyjQI2akguAWoA4QDkAE0IB5sMkAEBDsUAELgCdzICdqVCAnlORgJ4vSBf3kWxRvYCfEICessCfQwCfPNIA0iAZicALhhJW0peGBpKzwLRBALQz0sqA4hSA4fpRMiRNQLypF0GAwOxS9FMMCgG0k1PTbICi0ICitvEHgogRmoIugKOOgKOX0OahAKO3AKOX3tRt1M4AA1S11SIApP+ApMPAOwAH1UhVbJV0wksHimYiTLkeGlFPjwCl6IC77VYJKsAXCgClpICln+fAKxZr1oMhFAAPgKWuAKWUVxHXNQCmc4CmWdczV0KHAKcnjnFOqACnBkCn54CnruNACASNC0SAp30Ap6VALhAYTdh8gKe1gKgcQGsAp6iIgKeUahjy2QqKC4CJ7ICJoECoP4CoE/aAqYyAqXRAqgCAIACp/Vof2i0AAZMah9q1AKs5gKssQKtagKtBQJXIAJV3wKx5NoDH1FsmgKywBACsusabONtZm1LYgMl0AK2Xz5CbpMDKUgCuGECuUoYArktenA5cOQCvRwDLbUDMhQCvotyBQMzdAK+HXMlc1ICw84CwwdzhXROOEh04wM8qgADPJ0DPcICxX8CxkoCxhOMAshsVALIRwLJUgLJMQJkoALd1Xh8ZHixeShL0wMYpmcFAmH3GfaVJ3sOXpVevhQCz24Cz28yTlbV9haiAMmwAs92ASztA04Vfk4IAtwqAtuNAtJSA1JfA1NiAQQDVY+AjEIDzhnwY0h4AoLRg5AC2soC2eGEE4RMpz8DhqgAMgNkEYZ0XPwAWALfaALeu3Z6AuIy7RcB8zMqAfSeAfLVigLr9gLpc3wCAur8AurnAPxKAbwC7owC65+WrZcGAu5CA4XjmHxw43GkAvMGAGwDjhmZlgL3FgORcQOSigL3mwL53AL4aZofmq6+OpshA52GAv79AR4APJ8fAJ+2AwWQA6ZtA6bcANTIAwZtoYuiCAwDDEwBEgEiB3AGZLxqCAC+BG7CFI4ethAAGng8ACYDNhJQA4yCAWYqJACM8gAkAOamCqKUCLoGIqbIBQCuBRjCBfAkREUEFn8Fbz5FRzJCKEK7X3gYX8MAlswFOQCQUyCbwDstYDkYutYONhjNGJDJ/QVeBV8FXgVfBWoFXwVeBV8FXgVfBV4FXwVeBV9NHAjejG4JCQkKa17wMgTQA7gGNsLCAMIErsIA7kcwFrkFTT5wPndCRkK9X3w+X+8AWBgzsgCNBcxyzAOm7kaBRC0qCzIdLj08fnTfccH4GckscAFy13U3HgVmBXHJyMm/CNZQYgcHBwqDXoSSxQA6P4gAChbYBuy0KgwAjMoSAwgUAOVsJEQrJlFCuELDSD8qXy5gPS4/KgnIRAUKSz9KPn8+iD53PngCkELDUElCX9JVVnFUETNyWzYCcQASdSZf5zpBIgluogppKjJDJC1CskLDMswIzANf0BUmNRAPEAMGAQYpfqTfcUE0UR7JssmzCWzI0tMKZ0FmD+wQqhgAk5QkTEIsG7BtQM4/Cjo/Sj53QkYcDhEkU05zYjM0Wui8GQqE9CQyQkYcZA9REBU6W0pJPgs7SpwzCogiNEJGG/wPWikqHzc4BwyPaPBlCnhk0GASYDQqdQZKYCBACSIlYLoNCXIXbFVgVBgIBQZk7mAcYJxghGC6YFJgmG8WHga8FdxcsLxhC0MdsgHCMtTICSYcByMKJQGAAnMBNjecWYcCAZEKv04hAOsqdJUR0RQErU3xAaICjqNWBUdmAP4ARBEHOx1egRKsEysmwbZOAFYTOwMAHBO+NVsC2RJLbBEiAN9VBnwEESVhADgAvQKhLgsWdrI5P6YgAWIBjQoDA+D0FgaxBlEGwAAky1ywYRC7aBOQCy1GDsIBwgEpCU4DYQUvLy8nJSYoMxktDSgTlABbAnVel1CcCHUmBA94TgHadRbVWCcgsLdN8QcYBVNmAP4ARBEHgQYNK3MRjhKsPzc0zrZdFBIAZsMSAGpKblAoIiLGADgAvQKhLi1CFdUClxiCAVDCWM90eY7epaIO/KAVRBvzEuASDQ8iAwHOCUEQmgwXMhM9EgBCALrVAQkAqwDoAJuRNgAbAGIbzTVzfTEUyAIXCUIrStroIyUSG4QCggTIEbHxcwA+QDQOrT8u1agjB8IQABBBLtUYIAB9suEjD8IhThzUqHclAUQqZiMC8qAPBFPz6x9sDMMNAQhDCkUABccLRAJSDcIIww1DCUMKwy7VqDEOwgyYCCIPkhroBCILwhZCAKcLQhDCCwUYp3vjADtyDEMAAq0JwwUi1/UMBQ110QaCAAfCEmIYEsMBCADxCAAAexViDRbSG/x2F8IYQgAuwgLyqMIAHsICXCcxhgABwgAC6hVDFcIr8qPCz6hCCgKlJ1IAAmIA5+QZwg+lYhW/ywD7GoIIqAUR/3cA38KnwhjiARrCo5J5eQcCqaKKABLCDRsSAAOaAG3CDQALwqdCCBpCAsEIqJzRDwIHx6lCBQDhgi+9bcUDTwAD8gAVwgAHAgAJwgBpkgAawgAOwgkYwo5wFgIAAWIADnIALlIlAAbCABfCCCgADVEAusItAAPCAA6iKvIAsmEAHCIAG8IAAfIKqAAFzQscFeIAB6IAQsIBCQBpwgALggAdwgAIwgmoAAXRAG6mGdwAmAgoAAXRAAFCAAfiAB2iCCgABqEACYIAGzIAbSIA5sKHAAhiAAhCABTCAwBpAgkoAAbRAOOSAAlCC6gOy/tmAAdCAG6jQE8ATgAKwgsAA0IACbQDPgAHIgAZggACEqcCAAoiAApCAAoCp/IGwgAJIgADEgAQQgcAFEIAEXIAD5IADfIADcIAGRINFiIAFUIAbqIWugHCAMEAE0IKAGkyEQDhUgACQgAEWQAXggUiAAbXABjCBCUBgi9ZAEBMALYPBxQMeQAvMXcBqwwIZQJzKhMGBBAOdlJzZjGQJgWHGwVpND0DqAq7BgjfAB0DAgp1AX15TlkbKANWAhxFATMGCnpNxIJZgUcAMAA4CAACAAAAWhHiAIKXMwEyAH3sFBg5TQhRAF4MAAhXAQ6R0wB/QgQnrABhAN0cAJxvPiaSANRyuADW2wEdD8l8eiIfXSQQ2AGPl7IpWlpUTxlDyZAAAACGIz5HMDLnGJ5WAHkBMCw3KUkgFgM3XAT+zPUAUmzjAHECeAJGEYE6zng1NdwCAQwXGSYLGw60tQIBAQEABQIEAgIAGdMCACwBAAUFBQUFBQQEBAQEBAMEBQYHCAMEBAQEAwEBIQCMAI8AlDwA6QC6ANsAo0MAwQCxAKwApwDtAKUA2QCiAOYBBwECAMYAgABhANEA0wECAN0A8QCPAKgBMADpAN4A2woACA4xOtnZ2dm7xeHS1dNINxwBUQFbNEwBWQFoAWcBWgFLUEhKbRIBUhoMDwo5PRINACYTKiwuMT0/P0JCQkNEE0UFI1ZWVlZYWFdYLllaXFtbImJmZmVnZilrbXV0d3d3d3d3eXl5eXl5eXl5eXl7e3x7emEAQ/EASACZAHcAMQBl9wCNAFYAVgA2AnXuAIoABPf3AGMAkvEAngBOAGEAY/7+rwCEAIQAaABVALAAIwC1AIICPwJCAPsA5gD9AP0A5wD+AOgA6ADnAOUALgJ6AVABPwE9AVMBPQE9AT0BOAE3ATcBNwEbAVcWADAPBwAAUh4RHQocHRUAjQCVAKUAUABpHwIwAHUAbgCWAxQDJjEDIEhFTjAAkAJOAMYCVgKjAL8ClQKVApUClQKVApUCigKVApUClQKVApUClQKUApQClwKfApYClQKVApMCkwKTApMCkQKUAnQB0wKWAp4ClQKVApQdgBIEAP0MA54CYAI5HgFTFzwC4RgRMhoBTT4aVJgBeqtDAWhgAQQDQE4BBQCYMB4flnEAMGcAcAA1AJADm8yS8LWLYQzBMhXJARgIpNx7MQsEKmFzAbkA5IWHhoWHhYiJiYWKjYuFjI+Nh46Jj4mQhZGFkoWTkZSFlYWWiZeFmIWZhZqFm4qcj52JnoUAiXMrc6cAinNzBEIEPwRBBEQEQgRIBEUEQARGBEgERwRDBEUESACqA45zANBYc3MA1nMCE3MA/WFzAP0BIAD9APsA+wD8APvbA4sqbMUA/QD7APsA/AD7I3NzAJBhcwD9AJABIAD9AJAC8wD9AJDbA4sqbMUjcwD+YXMBIAD9AP0A+wD7APwA+wD+APsA+wD8APvbA4sqbMUjc3MAkGFzASAA/QCQAP0AkALzAP0AkNsDiypsxSNzAkoBPXMCUQFAcwJSyHNzA6UC8wOl2wOLKmzFI3NzAJBhcwEgA6UAkAOlAJAC8wOlAJDbA4sqbMUjcwQ3cwCQBDgAkA2UOHQnATNz3QdFdQoqcwEEAM1hCXNzAFthAAUaOQlzcwCQCXNE3wBQc90JcwCdbXNzQ4CD8BW5tNbewS6T/Np1iIh1Iy3DtPDAAXjPx9ENpwOgreI1z2BewtbX8Yi21FG1bBeCk7aB4sFY/Hi+/ekcwwyBHP+f0YI9G/iFY/5bObtuyY4MTYyHeQiZ62eBq/P8+68/rJI6cCQTfucgoskxeeDzvfo6MGQtbufZbw0FPGPpUNSG9SSs7NDWGUbpnlDGReZvnpkqvyGbE9edMaFydt2lujOB9XLYEAXRfM2Kx0lHbXJ4cszHh5aoooqxDeYXz4qvSy3ahNyE6DBY8J7v31dfMFEdiyjfirJ6hX3Pa2ygMOeuVytsRijRhyF9mVnMu2RxuZv3hI/Amu/2xe54SmySPFpHGxTUY0pe8SZ3I+HauujP4GbIzZYg6enubuUlyP0funGhg8HHYTHFSQD9Hm7HGbFy4n0sziYcpwdArgmsyy41VMV2ppGXMiMR4deCi34NNmlnftVdxoyCJzK+r1GvJvWDtbf4dPnrf0G9qOgEs2CpD3n+1P6MHu+kHtsR6lMcf3NcCDlg2BVcCpSVRHQRiw7qolVbxHeM9xvBMbdwjpFKXi7QUZOi6YaKam2q+tP/4Q5El2aNNWkj5UfSZY4ugEdPUnNXG3TnvpCSZ5IpiIvjM/Q7pZNYYv80gD+OdT5J+D+8K7RPkhzH4w8mJHEG67poqLR0JygXeOe4Qz7fpS6uh/vOXaryaHpamD78JfCU/VdaCwy9bCrfgh13NQynhoIdWRr1IQREtBfsr9bRjkodN4IdiTUMDdlCuM8mKFhoQzu5fn+1PZwtWpT+RAfPcOYqFvyg15NH3r44CwuiNOuJa3QiXx/LenV02OWmQIs/SX/g9e97kXeFyzzC5o3GZEj1A4edoQL/Hfudd5DbKP9jRl8TN4J6Kc1PFyNVAX5Xac6bdFhUIzF/y2fxEOMqCLdbgMjAScVBfo62Fi65kWkU5AuSnpXNEa53A8jiHAFWPQRbvChz7XzIQ1/JFkW4oI8xBV6UfjKIPDLC7squNvW2nzcUx+fOUY3Ocin2ftqIvHfTUJTRNcd7Ke70yAIwvqOtwoyPaZMBpoXD8wnXXhGcZwxMUx5c5bPIUoEI0NmMFTasTLrC3msRFOTj05Bautfl1sY/SvMF/LAsyI9YLxLDyLAdk5DR3UM3aUic2osD5OeVdqZVW/Q1m1ebiFPdS2jIqNLulNQ8bGE2SLfELriR1KiTO9P5+lrvWYO1fSrGrUt2bWuylLbZPkwOvWGZpLOHyarck2ZRqWS6sCGey7WyzKtSLDf8N998dc1hh6BN4lUthsFzHww9KK8RpC1vUV1amMjRDMR+KvY6u8hOpZEzHdLMb13izFQP3ijwSQCEFVH7Js8hL21h1Vgxap8exSPY1CBI89DYkx6Tv5XhsKTqejQ6qbBFVPb0FeZ+D1SdjxYgqAq6uvJHq7PW8hluldBOJ7puqANPsXDOtG/su5LwU1PnRExiBpZNO+7blORJ7i9gQYmu2AXSSiKxSZIyyJ+0umdON6y4aPTTM0FbgQzMWfO3PXOymBuZ9DjNH4dcMJSwm9PsU05clrl3w1WkZ04jCxhragJpQ4w9q2B/PX0G25bXPNnUGKSL3EAHAUkcsOzO66BRomJQr0Z8uQAcdKYDE3iFkuZQy+yZq2C3vghrwhw2d8jCgn3V2SEF0Obph80afZ5zohDVBkZps5UEZmSaeyACcgZ6Ecj/Z3Shx0cxedqpF4rbvSD14by33Qb4gSiKqHx0WH7WjNWW+fZz2t1PtJAPWvC6IaLarFyTSGtiv46IG1Q3YMBw5bDrisQFBnBi22oUgsO/eSzcLI5+wpv1ZX3aTHBQ79qiLoPd5uu6JrnhGzEeM0/gRT5wwCJ6uPDv35Qi4MGUO2s9+aimuET6TexV/KC9BGv9ibvW0+9hFedmTLXfrk2/sgHRe5wZPR6ao7kFwN3Egab8d2ApFPLOUgTY+d32/+XKglFsszuassqJBzo6MTbCwlYKO4yYdfk2gfjuHXxxdIjaUUcqePg/jf4AWUOsz7EjkKaPqLCzwTwkuPoskO+HPvSSIj56NBqwhlukh/SUlBPCAvpc+1hWM5aIt7e+NWicwHeXmf7JihSLmAxjDWNDmv6lSpQAYgl3KGYcLR/SwD/UbzS+YBYGKLhVlwwyGYf2autLOFuC7hdVncxFH6lx4+53/q/z8ukeP5C9jWhZLQvvvXJkWbnwQUbH8WW8VDTl7dYYgEw/d8e8PZVIP8QO8aJwNBObbcAh1bZg/ev/mIcRpHqvapWZBZJccfvQ55WYxxTdBLqYbSDjLNfI0d/IB7j1JaX07Z1abn2SGfV7zm8TU65Tqui5ZG/m8fTS7ZJVkQbJqcHfdRPbFKgIm9Q6lqhbspKIufB0JN5lyRQHiZp5cOyRLL44fHhfM56Ukt8hCMN0cSOYZcp5mvcoAcpVNPjMcA/siqAhaIn3EO6j0+ArsfN/wEexl90dGjecxE+R4JAHU9hBGZrDrJJ0L3FasUPVvPdmvrRUYY0LSEJpgUBo4pykiQr4GRZ9cAVKhzBxs86T9E+h0iOclANvJaS1ozReL9coKT4XJH2R15ed78yO6xqF3vPVSvwW+hApUYHspT4xNknEfEBks2ZT80sBfcq+kKqQeraVh2FtwOkIyPZc2PIZqDVqS2OfSXUEJ+aPajbV+aVHDMxPd4ak0ln8Lm3mlBsJjoNzm1LCOw1FWMbUNFmAyj82fesmdYwbtO9hz97ErIjkGBD8ojAOzSZzPT7bq7FxmZzdfzjVX5lq0DgHNm/HtOP0Fha40VmytaL4VvkkkmaH1vfbxgid+hNPqf//ggLAH9wOu9cN3TPGf7RkhvnFBg9Ue9dEMIY0QnUn6WfZwgFnf37KcfXeA/7qvv2NJesfukMgngn3pyJLjhbJ8DGZvbF61Q19ZVHZ/HfiOf3XZwiD/xlEDb+fuGzUrWRq7IMm/Qsd6SJc6Lqt4i6YC+L5h62FwYHiS63//p0lyL3iAb18QEPtnpbEUty0Zrt0fktA9L/YFLfrzYT6atdQjL6OMhCrZ4O3UUaYR0yme/4GNO/yHHufyAVpH/OIPEf2OzptXJ19+tA+NpivJNqCKOwUsJHqTzrT2G77O9dBe4ZcGyF0mPkzzJEpTJOjkgCt47TXZnFahlCXR9VbZ0lb1c1wAqXTKUqyPVaxz4Eu3rPJHiM3IXQQ0NjTvzUPG258V7vbrgoezETHlADY7B1WeyNMFYVE/LaWY7bSfQb7lKJ/KMRmoFwCrkwMEEkDen5KTEXCfVJrN+v4OeBxxE44mtzJOKdlLb7tqPfXrxftovGQyuaJhwlI3qpYBgfatKX2BJFeGTK5b4b9aSrMIv0QoyWUKQxoWaM41bP4QW5RbSawNQdN/0wv7aL9Jkk5J66IDpo7KQGXAKznLFeMn7t0F83ZTXPCDUhEjgWM2SA9ChmM5YEHa5l1hI1fsf77dxeRWfVHKPsN3Pbl3Dy5b4QIYb6N4Pm9jAAQLmQlaBBhZw5Ia7PfQ+xKgKJFQbR4F32mFfupbsbWLM9jDeqYdACLyf6uAKgVu9AJQpYtNbCj5wj9nXAWUWbWQL1cXcTXoVZqxjtyS/BsoaURCQi3dk09KVzUA0V6ZlrQ53Kj5AnQOcl+5F45QK+I7z2+zhbRVGq2VwcLCugx3BCQZwoiwsqtS8RQRixu4k8uRiaKZ/k7rmghRah8nMGZhmN6r12o0TqdMaPiD/n4TLE9VhVaO0KPZEGCIhU8QX+UXBAqICxssIsyKn1OrvUgTYYTO4jXEpu2+kVS6L6T5gjC1tufk8YssX4CRRcvyMaWoJuzmhC3Bq/DBUCuPaMuhQPIQfcmps2oqp9AqlngtSCo26+n5fKqSzEU3lpH1SMPRDrw6OdD/LhpNrs1YTHgMmP068bb8qMgF+/ASQedI7CvWdu04rAtlsP7kSnTDkyMw2LiZnpMx+i+ayXB7c3ckJcjFuig7H00vq2OQzM5PPevRdYi+cZJifcz1t3cNSD0yuvsuFXD/Nk2j60H5RpUU+Zrlp99wSgKEAkuC8nBJJnZ9PR+DkXPe3s4UeOKoq99964VWB9Pnva6uKI779pgq9oaspNcGV8vSOMCM8ACQn9kUPweu9UwI2n5+goo05CFaR5kALF5jhYmybPavdtAxmaC//LVF0ZLRkIcU+NGJzY3OdUKILkQKUDGABumIZHHzKw/jCOmPL+Zl8t46Wkz0WFvi9Gu4zuSn4okuXcj0BSeDVzHIf7sqCBjmC4zCJ+jyS/+Gq2fPUkgfW0bxdgVFMY+zY3TQuMfygLLiF9MzfKQiZXIgzRm4z85AALjRtWp3nO7kFP7ApIqqe2zn0NfjROHgw/hqbhgKGKjsXzu+rrdu5HeSlhWO8hxwDmVaQObSdcyTFMG/YiFD6lJGKdFb4NNS1HnW8T1P6nNQPqraOBTSnQKxz5tTGqNrbaAE4Iio3Cj50ZUqo6/O5OAtJ6Bznp4gKMgBetgD11fCO++j1RdcFdTbD0tkgfxXgzJTUtWCUmdYjl93RR27ifZGYzgK23MdwF4zvKNem782m0dQnmh47Rxz3+2MVhiiS85nTOXxmaODvzAWBE2IQowSrbzE12IJ82fOrvritWvRIF0aLCLdEytK+NVdDxLvmdW+dFeKOa/ocw1Son0O6OzX0lBLmjYSMQSrFe5X5yf6WE2ehsLrv6M8Cqjvwr+u9X+kP/f3iAk31TV+K9yZKQqAn3QOWy+9Hz7iVWRMuM9hs35+avVy4pXASFbOjGdXM1fSQkLOWmFUhyadKWYPjRZoZo0g3CS0qhz+mjygAvmtkYRBcGNpYAEYoIDEwQaswtATb9HLzTetQL8aK79YSb0vJNPSYzsij3FcXbmfnMiaOJIGrrBJnAPRqg2lmCZFXOFah9l2GRBm8HJMGeiupFvR0aRN41otN6X6tGTxS53wk+2+w+Q5ABTdCd15LYZm/a/3bxe9RDQJ5HZhLzr5x1ccTkxBkbxlYBGd8AKvkL2IR3V283R5noyhAM5o/2rKEi4U6kxCV5efr8llvLFrgjPIwS8iES5jxmV5zyPzj7TyzJTJze+9tgDNGYRyyXPkU4mtAh8XUy9vMigfO+1+ZKYW2WCFjDUfvyNiplha4LliPPg8Rc890ZT+F9pMYPAmEg3JJVUm3fp5N0IPNMAYKmbdj8dkIpjDhDJUd6o3G858DgYwPhSC+z3a78QpEmqq+tRaHEcQ30ZN5KVVdASN8NMTnLKoA+IJdapqCRgooGTkhyjB1yEmjSy52110hPaqe1upiUeObsTXtGELTk2p2NZw/3PzU281tafWNmFUPAmooj83DhoQgKPIB7f+NGTDlTOtyPgN8pIB/lnFLL/gcwigZPKDW7p6hnW/GnAzyNS46gLJAl0Eyhqx6UWLeQTU7odMYORK5zf/FV79JGVPOQpNUA58rlB0ugHsyeub8Lnf9QQ4/N5sRKaUjEEhdpF28vfgPZACBbg5UHuVHl8Lby8mVGsrtI7TjL9U3mbtcF+cXQI/5AxT2i0MyciXEKZ8OjvPoQHHU/YSnCXtEp2r08SJxUAHIz1zM+FwdRCYPffQNi2NhkPWTiYTxJ00WVZIrHwmG7jzOLcfWnquJkpOmdPzXfAu+s5EADm0X4VmatqLjVa86dS7Os55qXuRa1Y7dWGvv57LjBlKKgqsbI7lwfyBN3qkKBqe7nwUDn6xqhGPiUPT7j7s+oD52AF6oj6SFXhYWlRXy+1FL7YSbjFxfFvJt5tVXMAr8/voIg8YRiBsKB6eLeIG5Y/KmGmFBxxYzSH7W0IaK3IId+cBlEk6H3Y5BqIBfvhOOBtInLWnsAoRpqlkxd7o/+LP9UXEahdcYlifFlURgUJl0Ly6LHjSZN1CfHB7OORacnBdpIM1lRpBcvwkeyXUvndU4zrfqwtuBEpxqvk4PZPJMByJXUbXie52mfUB689h9GRV99U4gzn1aTbHPWjbB0DQ0Aes2E/ZzoCTxCef56sExSu8ynaPxuDOOeD31OWT0zHo1XxSPQbclDivD+4/v1aWdhGXLR1Ui+NzuQK1NTedznX44c5T3b+2GZZjl5RqH8KR7FTVjLAXvg64Gpc1RROH24J9jrNDyvrMxY453DRUjZ/K3zYJC+M1JxcvLkuZALsXVQ4Z7sj0EuLbRnhTKzRGwFrpXcixvnCgRbJrCl3+RjyWVipph0VLB0nDop/tvjfFmysZ+d2/k6baJMxYoqnE7PFceicrxUYyoJ2LMxicgJqrgvSR3mNJTkvfTU8BIoZz3PpSIS+Y7Ey3MXecxcxYZTeX62egI5Nub2z8Bj4Eg71YCz8Oiapkinw4RRlL+0c2/6jDqc8UK4Zzi1X4aIpgYsPJQOEz2YWBdvH6z5CuY7UvWK2F0Mg4ofRVBArX1p9Gv5VLqWYyL/raRVWkPNI4FEv9+ePcdmBSQR4CFSO6TG13hIV+cm1dkd0/Nt3r28H4NU2knSniDCeozM/Btc4i/ni4H83S2/ktAAvUM7UKJPT+RO8LOlvxhuI8HQmAuJCzVH23R/0JovidxgdJ7g7whCdVQa9/TLFUJWmNSYAaPRAXW/kk2UBmAz6f6POK1zcMlmI8P9tqW2qVXABN0L0zHarXbWHlhtYpXMEda/pIHLwu8RHqmWWMgMzkyKicSFKK10UvZRdcO8fCiSijtFIY8qW7CscvtzpP92lm+c648urehw35v1EOfO3kdny+CQm/Y0u+zPuevhCrQKhTsUq4G1rNPoGuVzvhf2Ui1f8jzvx9fJbQR69A0ETLUUC2ndk1YFQNi22yLwyZyw4xU8P3RGLM5qojKNwHAZAMAEudzg8UdfV6i4VktOLbhhHUPqpCn6dtpnr16rINs5hWJGMYXaEn0irFCuoYnJEVhdJ4PZLKuTkrP1UUVWZ0SMgJ3F2I8YRhtLwK4dhh/oKk0hdVgEH/l2/0c+cLlF7kpDuF3lC4fsFw3V0QrwH3GLNb2waS18OmYB07yaLEqhd58bSaGJZzePoroV5v3UK46/sWdKczstFIiYLmmKeaVGRNo3IWk+dYUqWy5aJClXj5tf/v47ijlkmMDP+ROUxoGk7LFzne4/0CRPl/5SUyOa679jibvdVQFZ1o0H9kBux7OSC9B+qVKE1trxr4xqTkjc1ZGZBpY0zyKBiu8wr+/KXc37u0cdXGJwY/aTic3kGj4jt3y4ZwleKskyXMFHKGwVhqpFH3ba02boSzGHyPMAe/reVqWSTT2Uz47+uYvHZGNASqYQ23uZoxalHK+PGoH9trTVaw2KB4dH8fNrXRLhiyxGdRtS0x8k3feeOvsOdKEdaOf3IrfWCZM/n3+hVJizA4zoX8MzsIf6bDfuFXIIRR2RN0rICZcMRmnRxUXT+YMOid50gg+Nt4Uucemmbd9kvJG/O04PVC0vm5gGDlIY3THI2+l1rZcMOuSDWBp6I4Eltp7naHZCdaPUWnQ07VqO49znDgCmtu5Tb+SSEQJV+rJsiXgCqoeeQciher8cqF616P8qlZeonKihdVkj+RTnjOcnoERWubvyaeFO6Ub3dhh0qmm2RD4enszxE1JaAaiezuSoCayJQP931HGcy0NmuVr/UV0pvbwICLpBbVkxC6qebjLGRXucTG0dbQDFPz049hMem2pb/FOTGYRLR0uPCa0oIwc9Z/g+Iy/zYFDThHi1cqbK824savKGMLMj7j87RT9NMwxaI0eKTfMFioi9SyLq5sN9pV8be2FrOc7xMOdv6btXyqFx63y9fIGMBP2T9Wmeeg61ZGdTE4IwybcGlXLJ3qLbRRpQ8vSzcqFobN+QPtL+51hadAWtRbF6aJpeb7Gca4/Ldh7BDvEbrUuEm+gTyVMeRQ3Ypf9uyFjVstrQIcdY+aur3LC5I5OOnJck1zLUKxLobjy9slG3hv6zylhtKbAbpX5p8Hc910fCT7FNH5/t9xEJX9kkeZ9IMCHAk9zn7L3pXEGZVvdaf85NtlemPpY7iSgSC7zRGsI5W6/UEwX6jDtNVZ9VqPDBe/EqmEEsGcs7jZPQPhi3xpj9UXWQLiy6tsxv/ft9aKQnUg0Sps/x3AZ2uK3ETGTQogPTMQPOnoU6p5KuS3uY6DfW0GeGQ1wNpGzGoUdRJRvHP9MDQpWRSZqZkE/rcNnQ5lS9BmMDW/umgZQD1C2YXfZMy7fIVXo121293Gfx9n7DQP6OxSqiSTNx48KId9kfGYOnV2Wg2TQQywNBRB0mSmqa/jwoBDYVDl6B0XFrVEAwbnhLyqGp5BH9bzsWrrFlu0x285RpqTylTZk3rgcm57prav0DUAKUd02vXdYyNBf7sfX7VYn0Syug9++ey/dHoG7GQzMbhXhtEuRXv6YR20SQgSOrgDUGPR4HhS+Qvk2zOtyH8N/lHYfQxNKt/f7uCpsBBh5eGZaeWNRTBdOObWOvyKJMfD8FLEX1v/5ywtRV27weRzSNaHEQFE0hIzzS4VPzgWtg/4bcetwXpabsePP192muNPyXiRzRZkoeudA9D9x/oVWfRieLfjdXbi/41RGNB3aIj0IxCBHSvUN7LzntO6Oh910zV9u4Glrouyr5odjs8/fW9r0buiTMWTjjLbi2k5tZ3m/134ci/d9f8zuv+4BI7F13Mjb7DTTD5ukfqNTlNC4V9PnfbGAJdKLEDJgBPKyYXCaAL9U5Cxi2j5j+IWmNg6NSnWcATzmOO4+dNBmefy6ceyd8J9/Q7amUWVVkuNVSq3iWEb3UJP7kG+P8wfL4xS0ZNuSKYuo9KpdkJ3b4PYRNSzF+8OXKDWqXuWsan/wconybIRBoGWHMuCkb35BtGfiqZ4hc2CCapKiLmrWnBLlRT+9GA0Qcykkg1B6C3kESJMu2dWyGabbhRwxUeMxARHqbXzHmHpr4Z3vmOxHZ6b1q6MJ0Vb/XKkaPF4xn/VindEJ3S8/9xcGF+PNFuAXc2Jf9uZLLtjxDAEeohd7wjie66LHvcNT0UpWif4uCox2YR/liegMgx8vEbvQClJBMBub7zJQMCr1C/Vf8siWQASp0Ewd7D2uP6f9YTISdEaUAzF9rST9JTHxez310BfdgtWKU1ZYoRuDZvGn2tj9DPjXrkgCr/13OHsP4MOC5b6YqHSedYMW9bEfS5M3nO7zTGS85BzpLTIFqAGhZJLEyLFcZXS7hDhDYVvlm10RLEslMK0cUL/9xqTMOX2iR65umsC8dW4hT0Sg6Tf3T2HAxsHKcNzoqFwuM9k3/LpYekhRc0C+f1I+vMQ4thkfSotx9GUt/cdRosaE8XwqV0k+8ZtU+jv8nn3lbcNxfXXKi5l0SL5kMmrCdrxeVVqxBobrFF+tb0wtkN+DMm88I4jWH/DcdJOjcMOLEsN70vlsfIi+NexpaT0ZsnfewPoTvUSXqqfhRcRk3jA7AdYHEFk4l6O3fe65uZNIMf1lbtJNCNaK2+c5hGKLcTSrBmwWv9TP6JDfZ6UY96g4baayVCbrDpXePgXTG6xO3rT0DAXG9OuPxkSEPLJnqxQViyYQhCp36Q2yFpF6cR04RO7Ab5HPrECqGR0Fnr2gzmjx49XjQf8N5Bk5XH0dh8NOoB62acHwMhlBM8duW9tghc7CN7oz91UEyd8fOtwDK/j7SykdllCAN5kUrcawufMV9y/EqUoKHtP5i8MgQY9RlZFZzi0BeT9Ang4mMIvWAFChZCNnb4tT5cS20jeit8JEN4tz4mUmZxDwiWkEucI1KF/FyAnvE4wybWvbaxBYjT2jdhlzd4y/eTmTl3im5YImADc2unOtmNTcgMdOb9kUgJmgzY/hDaAxqvwLEulLsjq0bsfSE3tRYCRn6xb0uv5B5yFshhewdO5KgoLcaGeqeg0pa9k2RXM32g1jE1UDWO0CaMobavPk+4u26Tmgg6VindBdYdRxpGqlvkxai0K/atC5CWUxlHuukX5b+hg83khzsZK7AVRVptyVNicu0sfQToTDEeIeDdFvDrReJUiJGZcXAhpRL3OufhL4aDfO1zsCmfGq8qFspBiJe13lgS9GguiMsdmgpWOhHkSTVkWnMOnUeIJgqZks/AwL/1yKPm00t6x6qLXQrCJrysUwR+ILJdyyyuUN4BuEtCDUXMXPU5srsAnDUhSfFM/j4RK+cK01o6lXAVbhiOLaaQtpYN6mCOwtJNcVqEpyrxXuWxvE4mbVCytBu/qKO4X2BI1NUSlj/g6FQEiYsXMAQuM9wnHngXKLZRWFHcgroF7URRzLPrMQUfALjbga6S+tGc3Tshv6PA6xeSqRPDbLG+X+0qt9crNzbaxGbStSCfYhdRY4t5BSVY9Pxl9trcYFiUdsV1BSwaZM5u8K+hUm8HV6PoLD/jlsRRzgUq6O+Qw3asFkTKm3clSTo8VtXdpTdzFAZP+tVvAjkfGq3MkSLyTYi08pvQ3h/L9o0JpUnnQeKxXk3qIsGGsH1BXzcZT+voCNv39FSdg6gNY51z9Cyq5Dql8wER5ylTwnLVeHlHAn/HNwxGYeUqrrc2gcmIybVKVD1XAPXjKks2+oHZk4OXYP6+LwVaFEApqEMyEusTgVFTzdjVa2BAaELvpyVhOSMW/ae3NwMfWId4Ue28z5IzumOF/CmY1GmXBOWBf2hgp/r3qS0GU7nGETmj+7Tudbjd1cKhgP39tVtWogjxHt6NLXz8OCbV1nIBG+mmrrZDCbH/o4Vgn3gZkRkq+iHOVW82LunJPXBZjX/ntmptWsqP8nDZBSb3TzAD4vSQeQ1GmtgGWAYfB951YKUnFVJb0z1YRjQqVksL5VpD4N/Vy31vtYY/2g9TmyMADPgCwwA6MhjQ9bd1JFJ3Vls7lD2RYjdIwQwhWzBRPfrxpKcYeu03F0/odRbEc9RZ11TxVY8mXqgJx/vDk0eF4MPV7lgBxYqxoGfEtGZBC1kZlxbcez4Ts4/TuXJ/QsfWT95Fwpc4CtiGCgU4i7LHgoDalqmBabvzV5xvq2pMVourJYZ4paytzilEG+lADOGx7qf9O5/4cP5SqyTCMG4I16I/6I5o4Y/QkWX9ctABry/8Adxz+ZB8AI1yUyNXk1Z073ECiDJ1EuVT69eIDEAlbnv24j4DJGeqIV1b1GDCHJ+OFD4W0gXUs/1bMkNESNKl2ON6DZzAXvqmr8X68yRDgIReKbX1SUwtzYnyadBLhEWS0WTE7T1IxC2SHChb1NFD+2rtJSN8OPTIZRqiizaoh7OSSNpBXJMkKcUQZV8sXw8VkU5ea8j0WZ/YK35loUxE1aG30SL/JYxZWlUenDyKrfbHWJ+z6JOsV0e1Xfw7VGavtHACLwn0tTG9e3lf++w1MCVjFIyU57uOlbTkUSnxAjzmA71qvjTzHeMDWcK099tm9rS8cnfuwxq+YRWANkfmLbCl+74mg4bccPsNY5zz7cjbaFAL0hAwId61yM5uqhMBr4Wcew3b2spG5tkKFOnADeXkGkH4vk+f+an92mWXemOFCpjRsFeEnPEAIsLemM3QfMoME5/w+7Y48y/SvkBN6/KSRVmB7/rHiW7iVkXF6Y1T853OaDg66cIfWkD5TqCDugrlaXlEL1fFjxPoKRHkP5GD/xDiscNH+Dp2fXEKUpwAvC8JTNC+k9JpaMXUB7oj4p77qiAOjXD2pT4v/v0Ukid02LpuYsS7/ScDL1SxB9hxxbkeGOMyPyL4HZPAbyagOgP5Xe2pCqMPyj/KJ0blDHzFVBqzeLIO5D4yq7IpSi9p/QlHa50sCHzGoMqrBS8l9IfRyhq8IDQtOZzjgdvgQDwH7cqa/sybwdfcQse9THS08maKkkgnOi0ShO8Gyf+WL4K9DX11CF9uIbVwJUaCv8r/6FDVOdsEjeumisIJlLJQsjjkEL2QfEc68oqsevnNAEdp4YMJivwBJnE0R2GiBFRTJZNkq/MHDP9O5unQoRoivMJkPm+A0K8CQNXL6V3apC4ROBTyJSW9oOGNF4YrwoTFyz/pexIkeWQADpi+M7q8gBlmGRUune0k7cXyacdbOsD0Q1JQat9T8nmHhyO8PNd2k4qjZsQCs6lEcmaThpVUzGzWOJQGGf2oz7+F/bMfUMARo1PD0/yIhVDK+8MGRo/uByG5UAwPfNeHAd09gkMFpZmTN2rZgoqdSjwv1SbFnFRAqYuzwW8P4+Rk9fE3PVu80HKcXyIEvPfit+o+pnlHDUKKo32HapcVtQhsNiIdH80j/lRnJ2y5RYRbECyY4vl20j/NiBAD0Z5jxWWiL6xAZIonSEJb1qhwmdRp3hISLL9Q1QYOt6C/OixU3eUtXblgBu+fGPAQE0o");let o=new Map([[8217,"apostrophe"],[8260,"fraction slash"],[12539,"middle dot"]]);function quote_cp(A){return`{${A.toString(16).toUpperCase().padStart(2,"0")}}`}function str_from_cps(A){let e=A.length;if(e<4096)return String.fromCodePoint(...A);let t=[];for(let r=0;r>24&255}function unpack_cp(A){return 16777215&A}let B=new Map(read_sorted_arrays(l).flatMap((A,e)=>A.map(A=>[A,e+1<<24]))),w=new Set(read_sorted(l)),n=new Map,a=new Map;for(let[A,e]of read_mapped(l)){if(!w.has(A)&&2==e.length){let[t,r]=e,C=a.get(t);C||(C=new Map,a.set(t,C)),C.set(r,A)}n.set(A,e.reverse())}function is_hangul(A){return A>=44032&&A<55204}function decomposed(A){let e=[],t=[],r=!1;function add(A){let t=B.get(A);t&&(r=!0,A|=t),e.push(A)}for(let r of A)for(;;){if(r<128)e.push(r);else if(is_hangul(r)){let A=r-44032,e=A/588|0,t=A%588/28|0,C=A%28;add(4352+e),add(4449+t),C>0&&add(4519+C)}else{let A=n.get(r);A?t.push(...A):add(r)}if(!t.length)break;r=t.pop()}if(r&&e.length>1){let A=unpack_cc(e[0]);for(let t=1;t0&&C>=A)0==A?(e.push(r,...t),t.length=0,r=o):t.push(o),C=A;else{let g=function(A,e){if(A>=4352&&A<4371&&e>=4449&&e<4470)return 44032+(A-4352)*588+(e-4449)*28;if(is_hangul(A)&&e>4519&&e<4547&&(A-44032)%28==0)return A+(e-4519);{let t=a.get(A);return t&&(t=t.get(e))?t:-1}}(r,o);g>=0?r=g:0==C&&0==A?(e.push(r),r=o):(t.push(o),C=A)}}return r>=0&&e.push(r,...t),e}(decomposed(A))}function read_set(){return new Set(read_sorted(g))}let c=new Map(read_mapped(g)),s=read_set(),f=read_set(),Q=new Set(read_sorted(g).map(function(A){return this[A]},[...f])),i=read_set();read_set();let E=read_sorted_arrays(g);function read_chunked(){return new Set([read_sorted(g).map(A=>E[A]),read_sorted(g)].flat(2))}let h=g(),u=read_array_while(A=>{let e=read_array_while(g).map(A=>A+96);if(e.length){let t=A>=h;e[0]-=32,e=str_from_cps(e),t&&(e=`Restricted[${e}]`);let r=read_chunked(),C=[...r,...read_chunked()].sort((A,e)=>A-e);return{N:e,P:r,M:!g(),R:t,V:new Set(C)}}}),M=read_set(),I=new Map;for(let{V:A,M:e}of([...M,...read_set()].sort((A,e)=>A-e).map((A,e,t)=>{let r=g(),C=t[e]=r?t[e-r]:{V:[],M:new Map};C.V.push(A),M.has(A)||I.set(A,C)}),new Set(I.values()))){let t=[];for(let e of A){let A=u.filter(A=>A.V.has(e)),r=t.find(({G:e})=>A.some(A=>e.has(A)));r||(r={G:new Set,V:[]},t.push(r)),r.V.push(e),A.forEach(A=>r.G.add(A))}let r=t.flatMap(({G:A})=>[...A]);for(let{G:A,V:C}of t){let t=new Set(r.filter(e=>!A.has(e)));for(let A of C)e.set(A,t)}}let p=new Set,d=new Set;for(let A of u)for(let e of A.V)(p.has(e)?d:p).add(e);for(let A of p)I.has(A)||d.has(A)||I.set(A,1);let D=new Set([...p,...decomposed(p).map(unpack_cp)]);let Emoji=class Emoji extends Array{get is_emoji(){return!0}};let U=(r=[],C=read_sorted(g),function expand({S:A,B:e},t,C){if(!(4&A)||C!==t[t.length-1])for(let g of(2&A&&(C=t[t.length-1]),1&A&&r.push(t),e))for(let A of g.Q)expand(g,[...t,A],C)}(function decode(A){return{S:g(),B:read_array_while(()=>{let A=read_sorted(g).map(A=>C[A]);if(A.length)return decode(A)}),Q:A}}([]),[]),r).map(A=>Emoji.from(A)).sort(function(A,e){let t=A.length,r=t-e.length;for(let C=0;0==r&&C{let e=A.get(t);return e||(e=new Map,A.set(t,e)),e});65039===t?e.push(...A):e=A}for(let t of e)t.V=A}function safe_str_from_cps(A,e=quote_cp){var t;let r=[];t=A[0],f.has(t)&&r.push("◌");let C=0,g=A.length;for(let t=0;tA.P.has(e));return r&&(t=`${r.N} ${t}`),Error(`illegal mixture: ${A.N} + ${t}`)}function error_placement(A){return Error(`illegal placement: ${A}`)}function filter_fe0f(A){return A.filter(A=>65039!=A)}function normalize(A){var e;return(e=function(A,e,t){if(!A)return[];let r=0;return A.split(".").map(A=>{let C,g=function(A){let e=[];for(let t=0,r=A.length;t0;)if(95!==A[--e])throw Error("underscore allowed only at start")}(C),!(l.emoji=B>1||r[0].is_emoji)&&C.every(A=>A<128))!function(A){if(A.length>=4&&45==A[2]&&45==A[3])throw Error(`invalid label extension: "${str_from_cps(A.slice(0,4))}"`)}(C),A="ASCII";else{let e=r.flatMap(A=>A.is_emoji?[]:A);if(e.length){if(f.has(C[0]))throw error_placement("leading combining mark");for(let A=1;AA.V.has(t));if(!A.length){if(u.some(A=>A.V.has(t)))throw error_group_member(e[0],t);throw error_disallowed(t)}if(e=A,1==A.length)break}return e}(t);(function(A,e){let{V:t,M:r}=A;for(let r of e)if(!t.has(r))throw error_group_member(A,r);if(r){let A=decomposed(e).map(unpack_cp);for(let e=1,t=A.length;e4)throw Error(`excessive non-spacing marks: ${bidi_qq(safe_str_from_cps(A.slice(e-1,r)))} (${r-e}/4)`);e=r}}})(g,e),function(A,e){let t;let r=[];for(let A of e){let e=I.get(A);if(1===e)return;if(e){let r=e.M.get(A);if(!(t=t?t.filter(A=>r.has(A)):[...r]).length)return}else r.push(A)}if(t){for(let e of t)if(r.every(A=>e.V.has(A)))throw Error(`whole-script confusable: ${A.N}/${e.N}`)}}(g,t),A=g.N}else A="Emoji"}}else throw Error("empty label");l.type=A}catch(A){l.error=A}return l.output=C,l})}(A,nfc,filter_fe0f)).map(({input:A,error:t,output:r})=>{if(t){let r=t.message;throw Error(1==e.length?r:`Invalid label ${bidi_qq(safe_str_from_cps(A))}: ${r}`)}return str_from_cps(r)}).join(".")}}}]); \ No newline at end of file diff --git a/_next/static/chunks/465.581b3ba67298757a.js b/_next/static/chunks/465.581b3ba67298757a.js new file mode 100644 index 0000000..2cbec01 --- /dev/null +++ b/_next/static/chunks/465.581b3ba67298757a.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[465],{39670:function(e,t,s){s.d(t,{ConfigCtrl:function(){return C},zv:function(){return f},uA:function(){return g},ExplorerCtrl:function(){return R},jb:function(){return V},OptionsCtrl:function(){return w},AV:function(){return u},ThemeCtrl:function(){return G},ToastCtrl:function(){return X}}),Symbol();let r=Symbol(),o=Object.getPrototypeOf,n=new WeakMap,l=e=>e&&(n.has(e)?n.get(e):o(e)===Object.prototype||o(e)===Array.prototype),y=e=>l(e)&&e[r]||null,h=(e,t=!0)=>{n.set(e,t)},isObject=e=>"object"==typeof e&&null!==e,i=new WeakMap,a=new WeakSet,buildProxyFunction=(e=Object.is,t=(e,t)=>new Proxy(e,t),s=e=>isObject(e)&&!a.has(e)&&(Array.isArray(e)||!(Symbol.iterator in e))&&!(e instanceof WeakMap)&&!(e instanceof WeakSet)&&!(e instanceof Error)&&!(e instanceof Number)&&!(e instanceof Date)&&!(e instanceof String)&&!(e instanceof RegExp)&&!(e instanceof ArrayBuffer),r=e=>{switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:throw e}},o=new WeakMap,n=(e,t,s=r)=>{let c=o.get(e);if((null==c?void 0:c[0])===t)return c[1];let p=Array.isArray(e)?[]:Object.create(Object.getPrototypeOf(e));return h(p,!0),o.set(e,[t,p]),Reflect.ownKeys(e).forEach(t=>{if(Object.getOwnPropertyDescriptor(p,t))return;let r=Reflect.get(e,t),o={value:r,enumerable:!0,configurable:!0};if(a.has(r))h(r,!1);else if(r instanceof Promise)delete o.value,o.get=()=>s(r);else if(i.has(r)){let[e,t]=i.get(r);o.value=n(e,t(),s)}Object.defineProperty(p,t,o)}),Object.preventExtensions(p)},c=new WeakMap,p=[1,1],u=r=>{if(!isObject(r))throw Error("object required");let o=c.get(r);if(o)return o;let f=p[0],b=new Set,notifyUpdate=(e,t=++p[0])=>{f!==t&&(f=t,b.forEach(s=>s(e,t)))},m=p[1],ensureVersion=(e=++p[1])=>(m===e||b.size||(m=e,g.forEach(([t])=>{let s=t[1](e);s>f&&(f=s)})),f),createPropListener=e=>(t,s)=>{let r=[...t];r[1]=[e,...r[1]],notifyUpdate(r,s)},g=new Map,addPropListener=(e,t)=>{if(g.has(e))throw Error("prop listener already exists");if(b.size){let s=t[3](createPropListener(e));g.set(e,[t,s])}else g.set(e,[t])},removePropListener=e=>{var t;let s=g.get(e);s&&(g.delete(e),null==(t=s[1])||t.call(s))},addListener=e=>{b.add(e),1===b.size&&g.forEach(([e,t],s)=>{if(t)throw Error("remove already exists");let r=e[3](createPropListener(s));g.set(s,[e,r])});let removeListener=()=>{b.delete(e),0===b.size&&g.forEach(([e,t],s)=>{t&&(t(),g.set(s,[e]))})};return removeListener},v=Array.isArray(r)?[]:Object.create(Object.getPrototypeOf(r)),w={deleteProperty(e,t){let s=Reflect.get(e,t);removePropListener(t);let r=Reflect.deleteProperty(e,t);return r&¬ifyUpdate(["delete",[t],s]),r},set(t,r,o,n){let p=Reflect.has(t,r),f=Reflect.get(t,r,n);if(p&&(e(f,o)||c.has(o)&&e(f,c.get(o))))return!0;removePropListener(r),isObject(o)&&(o=y(o)||o);let b=o;if(o instanceof Promise)o.then(e=>{o.status="fulfilled",o.value=e,notifyUpdate(["resolve",[r],e])}).catch(e=>{o.status="rejected",o.reason=e,notifyUpdate(["reject",[r],e])});else{!i.has(o)&&s(o)&&(b=u(o));let e=!a.has(b)&&i.get(b);e&&addPropListener(r,e)}return Reflect.set(t,r,b,n),notifyUpdate(["set",[r],o,f]),!0}},I=t(v,w);c.set(r,I);let C=[v,ensureVersion,n,addListener];return i.set(I,C),Reflect.ownKeys(r).forEach(e=>{let t=Object.getOwnPropertyDescriptor(r,e);"value"in t&&(I[e]=r[e],delete t.value,delete t.writable),Object.defineProperty(v,e,t)}),I})=>[u,i,a,e,t,s,r,o,n,c,p],[c]=buildProxyFunction();function proxy(e={}){return c(e)}function subscribe(e,t,s){let r;let o=i.get(e);o||console.warn("Please use proxy object");let n=[],a=o[3],c=!1,p=a(e=>{if(n.push(e),s){t(n.splice(0));return}r||(r=Promise.resolve().then(()=>{r=void 0,c&&t(n.splice(0))}))});return c=!0,()=>{c=!1,p()}}let p=proxy({history:["ConnectWallet"],view:"ConnectWallet",data:void 0}),u={state:p,subscribe:e=>subscribe(p,()=>e(p)),push(e,t){e!==p.view&&(p.view=e,t&&(p.data=t),p.history.push(e))},reset(e){p.view=e,p.history=[e]},replace(e){p.history.length>1&&(p.history[p.history.length-1]=e,p.view=e)},goBack(){if(p.history.length>1){p.history.pop();let[e]=p.history.slice(-1);p.view=e}},setData(e){p.data=e}},f={WALLETCONNECT_DEEPLINK_CHOICE:"WALLETCONNECT_DEEPLINK_CHOICE",WCM_VERSION:"WCM_VERSION",RECOMMENDED_WALLET_AMOUNT:9,isMobile:()=>"u">typeof window&&!!(window.matchMedia("(pointer:coarse)").matches||/Android|webOS|iPhone|iPad|iPod|BlackBerry|Opera Mini/u.test(navigator.userAgent)),isAndroid:()=>f.isMobile()&&navigator.userAgent.toLowerCase().includes("android"),isIos(){let e=navigator.userAgent.toLowerCase();return f.isMobile()&&(e.includes("iphone")||e.includes("ipad"))},isHttpUrl:e=>e.startsWith("http://")||e.startsWith("https://"),isArray:e=>Array.isArray(e)&&e.length>0,formatNativeUrl(e,t,s){if(f.isHttpUrl(e))return this.formatUniversalUrl(e,t,s);let r=e;r.includes("://")||(r=e.replaceAll("/","").replaceAll(":",""),r=`${r}://`),r.endsWith("/")||(r=`${r}/`),this.setWalletConnectDeepLink(r,s);let o=encodeURIComponent(t);return`${r}wc?uri=${o}`},formatUniversalUrl(e,t,s){if(!f.isHttpUrl(e))return this.formatNativeUrl(e,t,s);let r=e;r.endsWith("/")||(r=`${r}/`),this.setWalletConnectDeepLink(r,s);let o=encodeURIComponent(t);return`${r}wc?uri=${o}`},wait:async e=>new Promise(t=>{setTimeout(t,e)}),openHref(e,t){window.open(e,t,"noreferrer noopener")},setWalletConnectDeepLink(e,t){try{localStorage.setItem(f.WALLETCONNECT_DEEPLINK_CHOICE,JSON.stringify({href:e,name:t}))}catch{console.info("Unable to set WalletConnect deep link")}},setWalletConnectAndroidDeepLink(e){try{let[t]=e.split("?");localStorage.setItem(f.WALLETCONNECT_DEEPLINK_CHOICE,JSON.stringify({href:t,name:"Android"}))}catch{console.info("Unable to set WalletConnect android deep link")}},removeWalletConnectDeepLink(){try{localStorage.removeItem(f.WALLETCONNECT_DEEPLINK_CHOICE)}catch{console.info("Unable to remove WalletConnect deep link")}},setModalVersionInStorage(){try{"u">typeof localStorage&&localStorage.setItem(f.WCM_VERSION,"2.6.2")}catch{console.info("Unable to set Web3Modal version in storage")}},getWalletRouterData(){var e;let t=null==(e=u.state.data)?void 0:e.Wallet;if(!t)throw Error('Missing "Wallet" view data');return t}},b="u">typeof location&&(location.hostname.includes("localhost")||location.protocol.includes("https")),m=proxy({enabled:b,userSessionId:"",events:[],connectedWalletId:void 0}),g={state:m,subscribe:e=>subscribe(m.events,()=>e(function(e,t){let s=i.get(e);s||console.warn("Please use proxy object");let[r,o,n]=s;return n(r,o(),void 0)}(m.events[m.events.length-1]))),initialize(){m.enabled&&"u">typeof(null==crypto?void 0:crypto.randomUUID)&&(m.userSessionId=crypto.randomUUID())},setConnectedWalletId(e){m.connectedWalletId=e},click(e){if(m.enabled){let t={type:"CLICK",name:e.name,userSessionId:m.userSessionId,timestamp:Date.now(),data:e};m.events.push(t)}},track(e){if(m.enabled){let t={type:"TRACK",name:e.name,userSessionId:m.userSessionId,timestamp:Date.now(),data:e};m.events.push(t)}},view(e){if(m.enabled){let t={type:"VIEW",name:e.name,userSessionId:m.userSessionId,timestamp:Date.now(),data:e};m.events.push(t)}}},v=proxy({chains:void 0,walletConnectUri:void 0,isAuth:!1,isCustomDesktop:!1,isCustomMobile:!1,isDataLoaded:!1,isUiLoaded:!1}),w={state:v,subscribe:e=>subscribe(v,()=>e(v)),setChains(e){v.chains=e},setWalletConnectUri(e){v.walletConnectUri=e},setIsCustomDesktop(e){v.isCustomDesktop=e},setIsCustomMobile(e){v.isCustomMobile=e},setIsDataLoaded(e){v.isDataLoaded=e},setIsUiLoaded(e){v.isUiLoaded=e},setIsAuth(e){v.isAuth=e}},I=proxy({projectId:"",mobileWallets:void 0,desktopWallets:void 0,walletImages:void 0,chains:void 0,enableAuthMode:!1,enableExplorer:!0,explorerExcludedWalletIds:void 0,explorerRecommendedWalletIds:void 0,termsOfServiceUrl:void 0,privacyPolicyUrl:void 0}),C={state:I,subscribe:e=>subscribe(I,()=>e(I)),setConfig(e){var t,s;g.initialize(),w.setChains(e.chains),w.setIsAuth(!!e.enableAuthMode),w.setIsCustomMobile(!!(null==(t=e.mobileWallets)?void 0:t.length)),w.setIsCustomDesktop(!!(null==(s=e.desktopWallets)?void 0:s.length)),f.setModalVersionInStorage(),Object.assign(I,e)}};var O=Object.defineProperty,L=Object.getOwnPropertySymbols,W=Object.prototype.hasOwnProperty,E=Object.prototype.propertyIsEnumerable,M=(e,t,s)=>t in e?O(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,K=(e,t)=>{for(var s in t||(t={}))W.call(t,s)&&M(e,s,t[s]);if(L)for(var s of L(t))E.call(t,s)&&M(e,s,t[s]);return e};let j="https://explorer-api.walletconnect.com",A="js-2.6.2";async function dist_w(e,t){let s=K({sdkType:"wcm",sdkVersion:A},t),r=new URL(e,j);return r.searchParams.append("projectId",C.state.projectId),Object.entries(s).forEach(([e,t])=>{t&&r.searchParams.append(e,String(t))}),(await fetch(r)).json()}let U={getDesktopListings:async e=>dist_w("/w3m/v1/getDesktopListings",e),getMobileListings:async e=>dist_w("/w3m/v1/getMobileListings",e),getInjectedListings:async e=>dist_w("/w3m/v1/getInjectedListings",e),getAllListings:async e=>dist_w("/w3m/v1/getAllListings",e),getWalletImageUrl:e=>`${j}/w3m/v1/getWalletImage/${e}?projectId=${C.state.projectId}&sdkType=wcm&sdkVersion=${A}`,getAssetImageUrl:e=>`${j}/w3m/v1/getAssetImage/${e}?projectId=${C.state.projectId}&sdkType=wcm&sdkVersion=${A}`};var P=Object.defineProperty,D=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,N=Object.prototype.propertyIsEnumerable,k=(e,t,s)=>t in e?P(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,F=(e,t)=>{for(var s in t||(t={}))x.call(t,s)&&k(e,s,t[s]);if(D)for(var s of D(t))N.call(t,s)&&k(e,s,t[s]);return e};let T=f.isMobile(),_=proxy({wallets:{listings:[],total:0,page:1},search:{listings:[],total:0,page:1},recomendedWallets:[]}),R={state:_,async getRecomendedWallets(){let{explorerRecommendedWalletIds:e,explorerExcludedWalletIds:t}=C.state;if("NONE"===e||"ALL"===t&&!e)return _.recomendedWallets;if(f.isArray(e)){let t={recommendedIds:e.join(",")},{listings:s}=await U.getAllListings(t),r=Object.values(s);r.sort((t,s)=>{let r=e.indexOf(t.id),o=e.indexOf(s.id);return r-o}),_.recomendedWallets=r}else{let{chains:e,isAuth:s}=w.state,r=e?.join(","),o=f.isArray(t),n={page:1,sdks:s?"auth_v1":void 0,entries:f.RECOMMENDED_WALLET_AMOUNT,chains:r,version:2,excludedIds:o?t.join(","):void 0},{listings:i}=T?await U.getMobileListings(n):await U.getDesktopListings(n);_.recomendedWallets=Object.values(i)}return _.recomendedWallets},async getWallets(e){let t=F({},e),{explorerRecommendedWalletIds:s,explorerExcludedWalletIds:r}=C.state,{recomendedWallets:o}=_;if("ALL"===r)return _.wallets;o.length?t.excludedIds=o.map(e=>e.id).join(","):f.isArray(s)&&(t.excludedIds=s.join(",")),f.isArray(r)&&(t.excludedIds=[t.excludedIds,r].filter(Boolean).join(",")),w.state.isAuth&&(t.sdks="auth_v1");let{page:n,search:i}=e,{listings:a,total:c}=T?await U.getMobileListings(t):await U.getDesktopListings(t),p=Object.values(a),u=i?"search":"wallets";return _[u]={listings:[..._[u].listings,...p],total:c,page:n??1},{listings:p,total:c}},getWalletImageUrl:e=>U.getWalletImageUrl(e),getAssetImageUrl:e=>U.getAssetImageUrl(e),resetSearch(){_.search={listings:[],total:0,page:1}}},$=proxy({open:!1}),V={state:$,subscribe:e=>subscribe($,()=>e($)),open:async e=>new Promise(t=>{let{isUiLoaded:s,isDataLoaded:r}=w.state;if(f.removeWalletConnectDeepLink(),w.setWalletConnectUri(e?.uri),w.setChains(e?.chains),u.reset("ConnectWallet"),s&&r)$.open=!0,t();else{let e=setInterval(()=>{let s=w.state;s.isUiLoaded&&s.isDataLoaded&&(clearInterval(e),$.open=!0,t())},200)}}),close(){$.open=!1}};var H=Object.defineProperty,z=Object.getOwnPropertySymbols,B=Object.prototype.hasOwnProperty,J=Object.prototype.propertyIsEnumerable,S=(e,t,s)=>t in e?H(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,Y=(e,t)=>{for(var s in t||(t={}))B.call(t,s)&&S(e,s,t[s]);if(z)for(var s of z(t))J.call(t,s)&&S(e,s,t[s]);return e};let q=proxy({themeMode:"u">typeof matchMedia&&matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}),G={state:q,subscribe:e=>subscribe(q,()=>e(q)),setThemeConfig(e){let{themeMode:t,themeVariables:s}=e;t&&(q.themeMode=t),s&&(q.themeVariables=Y({},s))}},Q=proxy({open:!1,message:"",variant:"success"}),X={state:Q,subscribe:e=>subscribe(Q,()=>e(Q)),openToast(e,t){Q.open=!0,Q.message=e,Q.variant=t},closeToast(){Q.open=!1}}},78465:function(e,t,s){s.d(t,{WalletConnectModal:function(){return d}});var r=s(39670);let d=class d{constructor(e){this.openModal=r.jb.open,this.closeModal=r.jb.close,this.subscribeModal=r.jb.subscribe,this.setTheme=r.ThemeCtrl.setThemeConfig,r.ThemeCtrl.setThemeConfig(e),r.ConfigCtrl.setConfig(e),this.initUi()}async initUi(){if("u">typeof window){await s.e(777).then(s.bind(s,88777));let e=document.createElement("wcm-modal");document.body.insertAdjacentElement("beforeend",e),r.OptionsCtrl.setIsUiLoaded(!0)}}}}}]); \ No newline at end of file diff --git a/_next/static/chunks/572.a8d809b8ab002224.js b/_next/static/chunks/572.a8d809b8ab002224.js new file mode 100644 index 0000000..dc95d5a --- /dev/null +++ b/_next/static/chunks/572.a8d809b8ab002224.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[572],{5572:function(e,a,t){t.d(a,{offchainLookup:function(){return offchainLookup},offchainLookupSignature:function(){return p}});var r=t(98873),n=t(71891),s=t(95950),o=t(66291);let OffchainLookupError=class OffchainLookupError extends s.G{constructor({callbackSelector:e,cause:a,data:t,extraData:r,sender:n,urls:s}){super(a.shortMessage||"An error occurred while fetching for an offchain result.",{cause:a,metaMessages:[...a.metaMessages||[],a.metaMessages?.length?"":[],"Offchain Gateway Call:",s&&[" Gateway URL(s):",...s.map(e=>` ${(0,o.Gr)(e)}`)],` Sender: ${n}`,` Data: ${t}`,` Callback selector: ${e}`,` Extra data: ${r}`].flat()}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupError"})}};let OffchainLookupResponseMalformedError=class OffchainLookupResponseMalformedError extends s.G{constructor({result:e,url:a}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${(0,o.Gr)(a)}`,`Response: ${(0,n.P)(e)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupResponseMalformedError"})}};let OffchainLookupSenderMismatchError=class OffchainLookupSenderMismatchError extends s.G{constructor({sender:e,to:a}){super("Reverted sender address does not match target contract address (`to`).",{metaMessages:[`Contract address: ${a}`,`OffchainLookup sender address: ${e}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"OffchainLookupSenderMismatchError"})}};var c=t(20722),i=t(49039),f=t(90929),u=t(21485),d=t(87364),l=t(69809),h=t(45008);let p="0x556f1830",w={name:"OffchainLookup",type:"error",inputs:[{name:"sender",type:"address"},{name:"urls",type:"string[]"},{name:"callData",type:"bytes"},{name:"callbackFunction",type:"bytes4"},{name:"extraData",type:"bytes"}]};async function offchainLookup(e,{blockNumber:a,blockTag:t,data:n,to:s}){let{args:o}=(0,i.p)({data:n,abi:[w]}),[c,h,p,m,y]=o;try{if(!function(e,a){if(!(0,d.U)(e))throw new u.b({address:e});if(!(0,d.U)(a))throw new u.b({address:a});return e.toLowerCase()===a.toLowerCase()}(s,c))throw new OffchainLookupSenderMismatchError({sender:c,to:s});let n=await ccipFetch({data:p,sender:c,urls:h}),{data:o}=await (0,r.R)(e,{blockNumber:a,blockTag:t,data:(0,l.zo)([m,(0,f.E)([{type:"bytes"},{type:"bytes"}],[n,y])]),to:s});return o}catch(e){throw new OffchainLookupError({callbackSelector:m,cause:e,data:n,extraData:y,sender:c,urls:h})}}async function ccipFetch({data:e,sender:a,urls:t}){let r=Error("An unknown error occurred.");for(let s=0;s"}),[s,l]=(0,i.k)({name:"AccordionItemContext",hookName:"useAccordionItemContext",providerName:""}),[u,c,d,f]=(0,r.n)(),p=n(58250),h=n(23145),m=n(16465),v=n(57437),g=(0,p.forwardRef)(function(e,t){let{getButtonProps:n}=l(),r=n(e,t),i=a(),o={display:"flex",alignItems:"center",width:"100%",outline:0,...i.button};return(0,v.jsx)(h.chakra.button,{...r,className:(0,m.cx)("chakra-accordion__button",e.className),__css:o})});g.displayName="AccordionButton";var y=n(27771),b=n(45663),x=n(2265);function useAccordion(e){let{onChange:t,defaultIndex:n,index:r,allowMultiple:i,allowToggle:o,...a}=e;(function(e){let t=e.index||e.defaultIndex,n=null!=t&&!Array.isArray(t)&&e.allowMultiple;(0,m.ZK)({condition:!!n,message:`If 'allowMultiple' is passed, then 'index' or 'defaultIndex' must be an array. You passed: ${typeof t},`})})(e),(0,m.ZK)({condition:!!(e.allowMultiple&&e.allowToggle),message:"If 'allowMultiple' is passed, 'allowToggle' will be ignored. Either remove 'allowToggle' or 'allowMultiple' depending on whether you want multiple accordions visible or not"});let s=d(),[l,u]=(0,x.useState)(-1);(0,x.useEffect)(()=>()=>{u(-1)},[]);let[c,f]=(0,y.T)({value:r,defaultValue:()=>i?null!=n?n:[]:null!=n?n:-1,onChange:t});return{index:c,setIndex:f,htmlProps:a,getAccordionItemProps:e=>{let t=!1;return null!==e&&(t=Array.isArray(c)?c.includes(e):c===e),{isOpen:t,onChange:t=>{if(null!==e){if(i&&Array.isArray(c)){let n=t?c.concat(e):c.filter(t=>t!==e);f(n)}else t?f(e):o&&f(-1)}}}},focusedIndex:l,setFocusedIndex:u,descendants:s}}var[w,k]=(0,i.k)({name:"AccordionContext",hookName:"useAccordionContext",providerName:"Accordion"});function useAccordionItem(e){var t;let{isDisabled:n,isFocusable:r,id:i,...o}=e,{getAccordionItemProps:a,setFocusedIndex:s}=k(),l=(0,x.useRef)(null),u=(0,x.useId)(),c=null!=i?i:u,d=`accordion-button-${c}`,p=`accordion-panel-${c}`;(0,m.ZK)({condition:!!(e.isFocusable&&!e.isDisabled),message:`Using only 'isFocusable', this prop is reserved for situations where you pass 'isDisabled' but you still want the element to receive focus (A11y). Either remove it or pass 'isDisabled' as well. + `});let{register:h,index:v,descendants:g}=f({disabled:n&&!r}),{isOpen:y,onChange:w}=a(-1===v?null:v);t={isOpen:y,isDisabled:n},(0,m.ZK)({condition:t.isOpen&&!!t.isDisabled,message:"Cannot open a disabled accordion item"});let S=(0,x.useCallback)(()=>{null==w||w(!y),s(v)},[v,s,y,w]),C=(0,x.useCallback)(e=>{let t={ArrowDown:()=>{let e=g.nextEnabled(v);null==e||e.node.focus()},ArrowUp:()=>{let e=g.prevEnabled(v);null==e||e.node.focus()},Home:()=>{let e=g.firstEnabled();null==e||e.node.focus()},End:()=>{let e=g.lastEnabled();null==e||e.node.focus()}}[e.key];t&&(e.preventDefault(),t(e))},[g,v]),E=(0,x.useCallback)(()=>{s(v)},[s,v]),P=(0,x.useCallback)(function(e={},t=null){return{...e,type:"button",ref:(0,b.lq)(h,l,t),id:d,disabled:!!n,"aria-expanded":!!y,"aria-controls":p,onClick:(0,m.v0)(e.onClick,S),onFocus:(0,m.v0)(e.onFocus,E),onKeyDown:(0,m.v0)(e.onKeyDown,C)}},[d,n,y,S,E,C,p,h]),T=(0,x.useCallback)(function(e={},t=null){return{...e,ref:t,role:"region",id:p,"aria-labelledby":d,hidden:!y}},[d,y,p]);return{isOpen:y,isDisabled:n,isFocusable:r,onOpen:()=>{null==w||w(!0)},onClose:()=>{null==w||w(!1)},getButtonProps:P,getPanelProps:T,htmlProps:o}}var S=n(16248);function AccordionIcon(e){let{isOpen:t,isDisabled:n}=l(),{reduceMotion:r}=k(),i=(0,m.cx)("chakra-accordion__icon",e.className),o=a(),s={opacity:n?.4:1,transform:t?"rotate(-180deg)":void 0,transition:r?void 0:"transform 0.2s",transformOrigin:"center",...o.icon};return(0,v.jsx)(S.J,{viewBox:"0 0 24 24","aria-hidden":!0,className:i,__css:s,...e,children:(0,v.jsx)("path",{fill:"currentColor",d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})})}AccordionIcon.displayName="AccordionIcon";var C=(0,p.forwardRef)(function(e,t){let{children:n,className:r}=e,{htmlProps:i,...o}=useAccordionItem(e),l=a(),u={...l.container,overflowAnchor:"none"},c=(0,x.useMemo)(()=>o,[o]);return(0,v.jsx)(s,{value:c,children:(0,v.jsx)(h.chakra.div,{ref:t,...i,className:(0,m.cx)("chakra-accordion__item",r),__css:u,children:"function"==typeof n?n({isExpanded:!!o.isOpen,isDisabled:!!o.isDisabled}):n})})});C.displayName="AccordionItem";var E=n(43138),P=(0,p.forwardRef)(function(e,t){let{className:n,motionProps:r,...i}=e,{reduceMotion:o}=k(),{getPanelProps:s,isOpen:u}=l(),c=s(i,t),d=(0,m.cx)("chakra-accordion__panel",n),f=a();o||delete c.hidden;let p=(0,v.jsx)(h.chakra.div,{...c,__css:f.panel,className:d});return o?p:(0,v.jsx)(E.U,{in:u,...r,children:p})});P.displayName="AccordionPanel";var T=n(92013),A=n(50446),M=(0,p.forwardRef)(function({children:e,reduceMotion:t,...n},r){let i=(0,T.useMultiStyleConfig)("Accordion",n),a=(0,A.Lr)(n),{htmlProps:s,descendants:l,...c}=useAccordion(a),d=(0,x.useMemo)(()=>({...c,reduceMotion:!!t}),[c,t]);return(0,v.jsx)(u,{value:l,children:(0,v.jsx)(w,{value:d,children:(0,v.jsx)(o,{value:i,children:(0,v.jsx)(h.chakra.div,{ref:r,...s,className:(0,m.cx)("chakra-accordion",n.className),__css:i.root,children:e})})})})});function useAccordionItemState(){let{isOpen:e,isDisabled:t,onClose:n,onOpen:r}=l();return{isOpen:e,onClose:n,isDisabled:t,onOpen:r}}M.displayName="Accordion"},45550:function(e,t,n){"use strict";n.d(t,{b:function(){return c}});var r=n(39337),i=n(16465),o=n(58250),a=n(50446),s=n(92013),l=n(23145),u=n(57437),c=(0,o.forwardRef)(function(e,t){var n;let{status:o="info",addRole:c=!0,...d}=(0,a.Lr)(e),f=null!=(n=e.colorScheme)?n:(0,r.TR)(o),p=(0,s.useMultiStyleConfig)("Alert",{...e,colorScheme:f}),h={width:"100%",display:"flex",alignItems:"center",position:"relative",overflow:"hidden",...p.container};return(0,u.jsx)(r.uZ,{value:{status:o},children:(0,u.jsx)(r.Hm,{value:p,children:(0,u.jsx)(l.chakra.div,{"data-status":o,role:c?"alert":void 0,ref:t,...d,className:(0,i.cx)("chakra-alert",e.className),__css:h})})})});c.displayName="Alert"},25303:function(e,t,n){"use strict";n.d(t,{z:function(){return AlertIcon}});var r=n(39337),i=n(16465),o=n(23145),a=n(57437);function AlertIcon(e){let{status:t}=(0,r.oX)(),n=(0,r.XO)(t),s=(0,r.uL)(),l="loading"===t?s.spinner:s.icon;return(0,a.jsx)(o.chakra.span,{display:"inherit","data-status":t,...e,className:(0,i.cx)("chakra-alert__icon",e.className),__css:l,children:e.children||(0,a.jsx)(n,{h:"100%",w:"100%"})})}AlertIcon.displayName="AlertIcon"},30609:function(e,t,n){"use strict";n.d(t,{X:function(){return l}});var r=n(39337),i=n(16465),o=n(58250),a=n(23145),s=n(57437),l=(0,o.forwardRef)(function(e,t){let n=(0,r.uL)(),{status:o}=(0,r.oX)(),l={display:"inline",...n.description};return(0,s.jsx)(a.chakra.div,{ref:t,"data-status":o,...e,className:(0,i.cx)("chakra-alert__desc",e.className),__css:l})});l.displayName="AlertDescription"},62035:function(e,t,n){"use strict";n.d(t,{C:function(){return l}});var r=n(39337),i=n(16465),o=n(58250),a=n(23145),s=n(57437),l=(0,o.forwardRef)(function(e,t){let n=(0,r.uL)(),{status:o}=(0,r.oX)();return(0,s.jsx)(a.chakra.div,{ref:t,"data-status":o,...e,className:(0,i.cx)("chakra-alert__title",e.className),__css:n.title})});l.displayName="AlertTitle"},39337:function(e,t,n){"use strict";n.d(t,{uZ:function(){return s},Hm:function(){return u},TR:function(){return getStatusColorScheme},XO:function(){return getStatusIcon},oX:function(){return l},uL:function(){return c}});var r=n(16248),i=n(57437);function WarningIcon(e){return(0,i.jsx)(r.J,{viewBox:"0 0 24 24",...e,children:(0,i.jsx)("path",{fill:"currentColor",d:"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z"})})}var o=n(310),a=n(83109),[s,l]=(0,o.k)({name:"AlertContext",hookName:"useAlertContext",providerName:""}),[u,c]=(0,o.k)({name:"AlertStylesContext",hookName:"useAlertStyles",providerName:""}),d={info:{icon:function(e){return(0,i.jsx)(r.J,{viewBox:"0 0 24 24",...e,children:(0,i.jsx)("path",{fill:"currentColor",d:"M12,0A12,12,0,1,0,24,12,12.013,12.013,0,0,0,12,0Zm.25,5a1.5,1.5,0,1,1-1.5,1.5A1.5,1.5,0,0,1,12.25,5ZM14.5,18.5h-4a1,1,0,0,1,0-2h.75a.25.25,0,0,0,.25-.25v-4.5a.25.25,0,0,0-.25-.25H10.5a1,1,0,0,1,0-2h1a2,2,0,0,1,2,2v4.75a.25.25,0,0,0,.25.25h.75a1,1,0,1,1,0,2Z"})})},colorScheme:"blue"},warning:{icon:WarningIcon,colorScheme:"orange"},success:{icon:function(e){return(0,i.jsx)(r.J,{viewBox:"0 0 24 24",...e,children:(0,i.jsx)("path",{fill:"currentColor",d:"M12,0A12,12,0,1,0,24,12,12.014,12.014,0,0,0,12,0Zm6.927,8.2-6.845,9.289a1.011,1.011,0,0,1-1.43.188L5.764,13.769a1,1,0,1,1,1.25-1.562l4.076,3.261,6.227-8.451A1,1,0,1,1,18.927,8.2Z"})})},colorScheme:"green"},error:{icon:WarningIcon,colorScheme:"red"},loading:{icon:a.$,colorScheme:"blue"}};function getStatusColorScheme(e){return d[e].colorScheme}function getStatusIcon(e){return d[e].icon}},1410:function(e,t,n){"use strict";n.r(t),n.d(t,{Alert:function(){return a.b},AlertDescription:function(){return r.X},AlertIcon:function(){return i.z},AlertTitle:function(){return o.C},useAlertStyles:function(){return s.uL}});var r=n(30609),i=n(25303),o=n(62035),a=n(45550),s=n(39337)},82999:function(e,t,n){"use strict";n.r(t),n.d(t,{Avatar:function(){return v},AvatarBadge:function(){return c},AvatarGroup:function(){return y},GenericAvatarIcon:function(){return GenericAvatarIcon},useAvatarStyles:function(){return i}});var[r,i]=(0,n(310).k)({name:"AvatarStylesContext",hookName:"useAvatarStyles",providerName:""}),o=n(58250),a=n(23145),s=n(16465),l=n(57437),u={"top-start":{top:"0",insetStart:"0",transform:"translate(-25%, -25%)"},"top-end":{top:"0",insetEnd:"0",transform:"translate(25%, -25%)"},"bottom-start":{bottom:"0",insetStart:"0",transform:"translate(-25%, 25%)"},"bottom-end":{bottom:"0",insetEnd:"0",transform:"translate(25%, 25%)"}},c=(0,o.forwardRef)(function(e,t){let{placement:n="bottom-end",className:r,...o}=e,c=i(),d=u[n],f={position:"absolute",display:"flex",alignItems:"center",justifyContent:"center",...d,...c.badge};return(0,l.jsx)(a.chakra.div,{ref:t,...o,className:(0,s.cx)("chakra-avatar__badge",r),__css:f})});function initials(e){var t;let n=e.split(" "),r=null!=(t=n[0])?t:"",i=n.length>1?n[n.length-1]:"";return r&&i?`${r.charAt(0)}${i.charAt(0)}`:r.charAt(0)}function AvatarName(e){let{name:t,getInitials:n,...r}=e,o=i();return(0,l.jsx)(a.chakra.div,{role:"img","aria-label":t,...r,__css:o.label,children:t?null==n?void 0:n(t):null})}c.displayName="AvatarBadge",AvatarName.displayName="AvatarName";var GenericAvatarIcon=e=>(0,l.jsxs)(a.chakra.svg,{viewBox:"0 0 128 128",color:"#fff",width:"100%",height:"100%",className:"chakra-avatar__svg",...e,children:[(0,l.jsx)("path",{fill:"currentColor",d:"M103,102.1388 C93.094,111.92 79.3504,118 64.1638,118 C48.8056,118 34.9294,111.768 25,101.7892 L25,95.2 C25,86.8096 31.981,80 40.6,80 L87.4,80 C96.019,80 103,86.8096 103,95.2 L103,102.1388 Z"}),(0,l.jsx)("path",{fill:"currentColor",d:"M63.9961647,24 C51.2938136,24 41,34.2938136 41,46.9961647 C41,59.7061864 51.2938136,70 63.9961647,70 C76.6985159,70 87,59.7061864 87,46.9961647 C87,34.2938136 76.6985159,24 63.9961647,24"})]}),d=n(21366),f=n(2265);function AvatarImage(e){let{src:t,srcSet:n,onError:r,onLoad:i,getInitials:o,name:s,borderRadius:u,loading:c,iconLabel:p,icon:h=(0,l.jsx)(GenericAvatarIcon,{}),ignoreFallback:m,referrerPolicy:v,crossOrigin:g}=e,y=(0,d.d)({src:t,onError:r,crossOrigin:g,ignoreFallback:m}),b=!t||"loaded"!==y;return b?s?(0,l.jsx)(AvatarName,{className:"chakra-avatar__initials",getInitials:o,name:s}):(0,f.cloneElement)(h,{role:"img","aria-label":p}):(0,l.jsx)(a.chakra.img,{src:t,srcSet:n,alt:s,onLoad:i,referrerPolicy:v,crossOrigin:null!=g?g:void 0,className:"chakra-avatar__img",loading:c,__css:{width:"100%",height:"100%",objectFit:"cover",borderRadius:u}})}AvatarImage.displayName="AvatarImage";var p=n(92013),h=n(50446),m={display:"inline-flex",alignItems:"center",justifyContent:"center",textAlign:"center",textTransform:"uppercase",fontWeight:"medium",position:"relative",flexShrink:0},v=(0,o.forwardRef)((e,t)=>{let n=(0,p.useMultiStyleConfig)("Avatar",e),[i,o]=(0,f.useState)(!1),{src:u,srcSet:c,name:d,showBorder:v,borderRadius:g="full",onError:y,onLoad:b,getInitials:x=initials,icon:w=(0,l.jsx)(GenericAvatarIcon,{}),iconLabel:k=" avatar",loading:S,children:C,borderColor:E,ignoreFallback:P,crossOrigin:T,referrerPolicy:A,...M}=(0,h.Lr)(e),_={borderRadius:g,borderWidth:v?"2px":void 0,...m,...n.container};return E&&(_.borderColor=E),(0,l.jsx)(a.chakra.span,{ref:t,...M,className:(0,s.cx)("chakra-avatar",e.className),"data-loaded":(0,s.PB)(i),__css:_,children:(0,l.jsxs)(r,{value:n,children:[(0,l.jsx)(AvatarImage,{src:u,srcSet:c,loading:S,onLoad:(0,s.v0)(b,()=>{o(!0)}),onError:y,getInitials:x,name:d,borderRadius:g,icon:w,iconLabel:k,ignoreFallback:P,crossOrigin:T,referrerPolicy:A}),C]})})});v.displayName="Avatar";var g=n(61158),y=(0,o.forwardRef)(function(e,t){let n=(0,p.useMultiStyleConfig)("Avatar",e),{children:r,borderColor:i,max:o,spacing:u="-0.75rem",borderRadius:c="full",...d}=(0,h.Lr)(e),v=(0,g.W)(r),y=null!=o?v.slice(0,o):v,b=null!=o?v.length-o:0,x=y.reverse(),w=x.map((t,n)=>{var r;let o={marginEnd:0===n?0:u,size:e.size,borderColor:null!=(r=t.props.borderColor)?r:i,showBorder:!0};return(0,f.cloneElement)(t,function(e){let t=Object.assign({},e);for(let e in t)void 0===t[e]&&delete t[e];return t}(o))}),k={display:"flex",alignItems:"center",justifyContent:"flex-end",flexDirection:"row-reverse",...n.group},S={borderRadius:c,marginStart:u,...m,...n.excessLabel};return(0,l.jsxs)(a.chakra.div,{ref:t,role:"group",__css:k,...d,className:(0,s.cx)("chakra-avatar__group",e.className),children:[b>0&&(0,l.jsx)(a.chakra.span,{className:"chakra-avatar__excess",__css:S,children:`+${b}`}),w]})});y.displayName="AvatarGroup"},46242:function(e,t,n){"use strict";n.r(t),n.d(t,{Breadcrumb:function(){return v},BreadcrumbItem:function(){return p},BreadcrumbLink:function(){return u},BreadcrumbSeparator:function(){return c},useBreadcrumbStyles:function(){return i}});var[r,i]=(0,n(310).k)({name:"BreadcrumbStylesContext",errorMessage:"useBreadcrumbStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),o=n(58250),a=n(23145),s=n(16465),l=n(57437),u=(0,o.forwardRef)(function(e,t){let{isCurrentPage:n,as:r,className:o,href:u,...c}=e,d=i(),f={ref:t,as:r,className:(0,s.cx)("chakra-breadcrumb__link",o),...c};return n?(0,l.jsx)(a.chakra.span,{"aria-current":"page",__css:d.link,...f}):(0,l.jsx)(a.chakra.a,{__css:d.link,href:u,...f})});u.displayName="BreadcrumbLink";var c=(0,o.forwardRef)(function(e,t){let{spacing:n,...r}=e,o=i(),s={mx:n,...o.separator};return(0,l.jsx)(a.chakra.span,{ref:t,role:"presentation",...r,__css:s})});c.displayName="BreadcrumbSeparator";var d=n(61158),f=n(2265),p=(0,o.forwardRef)(function(e,t){let{isCurrentPage:n,separator:r,isLastChild:o,spacing:p,children:h,className:m,...v}=e,g=(0,d.W)(h),y=g.map(e=>e.type===u?(0,f.cloneElement)(e,{isCurrentPage:n}):e.type===c?(0,f.cloneElement)(e,{spacing:p,children:e.props.children||r}):e),b=i(),x={display:"inline-flex",alignItems:"center",...b.item},w=(0,s.cx)("chakra-breadcrumb__list-item",m);return(0,l.jsxs)(a.chakra.li,{ref:t,className:w,...v,__css:x,children:[y,!o&&(0,l.jsx)(c,{spacing:p,children:r})]})});p.displayName="BreadcrumbItem";var h=n(92013),m=n(50446),v=(0,o.forwardRef)(function(e,t){let n=(0,h.useMultiStyleConfig)("Breadcrumb",e),i=(0,m.Lr)(e),{children:o,spacing:u="0.5rem",separator:c="/",className:p,listProps:v,...g}=i,y=(0,d.W)(o),b=y.length,x=y.map((e,t)=>(0,f.cloneElement)(e,{separator:c,spacing:u,isLastChild:b===t+1})),w=(0,s.cx)("chakra-breadcrumb",p);return(0,l.jsx)(a.chakra.nav,{ref:t,"aria-label":"breadcrumb",className:w,__css:n.container,...g,children:(0,l.jsx)(r,{value:n,children:(0,l.jsx)(a.chakra.ol,{className:"chakra-breadcrumb__list",...v,__css:{display:"flex",alignItems:"center",...n.list},children:x})})})});v.displayName="Breadcrumb"},71369:function(e,t,n){"use strict";n.d(t,{AV:function(){return i},XQ:function(){return mapResponsive},Yq:function(){return arrayToObjectNotation}});var r=n(16465),i=Object.freeze(["base","sm","md","lg","xl","2xl"]);function mapResponsive(e,t){return Array.isArray(e)?e.map(e=>null===e?null:t(e)):(0,r.Kn)(e)?Object.keys(e).reduce((n,r)=>(n[r]=t(e[r]),n),{}):null!=e?t(e):null}function arrayToObjectNotation(e,t=i){let n={};return e.forEach((e,r)=>{let i=t[r];null!=e&&(n[i]=e)}),n}},68083:function(e,t,n){"use strict";n.r(t),n.d(t,{Button:function(){return f.z},ButtonGroup:function(){return d},ButtonSpinner:function(){return h.X},IconButton:function(){return p},useButtonGroup:function(){return r.i}});var r=n(56663),i=n(58250),o=n(23145),a=n(16465),s=n(2265),l=n(57437),u={horizontal:{"> *:first-of-type:not(:last-of-type)":{borderEndRadius:0},"> *:not(:first-of-type):not(:last-of-type)":{borderRadius:0},"> *:not(:first-of-type):last-of-type":{borderStartRadius:0}},vertical:{"> *:first-of-type:not(:last-of-type)":{borderBottomRadius:0},"> *:not(:first-of-type):not(:last-of-type)":{borderRadius:0},"> *:not(:first-of-type):last-of-type":{borderTopRadius:0}}},c={horizontal:e=>({"& > *:not(style) ~ *:not(style)":{marginStart:e}}),vertical:e=>({"& > *:not(style) ~ *:not(style)":{marginTop:e}})},d=(0,i.forwardRef)(function(e,t){let{size:n,colorScheme:i,variant:d,className:f,spacing:p="0.5rem",isAttached:h,isDisabled:m,orientation:v="horizontal",...g}=e,y=(0,a.cx)("chakra-button__group",f),b=(0,s.useMemo)(()=>({size:n,colorScheme:i,variant:d,isDisabled:m}),[n,i,d,m]),x={display:"inline-flex",...h?u[v]:c[v](p)};return(0,l.jsx)(r.D,{value:b,children:(0,l.jsx)(o.chakra.div,{ref:t,role:"group",__css:x,className:y,"data-attached":h?"":void 0,"data-orientation":v,flexDir:"vertical"===v?"column":void 0,...g})})});d.displayName="ButtonGroup";var f=n(48433),p=(0,i.forwardRef)((e,t)=>{let{icon:n,children:r,isRound:i,"aria-label":o,...a}=e,u=n||r,c=(0,s.isValidElement)(u)?(0,s.cloneElement)(u,{"aria-hidden":!0,focusable:!1}):null;return(0,l.jsx)(f.z,{padding:"0",borderRadius:i?"full":void 0,ref:t,"aria-label":o,...a,children:c})});p.displayName="IconButton";var h=n(35279)},36359:function(e,t,n){"use strict";n.r(t),n.d(t,{Card:function(){return h},CardBody:function(){return u},CardFooter:function(){return c},CardHeader:function(){return d},useCardStyles:function(){return i}});var[r,i]=(0,n(33962).createStylesContext)("Card"),o=n(16465),a=n(58250),s=n(23145),l=n(57437),u=(0,a.forwardRef)(function(e,t){let{className:n,...r}=e,a=i();return(0,l.jsx)(s.chakra.div,{ref:t,className:(0,o.cx)("chakra-card__body",n),__css:a.body,...r})}),c=(0,a.forwardRef)(function(e,t){let{className:n,justify:r,...a}=e,u=i();return(0,l.jsx)(s.chakra.div,{ref:t,className:(0,o.cx)("chakra-card__footer",n),__css:{display:"flex",justifyContent:r,...u.footer},...a})}),d=(0,a.forwardRef)(function(e,t){let{className:n,...r}=e,a=i();return(0,l.jsx)(s.chakra.div,{ref:t,className:(0,o.cx)("chakra-card__header",n),__css:a.header,...r})}),f=n(50446),p=n(92013),h=(0,a.forwardRef)(function(e,t){let{className:n,children:i,direction:a="column",justify:u,align:c,...d}=(0,f.Lr)(e),h=(0,p.useMultiStyleConfig)("Card",e);return(0,l.jsx)(s.chakra.div,{ref:t,className:(0,o.cx)("chakra-card",n),__css:{display:"flex",flexDirection:a,justifyContent:u,alignItems:c,position:"relative",minWidth:0,wordWrap:"break-word",...h.container},...d,children:(0,l.jsx)(r,{value:h,children:i})})})},6816:function(e,t,n){"use strict";n.d(t,{O:function(){return useCheckbox}});var r=n(75992),i=n(67673),o=n(89656),a=n(37977),s=n(45663),l=n(16465),u=n(14954),c=n(29522),d=n(2265);function useCheckbox(e={}){let t=(0,r.K)(e),{isDisabled:n,isReadOnly:f,isRequired:p,isInvalid:h,id:m,onBlur:v,onFocus:g,"aria-describedby":y}=t,{defaultChecked:b,isChecked:x,isFocusable:w,onChange:k,isIndeterminate:S,name:C,value:E,tabIndex:P,"aria-label":T,"aria-labelledby":A,"aria-invalid":M,..._}=e,N=function(e,t=[]){let n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}(_,["isDisabled","isReadOnly","isRequired","isInvalid","id","onBlur","onFocus","aria-describedby"]),R=(0,a.W)(k),D=(0,a.W)(v),I=(0,a.W)(g),[j,L]=(0,d.useState)(!1),[O,F]=(0,d.useState)(!1),[V,B]=(0,d.useState)(!1),[W,$]=(0,d.useState)(!1);(0,d.useEffect)(()=>(0,c.BT)(L),[]);let U=(0,d.useRef)(null),[H,z]=(0,d.useState)(!0),[G,q]=(0,d.useState)(!!b),K=void 0!==x,X=K?x:G,Z=(0,d.useCallback)(e=>{if(f||n){e.preventDefault();return}K||(X?q(e.target.checked):q(!!S||e.target.checked)),null==R||R(e)},[f,n,X,K,S,R]);(0,i.G)(()=>{U.current&&(U.current.indeterminate=!!S)},[S]),(0,o.r)(()=>{n&&F(!1)},[n,F]),(0,i.G)(()=>{let e=U.current;if(!(null==e?void 0:e.form))return;let formResetListener=()=>{q(!!b)};return e.form.addEventListener("reset",formResetListener),()=>{var t;return null==(t=e.form)?void 0:t.removeEventListener("reset",formResetListener)}},[]);let Y=n&&!w,Q=(0,d.useCallback)(e=>{" "===e.key&&$(!0)},[$]),J=(0,d.useCallback)(e=>{" "===e.key&&$(!1)},[$]);(0,i.G)(()=>{if(!U.current)return;let e=U.current.checked!==X;e&&q(U.current.checked)},[U.current]);let ee=(0,d.useCallback)((e={},t=null)=>({...e,ref:t,"data-active":(0,l.PB)(W),"data-hover":(0,l.PB)(V),"data-checked":(0,l.PB)(X),"data-focus":(0,l.PB)(O),"data-focus-visible":(0,l.PB)(O&&j),"data-indeterminate":(0,l.PB)(S),"data-disabled":(0,l.PB)(n),"data-invalid":(0,l.PB)(h),"data-readonly":(0,l.PB)(f),"aria-hidden":!0,onMouseDown:(0,l.v0)(e.onMouseDown,e=>{O&&e.preventDefault(),$(!0)}),onMouseUp:(0,l.v0)(e.onMouseUp,()=>$(!1)),onMouseEnter:(0,l.v0)(e.onMouseEnter,()=>B(!0)),onMouseLeave:(0,l.v0)(e.onMouseLeave,()=>B(!1))}),[W,X,n,O,j,V,S,h,f]),et=(0,d.useCallback)((e={},t=null)=>({...e,ref:t,"data-active":(0,l.PB)(W),"data-hover":(0,l.PB)(V),"data-checked":(0,l.PB)(X),"data-focus":(0,l.PB)(O),"data-focus-visible":(0,l.PB)(O&&j),"data-indeterminate":(0,l.PB)(S),"data-disabled":(0,l.PB)(n),"data-invalid":(0,l.PB)(h),"data-readonly":(0,l.PB)(f)}),[W,X,n,O,j,V,S,h,f]),en=(0,d.useCallback)((e={},t=null)=>({...N,...e,ref:(0,s.lq)(t,e=>{e&&z("LABEL"===e.tagName)}),onClick:(0,l.v0)(e.onClick,()=>{var e;H||(null==(e=U.current)||e.click(),requestAnimationFrame(()=>{var e;null==(e=U.current)||e.focus({preventScroll:!0})}))}),"data-disabled":(0,l.PB)(n),"data-checked":(0,l.PB)(X),"data-invalid":(0,l.PB)(h)}),[N,n,X,h,H]),er=(0,d.useCallback)((e={},t=null)=>({...e,ref:(0,s.lq)(U,t),type:"checkbox",name:C,value:E,id:m,tabIndex:P,onChange:(0,l.v0)(e.onChange,Z),onBlur:(0,l.v0)(e.onBlur,D,()=>F(!1)),onFocus:(0,l.v0)(e.onFocus,I,()=>F(!0)),onKeyDown:(0,l.v0)(e.onKeyDown,Q),onKeyUp:(0,l.v0)(e.onKeyUp,J),required:p,checked:X,disabled:Y,readOnly:f,"aria-label":T,"aria-labelledby":A,"aria-invalid":M?!!M:h,"aria-describedby":y,"aria-disabled":n,style:u.N}),[C,E,m,Z,D,I,Q,J,p,X,Y,f,T,A,M,h,y,n,P]),ei=(0,d.useCallback)((e={},t=null)=>({...e,ref:t,onMouseDown:(0,l.v0)(e.onMouseDown,stopEvent),"data-disabled":(0,l.PB)(n),"data-checked":(0,l.PB)(X),"data-invalid":(0,l.PB)(h)}),[X,n,h]);return{state:{isInvalid:h,isFocused:O,isChecked:X,isActive:W,isHovered:V,isIndeterminate:S,isDisabled:n,isReadOnly:f,isRequired:p},getRootProps:en,getCheckboxProps:ee,getIndicatorProps:et,getInputProps:er,getLabelProps:ei,htmlProps:N}}function stopEvent(e){e.preventDefault(),e.stopPropagation()}},57243:function(e,t,n){"use strict";n.r(t),n.d(t,{Checkbox:function(){return w},CheckboxGroup:function(){return CheckboxGroup},CheckboxIcon:function(){return CheckboxIcon},useCheckbox:function(){return d.O},useCheckboxGroup:function(){return useCheckboxGroup}});var[r,i]=(0,n(310).k)({name:"CheckboxGroupContext",strict:!1}),o=n(37977),a=n(27771),s=n(16465),l=n(2265);function isInputEvent(e){return e&&(0,s.Kn)(e)&&(0,s.Kn)(e.target)}function useCheckboxGroup(e={}){let{defaultValue:t,value:n,onChange:r,isDisabled:i,isNative:s}=e,u=(0,o.W)(r),[c,d]=(0,a.T)({value:n,defaultValue:t||[],onChange:u}),f=(0,l.useCallback)(e=>{if(!c)return;let t=isInputEvent(e)?e.target.checked:!c.includes(e),n=isInputEvent(e)?e.target.value:e,r=t?[...c,n]:c.filter(e=>String(e)!==String(n));d(r)},[d,c]),p=(0,l.useCallback)((e={})=>{let t=s?"checked":"isChecked";return{...e,[t]:c.some(t=>String(e.value)===String(t)),onChange:f}},[f,s,c]);return{value:c,isDisabled:i,onChange:f,setValue:d,getCheckboxProps:p}}var u=n(57437);function CheckboxGroup(e){let{colorScheme:t,size:n,variant:i,children:o,isDisabled:a}=e,{value:s,onChange:c}=useCheckboxGroup(e),d=(0,l.useMemo)(()=>({size:n,onChange:c,colorScheme:t,value:s,variant:i,isDisabled:a}),[n,c,t,s,i,a]);return(0,u.jsx)(r,{value:d,children:o})}CheckboxGroup.displayName="CheckboxGroup";var c=n(23145);function CheckIcon(e){return(0,u.jsx)(c.chakra.svg,{width:"1.2em",viewBox:"0 0 12 10",style:{fill:"none",strokeWidth:2,stroke:"currentColor",strokeDasharray:16},...e,children:(0,u.jsx)("polyline",{points:"1.5 6 4.5 9 10.5 1"})})}function IndeterminateIcon(e){return(0,u.jsx)(c.chakra.svg,{width:"1.2em",viewBox:"0 0 24 24",style:{stroke:"currentColor",strokeWidth:4},...e,children:(0,u.jsx)("line",{x1:"21",x2:"3",y1:"12",y2:"12"})})}function CheckboxIcon(e){let{isIndeterminate:t,isChecked:n,...r}=e,i=t?IndeterminateIcon:CheckIcon;return n||t?(0,u.jsx)(c.chakra.div,{style:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%"},children:(0,u.jsx)(i,{...r})}):null}var d=n(6816),f=n(99538),p=n(58250),h=n(92013),m=n(50446),v={display:"inline-flex",alignItems:"center",justifyContent:"center",verticalAlign:"top",userSelect:"none",flexShrink:0},g={cursor:"pointer",display:"inline-flex",alignItems:"center",verticalAlign:"top",position:"relative"},y=(0,f.F4)({from:{opacity:0,strokeDashoffset:16,transform:"scale(0.95)"},to:{opacity:1,strokeDashoffset:0,transform:"scale(1)"}}),b=(0,f.F4)({from:{opacity:0},to:{opacity:1}}),x=(0,f.F4)({from:{transform:"scaleX(0.65)"},to:{transform:"scaleX(1)"}}),w=(0,p.forwardRef)(function(e,t){let n=i(),r={...n,...e},o=(0,h.useMultiStyleConfig)("Checkbox",r),a=(0,m.Lr)(e),{spacing:f="0.5rem",className:p,children:w,iconColor:k,iconSize:S,icon:C=(0,u.jsx)(CheckboxIcon,{}),isChecked:E,isDisabled:P=null==n?void 0:n.isDisabled,onChange:T,inputProps:A,...M}=a,_=E;(null==n?void 0:n.value)&&a.value&&(_=n.value.includes(a.value));let N=T;(null==n?void 0:n.onChange)&&a.value&&(N=(0,s.PP)(n.onChange,T));let{state:R,getInputProps:D,getCheckboxProps:I,getLabelProps:j,getRootProps:L}=(0,d.O)({...M,isDisabled:P,isChecked:_,onChange:N}),O=function(e){let[t,n]=(0,l.useState)(e),[r,i]=(0,l.useState)(!1);return e!==t&&(i(!0),n(e)),r}(R.isChecked),F=(0,l.useMemo)(()=>({animation:O?R.isIndeterminate?`${b} 20ms linear, ${x} 200ms linear`:`${y} 200ms linear`:void 0,fontSize:S,color:k,...o.icon}),[k,S,O,R.isIndeterminate,o.icon]),V=(0,l.cloneElement)(C,{__css:F,isIndeterminate:R.isIndeterminate,isChecked:R.isChecked});return(0,u.jsxs)(c.chakra.label,{__css:{...g,...o.container},className:(0,s.cx)("chakra-checkbox",p),...L(),children:[(0,u.jsx)("input",{className:"chakra-checkbox__input",...D(A,t)}),(0,u.jsx)(c.chakra.span,{__css:{...v,...o.control},className:"chakra-checkbox__control",...I(),children:V}),w&&(0,u.jsx)(c.chakra.span,{className:"chakra-checkbox__label",...j(),__css:{marginStart:f,...o.label},children:w})]})});w.displayName="Checkbox"},13079:function(e,t,n){"use strict";n.d(t,{h:function(){return useClickable}});var r=n(2265),i=n(16465),o=n(45663);function isValidElement(e){let t=e.target,{tagName:n,isContentEditable:r}=t;return"INPUT"!==n&&"TEXTAREA"!==n&&!0!==r}function useClickable(e={}){let{ref:t,isDisabled:n,isFocusable:a,clickOnEnter:s=!0,clickOnSpace:l=!0,onMouseDown:u,onMouseUp:c,onClick:d,onKeyDown:f,onKeyUp:p,tabIndex:h,onMouseOver:m,onMouseLeave:v,...g}=e,[y,b]=(0,r.useState)(!0),[x,w]=(0,r.useState)(!1),k=function(){let e=(0,r.useRef)(new Map),t=e.current,n=(0,r.useCallback)((t,n,r,i)=>{e.current.set(r,{type:n,el:t,options:i}),t.addEventListener(n,r,i)},[]),i=(0,r.useCallback)((t,n,r,i)=>{t.removeEventListener(n,r,i),e.current.delete(r)},[]);return(0,r.useEffect)(()=>()=>{t.forEach((e,t)=>{i(e.el,e.type,t,e.options)})},[i,t]),{add:n,remove:i}}(),S=y?h:h||0,C=n&&!a,E=(0,r.useCallback)(e=>{if(n){e.stopPropagation(),e.preventDefault();return}let t=e.currentTarget;t.focus(),null==d||d(e)},[n,d]),P=(0,r.useCallback)(e=>{x&&isValidElement(e)&&(e.preventDefault(),e.stopPropagation(),w(!1),k.remove(document,"keyup",P,!1))},[x,k]),T=(0,r.useCallback)(e=>{if(null==f||f(e),n||e.defaultPrevented||e.metaKey||!isValidElement(e.nativeEvent)||y)return;let t=s&&"Enter"===e.key,r=l&&" "===e.key;if(r&&(e.preventDefault(),w(!0)),t){e.preventDefault();let t=e.currentTarget;t.click()}k.add(document,"keyup",P,!1)},[n,y,f,s,l,k,P]),A=(0,r.useCallback)(e=>{if(null==p||p(e),n||e.defaultPrevented||e.metaKey||!isValidElement(e.nativeEvent)||y)return;let t=l&&" "===e.key;if(t){e.preventDefault(),w(!1);let t=e.currentTarget;t.click()}},[l,y,n,p]),M=(0,r.useCallback)(e=>{0===e.button&&(w(!1),k.remove(document,"mouseup",M,!1))},[k]),_=(0,r.useCallback)(e=>{if(0!==e.button)return;if(n){e.stopPropagation(),e.preventDefault();return}y||w(!0);let t=e.currentTarget;t.focus({preventScroll:!0}),k.add(document,"mouseup",M,!1),null==u||u(e)},[n,y,u,k,M]),N=(0,r.useCallback)(e=>{0===e.button&&(y||w(!1),null==c||c(e))},[c,y]),R=(0,r.useCallback)(e=>{if(n){e.preventDefault();return}null==m||m(e)},[n,m]),D=(0,r.useCallback)(e=>{x&&(e.preventDefault(),w(!1)),null==v||v(e)},[x,v]),I=(0,o.lq)(t,e=>{e&&"BUTTON"!==e.tagName&&b(!1)});return y?{...g,ref:I,type:"button","aria-disabled":C?void 0:n,disabled:C,onClick:E,onMouseDown:u,onMouseUp:c,onKeyUp:p,onKeyDown:f,onMouseOver:m,onMouseLeave:v}:{...g,ref:I,role:"button","data-active":(0,i.PB)(x),"aria-disabled":n?"true":void 0,tabIndex:C?void 0:S,onClick:E,onMouseDown:_,onMouseUp:N,onKeyUp:A,onKeyDown:T,onMouseOver:R,onMouseLeave:D}}},96231:function(e,t,n){"use strict";n.d(t,{P:function(){return u}});var r=n(16248),i=n(58250),o=n(92013),a=n(50446),s=n(23145),l=n(57437);function CloseIcon(e){return(0,l.jsx)(r.J,{focusable:"false","aria-hidden":!0,...e,children:(0,l.jsx)("path",{fill:"currentColor",d:"M.439,21.44a1.5,1.5,0,0,0,2.122,2.121L11.823,14.3a.25.25,0,0,1,.354,0l9.262,9.263a1.5,1.5,0,1,0,2.122-2.121L14.3,12.177a.25.25,0,0,1,0-.354l9.263-9.262A1.5,1.5,0,0,0,21.439.44L12.177,9.7a.25.25,0,0,1-.354,0L2.561.44A1.5,1.5,0,0,0,.439,2.561L9.7,11.823a.25.25,0,0,1,0,.354Z"})})}var u=(0,i.forwardRef)(function(e,t){let n=(0,o.useStyleConfig)("CloseButton",e),{children:r,isDisabled:i,__css:u,...c}=(0,a.Lr)(e);return(0,l.jsx)(s.chakra.button,{type:"button","aria-label":"Close",ref:t,disabled:i,__css:{outline:0,display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0,...n,...u},...c,children:r||(0,l.jsx)(CloseIcon,{width:"1em",height:"1em"})})});u.displayName="CloseButton"},67090:function(e,t,n){"use strict";n.r(t),n.d(t,{CloseButton:function(){return r.P}});var r=n(96231)},50851:function(e,t,n){"use strict";n.d(t,{O2:function(){return createCookieStorageManager},Ty:function(){return cookieStorageManagerSSR},aN:function(){return i},rr:function(){return createLocalStorageManager},sb:function(){return o}});var r="chakra-ui-color-mode";function createLocalStorageManager(e){return{ssr:!1,type:"localStorage",get(t){let n;if(!(null==globalThis?void 0:globalThis.document))return t;try{n=localStorage.getItem(e)||t}catch(e){}return n||t},set(t){try{localStorage.setItem(e,t)}catch(e){}}}}var i=createLocalStorageManager(r);function parseCookie(e,t){let n=e.match(RegExp(`(^| )${t}=([^;]+)`));return null==n?void 0:n[2]}function createCookieStorageManager(e,t){return{ssr:!!t,type:"cookie",get:n=>t?parseCookie(t,e):(null==globalThis?void 0:globalThis.document)&&parseCookie(document.cookie,e)||n,set(t){document.cookie=`${e}=${t}; max-age=31536000; path=/`}}}var o=createCookieStorageManager(r),cookieStorageManagerSSR=e=>createCookieStorageManager(r,e)},1051:function(e,t,n){"use strict";n.d(t,{SG:function(){return ColorModeProvider},t7:function(){return DarkMode},iJ:function(){return LightMode}});var r=n(85035),i={light:"chakra-ui-light",dark:"chakra-ui-dark"},o=n(50851),a=n(67673),s=n(2265),l=n(57437),noop=()=>{};function getTheme(e,t){return"cookie"===e.type&&e.ssr?e.get(t):t}function ColorModeProvider(e){let{value:t,children:n,options:{useSystemColorMode:u,initialColorMode:c,disableTransitionOnChange:d}={},colorModeManager:f=o.aN}=e,p="dark"===c?"dark":"light",[h,m]=(0,s.useState)(()=>getTheme(f,p)),[v,g]=(0,s.useState)(()=>getTheme(f)),{getSystemTheme:y,setClassName:b,setDataset:x,addListener:w}=(0,s.useMemo)(()=>(function(e={}){let{preventTransition:t=!0}=e,n={setDataset:e=>{let r=t?n.preventTransition():void 0;document.documentElement.dataset.theme=e,document.documentElement.style.colorScheme=e,null==r||r()},setClassName(e){document.body.classList.add(e?i.dark:i.light),document.body.classList.remove(e?i.light:i.dark)},query:()=>window.matchMedia("(prefers-color-scheme: dark)"),getSystemTheme(e){var t;let r=null!=(t=n.query().matches)?t:"dark"===e;return r?"dark":"light"},addListener(e){let t=n.query(),listener=t=>{e(t.matches?"dark":"light")};return"function"==typeof t.addListener?t.addListener(listener):t.addEventListener("change",listener),()=>{"function"==typeof t.removeListener?t.removeListener(listener):t.removeEventListener("change",listener)}},preventTransition(){let e=document.createElement("style");return e.appendChild(document.createTextNode("*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")),document.head.appendChild(e),()=>{window.getComputedStyle(document.body),requestAnimationFrame(()=>{requestAnimationFrame(()=>{document.head.removeChild(e)})})}}};return n})({preventTransition:d}),[d]),k="system"!==c||h?h:v,S=(0,s.useCallback)(e=>{let t="system"===e?y():e;m(t),b("dark"===t),x(t),f.set(t)},[f,y,b,x]);(0,a.G)(()=>{"system"===c&&g(y())},[]),(0,s.useEffect)(()=>{let e=f.get();if(e){S(e);return}if("system"===c){S("system");return}S(p)},[f,p,c,S]);let C=(0,s.useCallback)(()=>{S("dark"===k?"light":"dark")},[k,S]);(0,s.useEffect)(()=>{if(u)return w(S)},[u,w,S]);let E=(0,s.useMemo)(()=>({colorMode:null!=t?t:k,toggleColorMode:t?noop:C,setColorMode:t?noop:S,forced:void 0!==t}),[k,C,S,t]);return(0,l.jsx)(r.kc.Provider,{value:E,children:n})}function DarkMode(e){let t=(0,s.useMemo)(()=>({colorMode:"dark",toggleColorMode:noop,setColorMode:noop,forced:!0}),[]);return(0,l.jsx)(r.kc.Provider,{value:t,...e})}function LightMode(e){let t=(0,s.useMemo)(()=>({colorMode:"light",toggleColorMode:noop,setColorMode:noop,forced:!0}),[]);return(0,l.jsx)(r.kc.Provider,{value:t,...e})}ColorModeProvider.displayName="ColorModeProvider",DarkMode.displayName="DarkMode",LightMode.displayName="LightMode"},64414:function(e,t,n){"use strict";n.r(t),n.d(t,{ColorModeContext:function(){return i.kc},ColorModeProvider:function(){return r.SG},ColorModeScript:function(){return ColorModeScript},DarkMode:function(){return r.t7},LightMode:function(){return r.iJ},cookieStorageManager:function(){return s.sb},cookieStorageManagerSSR:function(){return s.Ty},createCookieStorageManager:function(){return s.O2},createLocalStorageManager:function(){return s.rr},getScriptSrc:function(){return getScriptSrc},localStorageManager:function(){return s.aN},useColorMode:function(){return i.If},useColorModeValue:function(){return i.ff}});var r=n(1051),i=n(85035),o=n(57437),a=new Set(["dark","light","system"]);function getScriptSrc(e={}){let t;let{initialColorMode:n="light",type:r="localStorage",storageKey:i="chakra-ui-color-mode"}=e,o=(t=n,a.has(t)||(t="light"),t),s=`(function(){try{var a=function(o){var l="(prefers-color-scheme: dark)",v=window.matchMedia(l).matches?"dark":"light",e=o==="system"?v:o,d=document.documentElement,m=document.body,i="chakra-ui-light",n="chakra-ui-dark",s=e==="dark";return m.classList.add(s?n:i),m.classList.remove(s?i:n),d.style.colorScheme=e,d.dataset.theme=e,e},u=a,h="${o}",r="${i}",t=document.cookie.match(new RegExp("(^| )".concat(r,"=([^;]+)"))),c=t?t[2]:null;c?a(c):document.cookie="".concat(r,"=").concat(a(h),"; max-age=31536000; path=/")}catch(a){}})(); + `,l=`(function(){try{var a=function(c){var v="(prefers-color-scheme: dark)",h=window.matchMedia(v).matches?"dark":"light",r=c==="system"?h:c,o=document.documentElement,s=document.body,l="chakra-ui-light",d="chakra-ui-dark",i=r==="dark";return s.classList.add(i?d:l),s.classList.remove(i?l:d),o.style.colorScheme=r,o.dataset.theme=r,r},n=a,m="${o}",e="${i}",t=localStorage.getItem(e);t?a(t):localStorage.setItem(e,a(m))}catch(a){}})(); + `;return`!${"cookie"===r?s:l}`.trim()}function ColorModeScript(e={}){let{nonce:t}=e;return(0,o.jsx)("script",{id:"chakra-script",nonce:t,dangerouslySetInnerHTML:{__html:getScriptSrc(e)}})}var s=n(50851)},70935:function(e,t,n){"use strict";n.r(t),n.d(t,{ControlBox:function(){return ControlBox}});var r=n(23145),i=n(57437),ControlBox=e=>{let{type:t="checkbox",_hover:n,_invalid:o,_disabled:a,_focus:s,_checked:l,_child:u={opacity:0},_checkedAndChild:c={opacity:1},_checkedAndDisabled:d,_checkedAndFocus:f,_checkedAndHover:p,children:h,...m}=e,v=`input[type=${t}]:checked:disabled + &`,g=`input[type=${t}]:checked:hover:not(:disabled) + &`,y=`input[type=${t}]:checked:focus + &`,b=`input[type=${t}]:disabled + &`,x=`input[type=${t}]:focus + &`,w=`input[type=${t}]:hover:not(:disabled):not(:checked) + &`,k=`input[type=${t}]:checked + &, input[type=${t}][aria-checked=mixed] + &`,S=`input[type=${t}][aria-invalid=true] + &`,C="& > *";return(0,i.jsx)(r.chakra.div,{...m,"aria-hidden":!0,__css:{display:"inline-flex",alignItems:"center",justifyContent:"center",transitionProperty:"common",transitionDuration:"fast",flexShrink:0,[x]:s,[w]:n,[b]:a,[S]:o,[v]:d,[y]:f,[g]:p,[C]:u,[k]:{...l,[C]:c}},children:h})};ControlBox.displayName="ControlBox"},99323:function(e,t,n){"use strict";n.d(t,{C:function(){return useCounter}});var r=n(37977),i=n(18234),o=n(2265);function useCounter(e={}){let{onChange:t,precision:n,defaultValue:a,value:s,step:l=1,min:u=Number.MIN_SAFE_INTEGER,max:c=Number.MAX_SAFE_INTEGER,keepWithinRange:d=!0}=e,f=(0,r.W)(t),[p,h]=(0,o.useState)(()=>{var e;return null==a?"":null!=(e=cast(a,l,n))?e:""}),m=void 0!==s,v=m?s:p,g=getDecimalPlaces(parse(v),l),y=null!=n?n:g,b=(0,o.useCallback)(e=>{e!==v&&(m||h(e.toString()),null==f||f(e.toString(),parse(e)))},[f,m,v]),x=(0,o.useCallback)(e=>{let t=e;return d&&(t=(0,i.HU)(t,u,c)),(0,i.Zd)(t,y)},[y,d,c,u]),w=(0,o.useCallback)((e=l)=>{b(x(""===v?parse(e):parse(v)+e))},[x,l,b,v]),k=(0,o.useCallback)((e=l)=>{b(x(""===v?parse(-e):parse(v)-e))},[x,l,b,v]),S=(0,o.useCallback)(()=>{var e;b(null==a?"":null!=(e=cast(a,l,n))?e:u)},[a,n,l,b,u]),C=(0,o.useCallback)(e=>{var t;let n=null!=(t=cast(e,l,y))?t:u;b(n)},[y,l,b,u]),E=parse(v),P=E>c||E(0,i.jsx)(r.xB,{styles:a}),CSSReset=({scope:e=""})=>(0,i.jsx)(r.xB,{styles:o` + html { + line-height: 1.5; + -webkit-text-size-adjust: 100%; + font-family: system-ui, sans-serif; + -webkit-font-smoothing: antialiased; + text-rendering: optimizeLegibility; + -moz-osx-font-smoothing: grayscale; + touch-action: manipulation; + } + + body { + position: relative; + min-height: 100%; + margin: 0; + font-feature-settings: "kern"; + } + + ${e} :where(*, *::before, *::after) { + border-width: 0; + border-style: solid; + box-sizing: border-box; + word-wrap: break-word; + } + + main { + display: block; + } + + ${e} hr { + border-top-width: 1px; + box-sizing: content-box; + height: 0; + overflow: visible; + } + + ${e} :where(pre, code, kbd,samp) { + font-family: SFMono-Regular, Menlo, Monaco, Consolas, monospace; + font-size: 1em; + } + + ${e} a { + background-color: transparent; + color: inherit; + text-decoration: inherit; + } + + ${e} abbr[title] { + border-bottom: none; + text-decoration: underline; + -webkit-text-decoration: underline dotted; + text-decoration: underline dotted; + } + + ${e} :where(b, strong) { + font-weight: bold; + } + + ${e} small { + font-size: 80%; + } + + ${e} :where(sub,sup) { + font-size: 75%; + line-height: 0; + position: relative; + vertical-align: baseline; + } + + ${e} sub { + bottom: -0.25em; + } + + ${e} sup { + top: -0.5em; + } + + ${e} img { + border-style: none; + } + + ${e} :where(button, input, optgroup, select, textarea) { + font-family: inherit; + font-size: 100%; + line-height: 1.15; + margin: 0; + } + + ${e} :where(button, input) { + overflow: visible; + } + + ${e} :where(button, select) { + text-transform: none; + } + + ${e} :where( + button::-moz-focus-inner, + [type="button"]::-moz-focus-inner, + [type="reset"]::-moz-focus-inner, + [type="submit"]::-moz-focus-inner + ) { + border-style: none; + padding: 0; + } + + ${e} fieldset { + padding: 0.35em 0.75em 0.625em; + } + + ${e} legend { + box-sizing: border-box; + color: inherit; + display: table; + max-width: 100%; + padding: 0; + white-space: normal; + } + + ${e} progress { + vertical-align: baseline; + } + + ${e} textarea { + overflow: auto; + } + + ${e} :where([type="checkbox"], [type="radio"]) { + box-sizing: border-box; + padding: 0; + } + + ${e} input[type="number"]::-webkit-inner-spin-button, + ${e} input[type="number"]::-webkit-outer-spin-button { + -webkit-appearance: none !important; + } + + ${e} input[type="number"] { + -moz-appearance: textfield; + } + + ${e} input[type="search"] { + -webkit-appearance: textfield; + outline-offset: -2px; + } + + ${e} input[type="search"]::-webkit-search-decoration { + -webkit-appearance: none !important; + } + + ${e} ::-webkit-file-upload-button { + -webkit-appearance: button; + font: inherit; + } + + ${e} details { + display: block; + } + + ${e} summary { + display: list-item; + } + + template { + display: none; + } + + [hidden] { + display: none !important; + } + + ${e} :where( + blockquote, + dl, + dd, + h1, + h2, + h3, + h4, + h5, + h6, + hr, + figure, + p, + pre + ) { + margin: 0; + } + + ${e} button { + background: transparent; + padding: 0; + } + + ${e} fieldset { + margin: 0; + padding: 0; + } + + ${e} :where(ol, ul) { + margin: 0; + padding: 0; + } + + ${e} textarea { + resize: vertical; + } + + ${e} :where(button, [role="button"]) { + cursor: pointer; + } + + ${e} button::-moz-focus-inner { + border: 0 !important; + } + + ${e} table { + border-collapse: collapse; + } + + ${e} :where(h1, h2, h3, h4, h5, h6) { + font-size: inherit; + font-weight: inherit; + } + + ${e} :where(button, input, optgroup, select, textarea) { + padding: 0; + line-height: inherit; + color: inherit; + } + + ${e} :where(img, svg, video, canvas, audio, iframe, embed, object) { + display: block; + } + + ${e} :where(img, video) { + max-width: 100%; + height: auto; + } + + [data-js-focus-visible] + :focus:not([data-focus-visible-added]):not( + [data-focus-visible-disabled] + ) { + outline: none; + box-shadow: none; + } + + ${e} select::-ms-expand { + display: none; + } + + ${a} + `})},87758:function(e,t,n){"use strict";n.r(t),n.d(t,{CSSPolyfill:function(){return r.f},CSSReset:function(){return r.mA}});var r=n(96671)},64763:function(e,t,n){"use strict";n.d(t,{n:function(){return createDescendantContext}});var r=n(2265),i=Object.defineProperty,__defNormalProp=(e,t,n)=>t in e?i(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__publicField=(e,t,n)=>(__defNormalProp(e,"symbol"!=typeof t?t+"":t,n),n);function sortNodes(e){return e.sort((e,t)=>{let n=e.compareDocumentPosition(t);if(n&Node.DOCUMENT_POSITION_FOLLOWING||n&Node.DOCUMENT_POSITION_CONTAINED_BY)return -1;if(n&Node.DOCUMENT_POSITION_PRECEDING||n&Node.DOCUMENT_POSITION_CONTAINS)return 1;if(!(n&Node.DOCUMENT_POSITION_DISCONNECTED)&&!(n&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC))return 0;throw Error("Cannot sort the given nodes.")})}var isElement=e=>"object"==typeof e&&"nodeType"in e&&e.nodeType===Node.ELEMENT_NODE;function getNextIndex(e,t,n){let r=e+1;return n&&r>=t&&(r=0),r}function getPrevIndex(e,t,n){let r=e-1;return n&&r<0&&(r=t),r}var o="undefined"!=typeof window?r.useLayoutEffect:r.useEffect,cast=e=>e,a=class{constructor(){__publicField(this,"descendants",new Map),__publicField(this,"register",e=>{if(null!=e)return isElement(e)?this.registerNode(e):t=>{this.registerNode(t,e)}}),__publicField(this,"unregister",e=>{this.descendants.delete(e);let t=sortNodes(Array.from(this.descendants.keys()));this.assignIndex(t)}),__publicField(this,"destroy",()=>{this.descendants.clear()}),__publicField(this,"assignIndex",e=>{this.descendants.forEach(t=>{let n=e.indexOf(t.node);t.index=n,t.node.dataset.index=t.index.toString()})}),__publicField(this,"count",()=>this.descendants.size),__publicField(this,"enabledCount",()=>this.enabledValues().length),__publicField(this,"values",()=>{let e=Array.from(this.descendants.values());return e.sort((e,t)=>e.index-t.index)}),__publicField(this,"enabledValues",()=>this.values().filter(e=>!e.disabled)),__publicField(this,"item",e=>{if(0!==this.count())return this.values()[e]}),__publicField(this,"enabledItem",e=>{if(0!==this.enabledCount())return this.enabledValues()[e]}),__publicField(this,"first",()=>this.item(0)),__publicField(this,"firstEnabled",()=>this.enabledItem(0)),__publicField(this,"last",()=>this.item(this.descendants.size-1)),__publicField(this,"lastEnabled",()=>{let e=this.enabledValues().length-1;return this.enabledItem(e)}),__publicField(this,"indexOf",e=>{var t,n;return e&&null!=(n=null==(t=this.descendants.get(e))?void 0:t.index)?n:-1}),__publicField(this,"enabledIndexOf",e=>null==e?-1:this.enabledValues().findIndex(t=>t.node.isSameNode(e))),__publicField(this,"next",(e,t=!0)=>{let n=getNextIndex(e,this.count(),t);return this.item(n)}),__publicField(this,"nextEnabled",(e,t=!0)=>{let n=this.item(e);if(!n)return;let r=this.enabledIndexOf(n.node),i=getNextIndex(r,this.enabledCount(),t);return this.enabledItem(i)}),__publicField(this,"prev",(e,t=!0)=>{let n=getPrevIndex(e,this.count()-1,t);return this.item(n)}),__publicField(this,"prevEnabled",(e,t=!0)=>{let n=this.item(e);if(!n)return;let r=this.enabledIndexOf(n.node),i=getPrevIndex(r,this.enabledCount()-1,t);return this.enabledItem(i)}),__publicField(this,"registerNode",(e,t)=>{if(!e||this.descendants.has(e))return;let n=Array.from(this.descendants.keys()).concat(e),r=sortNodes(n);(null==t?void 0:t.disabled)&&(t.disabled=!!t.disabled);let i={node:e,index:-1,...t};this.descendants.set(e,i),this.assignIndex(r)})}},s=n(310),l=n(45663),[u,c]=(0,s.k)({name:"DescendantsProvider",errorMessage:"useDescendantsContext must be used within DescendantsProvider"});function createDescendantContext(){let e=cast(u);return[e,()=>cast(c()),()=>(function(){let e=(0,r.useRef)(new a);return o(()=>()=>e.current.destroy()),e.current})(),e=>(function(e){let t=c(),[n,i]=(0,r.useState)(-1),a=(0,r.useRef)(null);o(()=>()=>{a.current&&t.unregister(a.current)},[]),o(()=>{if(!a.current)return;let e=Number(a.current.dataset.index);n==e||Number.isNaN(e)||i(e)});let s=e?cast(t.register(e)):cast(t.register);return{descendants:t,index:n,enabledIndex:t.enabledIndexOf(a.current),register:(0,l.lq)(s,a)}})(e)]}},65346:function(e,t,n){"use strict";function isElement(e){return null!=e&&"object"==typeof e&&"nodeType"in e&&e.nodeType===Node.ELEMENT_NODE}function isHTMLElement(e){var t;if(!isElement(e))return!1;let n=null!=(t=e.ownerDocument.defaultView)?t:window;return e instanceof n.HTMLElement}function getOwnerWindow(e){var t,n;return null!=(n=null==(t=getOwnerDocument(e))?void 0:t.defaultView)?n:window}function getOwnerDocument(e){return isElement(e)?e.ownerDocument:document}function getActiveElement(e){return getOwnerDocument(e).activeElement}n.d(t,{Re:function(){return isHTMLElement},kR:function(){return getOwnerWindow},vY:function(){return getActiveElement}})},38955:function(e,t,n){"use strict";n.d(t,{EB:function(){return isFocusable},Wq:function(){return isTabbable}});var r=n(65346),hasTabIndex=e=>e.hasAttribute("tabindex"),hasNegativeTabIndex=e=>hasTabIndex(e)&&-1===e.tabIndex;function isFocusable(e){var t;if(!(0,r.Re)(e)||function isHidden(e){return!!(e.parentElement&&isHidden(e.parentElement))||e.hidden}(e)||!0==!!(t=e).getAttribute("disabled")||!0==!!t.getAttribute("aria-disabled"))return!1;let{localName:n}=e;if(["input","select","textarea","button"].indexOf(n)>=0)return!0;let i={a:()=>e.hasAttribute("href"),audio:()=>e.hasAttribute("controls"),video:()=>e.hasAttribute("controls")};return n in i?i[n]():!!function(e){let t=e.getAttribute("contenteditable");return"false"!==t&&null!=t}(e)||hasTabIndex(e)}function isTabbable(e){return!!e&&(0,r.Re)(e)&&isFocusable(e)&&!hasNegativeTabIndex(e)}},58878:function(e,t,n){"use strict";n.d(t,{t5:function(){return getAllFocusable}});var r=n(38955),isVisible=e=>e.offsetWidth>0&&e.offsetHeight>0;function getAllFocusable(e){let t=Array.from(e.querySelectorAll("input:not(:disabled):not([disabled]),select:not(:disabled):not([disabled]),textarea:not(:disabled):not([disabled]),embed,iframe,object,a[href],area[href],button:not(:disabled):not([disabled]),[tabindex],audio[controls],video[controls],*[tabindex]:not([aria-disabled]),*[contenteditable]"));return t.unshift(e),t.filter(e=>(0,r.EB)(e)&&isVisible(e))}},1889:function(e,t,n){"use strict";n.r(t),n.d(t,{Editable:function(){return E},EditableInput:function(){return p},EditablePreview:function(){return h},EditableTextarea:function(){return m},useEditable:function(){return useEditable},useEditableContext:function(){return s},useEditableControls:function(){return useEditableControls},useEditableState:function(){return useEditableState},useEditableStyles:function(){return o}});var r=n(310),[i,o]=(0,r.k)({name:"EditableStylesContext",errorMessage:"useEditableStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),[a,s]=(0,r.k)({name:"EditableContext",errorMessage:"useEditableContext: context is undefined. Seems you forgot to wrap the editable components in ``"});function useEditableState(){let{isEditing:e,onSubmit:t,onCancel:n,onEdit:r,isDisabled:i}=s();return{isEditing:e,onSubmit:t,onCancel:n,onEdit:r,isDisabled:i}}var l={fontSize:"inherit",fontWeight:"inherit",textAlign:"inherit",bg:"transparent"},u=n(58250),c=n(23145),d=n(16465),f=n(57437),p=(0,u.forwardRef)(function(e,t){let{getInputProps:n}=s(),r=o(),i=n(e,t),a=(0,d.cx)("chakra-editable__input",e.className);return(0,f.jsx)(c.chakra.input,{...i,__css:{outline:0,...l,...r.input},className:a})});p.displayName="EditableInput";var h=(0,u.forwardRef)(function(e,t){let{getPreviewProps:n}=s(),r=o(),i=n(e,t),a=(0,d.cx)("chakra-editable__preview",e.className);return(0,f.jsx)(c.chakra.span,{...i,__css:{cursor:"text",display:"inline-block",...l,...r.preview},className:a})});h.displayName="EditablePreview";var m=(0,u.forwardRef)(function(e,t){let{getTextareaProps:n}=s(),r=o(),i=n(e,t),a=(0,d.cx)("chakra-editable__textarea",e.className);return(0,f.jsx)(c.chakra.textarea,{...i,__css:{outline:0,...l,...r.textarea},className:a})});m.displayName="EditableTextarea";var v=n(38594),g=n(67673),y=n(89656),b=n(27771),x=n(45663),w=n(37977),k=n(2265);function contains(e,t){return!!e&&(e===t||e.contains(t))}function useEditable(e={}){let{onChange:t,onCancel:n,onSubmit:r,onBlur:i,value:o,isDisabled:a,defaultValue:s,startWithEditView:l,isPreviewFocusable:u=!0,submitOnBlur:c=!0,selectAllOnFocus:f=!0,placeholder:p,onEdit:h,finalFocusRef:m,...S}=e,C=(0,w.W)(h),E=!!(l&&!a),[P,T]=(0,k.useState)(E),[A,M]=(0,b.T)({defaultValue:s||"",value:o,onChange:t}),[_,N]=(0,k.useState)(A),R=(0,k.useRef)(null),D=(0,k.useRef)(null),I=(0,k.useRef)(null),j=(0,k.useRef)(null),L=(0,k.useRef)(null);(0,v.s)({ref:R,enabled:P,elements:[j,L]});let O=!P&&!a;(0,g.G)(()=>{var e,t;P&&(null==(e=R.current)||e.focus(),f&&(null==(t=R.current)||t.select()))},[]),(0,y.r)(()=>{var e,t,n,r;if(!P){m?null==(e=m.current)||e.focus():null==(t=I.current)||t.focus();return}null==(n=R.current)||n.focus(),f&&(null==(r=R.current)||r.select()),null==C||C()},[P,C,f]);let F=(0,k.useCallback)(()=>{O&&T(!0)},[O]),V=(0,k.useCallback)(()=>{N(A)},[A]),B=(0,k.useCallback)(()=>{T(!1),M(_),null==n||n(_),null==i||i(_)},[n,i,M,_]),W=(0,k.useCallback)(()=>{T(!1),N(A),null==r||r(A),null==i||i(_)},[A,r,i,_]);(0,k.useEffect)(()=>{if(P)return;let e=R.current;(null==e?void 0:e.ownerDocument.activeElement)===e&&(null==e||e.blur())},[P]);let $=(0,k.useCallback)(e=>{M(e.currentTarget.value)},[M]),U=(0,k.useCallback)(e=>{let t=e.key,n={Escape:B,Enter:e=>{e.shiftKey||e.metaKey||W()}}[t];n&&(e.preventDefault(),n(e))},[B,W]),H=(0,k.useCallback)(e=>{let t=e.key,n={Escape:B}[t];n&&(e.preventDefault(),n(e))},[B]),z=0===A.length,G=(0,k.useCallback)(e=>{var t;if(!P)return;let n=e.currentTarget.ownerDocument,r=null!=(t=e.relatedTarget)?t:n.activeElement,i=contains(j.current,r),o=contains(L.current,r);i||o||(c?W():B())},[c,W,B,P]),q=(0,k.useCallback)((e={},t=null)=>{let n=O&&u?0:void 0;return{...e,ref:(0,x.lq)(t,D),children:z?p:A,hidden:P,"aria-disabled":(0,d.Qm)(a),tabIndex:n,onFocus:(0,d.v0)(e.onFocus,F,V)}},[a,P,O,u,z,F,V,p,A]),K=(0,k.useCallback)((e={},t=null)=>({...e,hidden:!P,placeholder:p,ref:(0,x.lq)(t,R),disabled:a,"aria-disabled":(0,d.Qm)(a),value:A,onBlur:(0,d.v0)(e.onBlur,G),onChange:(0,d.v0)(e.onChange,$),onKeyDown:(0,d.v0)(e.onKeyDown,U),onFocus:(0,d.v0)(e.onFocus,V)}),[a,P,G,$,U,V,p,A]),X=(0,k.useCallback)((e={},t=null)=>({...e,hidden:!P,placeholder:p,ref:(0,x.lq)(t,R),disabled:a,"aria-disabled":(0,d.Qm)(a),value:A,onBlur:(0,d.v0)(e.onBlur,G),onChange:(0,d.v0)(e.onChange,$),onKeyDown:(0,d.v0)(e.onKeyDown,H),onFocus:(0,d.v0)(e.onFocus,V)}),[a,P,G,$,H,V,p,A]),Z=(0,k.useCallback)((e={},t=null)=>({"aria-label":"Edit",...e,type:"button",onClick:(0,d.v0)(e.onClick,F),ref:(0,x.lq)(t,I),disabled:a}),[F,a]),Y=(0,k.useCallback)((e={},t=null)=>({...e,"aria-label":"Submit",ref:(0,x.lq)(L,t),type:"button",onClick:(0,d.v0)(e.onClick,W),disabled:a}),[W,a]),Q=(0,k.useCallback)((e={},t=null)=>({"aria-label":"Cancel",id:"cancel",...e,ref:(0,x.lq)(j,t),type:"button",onClick:(0,d.v0)(e.onClick,B),disabled:a}),[B,a]);return{isEditing:P,isDisabled:a,isValueEmpty:z,value:A,onEdit:F,onCancel:B,onSubmit:W,getPreviewProps:q,getInputProps:K,getTextareaProps:X,getEditButtonProps:Z,getSubmitButtonProps:Y,getCancelButtonProps:Q,htmlProps:S}}var S=n(92013),C=n(50446),E=(0,u.forwardRef)(function(e,t){let n=(0,S.useMultiStyleConfig)("Editable",e),r=(0,C.Lr)(e),{htmlProps:o,...s}=useEditable(r),{isEditing:l,onSubmit:u,onCancel:p,onEdit:h}=s,m=(0,d.cx)("chakra-editable",e.className),v=(0,d.Pu)(e.children,{isEditing:l,onSubmit:u,onCancel:p,onEdit:h});return(0,f.jsx)(a,{value:s,children:(0,f.jsx)(i,{value:n,children:(0,f.jsx)(c.chakra.div,{ref:t,...o,className:m,children:v})})})});function useEditableControls(){let{isEditing:e,getEditButtonProps:t,getCancelButtonProps:n,getSubmitButtonProps:r}=s();return{isEditing:e,getEditButtonProps:t,getCancelButtonProps:n,getSubmitButtonProps:r}}E.displayName="Editable"},68609:function(e,t,n){"use strict";n.d(t,{E:function(){return chunk_UU5OHSNF_FocusLock}});var r,i,o=n(13428),a=n(2265),s="data-focus-lock",l="data-focus-lock-disabled",u=n(55835),c={width:"1px",height:"0px",padding:0,overflow:"hidden",position:"fixed",top:"1px",left:"1px"},InFocusGuard=function(e){var t=e.children;return a.createElement(a.Fragment,null,a.createElement("div",{key:"guard-first","data-focus-guard":!0,"data-focus-auto-guard":!0,style:c}),t,t&&a.createElement("div",{key:"guard-last","data-focus-guard":!0,"data-focus-auto-guard":!0,style:c}))};InFocusGuard.propTypes={},InFocusGuard.defaultProps={children:null};var d=n(18427),f=(0,d.s)({},function(e){return{target:e.target,currentTarget:e.currentTarget}}),p=(0,d.s)(),h=(0,d.s)(),m=(0,d._)({async:!0}),v=[],g=a.forwardRef(function(e,t){var n,r=a.useState(),i=r[0],d=r[1],h=a.useRef(),g=a.useRef(!1),y=a.useRef(null),b=e.children,x=e.disabled,w=e.noFocusGuards,k=e.persistentFocus,S=e.crossFrame,C=e.autoFocus,E=(e.allowTextSelection,e.group),P=e.className,T=e.whiteList,A=e.hasPositiveIndices,M=e.shards,_=void 0===M?v:M,N=e.as,R=void 0===N?"div":N,D=e.lockProps,I=void 0===D?{}:D,j=e.sideCar,L=e.returnFocus,O=e.focusOptions,F=e.onActivation,V=e.onDeactivation,B=a.useState({})[0],W=a.useCallback(function(){y.current=y.current||document&&document.activeElement,h.current&&F&&F(h.current),g.current=!0},[F]),$=a.useCallback(function(){g.current=!1,V&&V(h.current)},[V]);(0,a.useEffect)(function(){x||(y.current=null)},[]);var U=a.useCallback(function(e){var t=y.current;if(t&&t.focus){var n="function"==typeof L?L(t):L;if(n){var r="object"==typeof n?n:void 0;y.current=null,e?Promise.resolve().then(function(){return t.focus(r)}):t.focus(r)}}},[L]),H=a.useCallback(function(e){g.current&&f.useMedium(e)},[]),z=p.useMedium,G=a.useCallback(function(e){h.current!==e&&(h.current=e,d(e))},[]),q=(0,o.Z)(((n={})[l]=x&&"disabled",n[s]=E,n),I),K=!0!==w,X=K&&"tail"!==w,Z=(0,u.q)([t,G]);return a.createElement(a.Fragment,null,K&&[a.createElement("div",{key:"guard-first","data-focus-guard":!0,tabIndex:x?-1:0,style:c}),A?a.createElement("div",{key:"guard-nearest","data-focus-guard":!0,tabIndex:x?-1:1,style:c}):null],!x&&a.createElement(j,{id:B,sideCar:m,observed:i,disabled:x,persistentFocus:k,crossFrame:S,autoFocus:C,whiteList:T,shards:_,onActivation:W,onDeactivation:$,returnFocus:U,focusOptions:O}),a.createElement(R,(0,o.Z)({ref:Z},q,{className:P,onBlur:z,onFocus:H}),b),X&&a.createElement("div",{"data-focus-guard":!0,tabIndex:x?-1:0,style:c}))});function _setPrototypeOf(e,t){return(_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function _typeof(e){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}g.propTypes={},g.defaultProps={children:void 0,disabled:!1,returnFocus:!1,focusOptions:void 0,noFocusGuards:!1,autoFocus:!0,persistentFocus:!1,crossFrame:!0,hasPositiveIndices:void 0,allowTextSelection:void 0,group:void 0,className:void 0,whiteList:void 0,shards:void 0,as:"div",lockProps:{},onActivation:void 0,onDeactivation:void 0};var toArray=function(e){for(var t=Array(e.length),n=0;n=0}).sort(tabSort)},y="button:enabled,select:enabled,textarea:enabled,input:enabled,a[href],area[href],summary,iframe,object,embed,audio[controls],video[controls],[tabindex],[contenteditable],[autofocus]",b="".concat(y,", [data-focus-guard]"),getFocusablesWithShadowDom=function(e,t){return toArray((e.shadowRoot||e).children).reduce(function(e,n){return e.concat(n.matches(t?b:y)?[n]:[],getFocusablesWithShadowDom(n))},[])},getFocusablesWithIFrame=function(e,t){var n;return e instanceof HTMLIFrameElement&&(null===(n=e.contentDocument)||void 0===n?void 0:n.body)?getFocusables([e.contentDocument.body],t):[e]},getFocusables=function(e,t){return e.reduce(function(e,n){var r,i=getFocusablesWithShadowDom(n,t),o=(r=[]).concat.apply(r,i.map(function(e){return getFocusablesWithIFrame(e,t)}));return e.concat(o,n.parentNode?toArray(n.parentNode.querySelectorAll(y)).filter(function(e){return e===n}):[])},[])},filterFocusable=function(e,t){return toArray(e).filter(function(e){return isVisibleCached(t,e)}).filter(function(e){return!((isHTMLInputElement(e)||"BUTTON"===e.tagName)&&("hidden"===e.type||e.disabled))})},filterAutoFocusable=function(e,t){return void 0===t&&(t=new Map),toArray(e).filter(function(e){return isAutoFocusAllowedCached(t,e)})},getTabbableNodes=function(e,t,n){return orderByTabIndex(filterFocusable(getFocusables(e,n),t),!0,n)},getAllTabbableNodes=function(e,t){return orderByTabIndex(filterFocusable(getFocusables(e),t),!1)},contains=function(e,t){return e.shadowRoot?contains(e.shadowRoot,t):!!(void 0!==Object.getPrototypeOf(e).contains&&Object.getPrototypeOf(e).contains.call(e,t))||toArray(e.children).some(function(e){var n;if(e instanceof HTMLIFrameElement){var r=null===(n=e.contentDocument)||void 0===n?void 0:n.body;return!!r&&contains(r,t)}return contains(e,t)})},safeProbe=function(e){try{return e()}catch(e){return}},getActiveElement=function(e){if(void 0===e&&(e=document),e&&e.activeElement){var t=e.activeElement;return t.shadowRoot?getActiveElement(t.shadowRoot):t instanceof HTMLIFrameElement&&safeProbe(function(){return t.contentWindow.document})?getActiveElement(t.contentWindow.document):t}},focusIsHidden=function(e){void 0===e&&(e=document);var t=getActiveElement(e);return!!t&&toArray(e.querySelectorAll("[".concat("data-no-focus-lock","]"))).some(function(e){return contains(e,t)})},filterNested=function(e){for(var t=new Set,n=e.length,r=0;r0&&t.add(i),(o&Node.DOCUMENT_POSITION_CONTAINS)>0&&t.add(r)}return e.filter(function(e,n){return!t.has(n)})},getTopParent=function(e){return e.parentNode?getTopParent(e.parentNode):e},getAllAffectedNodes=function(e){return asArray(e).filter(Boolean).reduce(function(e,t){var n=t.getAttribute(s);return e.push.apply(e,n?filterNested(toArray(getTopParent(t).querySelectorAll("[".concat(s,'="').concat(n,'"]:not([').concat(l,'="disabled"])')))):[t]),e},[])},focusInside=function(e,t){return void 0===t&&(t=getActiveElement(getFirst(e).ownerDocument)),!!t&&(!t.dataset||!t.dataset.focusGuard)&&getAllAffectedNodes(e).some(function(e){var n;return contains(e,t)||(n=t,!!toArray(e.querySelectorAll("iframe")).some(function(e){return e===n}))})},correctNode=function(e,t){return isRadioElement(e)&&e.name&&t.filter(isRadioElement).filter(function(t){return t.name===e.name}).filter(function(e){return e.checked})[0]||e},correctNodes=function(e){var t=new Set;return e.forEach(function(n){return t.add(correctNode(n,e))}),e.filter(function(e){return t.has(e)})},pickFirstFocus=function(e){return e[0]&&e.length>1?correctNode(e[0],e):e[0]},pickFocusable=function(e,t){return e.length>1?e.indexOf(correctNode(e[t],e)):t},x="NEW_FOCUS",newFocus=function(e,t,n,r){var i=e.length,o=e[0],a=e[i-1],s=isGuard(n);if(!(n&&e.indexOf(n)>=0)){var l=void 0!==n?t.indexOf(n):-1,u=r?t.indexOf(r):l,c=r?e.indexOf(r):-1,d=l-u,f=t.indexOf(o),p=t.indexOf(a),h=correctNodes(t),m=(void 0!==n?h.indexOf(n):-1)-(r?h.indexOf(r):l),v=pickFocusable(e,0),g=pickFocusable(e,i-1);if(-1===l||-1===c)return x;if(!d&&c>=0)return c;if(l<=f&&s&&Math.abs(d)>1)return g;if(l>=p&&s&&Math.abs(d)>1)return v;if(d&&Math.abs(m)>1)return c;if(l<=f)return g;if(l>p)return v;if(d)return Math.abs(d)>1?c:(i+c+d)%i}},pickAutofocus=function(e,t,n){var r=filterAutoFocusable(e.map(function(e){return e.node}).filter(function(e){var t,r=null===(t=getDataset(e))||void 0===t?void 0:t.autofocus;return e.autofocus||void 0!==r&&"false"!==r||n.indexOf(e)>=0}));return r&&r.length?pickFirstFocus(r):pickFirstFocus(filterAutoFocusable(t))},getParents=function(e,t){return void 0===t&&(t=[]),t.push(e),e.parentNode&&getParents(e.parentNode.host||e.parentNode,t),t},getCommonParent=function(e,t){for(var n=getParents(e),r=getParents(t),i=0;i=0)return o}return!1},getTopCommonParent=function(e,t,n){var r=asArray(e),i=asArray(t),o=r[0],a=!1;return i.filter(Boolean).forEach(function(e){a=getCommonParent(a||e,e)||a,n.filter(Boolean).forEach(function(e){var t=getCommonParent(o,e);t&&(a=!a||contains(t,a)?t:getCommonParent(t,a))})}),a},reorderNodes=function(e,t){var n=new Map;return t.forEach(function(e){return n.set(e.node,e)}),e.map(function(e){return n.get(e)}).filter(isDefined)},getFocusMerge=function(e,t){var n=getActiveElement(asArray(e).length>0?document:getFirst(e).ownerDocument),r=getAllAffectedNodes(e).filter(isNotAGuard),i=getTopCommonParent(n||e,e,r),o=new Map,a=getAllTabbableNodes(r,o),s=getTabbableNodes(r,o).filter(function(e){return isNotAGuard(e.node)});if(s[0]||(s=a)[0]){var l=getAllTabbableNodes([i],o).map(function(e){return e.node}),u=reorderNodes(l,s),c=u.map(function(e){return e.node}),d=newFocus(c,l,n,t);if(d===x){var f=pickAutofocus(a,c,r.reduce(function(e,t){return e.concat(filterFocusable(toArray(t.querySelectorAll("[".concat("data-autofocus-inside","]"))).map(function(e){return getFocusables([e])}).reduce(function(e,t){return e.concat(t)},[]),o))},[]));return f?{node:f}:void console.warn("focus-lock: cannot find any node to move focus into")}return void 0===d?d:u[d]}},focusOn=function(e,t){"focus"in e&&e.focus(t),"contentWindow"in e&&e.contentWindow&&e.contentWindow.focus()},w=0,k=!1,es2015=function(e,t,n){void 0===n&&(n={});var r=getFocusMerge(e,t);if(!k&&r){if(w>2){console.error("FocusLock: focus-fighting detected. Only one focus management system could be active. See https://github.com/theKashey/focus-lock/#focus-fighting"),k=!0,setTimeout(function(){k=!1},1);return}w++,focusOn(r.node,n.focusOptions),w--}},getFocusabledIn=function(e){var t=getAllAffectedNodes(e).filter(isNotAGuard),n=getTopCommonParent(e,e,t),r=new Map,i=getTabbableNodes([n],r,!0),o=getTabbableNodes(t,r).filter(function(e){return isNotAGuard(e.node)}).map(function(e){return e.node});return i.map(function(e){var t=e.node;return{node:t,index:e.index,lockItem:o.indexOf(t)>=0,guard:isGuard(t)}})};function deferAction(e){setTimeout(e,1)}var S=null,C=null,E=null,P=!1,recordPortal=function(e,t){E={observerNode:e,portaledElement:t}};function autoGuard(e,t,n,r){var i=null,o=e;do{var a=r[o];if(a.guard)a.node.dataset.focusAutoGuard&&(i=a);else if(a.lockItem){if(o!==e)return;i=null}else break}while((o+=n)!==t);i&&(i.node.tabIndex=0)}var extractRef=function(e){return e&&"current"in e?e.current:e},activateTrap=function(){var e=!1;if(S){var t=S,n=t.observed,r=t.persistentFocus,i=t.autoFocus,o=t.shards,a=t.crossFrame,s=t.focusOptions,l=n||E&&E.portaledElement,u=document&&document.activeElement;if(l){var c=[l].concat(o.map(extractRef).filter(Boolean));if((!u||(S.whiteList||function(){return!0})(u))&&(r||(a?!!P:"meanwhile"===P)||!(document&&document.activeElement===document.body||focusIsHidden())||!C&&i)&&(l&&!(focusInside(c)||u&&c.some(function(e){return function checkInHost(e,t,n){return t&&(t.host===e&&(!t.activeElement||n.contains(t.activeElement))||t.parentNode&&checkInHost(e,t.parentNode,n))}(u,e,e)})||E&&E.portaledElement===u)&&(document&&!C&&u&&!i?(u.blur&&u.blur(),document.body.focus()):(e=es2015(c,C,{focusOptions:s}),E={})),P=!1,C=document&&document.activeElement),document){var d=document&&document.activeElement,f=getFocusabledIn(c),p=f.map(function(e){return e.node}).indexOf(d);p>-1&&(f.filter(function(e){var t=e.guard,n=e.node;return t&&n.dataset.focusAutoGuard}).forEach(function(e){return e.node.removeAttribute("tabIndex")}),autoGuard(p,f.length,1,f),autoGuard(p,-1,-1,f))}}}return e},onTrap=function(e){activateTrap()&&e&&(e.stopPropagation(),e.preventDefault())},onBlur=function(){return deferAction(activateTrap)},onWindowBlur=function(){P="just",deferAction(function(){P="meanwhile"})},attachHandler=function(){document.addEventListener("focusin",onTrap),document.addEventListener("focusout",onBlur),window.addEventListener("blur",onWindowBlur)},detachHandler=function(){document.removeEventListener("focusin",onTrap),document.removeEventListener("focusout",onBlur),window.removeEventListener("blur",onWindowBlur)};f.assignSyncMedium(function(e){var t=e.target,n=e.currentTarget;n.contains(t)||recordPortal(n,t)}),p.assignMedium(onBlur),h.assignMedium(function(e){return e({moveFocusInside:es2015,focusInside:focusInside})});var T=(r=function(e){var t=e.slice(-1)[0];t&&!S&&attachHandler();var n=S,r=n&&t&&t.id===n.id;S=t,!n||r||(n.onDeactivation(),e.filter(function(e){return e.id===n.id}).length||n.returnFocus(!t)),t?(C=null,r&&n.observed===t.observed||t.onActivation(),activateTrap(!0),deferAction(activateTrap)):(detachHandler(),C=null)},function(e){var t,n,i,o,s=[];function emitChange(){r(o=s.map(function(e){return e.props}).filter(function(e){return!e.disabled}))}var l=function(t){function SideEffect(){return t.apply(this,arguments)||this}SideEffect.prototype=Object.create(t.prototype),SideEffect.prototype.constructor=SideEffect,_setPrototypeOf(SideEffect,t),SideEffect.peek=function(){return o};var n=SideEffect.prototype;return n.componentDidMount=function(){s.push(this),emitChange()},n.componentDidUpdate=function(){emitChange()},n.componentWillUnmount=function(){var e=s.indexOf(this);s.splice(e,1),emitChange()},n.render=function(){return a.createElement(e,this.props)},SideEffect}(a.PureComponent);return t="displayName",n="SideEffect("+(e.displayName||e.name||"Component")+")",i=function(e,t){if("object"!==_typeof(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==_typeof(r))return r;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"===_typeof(i)?i:String(i))in l?Object.defineProperty(l,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):l[t]=n,l})(function(){return null}),A=a.forwardRef(function(e,t){return a.createElement(g,(0,o.Z)({sideCar:T,ref:t},e))}),M=g.propTypes||{};M.sideCar,function(e,t){if(null!=e){var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n])}}(M,["sideCar"]),A.propTypes={};var _=n(58878),N=n(57437),R=null!=(i=A.default)?i:A,chunk_UU5OHSNF_FocusLock=e=>{let{initialFocusRef:t,finalFocusRef:n,contentRef:r,restoreFocus:i,children:o,isDisabled:s,autoFocus:l,persistentFocus:u,lockFocusAcrossFrames:c}=e,d=(0,a.useCallback)(()=>{if(null==t?void 0:t.current)t.current.focus();else if(null==r?void 0:r.current){let e=(0,_.t5)(r.current);0===e.length&&requestAnimationFrame(()=>{var e;null==(e=r.current)||e.focus()})}},[t,r]),f=(0,a.useCallback)(()=>{var e;null==(e=null==n?void 0:n.current)||e.focus()},[n]),p=i&&!n;return(0,N.jsx)(R,{crossFrame:c,persistentFocus:u,autoFocus:l,disabled:s,onActivation:d,onDeactivation:f,returnFocus:p,children:o})};chunk_UU5OHSNF_FocusLock.displayName="FocusLock"},22202:function(e,t,n){"use strict";n.r(t),n.d(t,{FocusLock:function(){return r.E}});var r=n(68609)},71051:function(e,t,n){"use strict";n.r(t),n.d(t,{FormControl:function(){return r.NI},FormErrorIcon:function(){return m},FormErrorMessage:function(){return h},FormHelperText:function(){return r.Q6},FormLabel:function(){return v},RequiredIndicator:function(){return g},useFormControl:function(){return y.Y},useFormControlContext:function(){return r.NJ},useFormControlProps:function(){return y.K},useFormControlStyles:function(){return r.e},useFormErrorStyles:function(){return p}});var r=n(68975),i=n(16248),o=n(310),a=n(58250),s=n(92013),l=n(50446),u=n(23145),c=n(16465),d=n(57437),[f,p]=(0,o.k)({name:"FormErrorStylesContext",errorMessage:"useFormErrorStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),h=(0,a.forwardRef)((e,t)=>{let n=(0,s.useMultiStyleConfig)("FormError",e),i=(0,l.Lr)(e),o=(0,r.NJ)();return(null==o?void 0:o.isInvalid)?(0,d.jsx)(f,{value:n,children:(0,d.jsx)(u.chakra.div,{...null==o?void 0:o.getErrorMessageProps(i,t),className:(0,c.cx)("chakra-form__error-message",e.className),__css:{display:"flex",alignItems:"center",...n.text}})}):null});h.displayName="FormErrorMessage";var m=(0,a.forwardRef)((e,t)=>{let n=p(),o=(0,r.NJ)();if(!(null==o?void 0:o.isInvalid))return null;let a=(0,c.cx)("chakra-form__error-icon",e.className);return(0,d.jsx)(i.J,{ref:t,"aria-hidden":!0,...e,__css:n.icon,className:a,children:(0,d.jsx)("path",{fill:"currentColor",d:"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z"})})});m.displayName="FormErrorIcon";var v=(0,a.forwardRef)(function(e,t){var n;let i=(0,s.useStyleConfig)("FormLabel",e),o=(0,l.Lr)(e),{className:a,children:f,requiredIndicator:p=(0,d.jsx)(g,{}),optionalIndicator:h=null,...m}=o,v=(0,r.NJ)(),y=null!=(n=null==v?void 0:v.getLabelProps(m,t))?n:{ref:t,...m};return(0,d.jsxs)(u.chakra.label,{...y,className:(0,c.cx)("chakra-form__label",o.className),__css:{display:"block",textAlign:"start",...i},children:[f,(null==v?void 0:v.isRequired)?p:h]})});v.displayName="FormLabel";var g=(0,a.forwardRef)(function(e,t){let n=(0,r.NJ)(),i=(0,r.e)();if(!(null==n?void 0:n.isRequired))return null;let o=(0,c.cx)("chakra-form__required-indicator",e.className);return(0,d.jsx)(u.chakra.span,{...null==n?void 0:n.getRequiredIndicatorProps(e,t),__css:i.requiredIndicator,className:o})});g.displayName="RequiredIndicator";var y=n(75992)},37392:function(e,t,n){"use strict";n.r(t),n.d(t,{assignRef:function(){return assignRef},useAnimationState:function(){return useAnimationState},useBoolean:function(){return useBoolean},useCallbackRef:function(){return useCallbackRef},useClipboard:function(){return useClipboard},useConst:function(){return useConst},useControllableProp:function(){return useControllableProp},useControllableState:function(){return useControllableState},useDimensions:function(){return useDimensions},useDisclosure:function(){return useDisclosure},useEventListener:function(){return useEventListener},useEventListenerMap:function(){return useEventListenerMap},useFocusEffect:function(){return useFocusEffect},useFocusOnHide:function(){return useFocusOnHide},useFocusOnPointerDown:function(){return useFocusOnPointerDown},useFocusOnShow:function(){return useFocusOnShow},useForceUpdate:function(){return useForceUpdate},useId:function(){return useId},useIds:function(){return useIds},useInterval:function(){return useInterval},useLatestRef:function(){return useLatestRef},useMergeRefs:function(){return useMergeRefs},useMouseDownRef:function(){return useMouseDownRef},useOptionalPart:function(){return useOptionalPart},useOutsideClick:function(){return useOutsideClick},usePanGesture:function(){return usePanGesture},usePointerEvent:function(){return usePointerEvent},usePrevious:function(){return usePrevious},useSafeLayoutEffect:function(){return o},useShortcut:function(){return useShortcut},useTimeout:function(){return useTimeout},useUnmountEffect:function(){return useUnmountEffect},useUpdateEffect:function(){return useUpdateEffect},useWhyDidYouUpdate:function(){return useWhyDidYouUpdate}});var r=n(2265);function usePrevious(e){let t=(0,r.useRef)();return(0,r.useEffect)(()=>{t.current=e},[e]),t.current}function useShortcut(e={}){let{timeout:t=300,preventDefault:n=()=>!0}=e,[i,o]=(0,r.useState)([]),a=(0,r.useRef)(),flush=()=>{a.current&&(clearTimeout(a.current),a.current=null)},clearKeysAfterDelay=()=>{flush(),a.current=setTimeout(()=>{o([]),a.current=null},t)};return(0,r.useEffect)(()=>flush,[]),function(e){return t=>{if("Backspace"===t.key){let e=[...i];e.pop(),o(e);return}if(function(e){let{key:t}=e;return 1===t.length||t.length>1&&/[^a-zA-Z0-9]/.test(t)}(t)){let r=i.concat(t.key);n(t)&&(t.preventDefault(),t.stopPropagation()),o(r),e(r.join("")),clearKeysAfterDelay()}}}}function isElement(e){return null!=e&&"object"==typeof e&&"nodeType"in e&&e.nodeType===Node.ELEMENT_NODE}function chunk_O3SWHQEE_isHTMLElement(e){var t;if(!isElement(e))return!1;let n=null!=(t=e.ownerDocument.defaultView)?t:window;return e instanceof n.HTMLElement}function getOwnerDocument(e){var t;return isElement(e)&&null!=(t=e.ownerDocument)?t:document}function getEventWindow(e){var t;return null!=(t=e.view)?t:window}var i=!!("undefined"!=typeof window&&window.document&&window.document.createElement);function contains(e,t){return!!e&&(e===t||e.contains(t))}var o=i?r.useLayoutEffect:r.useEffect;function useCallbackRef(e,t=[]){let n=(0,r.useRef)(e);return o(()=>{n.current=e}),(0,r.useCallback)((...e)=>{var t;return null==(t=n.current)?void 0:t.call(n,...e)},t)}function useTimeout(e,t){let n=useCallbackRef(e);(0,r.useEffect)(()=>{if(null==t)return;let e=null;return e=window.setTimeout(()=>{n()},t),()=>{e&&window.clearTimeout(e)}},[t,n])}function useWhyDidYouUpdate(e,t){let n=(0,r.useRef)();(0,r.useEffect)(()=>{if(n.current){let r=Object.keys({...n.current,...t}),i={};r.forEach(e=>{n.current[e]!==t[e]&&(i[e]={from:n.current[e],to:t[e]})}),Object.keys(i).length&&console.log("[why-did-you-update]",e,i)}n.current=t})}function useInterval(e,t){let n=useCallbackRef(e);(0,r.useEffect)(()=>{let e=null;return null!==t&&(e=window.setInterval(()=>n(),t)),()=>{e&&window.clearInterval(e)}},[t,n])}function useLatestRef(e){let t=(0,r.useRef)(null);return t.current=e,t}function assignRef(e,t){if(null!=e){if("function"==typeof e){e(t);return}try{e.current=t}catch(n){throw Error(`Cannot assign value '${t}' to ref '${e}'`)}}}function useMergeRefs(...e){return(0,r.useMemo)(()=>e.every(e=>null==e)?null:t=>{e.forEach(e=>{e&&assignRef(e,t)})},e)}var a=n(62788);function useEventListener(e,t,n,i){let o=useCallbackRef(t);return(0,r.useEffect)(()=>{var r;let s=null!=(r=(0,a.Pu)(n))?r:document;if(t)return s.addEventListener(e,o,i),()=>{s.removeEventListener(e,o,i)}},[e,n,i,o,t]),()=>{var t;let r=null!=(t=(0,a.Pu)(n))?t:document;r.removeEventListener(e,o,i)}}function useMouseDownRef(e=!0){let t=(0,r.useRef)();return useEventListener("mousedown",n=>{e&&(t.current=n.target)}),t}function useOutsideClick(e){let{ref:t,handler:n,enabled:i=!0}=e,o=useCallbackRef(n),a=(0,r.useRef)({isPointerDown:!1,ignoreEmulatedMouseEvents:!1}),s=a.current;(0,r.useEffect)(()=>{if(!i)return;let onPointerDown=e=>{isValidEvent(e,t)&&(s.isPointerDown=!0)},onMouseUp=e=>{if(s.ignoreEmulatedMouseEvents){s.ignoreEmulatedMouseEvents=!1;return}s.isPointerDown&&n&&isValidEvent(e,t)&&(s.isPointerDown=!1,o(e))},onTouchEnd=e=>{s.ignoreEmulatedMouseEvents=!0,n&&s.isPointerDown&&isValidEvent(e,t)&&(s.isPointerDown=!1,o(e))},e=getOwnerDocument(t.current);return e.addEventListener("mousedown",onPointerDown,!0),e.addEventListener("mouseup",onMouseUp,!0),e.addEventListener("touchstart",onPointerDown,!0),e.addEventListener("touchend",onTouchEnd,!0),()=>{e.removeEventListener("mousedown",onPointerDown,!0),e.removeEventListener("mouseup",onMouseUp,!0),e.removeEventListener("touchstart",onPointerDown,!0),e.removeEventListener("touchend",onTouchEnd,!0)}},[n,t,o,s,i])}function isValidEvent(e,t){var n;let r=e.target;if(r){let e=getOwnerDocument(r);if(!e.contains(r))return!1}return!(null==(n=t.current)?void 0:n.contains(r))}function isTouchEvent(e){let t=!!e.touches;return t}var s={pageX:0,pageY:0};function extractEventInfo(e,t="page"){return{point:isTouchEvent(e)?function(e,t="page"){let n=e.touches[0]||e.changedTouches[0],r=n||s;return{x:r[`${t}X`],y:r[`${t}Y`]}}(e,t):function(e,t="page"){return{x:e[`${t}X`],y:e[`${t}Y`]}}(e,t)}}var wrapPointerEventHandler=(e,t=!1)=>{let listener=t=>e(t,extractEventInfo(t));return t?e=>{let t=getEventWindow(e),n=e instanceof t.MouseEvent,r=!n||n&&0===e.button;r&&listener(e)}:listener},supportsPointerEvents=()=>i&&null===window.onpointerdown,supportsTouchEvents=()=>i&&null===window.ontouchstart,supportsMouseEvents=()=>i&&null===window.onmousedown,l={pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointercancel:"mousecancel",pointerover:"mouseover",pointerout:"mouseout",pointerenter:"mouseenter",pointerleave:"mouseleave"},u={pointerdown:"touchstart",pointermove:"touchmove",pointerup:"touchend",pointercancel:"touchcancel"};function getPointerEventName(e){return supportsPointerEvents()?e:supportsTouchEvents()?u[e]:supportsMouseEvents()?l[e]:e}function addPointerEvent(e,t,n,r){var i,o;return i=getPointerEventName(t),o=wrapPointerEventHandler(n,"pointerdown"===t),e.addEventListener(i,o,r),()=>{e.removeEventListener(i,o,r)}}function usePointerEvent(e,t,n,r){return useEventListener(getPointerEventName(t),wrapPointerEventHandler(n,"pointerdown"===t),e,r)}function useUnmountEffect(e,t=[]){return(0,r.useEffect)(()=>()=>e(),t)}var c=Object.defineProperty,__defNormalProp=(e,t,n)=>t in e?c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__publicField=(e,t,n)=>(__defNormalProp(e,"symbol"!=typeof t?t+"":t,n),n),d=n(98361),f=class{constructor(e,t,n){if(__publicField(this,"history",[]),__publicField(this,"startEvent",null),__publicField(this,"lastEvent",null),__publicField(this,"lastEventInfo",null),__publicField(this,"handlers",{}),__publicField(this,"removeListeners",a.ZT),__publicField(this,"threshold",3),__publicField(this,"win"),__publicField(this,"updatePoint",()=>{if(!(this.lastEvent&&this.lastEventInfo))return;let e=getPanInfo(this.lastEventInfo,this.history),t=null!==this.startEvent,n=(0,a.TE)(e.offset,{x:0,y:0})>=this.threshold;if(!t&&!n)return;let{timestamp:r}=(0,d.$B)();this.history.push({...e.point,timestamp:r});let{onStart:i,onMove:o}=this.handlers;t||(null==i||i(this.lastEvent,e),this.startEvent=this.lastEvent),null==o||o(this.lastEvent,e)}),__publicField(this,"onPointerMove",(e,t)=>{if(this.lastEvent=e,this.lastEventInfo=t,function(e){let t=getEventWindow(e);return void 0!==t.PointerEvent&&e instanceof t.PointerEvent?!("mouse"!==e.pointerType):e instanceof t.MouseEvent}(e)&&0===e.buttons){this.onPointerUp(e,t);return}d.ZP.update(this.updatePoint,!0)}),__publicField(this,"onPointerUp",(e,t)=>{let n=getPanInfo(t,this.history),{onEnd:r,onSessionEnd:i}=this.handlers;null==i||i(e,n),this.end(),r&&this.startEvent&&(null==r||r(e,n))}),this.win=getEventWindow(e),isTouchEvent(e)&&e.touches.length>1)return;this.handlers=t,n&&(this.threshold=n),e.stopPropagation(),e.preventDefault();let r=extractEventInfo(e),{timestamp:i}=(0,d.$B)();this.history=[{...r.point,timestamp:i}];let{onSessionStart:o}=t;null==o||o(e,getPanInfo(r,this.history)),this.removeListeners=(0,a.zG)(addPointerEvent(this.win,"pointermove",this.onPointerMove),addPointerEvent(this.win,"pointerup",this.onPointerUp),addPointerEvent(this.win,"pointercancel",this.onPointerUp))}updateHandlers(e){this.handlers=e}end(){var e;null==(e=this.removeListeners)||e.call(this),d.qY.update(this.updatePoint)}};function subtractPoint(e,t){return{x:e.x-t.x,y:e.y-t.y}}function getPanInfo(e,t){return{point:e.point,delta:subtractPoint(e.point,t[t.length-1]),offset:subtractPoint(e.point,t[0]),velocity:function(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=e[e.length-1];for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>toMilliseconds(.1)));)n--;if(!r)return{x:0,y:0};let o=(i.timestamp-r.timestamp)/1e3;if(0===o)return{x:0,y:0};let a={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}(t,0)}}var toMilliseconds=e=>1e3*e;function usePanGesture(e,t){let{onPan:n,onPanStart:i,onPanEnd:o,onPanSessionStart:s,onPanSessionEnd:l,threshold:u}=t,c=!!(n||i||o||s||l),d=(0,r.useRef)(null),p={onSessionStart:s,onSessionEnd:l,onStart:i,onMove:n,onEnd(e,t){d.current=null,null==o||o(e,t)}};(0,r.useEffect)(()=>{var e;null==(e=d.current)||e.updateHandlers(p)}),usePointerEvent(()=>e.current,"pointerdown",c?function(e){d.current=new f(e,p,u)}:a.ZT),useUnmountEffect(()=>{var e;null==(e=d.current)||e.end(),d.current=null})}function useId(e,t){let n=(0,r.useId)();return(0,r.useMemo)(()=>e||[t,n].filter(Boolean).join("-"),[e,t,n])}function useIds(e,...t){let n=useId(e);return(0,r.useMemo)(()=>t.map(e=>`${e}-${n}`),[n,t])}function useOptionalPart(e){let[t,n]=(0,r.useState)(null),i=(0,r.useCallback)(t=>{n(t?e:null)},[e]);return{ref:i,id:t,isRendered:!!t}}function useControllableProp(e,t){let n=void 0!==e;return[n,n&&void 0!==e?e:t]}function useControllableState(e){let{value:t,defaultValue:n,onChange:i,shouldUpdate:o=(e,t)=>e!==t}=e,s=useCallbackRef(i),l=useCallbackRef(o),[u,c]=(0,r.useState)(n),d=void 0!==t,f=d?t:u,p=(0,r.useCallback)(e=>{let t=(0,a.Pu)(e,f);l(f,t)&&(d||c(t),s(t))},[d,s,f,l]);return[f,p]}function useDisclosure(e={}){let{onClose:t,onOpen:n,isOpen:i,id:o}=e,s=useCallbackRef(n),l=useCallbackRef(t),[u,c]=(0,r.useState)(e.defaultIsOpen||!1),[d,f]=useControllableProp(i,u),p=useId(o,"disclosure"),h=(0,r.useCallback)(()=>{d||c(!1),null==l||l()},[d,l]),m=(0,r.useCallback)(()=>{d||c(!0),null==s||s()},[d,s]),v=(0,r.useCallback)(()=>{let e=f?h:m;e()},[f,m,h]);return{isOpen:!!f,onOpen:m,onClose:h,onToggle:v,isControlled:d,getButtonProps:(e={})=>({...e,"aria-expanded":f,"aria-controls":p,onClick:(0,a.v0)(e.onClick,v)}),getDisclosureProps:(e={})=>({...e,hidden:!f,id:p})}}function useEventListenerMap(){let e=(0,r.useRef)(new Map),t=e.current,n=(0,r.useCallback)((t,n,r,i)=>{let o=wrapPointerEventHandler(r,"pointerdown"===n);e.current.set(r,{__listener:o,type:getPointerEventName(n),el:t,options:i}),t.addEventListener(n,o,i)},[]),i=(0,r.useCallback)((t,n,r,i)=>{let{__listener:o}=e.current.get(r);t.removeEventListener(n,o,i),e.current.delete(o)},[]);return(0,r.useEffect)(()=>()=>{t.forEach((e,t)=>{i(e.el,e.type,t,e.options)})},[i,t]),{add:n,remove:i}}var useUpdateEffect=(e,t)=>{let n=(0,r.useRef)(!1),i=(0,r.useRef)(!1);(0,r.useEffect)(()=>{let t=n.current,r=t&&i.current;if(r)return e();i.current=!0},t),(0,r.useEffect)(()=>(n.current=!0,()=>{n.current=!1}),[])},hasTabIndex=e=>e.hasAttribute("tabindex"),hasNegativeTabIndex=e=>hasTabIndex(e)&&-1===e.tabIndex;function isActiveElement(e){let t=chunk_O3SWHQEE_isHTMLElement(e)?getOwnerDocument(e):document;return t.activeElement===e}function isFocusable(e){var t;if(!chunk_O3SWHQEE_isHTMLElement(e)||function isHidden(e){return!!(e.parentElement&&isHidden(e.parentElement))||e.hidden}(e)||!0==!!(t=e).getAttribute("disabled")||!0==!!t.getAttribute("aria-disabled"))return!1;let{localName:n}=e;if(["input","select","textarea","button"].indexOf(n)>=0)return!0;let r={a:()=>e.hasAttribute("href"),audio:()=>e.hasAttribute("controls"),video:()=>e.hasAttribute("controls")};return n in r?r[n]():!!function(e){let t=e.getAttribute("contenteditable");return"false"!==t&&null!=t}(e)||hasTabIndex(e)}function chunk_QKXRP2IX_focus(e,t={}){let{isActive:n=isActiveElement,nextTick:r,preventScroll:i=!0,selectTextIfInput:o=!0}=t;if(!e||n(e))return -1;function triggerFocus(){if(!e){(0,a.ZK)({condition:!0,message:"[chakra-ui]: can't call focus() on `null` or `undefined` element"});return}if(function(){if(null==p){p=!1;try{let e=document.createElement("div");e.focus({get preventScroll(){return p=!0,!0}})}catch(e){}}return p}())e.focus({preventScroll:i});else if(e.focus(),i){let t=function(e){var t;let n=getOwnerDocument(e),r=null!=(t=n.defaultView)?t:window,i=e.parentNode,o=[],a=n.scrollingElement||n.documentElement;for(;i instanceof r.HTMLElement&&i!==a;)(i.offsetHeight{let t=e.current;t&&n&&(document.activeElement&&t.contains(document.activeElement)||chunk_QKXRP2IX_focus(t,{preventScroll:r,nextTick:!0}))},[n,e,r])}function useFocusOnHide(e,t){let{shouldFocus:n,visible:r,focusRef:i}=t,o=n&&!r;useUpdateEffect(()=>{if(!o||function(e){let t=e.current;if(!t)return!1;let n=function(e){let t=getOwnerDocument(e);return null==t?void 0:t.activeElement}(t);return!(!n||contains(t,n))&&!!(n&&chunk_O3SWHQEE_isHTMLElement(n)&&isFocusable(n)&&!hasNegativeTabIndex(n))}(e))return;let t=(null==i?void 0:i.current)||e.current;t&&chunk_QKXRP2IX_focus(t,{nextTick:!0})},[o,e,i])}var h=n(82136);function useFocusOnPointerDown(e){let{ref:t,elements:n,enabled:r}=e,o=!!i&&"Safari"===function(e){let{userAgent:t,vendor:n}=e,r=/(android)/i.test(t);switch(!0){case/CriOS/.test(t):return"Chrome for iOS";case/Edg\//.test(t):return"Edge";case r&&/Silk\//.test(t):return"Silk";case/Chrome/.test(t)&&/Google Inc/.test(n):return"Chrome";case/Firefox\/\d+\.\d+$/.test(t):return"Firefox";case r:return"AOSP";case/MSIE|Trident/.test(t):return"IE";case/Safari/.test(e.userAgent)&&/Apple Computer/.test(t):return"Safari";case/AppleWebKit/.test(t):return"WebKit";default:return null}}(window.navigator);usePointerEvent(()=>getOwnerDocument(t.current),"pointerdown",e=>{if(!o||!r)return;let i=e.target,a=(null!=n?n:[t]).some(e=>{let t=(0,h.Ik)(e)?e.current:e;return contains(t,i)});!isActiveElement(i)&&a&&(e.preventDefault(),chunk_QKXRP2IX_focus(i))})}var isVisible=e=>e.offsetWidth>0&&e.offsetHeight>0,m={preventScroll:!0,shouldFocus:!1};function useFocusOnShow(e,t=m){let{focusRef:n,preventScroll:i,shouldFocus:a,visible:s}=t,l=(0,h.Ik)(e)?e.current:e,u=a&&s,c=(0,r.useRef)(u),d=(0,r.useRef)(s);o(()=>{!d.current&&s&&(c.current=u),d.current=s},[s,u]);let f=(0,r.useCallback)(()=>{if(s&&l&&c.current&&(c.current=!1,!contains(l,document.activeElement))){if(null==n?void 0:n.current)chunk_QKXRP2IX_focus(n.current,{preventScroll:i,nextTick:!0});else{let e=function(e){let t=Array.from(e.querySelectorAll("input:not(:disabled):not([disabled]),select:not(:disabled):not([disabled]),textarea:not(:disabled):not([disabled]),embed,iframe,object,a[href],area[href],button:not(:disabled):not([disabled]),[tabindex],audio[controls],video[controls],*[tabindex]:not([aria-disabled]),*[contenteditable]"));return t.unshift(e),t.filter(e=>isFocusable(e)&&isVisible(e))}(l);e.length>0&&chunk_QKXRP2IX_focus(e[0],{preventScroll:i,nextTick:!0})}}},[s,i,l,n]);useUpdateEffect(()=>{f()},[f]),useEventListener("transitionend",f,l)}function useForceUpdate(){let e=(0,r.useRef)(!1),[t,n]=(0,r.useState)(0);return useUnmountEffect(()=>{e.current=!0}),(0,r.useCallback)(()=>{e.current||n(t+1)},[t])}function useAnimationState(e){let{isOpen:t,ref:n}=e,[i,o]=(0,r.useState)(t),[a,s]=(0,r.useState)(!1);(0,r.useEffect)(()=>{a||(o(t),s(!0))},[t,a,i]),useEventListener("animationend",()=>{o(t)},()=>n.current);let l=!t&&!i;return{present:!l,onComplete(){var e,t,r,i;let o=isElement(t=n.current)&&null!=(i=null==(r=getOwnerDocument(t))?void 0:r.defaultView)?i:window,a=new o.CustomEvent("animationend",{bubbles:!0});null==(e=n.current)||e.dispatchEvent(a)}}}function useBoolean(e=!1){let[t,n]=(0,r.useState)(e),i=(0,r.useMemo)(()=>({on:()=>n(!0),off:()=>n(!1),toggle:()=>n(e=>!e)}),[]);return[t,i]}var v=n(2390);function useClipboard(e,t={}){let[n,i]=(0,r.useState)(!1),[o,a]=(0,r.useState)(e);(0,r.useEffect)(()=>a(e),[e]);let{timeout:s=1500,...l}="number"==typeof t?{timeout:t}:t,u=(0,r.useCallback)(()=>{let e=v(o,l);i(e)},[o,l]);return(0,r.useEffect)(()=>{let e=null;return n&&(e=window.setTimeout(()=>{i(!1)},s)),()=>{e&&window.clearTimeout(e)}},[s,n]),{value:o,setValue:a,onCopy:u,hasCopied:n}}function useConst(e){let t=(0,r.useRef)(null);return null===t.current&&(t.current="function"==typeof e?e():e),t.current}var getRect=function(e){var t=e.top,n=e.right,r=e.bottom,i=e.left;return{top:t,right:n,bottom:r,left:i,width:n-i,height:r-t,x:i,y:t,center:{x:(n+i)/2,y:(r+t)/2}}},shrink=function(e,t){return{top:e.top+t.top,left:e.left+t.left,bottom:e.bottom-t.bottom,right:e.right-t.right}},g={top:0,right:0,bottom:0,left:0},createBox=function(e){var t=e.borderBox,n=e.margin,r=void 0===n?g:n,i=e.border,o=void 0===i?g:i,a=e.padding,s=void 0===a?g:a,l=getRect({top:t.top-r.top,left:t.left-r.left,bottom:t.bottom+r.bottom,right:t.right+r.right}),u=getRect(shrink(t,o)),c=getRect(shrink(u,s));return{marginBox:l,borderBox:getRect(t),paddingBox:u,contentBox:c,margin:r,border:o,padding:s}},parse=function(e){var t=e.slice(0,-2);if("px"!==e.slice(-2))return 0;var n=Number(t);return isNaN(n)&&function(e,t){if(!e)throw Error("Invariant failed")}(!1),n},getBox=function(e){var t;return createBox({borderBox:e.getBoundingClientRect(),margin:{top:parse((t=window.getComputedStyle(e)).marginTop),right:parse(t.marginRight),bottom:parse(t.marginBottom),left:parse(t.marginLeft)},padding:{top:parse(t.paddingTop),right:parse(t.paddingRight),bottom:parse(t.paddingBottom),left:parse(t.paddingLeft)},border:{top:parse(t.borderTopWidth),right:parse(t.borderRightWidth),bottom:parse(t.borderBottomWidth),left:parse(t.borderLeftWidth)}})};function useDimensions(e,t){let[n,i]=(0,r.useState)(null),a=(0,r.useRef)();return o(()=>{function measure(){let t=e.current;t&&(a.current=requestAnimationFrame(()=>{let e=getBox(t);i(e)}))}return measure(),t&&(window.addEventListener("resize",measure),window.addEventListener("scroll",measure)),()=>{t&&(window.removeEventListener("resize",measure),window.removeEventListener("scroll",measure)),a.current&&cancelAnimationFrame(a.current)}},[t]),n}},16248:function(e,t,n){"use strict";n.d(t,{J:function(){return u}});var r=n(58250),i=n(92013),o=n(23145),a=n(16465),s=n(57437),l={path:(0,s.jsxs)("g",{stroke:"currentColor",strokeWidth:"1.5",children:[(0,s.jsx)("path",{strokeLinecap:"round",fill:"none",d:"M9,9a3,3,0,1,1,4,2.829,1.5,1.5,0,0,0-1,1.415V14.25"}),(0,s.jsx)("path",{fill:"currentColor",strokeLinecap:"round",d:"M12,17.25a.375.375,0,1,0,.375.375A.375.375,0,0,0,12,17.25h0"}),(0,s.jsx)("circle",{fill:"none",strokeMiterlimit:"10",cx:"12",cy:"12",r:"11.25"})]}),viewBox:"0 0 24 24"},u=(0,r.forwardRef)((e,t)=>{let{as:n,viewBox:r,color:u="currentColor",focusable:c=!1,children:d,className:f,__css:p,...h}=e,m=(0,a.cx)("chakra-icon",f),v=(0,i.useStyleConfig)("Icon",e),g={w:"1em",h:"1em",display:"inline-block",lineHeight:"1em",flexShrink:0,color:u,...p,...v},y={ref:t,focusable:c,className:m,__css:g},b=null!=r?r:l.viewBox;if(n&&"string"!=typeof n)return(0,s.jsx)(o.chakra.svg,{as:n,...y,...h});let x=null!=d?d:l.path;return(0,s.jsx)(o.chakra.svg,{verticalAlign:"middle",viewBox:b,...y,...h,children:x})});u.displayName="Icon"},24990:function(e,t,n){"use strict";n.r(t),n.d(t,{Icon:function(){return r.J},createIcon:function(){return createIcon}});var r=n(16248),i=n(58250),o=n(2265),a=n(57437);function createIcon(e){let{viewBox:t="0 0 24 24",d:n,displayName:s,defaultProps:l={}}=e,u=o.Children.toArray(e.path),c=(0,i.forwardRef)((e,i)=>(0,a.jsx)(r.J,{ref:i,viewBox:t,...l,...e,children:u.length?u:(0,a.jsx)("path",{fill:"currentColor",d:n})}));return c.displayName=s,c}},21366:function(e,t,n){"use strict";n.d(t,{d:function(){return useImage},z:function(){return shouldShowFallbackImage}});var r=n(67673),i=n(2265);function useImage(e){let{loading:t,src:n,srcSet:o,onLoad:a,onError:s,crossOrigin:l,sizes:u,ignoreFallback:c}=e,[d,f]=(0,i.useState)("pending");(0,i.useEffect)(()=>{f(n?"loading":"pending")},[n]);let p=(0,i.useRef)(),h=(0,i.useCallback)(()=>{if(!n)return;flush();let e=new Image;e.src=n,l&&(e.crossOrigin=l),o&&(e.srcset=o),u&&(e.sizes=u),t&&(e.loading=t),e.onload=e=>{flush(),f("loaded"),null==a||a(e)},e.onerror=e=>{flush(),f("failed"),null==s||s(e)},p.current=e},[n,l,o,u,a,s,t]),flush=()=>{p.current&&(p.current.onload=null,p.current.onerror=null,p.current=null)};return(0,r.G)(()=>{if(!c)return"loading"===d&&h(),()=>{flush()}},[d,h,c]),c?"loaded":d}var shouldShowFallbackImage=(e,t)=>"loaded"!==e&&"beforeLoadOrError"===t||"failed"===e&&"onError"===t},59616:function(e,t,n){"use strict";n.r(t),n.d(t,{Image:function(){return l},Img:function(){return u},useImage:function(){return a.d}});var r=n(58250),i=n(57437),o=(0,r.forwardRef)(function(e,t){let{htmlWidth:n,htmlHeight:r,alt:o,...a}=e;return(0,i.jsx)("img",{width:n,height:r,ref:t,alt:o,...a})});o.displayName="NativeImage";var a=n(21366),s=n(23145),l=(0,r.forwardRef)(function(e,t){let{fallbackSrc:n,fallback:r,src:l,srcSet:u,align:c,fit:d,loading:f,ignoreFallback:p,crossOrigin:h,fallbackStrategy:m="beforeLoadOrError",referrerPolicy:v,...g}=e,y=null!=f||p||!(void 0!==n||void 0!==r),b=(0,a.d)({...e,crossOrigin:h,ignoreFallback:y}),x=(0,a.z)(b,m),w={ref:t,objectFit:d,objectPosition:c,...y?g:function(e,t=[]){let n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}(g,["onError","onLoad"])};return x?r||(0,i.jsx)(s.chakra.img,{as:o,className:"chakra-image__placeholder",src:n,...w}):(0,i.jsx)(s.chakra.img,{as:o,src:l,srcSet:u,crossOrigin:h,loading:f,referrerPolicy:v,className:"chakra-image",...w})});l.displayName="Image";var u=(0,r.forwardRef)((e,t)=>(0,i.jsx)(s.chakra.img,{ref:t,as:o,className:"chakra-image",...e}))},36366:function(e,t,n){"use strict";n.r(t),n.d(t,{Input:function(){return E.I},InputAddon:function(){return y},InputGroup:function(){return m},InputLeftAddon:function(){return b},InputLeftElement:function(){return S},InputRightAddon:function(){return x},InputRightElement:function(){return C},useInputGroupStyles:function(){return h}});var r=n(310),i=n(61158),o=n(58250),a=n(92013),s=n(50446),l=n(23145),u=n(16465),c=n(89565),d=n(2265),f=n(57437),[p,h]=(0,r.k)({name:"InputGroupStylesContext",errorMessage:"useInputGroupStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),m=(0,o.forwardRef)(function(e,t){let n=(0,a.useMultiStyleConfig)("Input",e),{children:r,className:o,...h}=(0,s.Lr)(e),m=(0,u.cx)("chakra-input__group",o),v={},g=(0,i.W)(r),y=n.field;g.forEach(e=>{var t,r;n&&(y&&"InputLeftElement"===e.type.id&&(v.paddingStart=null!=(t=y.height)?t:y.h),y&&"InputRightElement"===e.type.id&&(v.paddingEnd=null!=(r=y.height)?r:y.h),"InputRightAddon"===e.type.id&&(v.borderEndRadius=0),"InputLeftAddon"===e.type.id&&(v.borderStartRadius=0))});let b=g.map(t=>{var n,r;let i=(0,c.o)({size:(null==(n=t.props)?void 0:n.size)||e.size,variant:(null==(r=t.props)?void 0:r.variant)||e.variant});return"Input"!==t.type.id?(0,d.cloneElement)(t,i):(0,d.cloneElement)(t,Object.assign(i,v,t.props))});return(0,f.jsx)(l.chakra.div,{className:m,ref:t,__css:{width:"100%",display:"flex",position:"relative",isolation:"isolate",...n.group},"data-group":!0,...h,children:(0,f.jsx)(p,{value:n,children:b})})});m.displayName="InputGroup";var v={left:{marginEnd:"-1px",borderEndRadius:0,borderEndColor:"transparent"},right:{marginStart:"-1px",borderStartRadius:0,borderStartColor:"transparent"}},g=(0,l.chakra)("div",{baseStyle:{flex:"0 0 auto",width:"auto",display:"flex",alignItems:"center",whiteSpace:"nowrap"}}),y=(0,o.forwardRef)(function(e,t){var n;let{placement:r="left",...i}=e,o=null!=(n=v[r])?n:{},a=h();return(0,f.jsx)(g,{ref:t,...i,__css:{...a.addon,...o}})});y.displayName="InputAddon";var b=(0,o.forwardRef)(function(e,t){return(0,f.jsx)(y,{ref:t,placement:"left",...e,className:(0,u.cx)("chakra-input__left-addon",e.className)})});b.displayName="InputLeftAddon",b.id="InputLeftAddon";var x=(0,o.forwardRef)(function(e,t){return(0,f.jsx)(y,{ref:t,placement:"right",...e,className:(0,u.cx)("chakra-input__right-addon",e.className)})});x.displayName="InputRightAddon",x.id="InputRightAddon";var w=(0,l.chakra)("div",{baseStyle:{display:"flex",alignItems:"center",justifyContent:"center",position:"absolute",top:"0",zIndex:2}}),k=(0,o.forwardRef)(function(e,t){var n,r;let{placement:i="left",...o}=e,a=h(),s=a.field,l={["left"===i?"insetStart":"insetEnd"]:"0",width:null!=(n=null==s?void 0:s.height)?n:null==s?void 0:s.h,height:null!=(r=null==s?void 0:s.height)?r:null==s?void 0:s.h,fontSize:null==s?void 0:s.fontSize,...a.element};return(0,f.jsx)(w,{ref:t,__css:l,...o})});k.id="InputElement",k.displayName="InputElement";var S=(0,o.forwardRef)(function(e,t){let{className:n,...r}=e,i=(0,u.cx)("chakra-input__left-element",n);return(0,f.jsx)(k,{ref:t,placement:"left",className:i,...r})});S.id="InputLeftElement",S.displayName="InputLeftElement";var C=(0,o.forwardRef)(function(e,t){let{className:n,...r}=e,i=(0,u.cx)("chakra-input__right-element",n);return(0,f.jsx)(k,{ref:t,placement:"right",className:i,...r})});C.id="InputRightElement",C.displayName="InputRightElement";var E=n(51091)},13158:function(e,t,n){"use strict";n.r(t),n.d(t,{AbsoluteCenter:function(){return K},AspectRatio:function(){return H},Badge:function(){return z},Box:function(){return L},Center:function(){return G},Circle:function(){return F},Code:function(){return X},Container:function(){return Z},Divider:function(){return Y},Flex:function(){return Q.k},Grid:function(){return x},GridItem:function(){return I},HStack:function(){return R},Heading:function(){return j},Highlight:function(){return Highlight},Indicator:function(){return B},Kbd:function(){return W},Link:function(){return u},LinkBox:function(){return U},LinkOverlay:function(){return $},List:function(){return m},ListIcon:function(){return b},ListItem:function(){return y},Mark:function(){return V},OrderedList:function(){return v},SimpleGrid:function(){return C},Spacer:function(){return E},Square:function(){return O},Stack:function(){return _},StackDivider:function(){return StackDivider},StackItem:function(){return StackItem},Text:function(){return P.x},UnorderedList:function(){return g},VStack:function(){return N},Wrap:function(){return A},WrapItem:function(){return M},useHighlight:function(){return useHighlight},useListStyles:function(){return h}});var r=n(58250),i=n(92013),o=n(50446),a=n(23145),s=n(16465),l=n(57437),u=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("Link",e),{className:r,isExternal:u,...c}=(0,o.Lr)(e);return(0,l.jsx)(a.chakra.a,{target:u?"_blank":void 0,rel:u?"noopener":void 0,ref:t,className:(0,s.cx)("chakra-link",r),...c,__css:n})});u.displayName="Link";var c=n(16248),d=n(310),f=n(61158),[p,h]=(0,d.k)({name:"ListStylesContext",errorMessage:"useListStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),m=(0,r.forwardRef)(function(e,t){let n=(0,i.useMultiStyleConfig)("List",e),{children:r,styleType:s="none",stylePosition:u,spacing:c,...d}=(0,o.Lr)(e),h=(0,f.W)(r);return(0,l.jsx)(p,{value:n,children:(0,l.jsx)(a.chakra.ul,{ref:t,listStyleType:s,listStylePosition:u,role:"list",__css:{...n.container,...c?{"& > *:not(style) ~ *:not(style)":{mt:c}}:{}},...d,children:h})})});m.displayName="List";var v=(0,r.forwardRef)((e,t)=>{let{as:n,...r}=e;return(0,l.jsx)(m,{ref:t,as:"ol",styleType:"decimal",marginStart:"1em",...r})});v.displayName="OrderedList";var g=(0,r.forwardRef)(function(e,t){let{as:n,...r}=e;return(0,l.jsx)(m,{ref:t,as:"ul",styleType:"initial",marginStart:"1em",...r})});g.displayName="UnorderedList";var y=(0,r.forwardRef)(function(e,t){let n=h();return(0,l.jsx)(a.chakra.li,{ref:t,...e,__css:n.item})});y.displayName="ListItem";var b=(0,r.forwardRef)(function(e,t){let n=h();return(0,l.jsx)(c.J,{ref:t,role:"presentation",...e,__css:n.icon})});b.displayName="ListIcon";var x=(0,r.forwardRef)(function(e,t){let{templateAreas:n,gap:r,rowGap:i,columnGap:o,column:s,row:u,autoFlow:c,autoRows:d,templateRows:f,autoColumns:p,templateColumns:h,...m}=e;return(0,l.jsx)(a.chakra.div,{ref:t,__css:{display:"grid",gridTemplateAreas:n,gridGap:r,gridRowGap:i,gridColumnGap:o,gridAutoColumns:p,gridColumn:s,gridRow:u,gridAutoFlow:c,gridAutoRows:d,gridTemplateRows:f,gridTemplateColumns:h},...m})});x.displayName="Grid";var w=n(90865),k=n(12704),S=n(71369),C=(0,r.forwardRef)(function(e,t){let{columns:n,spacingX:r,spacingY:i,spacing:o,minChildWidth:a,...s}=e,u=(0,w.useTheme)(),c=a?(0,S.XQ)(a,e=>{let t=(0,k.getToken)("sizes",e,"number"==typeof e?`${e}px`:e)(u);return null===e?null:`repeat(auto-fit, minmax(${t}, 1fr))`}):(0,S.XQ)(n,e=>null===e?null:`repeat(${e}, minmax(0, 1fr))`);return(0,l.jsx)(x,{ref:t,gap:o,columnGap:r,rowGap:i,templateColumns:c,...s})});C.displayName="SimpleGrid";var E=(0,a.chakra)("div",{baseStyle:{flex:1,justifySelf:"stretch",alignSelf:"stretch"}});E.displayName="Spacer";var P=n(79980),T=n(2265),A=(0,r.forwardRef)(function(e,t){let{spacing:n="0.5rem",spacingX:r,spacingY:i,children:o,justify:u,direction:c,align:d,className:f,shouldWrapChildren:p,...h}=e,m=(0,T.useMemo)(()=>p?T.Children.map(o,(e,t)=>(0,l.jsx)(M,{children:e},t)):o,[o,p]);return(0,l.jsx)(a.chakra.div,{ref:t,className:(0,s.cx)("chakra-wrap",f),...h,children:(0,l.jsx)(a.chakra.ul,{className:"chakra-wrap__list",__css:{display:"flex",flexWrap:"wrap",justifyContent:u,alignItems:d,flexDirection:c,listStyleType:"none",gap:n,columnGap:r,rowGap:i,padding:"0"},children:m})})});A.displayName="Wrap";var M=(0,r.forwardRef)(function(e,t){let{className:n,...r}=e;return(0,l.jsx)(a.chakra.li,{ref:t,__css:{display:"flex",alignItems:"flex-start"},className:(0,s.cx)("chakra-wrap__listitem",n),...r})});M.displayName="WrapItem";var StackDivider=e=>(0,l.jsx)(a.chakra.div,{className:"chakra-stack__divider",...e,__css:{...e.__css,borderWidth:0,alignSelf:"stretch",borderColor:"inherit",width:"auto",height:"auto"}});StackDivider.displayName="StackDivider";var StackItem=e=>(0,l.jsx)(a.chakra.div,{className:"chakra-stack__item",...e,__css:{display:"inline-block",flex:"0 0 auto",minWidth:0,...e.__css}});StackItem.displayName="StackItem";var _=(0,r.forwardRef)((e,t)=>{let{isInline:n,direction:r,align:i,justify:o,spacing:u="0.5rem",wrap:c,children:d,divider:p,className:h,shouldWrapChildren:m,...v}=e,g=n?"row":null!=r?r:"column",y=(0,T.useMemo)(()=>(function(e){let{spacing:t,direction:n}=e,r={column:{my:t,mx:0,borderLeftWidth:0,borderBottomWidth:"1px"},"column-reverse":{my:t,mx:0,borderLeftWidth:0,borderBottomWidth:"1px"},row:{mx:t,my:0,borderLeftWidth:"1px",borderBottomWidth:0},"row-reverse":{mx:t,my:0,borderLeftWidth:"1px",borderBottomWidth:0}};return{"&":(0,S.XQ)(n,e=>r[e])}})({spacing:u,direction:g}),[u,g]),b=!!p,x=!m&&!b,w=(0,T.useMemo)(()=>{let e=(0,f.W)(d);return x?e:e.map((t,n)=>{let r=void 0!==t.key?t.key:n,i=n+1===e.length,o=(0,l.jsx)(StackItem,{children:t},r),a=m?o:t;if(!b)return a;let s=(0,T.cloneElement)(p,{__css:y});return(0,l.jsxs)(T.Fragment,{children:[a,i?null:s]},r)})},[p,y,b,x,m,d]),k=(0,s.cx)("chakra-stack",h);return(0,l.jsx)(a.chakra.div,{ref:t,display:"flex",alignItems:i,justifyContent:o,flexDirection:g,flexWrap:c,gap:b?void 0:u,className:k,...v,children:w})});_.displayName="Stack";var N=(0,r.forwardRef)((e,t)=>(0,l.jsx)(_,{align:"center",...e,direction:"column",ref:t}));N.displayName="VStack";var R=(0,r.forwardRef)((e,t)=>(0,l.jsx)(_,{align:"center",...e,direction:"row",ref:t}));R.displayName="HStack";var D=n(89565);function spanFn(e){return(0,S.XQ)(e,e=>"auto"===e?"auto":`span ${e}/span ${e}`)}var I=(0,r.forwardRef)(function(e,t){let{area:n,colSpan:r,colStart:i,colEnd:o,rowEnd:s,rowSpan:u,rowStart:c,...d}=e,f=(0,D.o)({gridArea:n,gridColumn:spanFn(r),gridRow:spanFn(u),gridColumnStart:i,gridColumnEnd:o,gridRowStart:c,gridRowEnd:s});return(0,l.jsx)(a.chakra.div,{ref:t,__css:f,...d})});I.displayName="GridItem";var j=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("Heading",e),{className:r,...u}=(0,o.Lr)(e);return(0,l.jsx)(a.chakra.h2,{ref:t,className:(0,s.cx)("chakra-heading",e.className),...u,__css:n})});j.displayName="Heading";var L=(0,a.chakra)("div");L.displayName="Box";var O=(0,r.forwardRef)(function(e,t){let{size:n,centerContent:r=!0,...i}=e;return(0,l.jsx)(L,{ref:t,boxSize:n,__css:{...r?{display:"flex",alignItems:"center",justifyContent:"center"}:{},flexShrink:0,flexGrow:0},...i})});O.displayName="Square";var F=(0,r.forwardRef)(function(e,t){let{size:n,...r}=e;return(0,l.jsx)(O,{size:n,ref:t,borderRadius:"9999px",...r})});F.displayName="Circle";var escapeRegexp=e=>e.replace(/[|\\{}()[\]^$+*?.-]/g,e=>`\\${e}`);function useHighlight(e){let{text:t,query:n}=e;return(0,T.useMemo)(()=>(function({text:e,query:t}){let n=function(e){let t=e.filter(e=>0!==e.length).map(e=>escapeRegexp(e.trim()));return t.length?RegExp(`(${t.join("|")})`,"ig"):null}(Array.isArray(t)?t:[t]);if(!n)return[{text:e,match:!1}];let r=e.split(n).filter(Boolean);return r.map(e=>({text:e,match:n.test(e)}))})({text:t,query:n}),[t,n])}var V=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("Mark",e),r=(0,o.Lr)(e);return(0,l.jsx)(L,{ref:t,...r,as:"mark",__css:{bg:"transparent",whiteSpace:"nowrap",...n}})});function Highlight(e){let{children:t,query:n,styles:r}=e;if("string"!=typeof t)throw Error("The children prop of Highlight must be a string");let i=useHighlight({query:n,text:t});return(0,l.jsx)(l.Fragment,{children:i.map((e,t)=>e.match?(0,l.jsx)(V,{sx:r,children:e.text},t):(0,l.jsx)(T.Fragment,{children:e.text},t))})}var B=(0,r.forwardRef)(function(e,t){let{offsetX:n,offsetY:r,offset:i="0",placement:o="top-end",...s}=e,u=(0,T.useMemo)(()=>({display:"inline-flex",justifyContent:"center",alignItems:"center",position:"absolute",insetBlockStart:(0,S.XQ)(o,e=>{let[t]=e.split("-");return({top:null!=r?r:i,middle:"50%",bottom:"auto"})[t]}),insetBlockEnd:(0,S.XQ)(o,e=>{let[t]=e.split("-");return({top:"auto",middle:"50%",bottom:null!=r?r:i})[t]}),insetStart:(0,S.XQ)(o,e=>{let[,t]=e.split("-");return({start:null!=n?n:i,center:"50%",end:"auto"})[t]}),insetEnd:(0,S.XQ)(o,e=>{let[,t]=e.split("-");return({start:"auto",center:"50%",end:null!=n?n:i})[t]}),translate:(0,S.XQ)(o,e=>{let[t,n]=e.split("-");return`${({start:"-50%",center:"-50%",end:"50%"})[n]} ${({top:"-50%",middle:"-50%",bottom:"50%"})[t]}`})}),[i,n,r,o]);return(0,l.jsx)(a.chakra.div,{ref:t,__css:u,...s})}),W=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("Kbd",e),{className:r,...u}=(0,o.Lr)(e);return(0,l.jsx)(a.chakra.kbd,{ref:t,className:(0,s.cx)("chakra-kbd",r),...u,__css:{fontFamily:"mono",...n}})});W.displayName="Kbd";var $=(0,r.forwardRef)(function(e,t){let{isExternal:n,target:r,rel:i,className:o,...u}=e;return(0,l.jsx)(a.chakra.a,{...u,ref:t,className:(0,s.cx)("chakra-linkbox__overlay",o),rel:n?"noopener noreferrer":i,target:n?"_blank":r,__css:{position:"static","&::before":{content:"''",cursor:"inherit",display:"block",position:"absolute",top:0,left:0,zIndex:0,width:"100%",height:"100%"}}})}),U=(0,r.forwardRef)(function(e,t){let{className:n,...r}=e;return(0,l.jsx)(a.chakra.div,{ref:t,position:"relative",...r,className:(0,s.cx)("chakra-linkbox",n),__css:{"a[href]:not(.chakra-linkbox__overlay), abbr[title]":{position:"relative",zIndex:1}}})}),H=(0,r.forwardRef)(function(e,t){let{ratio:n=4/3,children:r,className:i,...o}=e,u=T.Children.only(r),c=(0,s.cx)("chakra-aspect-ratio",i);return(0,l.jsx)(a.chakra.div,{ref:t,position:"relative",className:c,_before:{height:0,content:'""',display:"block",paddingBottom:(0,S.XQ)(n,e=>`${1/e*100}%`)},__css:{"& > *:not(style)":{overflow:"hidden",position:"absolute",top:"0",right:"0",bottom:"0",left:"0",display:"flex",justifyContent:"center",alignItems:"center",width:"100%",height:"100%"},"& > img, & > video":{objectFit:"cover"}},...o,children:u})});H.displayName="AspectRatio";var z=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("Badge",e),{className:r,...u}=(0,o.Lr)(e);return(0,l.jsx)(a.chakra.span,{ref:t,className:(0,s.cx)("chakra-badge",e.className),...u,__css:{display:"inline-block",whiteSpace:"nowrap",verticalAlign:"middle",...n}})});z.displayName="Badge";var G=(0,a.chakra)("div",{baseStyle:{display:"flex",alignItems:"center",justifyContent:"center"}});G.displayName="Center";var q={horizontal:{insetStart:"50%",transform:"translateX(-50%)"},vertical:{top:"50%",transform:"translateY(-50%)"},both:{insetStart:"50%",top:"50%",transform:"translate(-50%, -50%)"}},K=(0,r.forwardRef)(function(e,t){let{axis:n="both",...r}=e;return(0,l.jsx)(a.chakra.div,{ref:t,__css:q[n],...r,position:"absolute"})}),X=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("Code",e),{className:r,...u}=(0,o.Lr)(e);return(0,l.jsx)(a.chakra.code,{ref:t,className:(0,s.cx)("chakra-code",e.className),...u,__css:{display:"inline-block",...n}})});X.displayName="Code";var Z=(0,r.forwardRef)(function(e,t){let{className:n,centerContent:r,...u}=(0,o.Lr)(e),c=(0,i.useStyleConfig)("Container",e);return(0,l.jsx)(a.chakra.div,{ref:t,className:(0,s.cx)("chakra-container",n),...u,__css:{...c,...r&&{display:"flex",flexDirection:"column",alignItems:"center"}}})});Z.displayName="Container";var Y=(0,r.forwardRef)(function(e,t){let{borderLeftWidth:n,borderBottomWidth:r,borderTopWidth:u,borderRightWidth:c,borderWidth:d,borderStyle:f,borderColor:p,...h}=(0,i.useStyleConfig)("Divider",e),{className:m,orientation:v="horizontal",__css:g,...y}=(0,o.Lr)(e);return(0,l.jsx)(a.chakra.hr,{ref:t,"aria-orientation":v,...y,__css:{...h,border:"0",borderColor:p,borderStyle:f,...{vertical:{borderLeftWidth:n||c||d||"1px",height:"100%"},horizontal:{borderBottomWidth:r||u||d||"1px",width:"100%"}}[v],...g},className:(0,s.cx)("chakra-divider",m)})});Y.displayName="Divider";var Q=n(26621)},21450:function(e,t,n){"use strict";function lazyDisclosure(e){let{wasSelected:t,enabled:n,isSelected:r,mode:i="unmount"}=e;return!n||!!r||"keepMounted"===i&&!!t}n.d(t,{k:function(){return lazyDisclosure}})},10128:function(e,t,n){"use strict";n.d(t,{a:function(){return useMediaQuery}});var r=n(52733),i=n(2265);function useMediaQuery(e,t={}){let{ssr:n=!0,fallback:o}=t,{getWindow:a}=(0,r.O)(),s=Array.isArray(e)?e:[e],l=Array.isArray(o)?o:[o];l=l.filter(e=>null!=e);let[u,c]=(0,i.useState)(()=>s.map((e,t)=>({media:e,matches:n?!!l[t]:a().matchMedia(e).matches})));return(0,i.useEffect)(()=>{let e=a();c(s.map(t=>({media:t,matches:e.matchMedia(t).matches})));let t=s.map(t=>e.matchMedia(t)),handler=e=>{c(t=>t.slice().map(t=>t.media===e.media?{...t,matches:e.matches}:t))};return t.forEach(e=>{"function"==typeof e.addListener?e.addListener(handler):e.addEventListener("change",handler)}),()=>{t.forEach(e=>{"function"==typeof e.removeListener?e.removeListener(handler):e.removeEventListener("change",handler)})}},[a]),u.map(e=>e.matches)}},74564:function(e,t,n){"use strict";n.d(t,{G:function(){return useBreakpoint}});var r=n(10128),i=n(90865),o=n(16465);function useBreakpoint(e){var t,n;let a=(0,o.Kn)(e)?e:{fallback:null!=e?e:"base"},s=(0,i.useTheme)(),l=s.__breakpoints.details.map(({minMaxQuery:e,breakpoint:t})=>({breakpoint:t,query:e.replace("@media screen and ","")})),u=l.map(e=>e.breakpoint===a.fallback),c=(0,r.a)(l.map(e=>e.query),{fallback:u,ssr:a.ssr}),d=c.findIndex(e=>!0==e);return null!=(n=null==(t=l[d])?void 0:t.breakpoint)?n:a.fallback}},63087:function(e,t,n){"use strict";n.d(t,{S:function(){return useBreakpointValue}});var r=n(71369),i=n(74564),o=n(90865),a=n(16465);function useBreakpointValue(e,t){var n;let s=(0,a.Kn)(t)?t:{fallback:null!=t?t:"base"},l=(0,i.G)(s),u=(0,o.useTheme)();if(!l)return;let c=Array.from((null==(n=u.__breakpoints)?void 0:n.keys)||[]),d=Array.isArray(e)?Object.fromEntries(Object.entries((0,r.Yq)(e,c)).map(([e,t])=>[e,t])):e;return function(e,t,n=r.AV){let i=Object.keys(e).indexOf(t);if(-1!==i)return e[t];let o=n.indexOf(t);for(;o>=0;){let t=n[o];if(e.hasOwnProperty(t)){i=o;break}o-=1}if(-1!==i){let t=n[i];return e[t]}}(d,l,c)}},71082:function(e,t,n){"use strict";n.r(t),n.d(t,{Hide:function(){return Hide},Show:function(){return Show},useBreakpoint:function(){return s.G},useBreakpointValue:function(){return a.S},useColorModePreference:function(){return useColorModePreference},useMediaQuery:function(){return r.a},usePrefersReducedMotion:function(){return usePrefersReducedMotion},useQuery:function(){return useQuery}});var r=n(10128);function Visibility(e){let{breakpoint:t,hide:n,children:i,ssr:o}=e,[a]=(0,r.a)(t,{ssr:o});return(n?!a:a)?i:null}var i=n(90865),getBreakpoint=(e,t)=>{var n,r;return null!=(r=null==(n=null==e?void 0:e.breakpoints)?void 0:n[t])?r:t};function useQuery(e){let{breakpoint:t="",below:n,above:r}=e,o=(0,i.useTheme)(),a=getBreakpoint(o,n),s=getBreakpoint(o,r),l=t;return a?l=`(max-width: ${a})`:s&&(l=`(min-width: ${s})`),l}var o=n(57437);function Hide(e){let{children:t,ssr:n}=e,r=useQuery(e);return(0,o.jsx)(Visibility,{breakpoint:r,hide:!0,ssr:n,children:t})}function usePrefersReducedMotion(e){let[t]=(0,r.a)("(prefers-reduced-motion: reduce)",e);return t}function useColorModePreference(e){let[t,n]=(0,r.a)(["(prefers-color-scheme: light)","(prefers-color-scheme: dark)"],e);return t?"light":n?"dark":void 0}function Show(e){let{children:t,ssr:n}=e,r=useQuery(e);return(0,o.jsx)(Visibility,{breakpoint:r,ssr:n,children:t})}Hide.displayName="Hide",Show.displayName="Show";var a=n(63087),s=n(74564)},10046:function(e,t,n){"use strict";n.r(t),n.d(t,{Menu:function(){return Menu},MenuButton:function(){return W},MenuCommand:function(){return R},MenuDescendantsProvider:function(){return y},MenuDivider:function(){return MenuDivider},MenuGroup:function(){return V},MenuIcon:function(){return MenuIcon},MenuItem:function(){return I},MenuItemOption:function(){return $},MenuList:function(){return F},MenuOptionGroup:function(){return MenuOptionGroup},MenuProvider:function(){return k},useMenu:function(){return useMenu},useMenuButton:function(){return useMenuButton},useMenuContext:function(){return S},useMenuDescendant:function(){return w},useMenuDescendants:function(){return x},useMenuDescendantsContext:function(){return b},useMenuItem:function(){return useMenuItem},useMenuList:function(){return useMenuList},useMenuOption:function(){return useMenuOption},useMenuOptionGroup:function(){return useMenuOptionGroup},useMenuPositioner:function(){return useMenuPositioner},useMenuState:function(){return useMenuState},useMenuStyles:function(){return M}});var r=n(2265),i=n(13079),o=n(64763),a=n(81958),s=n(1521),l=n(61113),u=n(37977);function isValidEvent(e,t){var n;let r=e.target;if(r){let e=getOwnerDocument(r);if(!e.contains(r))return!1}return!(null==(n=t.current)?void 0:n.contains(r))}function getOwnerDocument(e){var t;return null!=(t=null==e?void 0:e.ownerDocument)?t:document}var c=n(12937),d=n(310),f=n(61158),p=n(27771),h=n(89656),m=n(45663),v=n(16465),g=n(21450),[y,b,x,w]=(0,o.n)(),[k,S]=(0,d.k)({strict:!1,name:"MenuContext"});function chunk_SANI5SUM_getOwnerDocument(e){var t;return null!=(t=null==e?void 0:e.ownerDocument)?t:document}function isActiveElement(e){let t=chunk_SANI5SUM_getOwnerDocument(e);return t.activeElement===e}function useMenu(e={}){let{id:t,closeOnSelect:n=!0,closeOnBlur:i=!0,initialFocusRef:o,autoSelect:d=!0,isLazy:f,isOpen:p,defaultIsOpen:m,onClose:v,onOpen:g,placement:y="bottom-start",lazyBehavior:b="unmount",direction:w,computePositionOnMount:k=!1,...S}=e,C=(0,r.useRef)(null),E=(0,r.useRef)(null),P=x(),T=(0,r.useCallback)(()=>{requestAnimationFrame(()=>{var e;null==(e=C.current)||e.focus({preventScroll:!1})})},[]),A=(0,r.useCallback)(()=>{let e=setTimeout(()=>{var e;if(o)null==(e=o.current)||e.focus();else{let e=P.firstEnabled();e&&O(e.index)}});$.current.add(e)},[P,o]),M=(0,r.useCallback)(()=>{let e=setTimeout(()=>{let e=P.lastEnabled();e&&O(e.index)});$.current.add(e)},[P]),_=(0,r.useCallback)(()=>{null==g||g(),d?A():T()},[d,A,T,g]),{isOpen:N,onOpen:R,onClose:D,onToggle:I}=(0,l.q)({isOpen:p,defaultIsOpen:m,onClose:v,onOpen:_});!function(e){let{ref:t,handler:n,enabled:i=!0}=e,o=(0,u.W)(n),a=(0,r.useRef)({isPointerDown:!1,ignoreEmulatedMouseEvents:!1}),s=a.current;(0,r.useEffect)(()=>{if(!i)return;let onPointerDown=e=>{isValidEvent(e,t)&&(s.isPointerDown=!0)},onMouseUp=e=>{if(s.ignoreEmulatedMouseEvents){s.ignoreEmulatedMouseEvents=!1;return}s.isPointerDown&&n&&isValidEvent(e,t)&&(s.isPointerDown=!1,o(e))},onTouchEnd=e=>{s.ignoreEmulatedMouseEvents=!0,n&&s.isPointerDown&&isValidEvent(e,t)&&(s.isPointerDown=!1,o(e))},e=getOwnerDocument(t.current);return e.addEventListener("mousedown",onPointerDown,!0),e.addEventListener("mouseup",onMouseUp,!0),e.addEventListener("touchstart",onPointerDown,!0),e.addEventListener("touchend",onTouchEnd,!0),()=>{e.removeEventListener("mousedown",onPointerDown,!0),e.removeEventListener("mouseup",onMouseUp,!0),e.removeEventListener("touchstart",onPointerDown,!0),e.removeEventListener("touchend",onTouchEnd,!0)}},[n,t,o,s,i])}({enabled:N&&i,ref:C,handler:e=>{var t;(null==(t=E.current)?void 0:t.contains(e.target))||D()}});let j=(0,s.D)({...S,enabled:N||k,placement:y,direction:w}),[L,O]=(0,r.useState)(-1);(0,h.r)(()=>{N||O(-1)},[N]),(0,a.C)(C,{focusRef:E,visible:N,shouldFocus:!0});let F=(0,c.h)({isOpen:N,ref:C}),[V,B]=function(e,...t){let n=(0,r.useId)(),i=e||n;return(0,r.useMemo)(()=>t.map(e=>`${e}-${i}`),[i,t])}(t,"menu-button","menu-list"),W=(0,r.useCallback)(()=>{R(),T()},[R,T]),$=(0,r.useRef)(new Set([]));(0,r.useEffect)(()=>{let e=$.current;return()=>{e.forEach(e=>clearTimeout(e)),e.clear()}},[]);let U=(0,r.useCallback)(()=>{R(),A()},[A,R]),H=(0,r.useCallback)(()=>{R(),M()},[R,M]),z=(0,r.useCallback)(()=>{var e,t;let n=chunk_SANI5SUM_getOwnerDocument(C.current),r=null==(e=C.current)?void 0:e.contains(n.activeElement),i=N&&!r;if(!i)return;let o=null==(t=P.item(L))?void 0:t.node;null==o||o.focus({preventScroll:!0})},[N,L,P]),G=(0,r.useRef)(null);return{openAndFocusMenu:W,openAndFocusFirstItem:U,openAndFocusLastItem:H,onTransitionEnd:z,unstable__animationState:F,descendants:P,popper:j,buttonId:V,menuId:B,forceUpdate:j.forceUpdate,orientation:"vertical",isOpen:N,onToggle:I,onOpen:R,onClose:D,menuRef:C,buttonRef:E,focusedIndex:L,closeOnSelect:n,closeOnBlur:i,autoSelect:d,setFocusedIndex:O,isLazy:f,lazyBehavior:b,initialFocusRef:o,rafId:G}}function useMenuButton(e={},t=null){let n=S(),{onToggle:i,popper:o,openAndFocusFirstItem:a,openAndFocusLastItem:s}=n,l=(0,r.useCallback)(e=>{let t=e.key,n={Enter:a,ArrowDown:a,ArrowUp:s}[t];n&&(e.preventDefault(),e.stopPropagation(),n(e))},[a,s]);return{...e,ref:(0,m.lq)(n.buttonRef,t,o.referenceRef),id:n.buttonId,"data-active":(0,v.PB)(n.isOpen),"aria-expanded":n.isOpen,"aria-haspopup":"menu","aria-controls":n.menuId,onClick:(0,v.v0)(e.onClick,i),onKeyDown:(0,v.v0)(e.onKeyDown,l)}}function isTargetMenuItem(e){var t;return function(e){var t;if(!(null!=e&&"object"==typeof e&&"nodeType"in e&&e.nodeType===Node.ELEMENT_NODE))return!1;let n=null!=(t=e.ownerDocument.defaultView)?t:window;return e instanceof n.HTMLElement}(e)&&!!(null==(t=null==e?void 0:e.getAttribute("role"))?void 0:t.startsWith("menuitem"))}function useMenuList(e={},t=null){let n=S();if(!n)throw Error("useMenuContext: context is undefined. Seems you forgot to wrap component within ");let{focusedIndex:i,setFocusedIndex:o,menuRef:a,isOpen:s,onClose:l,menuId:u,isLazy:c,lazyBehavior:d,unstable__animationState:f}=n,p=b(),h=function(e={}){let{timeout:t=300,preventDefault:n=()=>!0}=e,[i,o]=(0,r.useState)([]),a=(0,r.useRef)(),flush=()=>{a.current&&(clearTimeout(a.current),a.current=null)},clearKeysAfterDelay=()=>{flush(),a.current=setTimeout(()=>{o([]),a.current=null},t)};return(0,r.useEffect)(()=>flush,[]),function(e){return t=>{if("Backspace"===t.key){let e=[...i];e.pop(),o(e);return}if(function(e){let{key:t}=e;return 1===t.length||t.length>1&&/[^a-zA-Z0-9]/.test(t)}(t)){let r=i.concat(t.key);n(t)&&(t.preventDefault(),t.stopPropagation()),o(r),e(r.join("")),clearKeysAfterDelay()}}}}({preventDefault:e=>" "!==e.key&&isTargetMenuItem(e.target)}),y=(0,r.useCallback)(e=>{if(!e.currentTarget.contains(e.target))return;let t=e.key,n={Tab:e=>e.preventDefault(),Escape:l,ArrowDown:()=>{let e=p.nextEnabled(i);e&&o(e.index)},ArrowUp:()=>{let e=p.prevEnabled(i);e&&o(e.index)}}[t];if(n){e.preventDefault(),n(e);return}let r=h(e=>{let t=function(e,t,n,r){if(null==t)return r;if(!r){let r=e.find(e=>n(e).toLowerCase().startsWith(t.toLowerCase()));return r}let i=e.filter(e=>n(e).toLowerCase().startsWith(t.toLowerCase()));if(i.length>0){let t;if(i.includes(r)){let e=i.indexOf(r);return(t=e+1)===i.length&&(t=0),i[t]}return t=e.indexOf(i[0]),e[t]}return r}(p.values(),e,e=>{var t,n;return null!=(n=null==(t=null==e?void 0:e.node)?void 0:t.textContent)?n:""},p.item(i));if(t){let e=p.indexOf(t.node);o(e)}});isTargetMenuItem(e.target)&&r(e)},[p,i,h,l,o]),x=(0,r.useRef)(!1);s&&(x.current=!0);let w=(0,g.k)({wasSelected:x.current,enabled:c,mode:d,isSelected:f.present});return{...e,ref:(0,m.lq)(a,t),children:w?e.children:null,tabIndex:-1,role:"menu",id:u,style:{...e.style,transformOrigin:"var(--popper-transform-origin)"},"aria-orientation":"vertical",onKeyDown:(0,v.v0)(e.onKeyDown,y)}}function useMenuPositioner(e={}){let{popper:t,isOpen:n}=S();return t.getPopperProps({...e,style:{visibility:n?"visible":"hidden",...e.style}})}function useMenuItem(e={},t=null){let{onMouseEnter:n,onMouseMove:o,onMouseLeave:a,onClick:s,onFocus:l,isDisabled:u,isFocusable:c,closeOnSelect:d,type:f,...p}=e,v=S(),{setFocusedIndex:g,focusedIndex:y,closeOnSelect:b,onClose:x,menuRef:k,isOpen:C,menuId:E,rafId:P}=v,T=(0,r.useRef)(null),A=`${E}-menuitem-${(0,r.useId)()}`,{index:M,register:_}=w({disabled:u&&!c}),N=(0,r.useCallback)(e=>{null==n||n(e),u||g(M)},[g,M,u,n]),R=(0,r.useCallback)(e=>{null==o||o(e),T.current&&!isActiveElement(T.current)&&N(e)},[N,o]),D=(0,r.useCallback)(e=>{null==a||a(e),u||g(-1)},[g,u,a]),I=(0,r.useCallback)(e=>{null==s||s(e),isTargetMenuItem(e.currentTarget)&&(null!=d?d:b)&&x()},[x,s,b,d]),j=(0,r.useCallback)(e=>{null==l||l(e),g(M)},[g,l,M]),L=M===y,O=u&&!c;(0,h.r)(()=>{if(C)return L&&!O&&T.current?(P.current&&cancelAnimationFrame(P.current),P.current=requestAnimationFrame(()=>{var e;null==(e=T.current)||e.focus({preventScroll:!0}),P.current=null})):k.current&&!isActiveElement(k.current)&&k.current.focus({preventScroll:!0}),()=>{P.current&&cancelAnimationFrame(P.current)}},[L,O,k,C]);let F=(0,i.h)({onClick:I,onFocus:j,onMouseEnter:N,onMouseMove:R,onMouseLeave:D,ref:(0,m.lq)(_,T,t),isDisabled:u,isFocusable:c});return{...p,...F,type:null!=f?f:F.type,id:A,role:"menuitem",tabIndex:L?0:-1}}function useMenuOption(e={},t=null){let{type:n="radio",isChecked:r,...i}=e,o=useMenuItem(i,t);return{...o,role:`menuitem${n}`,"aria-checked":r}}function useMenuOptionGroup(e={}){let{children:t,type:n="radio",value:i,defaultValue:o,onChange:a,...s}=e,l="radio"===n,[u,c]=(0,p.T)({defaultValue:null!=o?o:l?"":[],value:i,onChange:a}),d=(0,r.useCallback)(e=>{if("radio"===n&&"string"==typeof u&&c(e),"checkbox"===n&&Array.isArray(u)){let t=u.includes(e)?u.filter(t=>t!==e):u.concat(e);c(t)}},[u,c,n]),h=(0,f.W)(t),m=h.map(e=>{if("MenuItemOption"!==e.type.id)return e;let t="radio"===n?e.props.value===u:u.includes(e.props.value);return(0,r.cloneElement)(e,{type:n,onClick:t=>{var n,r;d(e.props.value),null==(r=(n=e.props).onClick)||r.call(n,t)},isChecked:t})});return{...s,children:m}}function useMenuState(){let{isOpen:e,onClose:t}=S();return{isOpen:e,onClose:t}}var C=n(92013),E=n(50446),P=n(90865),T=n(57437),[A,M]=(0,d.k)({name:"MenuStylesContext",errorMessage:"useMenuStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),Menu=e=>{let{children:t}=e,n=(0,C.useMultiStyleConfig)("Menu",e),i=(0,E.Lr)(e),{direction:o}=(0,P.useTheme)(),{descendants:a,...s}=useMenu({...i,direction:o}),l=(0,r.useMemo)(()=>s,[s]),{isOpen:u,onClose:c,forceUpdate:d}=l;return(0,T.jsx)(y,{value:a,children:(0,T.jsx)(k,{value:l,children:(0,T.jsx)(A,{value:n,children:(0,v.Pu)(t,{isOpen:u,onClose:c,forceUpdate:d})})})})};Menu.displayName="Menu";var _=n(58250),N=n(23145),R=(0,_.forwardRef)((e,t)=>{let n=M();return(0,T.jsx)(N.chakra.span,{ref:t,...e,__css:n.command,className:"chakra-menu__command"})});R.displayName="MenuCommand";var D=(0,_.forwardRef)((e,t)=>{let{type:n,...i}=e,o=M(),a=i.as||n?null!=n?n:void 0:"button",s=(0,r.useMemo)(()=>({textDecoration:"none",color:"inherit",userSelect:"none",display:"flex",width:"100%",alignItems:"center",textAlign:"start",flex:"0 0 auto",outline:0,...o.item}),[o.item]);return(0,T.jsx)(N.chakra.button,{ref:t,type:a,...i,__css:s})}),MenuIcon=e=>{let{className:t,children:n,...i}=e,o=M(),a=r.Children.only(n),s=(0,r.isValidElement)(a)?(0,r.cloneElement)(a,{focusable:"false","aria-hidden":!0,className:(0,v.cx)("chakra-menu__icon",a.props.className)}):null,l=(0,v.cx)("chakra-menu__icon-wrapper",t);return(0,T.jsx)(N.chakra.span,{className:l,...i,__css:o.icon,children:s})};MenuIcon.displayName="MenuIcon";var I=(0,_.forwardRef)((e,t)=>{let{icon:n,iconSpacing:r="0.75rem",command:i,commandSpacing:o="0.75rem",children:a,...s}=e,l=useMenuItem(s,t),u=n||i?(0,T.jsx)("span",{style:{pointerEvents:"none",flex:1},children:a}):a;return(0,T.jsxs)(D,{...l,className:(0,v.cx)("chakra-menu__menuitem",l.className),children:[n&&(0,T.jsx)(MenuIcon,{fontSize:"0.8em",marginEnd:r,children:n}),u,i&&(0,T.jsx)(R,{marginStart:o,children:i})]})});I.displayName="MenuItem";var j=n(72638),L={enter:{visibility:"visible",opacity:1,scale:1,transition:{duration:.2,ease:[.4,0,.2,1]}},exit:{transitionEnd:{visibility:"hidden"},opacity:0,scale:.8,transition:{duration:.1,easings:"easeOut"}}},O=(0,N.chakra)(j.E.div),F=(0,_.forwardRef)(function(e,t){var n,r;let{rootProps:i,motionProps:o,...a}=e,{isOpen:s,onTransitionEnd:l,unstable__animationState:u}=S(),c=useMenuList(a,t),d=useMenuPositioner(i),f=M();return(0,T.jsx)(N.chakra.div,{...d,__css:{zIndex:null!=(r=e.zIndex)?r:null==(n=f.list)?void 0:n.zIndex},children:(0,T.jsx)(O,{variants:L,initial:!1,animate:s?"enter":"exit",__css:{outline:0,...f.list},...o,className:(0,v.cx)("chakra-menu__menu-list",c.className),...c,onUpdate:l,onAnimationComplete:(0,v.PP)(u.onComplete,c.onAnimationComplete)})})});F.displayName="MenuList";var V=(0,_.forwardRef)((e,t)=>{let{title:n,children:r,className:i,...o}=e,a=(0,v.cx)("chakra-menu__group__title",i),s=M();return(0,T.jsxs)("div",{ref:t,className:"chakra-menu__group",role:"group",children:[n&&(0,T.jsx)(N.chakra.p,{className:a,...o,__css:s.groupTitle,children:n}),r]})});V.displayName="MenuGroup";var MenuOptionGroup=e=>{let{className:t,title:n,...r}=e,i=useMenuOptionGroup(r);return(0,T.jsx)(V,{title:n,className:(0,v.cx)("chakra-menu__option-group",t),...i})};MenuOptionGroup.displayName="MenuOptionGroup";var B=(0,_.forwardRef)((e,t)=>{let n=M();return(0,T.jsx)(N.chakra.button,{ref:t,...e,__css:{display:"inline-flex",appearance:"none",alignItems:"center",outline:0,...n.button}})}),W=(0,_.forwardRef)((e,t)=>{let{children:n,as:r,...i}=e,o=useMenuButton(i,t),a=r||B;return(0,T.jsx)(a,{...o,className:(0,v.cx)("chakra-menu__menu-button",e.className),children:(0,T.jsx)(N.chakra.span,{__css:{pointerEvents:"none",flex:"1 1 auto",minW:0},children:e.children})})});W.displayName="MenuButton";var MenuDivider=e=>{let{className:t,...n}=e,r=M();return(0,T.jsx)(N.chakra.hr,{"aria-orientation":"horizontal",className:(0,v.cx)("chakra-menu__divider",t),...n,__css:r.divider})};MenuDivider.displayName="MenuDivider";var CheckIcon=e=>(0,T.jsx)("svg",{viewBox:"0 0 14 14",width:"1em",height:"1em",...e,children:(0,T.jsx)("polygon",{fill:"currentColor",points:"5.5 11.9993304 14 3.49933039 12.5 2 5.5 8.99933039 1.5 4.9968652 0 6.49933039"})}),$=(0,_.forwardRef)((e,t)=>{let{icon:n,iconSpacing:r="0.75rem",...i}=e,o=useMenuOption(i,t);return(0,T.jsxs)(D,{...o,className:(0,v.cx)("chakra-menu__menuitem-option",i.className),children:[null!==n&&(0,T.jsx)(MenuIcon,{fontSize:"0.8em",marginEnd:r,opacity:e.isChecked?1:0,children:n||(0,T.jsx)(CheckIcon,{})}),(0,T.jsx)("span",{style:{flex:1},children:o.children})]})});$.id="MenuItemOption",$.displayName="MenuItemOption"},41470:function(e,t,n){"use strict";n.r(t),n.d(t,{AlertDialog:function(){return AlertDialog},AlertDialogBody:function(){return es},AlertDialogCloseButton:function(){return eu},AlertDialogContent:function(){return K},AlertDialogFooter:function(){return en},AlertDialogHeader:function(){return er},AlertDialogOverlay:function(){return ea},Drawer:function(){return Drawer},DrawerBody:function(){return es},DrawerCloseButton:function(){return eu},DrawerContent:function(){return et},DrawerFooter:function(){return en},DrawerHeader:function(){return er},DrawerOverlay:function(){return ea},Modal:function(){return Modal},ModalBody:function(){return es},ModalCloseButton:function(){return eu},ModalContent:function(){return q},ModalContextProvider:function(){return T},ModalFocusScope:function(){return ModalFocusScope},ModalFooter:function(){return en},ModalHeader:function(){return er},ModalOverlay:function(){return ea},useDrawerContext:function(){return Y},useModal:function(){return useModal},useModalContext:function(){return A},useModalManager:function(){return useModalManager},useModalStyles:function(){return P}});var r,i=n(23145),o=n(80834),a=n(20921),s=n(72638),l=n(2265),u=n(57437),c={slideInBottom:{...o.X,custom:{offsetY:16,reverse:!0}},slideInRight:{...o.X,custom:{offsetX:16,reverse:!0}},slideInTop:{...o.X,custom:{offsetY:-16,reverse:!0}},slideInLeft:{...o.X,custom:{offsetX:-16,reverse:!0}},scale:{...a.Q,custom:{initialScale:.95,reverse:!0}},none:{}},d=(0,i.chakra)(s.E.section),getMotionProps=e=>c[e||"none"],f=(0,l.forwardRef)((e,t)=>{let{preset:n,motionProps:r=getMotionProps(n),...i}=e;return(0,u.jsx)(d,{ref:t,...r,...i})});f.displayName="ModalTransition";var p=Object.defineProperty,__defNormalProp=(e,t,n)=>t in e?p(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__publicField=(e,t,n)=>(__defNormalProp(e,"symbol"!=typeof t?t+"":t,n),n),h=new class{constructor(){__publicField(this,"modals"),this.modals=new Map}add(e){return this.modals.set(e,this.modals.size+1),this.modals.size}remove(e){this.modals.delete(e)}isTopModal(e){return!!e&&this.modals.get(e)===this.modals.size}};function useModalManager(e,t){let[n,r]=(0,l.useState)(0);return(0,l.useEffect)(()=>{let n=e.current;if(n){if(t){let e=h.add(n);r(e)}return()=>{h.remove(n),r(0)}}},[t,e]),n}var m=n(16465),v=n(45663),g=new WeakMap,y=new WeakMap,b={},x=0,unwrapHost=function(e){return e&&(e.host||unwrapHost(e.parentNode))},applyAttributeToOthers=function(e,t,n,r){var i=(Array.isArray(e)?e:[e]).map(function(e){if(t.contains(e))return e;var n=unwrapHost(e);return n&&t.contains(n)?n:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e});b[n]||(b[n]=new WeakMap);var o=b[n],a=[],s=new Set,l=new Set(i),keep=function(e){!e||s.has(e)||(s.add(e),keep(e.parentNode))};i.forEach(keep);var deep=function(e){!e||l.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))deep(e);else{var t=e.getAttribute(r),i=null!==t&&"false"!==t,l=(g.get(e)||0)+1,u=(o.get(e)||0)+1;g.set(e,l),o.set(e,u),a.push(e),1===l&&i&&y.set(e,!0),1===u&&e.setAttribute(n,"true"),i||e.setAttribute(r,"true")}})};return deep(t),s.clear(),x++,function(){a.forEach(function(e){var t=g.get(e)-1,i=o.get(e)-1;g.set(e,t),o.set(e,i),t||(y.has(e)||e.removeAttribute(r),y.delete(e)),i||e.removeAttribute(n)}),--x||(g=new WeakMap,g=new WeakMap,y=new WeakMap,b={})}},hideOthers=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=t||("undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live]"))),applyAttributeToOthers(r,i,n,"aria-hidden")):function(){return null}};function useModal(e){let{isOpen:t,onClose:n,id:r,closeOnOverlayClick:i=!0,closeOnEsc:o=!0,useInert:a=!0,onOverlayClick:s,onEsc:u}=e,c=(0,l.useRef)(null),d=(0,l.useRef)(null),[f,p,g]=function(e,...t){let n=(0,l.useId)(),r=e||n;return(0,l.useMemo)(()=>t.map(e=>`${e}-${r}`),[r,t])}(r,"chakra-modal","chakra-modal--header","chakra-modal--body");!function(e,t){let n=e.current;(0,l.useEffect)(()=>{if(e.current&&t)return hideOthers(e.current)},[t,e,n])}(c,t&&a);let y=useModalManager(c,t),b=(0,l.useRef)(null),x=(0,l.useCallback)(e=>{b.current=e.target},[]),w=(0,l.useCallback)(e=>{"Escape"===e.key&&(e.stopPropagation(),o&&(null==n||n()),null==u||u())},[o,n,u]),[k,S]=(0,l.useState)(!1),[C,E]=(0,l.useState)(!1),P=(0,l.useCallback)((e={},t=null)=>({role:"dialog",...e,ref:(0,v.lq)(t,c),id:f,tabIndex:-1,"aria-modal":!0,"aria-labelledby":k?p:void 0,"aria-describedby":C?g:void 0,onClick:(0,m.v0)(e.onClick,e=>e.stopPropagation())}),[g,C,f,p,k]),T=(0,l.useCallback)(e=>{e.stopPropagation(),b.current===e.target&&h.isTopModal(c.current)&&(i&&(null==n||n()),null==s||s())},[n,i,s]),A=(0,l.useCallback)((e={},t=null)=>({...e,ref:(0,v.lq)(t,d),onClick:(0,m.v0)(e.onClick,T),onKeyDown:(0,m.v0)(e.onKeyDown,w),onMouseDown:(0,m.v0)(e.onMouseDown,x)}),[w,x,T]);return{isOpen:t,onClose:n,headerId:p,bodyId:g,setBodyMounted:E,setHeaderMounted:S,dialogRef:c,overlayRef:d,getDialogProps:P,getDialogContainerProps:A,index:y}}var w=n(2879),k=n(310),S=n(92013),C=n(62167),[E,P]=(0,k.k)({name:"ModalStylesContext",errorMessage:"useModalStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),[T,A]=(0,k.k)({strict:!0,name:"ModalContext",errorMessage:"useModalContext: `context` is undefined. Seems you forgot to wrap modal components in ``"}),Modal=e=>{let t={scrollBehavior:"outside",autoFocus:!0,trapFocus:!0,returnFocusOnClose:!0,blockScrollOnMount:!0,allowPinchZoom:!1,motionPreset:"scale",lockFocusAcrossFrames:!0,...e},{portalProps:n,children:r,autoFocus:i,trapFocus:o,initialFocusRef:a,finalFocusRef:s,returnFocusOnClose:l,blockScrollOnMount:c,allowPinchZoom:d,preserveScrollBarGap:f,motionPreset:p,lockFocusAcrossFrames:h,onCloseComplete:m}=t,v=(0,S.useMultiStyleConfig)("Modal",t),g=useModal(t),y={...g,autoFocus:i,trapFocus:o,initialFocusRef:a,finalFocusRef:s,returnFocusOnClose:l,blockScrollOnMount:c,allowPinchZoom:d,preserveScrollBarGap:f,motionPreset:p,lockFocusAcrossFrames:h};return(0,u.jsx)(T,{value:y,children:(0,u.jsx)(E,{value:v,children:(0,u.jsx)(C.M,{onExitComplete:m,children:y.isOpen&&(0,u.jsx)(w.h,{...n,children:r})})})})};Modal.displayName="Modal";var M=n(68609),_=n(77196),N=n(50044),R="right-scroll-bar-position",D="width-before-scroll-bar",I=n(55835),j=(0,n(18427)._)(),nothing=function(){},L=l.forwardRef(function(e,t){var n=l.useRef(null),r=l.useState({onScrollCapture:nothing,onWheelCapture:nothing,onTouchMoveCapture:nothing}),i=r[0],o=r[1],a=e.forwardProps,s=e.children,u=e.className,c=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,h=e.noIsolation,m=e.inert,v=e.allowPinchZoom,g=e.as,y=void 0===g?"div":g,b=e.gapMode,x=(0,N.__rest)(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),w=(0,I.q)([n,t]),k=(0,N.__assign)((0,N.__assign)({},x),i);return l.createElement(l.Fragment,null,d&&l.createElement(p,{sideCar:j,removeScrollBar:c,shards:f,noIsolation:h,inert:m,setCallbacks:o,allowPinchZoom:!!v,lockRef:n,gapMode:b}),a?l.cloneElement(l.Children.only(s),(0,N.__assign)((0,N.__assign)({},k),{ref:w})):l.createElement(y,(0,N.__assign)({},k,{className:u,ref:w}),s))});L.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},L.classNames={fullWidth:D,zeroRight:R};var SideCar=function(e){var t=e.sideCar,n=(0,N.__rest)(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error("Sidecar medium not found");return l.createElement(r,(0,N.__assign)({},n))};SideCar.isSideCarExport=!0;var stylesheetSingleton=function(){var e=0,t=null;return{add:function(i){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=r||n.nc;return t&&e.setAttribute("nonce",t),e}())){var o,a;(o=t).styleSheet?o.styleSheet.cssText=i:o.appendChild(document.createTextNode(i)),a=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(a)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},styleHookSingleton=function(){var e=stylesheetSingleton();return function(t,n){l.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},styleSingleton=function(){var e=styleHookSingleton();return function(t){return e(t.styles,t.dynamic),null}},O={left:0,top:0,right:0,gap:0},parse=function(e){return parseInt(e||"",10)||0},getOffset=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],i=t["padding"===e?"paddingRight":"marginRight"];return[parse(n),parse(r),parse(i)]},getGapWidth=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return O;var t=getOffset(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},F=styleSingleton(),getStyles=function(e,t,n,r){var i=e.left,o=e.top,a=e.right,s=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(s,"px ").concat(r,";\n }\n body {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(i,"px;\n padding-top: ").concat(o,"px;\n padding-right: ").concat(a,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(R," {\n right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(D," {\n margin-right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(R," .").concat(R," {\n right: 0 ").concat(r,";\n }\n \n .").concat(D," .").concat(D," {\n margin-right: 0 ").concat(r,";\n }\n \n body {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},RemoveScrollBar=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=void 0===r?"margin":r,o=l.useMemo(function(){return getGapWidth(i)},[i]);return l.createElement(F,{styles:getStyles(o,!t,i,n?"":"!important")})},V=!1;if("undefined"!=typeof window)try{var B=Object.defineProperty({},"passive",{get:function(){return V=!0,!0}});window.addEventListener("test",B,B),window.removeEventListener("test",B,B)}catch(e){V=!1}var W=!!V&&{passive:!1},elementCanBeScrolled=function(e,t){var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&"TEXTAREA"!==e.tagName&&"visible"===n[t])},locationCouldBeScrolled=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),elementCouldBeScrolled(e,r)){var i=getScrollVariables(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},elementCouldBeScrolled=function(e,t){return"v"===e?elementCanBeScrolled(t,"overflowY"):elementCanBeScrolled(t,"overflowX")},getScrollVariables=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},handleScroll=function(e,t,n,r,i){var o,a=(o=window.getComputedStyle(t).direction,"h"===e&&"rtl"===o?-1:1),s=a*r,l=n.target,u=t.contains(l),c=!1,d=s>0,f=0,p=0;do{var h=getScrollVariables(e,l),m=h[0],v=h[1]-h[2]-a*m;(m||v)&&elementCouldBeScrolled(e,l)&&(f+=v,p+=m),l=l.parentNode}while(!u&&l!==document.body||u&&(t.contains(l)||t===l));return d&&(i&&0===f||!i&&s>f)?c=!0:!d&&(i&&0===p||!i&&-s>p)&&(c=!0),c},getTouchXY=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},getDeltaXY=function(e){return[e.deltaX,e.deltaY]},extractRef=function(e){return e&&"current"in e?e.current:e},$=0,U=[],H=(j.useMedium(function(e){var t=l.useRef([]),n=l.useRef([0,0]),r=l.useRef(),i=l.useState($++)[0],o=l.useState(styleSingleton)[0],a=l.useRef(e);l.useEffect(function(){a.current=e},[e]),l.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var t=(0,N.__spreadArray)([e.lockRef.current],(e.shards||[]).map(extractRef),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var s=l.useCallback(function(e,t){if("touches"in e&&2===e.touches.length)return!a.current.allowPinchZoom;var i,o=getTouchXY(e),s=n.current,l="deltaX"in e?e.deltaX:s[0]-o[0],u="deltaY"in e?e.deltaY:s[1]-o[1],c=e.target,d=Math.abs(l)>Math.abs(u)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=locationCouldBeScrolled(d,c);if(!f)return!0;if(f?i=d:(i="v"===d?"h":"v",f=locationCouldBeScrolled(d,c)),!f)return!1;if(!r.current&&"changedTouches"in e&&(l||u)&&(r.current=i),!i)return!0;var p=r.current||i;return handleScroll(p,t,e,"h"===p?l:u,!0)},[]),u=l.useCallback(function(e){if(U.length&&U[U.length-1]===o){var n="deltaY"in e?getDeltaXY(e):getTouchXY(e),r=t.current.filter(function(t){var r;return t.name===e.type&&t.target===e.target&&(r=t.delta)[0]===n[0]&&r[1]===n[1]})[0];if(r&&r.should){e.cancelable&&e.preventDefault();return}if(!r){var i=(a.current.shards||[]).map(extractRef).filter(Boolean).filter(function(t){return t.contains(e.target)});(i.length>0?s(e,i[0]):!a.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),c=l.useCallback(function(e,n,r,i){var o={name:e,delta:n,target:r,should:i};t.current.push(o),setTimeout(function(){t.current=t.current.filter(function(e){return e!==o})},1)},[]),d=l.useCallback(function(e){n.current=getTouchXY(e),r.current=void 0},[]),f=l.useCallback(function(t){c(t.type,getDeltaXY(t),t.target,s(t,e.lockRef.current))},[]),p=l.useCallback(function(t){c(t.type,getTouchXY(t),t.target,s(t,e.lockRef.current))},[]);l.useEffect(function(){return U.push(o),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",u,W),document.addEventListener("touchmove",u,W),document.addEventListener("touchstart",d,W),function(){U=U.filter(function(e){return e!==o}),document.removeEventListener("wheel",u,W),document.removeEventListener("touchmove",u,W),document.removeEventListener("touchstart",d,W)}},[]);var h=e.removeScrollBar,m=e.inert;return l.createElement(l.Fragment,null,m?l.createElement(o,{styles:"\n .block-interactivity-".concat(i," {pointer-events: none;}\n .allow-interactivity-").concat(i," {pointer-events: all;}\n")}):null,h?l.createElement(RemoveScrollBar,{gapMode:e.gapMode}):null)}),SideCar),z=l.forwardRef(function(e,t){return l.createElement(L,(0,N.__assign)({},e,{ref:t,sideCar:H}))});function ModalFocusScope(e){let{autoFocus:t,trapFocus:n,dialogRef:r,initialFocusRef:i,blockScrollOnMount:o,allowPinchZoom:a,finalFocusRef:s,returnFocusOnClose:c,preserveScrollBarGap:d,lockFocusAcrossFrames:f,isOpen:p}=A(),[h,m]=(0,_.oO)();(0,l.useEffect)(()=>{!h&&m&&setTimeout(m)},[h,m]);let v=useModalManager(r,p);return(0,u.jsx)(M.E,{autoFocus:t,isDisabled:!n,initialFocusRef:i,finalFocusRef:s,restoreFocus:c,contentRef:r,lockFocusAcrossFrames:f,children:(0,u.jsx)(z,{removeScrollBar:!d,allowPinchZoom:a,enabled:1===v&&o,forwardProps:!0,children:e.children})})}z.classNames=L.classNames;var G=n(58250),q=(0,G.forwardRef)((e,t)=>{let{className:n,children:r,containerProps:o,motionProps:a,...s}=e,{getDialogProps:l,getDialogContainerProps:c}=A(),d=l(s,t),p=c(o),h=(0,m.cx)("chakra-modal__content",n),v=P(),g={display:"flex",flexDirection:"column",position:"relative",width:"100%",outline:0,...v.dialog},y={display:"flex",width:"100vw",height:"$100vh",position:"fixed",left:0,top:0,...v.dialogContainer},{motionPreset:b}=A();return(0,u.jsx)(ModalFocusScope,{children:(0,u.jsx)(i.chakra.div,{...p,className:"chakra-modal__content-container",tabIndex:-1,__css:y,children:(0,u.jsx)(f,{preset:b,motionProps:a,className:h,...d,__css:g,children:r})})})});function AlertDialog(e){let{leastDestructiveRef:t,...n}=e;return(0,u.jsx)(Modal,{...n,initialFocusRef:t})}q.displayName="ModalContent";var K=(0,G.forwardRef)((e,t)=>(0,u.jsx)(q,{ref:t,role:"alertdialog",...e})),X=n(90865),[Z,Y]=(0,k.k)(),Q={start:{ltr:"left",rtl:"right"},end:{ltr:"right",rtl:"left"}};function Drawer(e){var t;let{isOpen:n,onClose:r,placement:i="right",children:o,...a}=e,s=(0,X.useTheme)(),l=null==(t=s.components)?void 0:t.Drawer,c=function(e,t){var n,r;if(e)return null!=(r=null==(n=Q[e])?void 0:n[t])?r:e}(i,s.direction);return(0,u.jsx)(Z,{value:{placement:c},children:(0,u.jsx)(Modal,{isOpen:n,onClose:r,styleConfig:l,...a,children:o})})}var J=n(23002),ee=(0,i.chakra)(J.M),et=(0,G.forwardRef)((e,t)=>{let{className:n,children:r,motionProps:o,containerProps:a,...s}=e,{getDialogProps:l,getDialogContainerProps:c,isOpen:d}=A(),f=l(s,t),p=c(a),h=(0,m.cx)("chakra-modal__content",n),v=P(),g={display:"flex",flexDirection:"column",position:"relative",width:"100%",outline:0,...v.dialog},y={display:"flex",width:"100vw",height:"$100vh",position:"fixed",left:0,top:0,...v.dialogContainer},{placement:b}=Y();return(0,u.jsx)(ModalFocusScope,{children:(0,u.jsx)(i.chakra.div,{...p,className:"chakra-modal__content-container",__css:y,children:(0,u.jsx)(ee,{motionProps:o,direction:b,in:d,className:h,...f,__css:g,children:r})})})});et.displayName="DrawerContent";var en=(0,G.forwardRef)((e,t)=>{let{className:n,...r}=e,o=(0,m.cx)("chakra-modal__footer",n),a=P(),s={display:"flex",alignItems:"center",justifyContent:"flex-end",...a.footer};return(0,u.jsx)(i.chakra.footer,{ref:t,...r,__css:s,className:o})});en.displayName="ModalFooter";var er=(0,G.forwardRef)((e,t)=>{let{className:n,...r}=e,{headerId:o,setHeaderMounted:a}=A();(0,l.useEffect)(()=>(a(!0),()=>a(!1)),[a]);let s=(0,m.cx)("chakra-modal__header",n),c=P(),d={flex:0,...c.header};return(0,u.jsx)(i.chakra.header,{ref:t,className:s,id:o,...r,__css:d})});er.displayName="ModalHeader";var ei=n(11243),eo=(0,i.chakra)(s.E.div),ea=(0,G.forwardRef)((e,t)=>{let{className:n,transition:r,motionProps:i,...o}=e,a=(0,m.cx)("chakra-modal__overlay",n),s=P(),l={pos:"fixed",left:"0",top:"0",w:"100vw",h:"100vh",...s.overlay},{motionPreset:c}=A(),d="none"===c?{}:ei.u,f=i||d;return(0,u.jsx)(eo,{...f,__css:l,ref:t,className:a,...o})});ea.displayName="ModalOverlay";var es=(0,G.forwardRef)((e,t)=>{let{className:n,...r}=e,{bodyId:o,setBodyMounted:a}=A();(0,l.useEffect)(()=>(a(!0),()=>a(!1)),[a]);let s=(0,m.cx)("chakra-modal__body",n),c=P();return(0,u.jsx)(i.chakra.div,{ref:t,className:s,id:o,...r,__css:c.body})});es.displayName="ModalBody";var el=n(96231),eu=(0,G.forwardRef)((e,t)=>{let{onClick:n,className:r,...i}=e,{onClose:o}=A(),a=(0,m.cx)("chakra-modal__close-btn",r),s=P();return(0,u.jsx)(el.P,{ref:t,__css:s.closeButton,className:a,onClick:(0,m.v0)(n,e=>{e.stopPropagation(),o()}),...i})});eu.displayName="ModalCloseButton"},1647:function(e,t,n){"use strict";n.d(t,{n:function(){return CacheProvider}});var r,i=n(56335),o=n(24033),a=n(2265),s=null!=(r=i.Z.default)?r:i.Z,l=n(65673),u=n(57437);function CacheProvider({children:e,...t}){return(0,u.jsx)(l.C,{value:function(e){let t=(0,a.useMemo)(()=>{let t=s({key:"css",prepend:!0,...e});return t.compat=!0,t},[e]);return(0,o.useServerInsertedHTML)(()=>(0,a.createElement)("style",{key:t.key,"data-emotion":`${t.key} ${Object.keys(t.inserted).join(" ")}`,dangerouslySetInnerHTML:{__html:Object.values(t.inserted).join(" ")}})),t}(t),children:e})}},77162:function(e,t,n){"use strict";n.r(t),n.d(t,{NumberDecrementStepper:function(){return A},NumberIncrementStepper:function(){return M},NumberInput:function(){return C},NumberInputField:function(){return P},NumberInputStepper:function(){return E},useNumberInput:function(){return useNumberInput},useNumberInputStyles:function(){return w}});var r=n(16248),i=n(57437),TriangleDownIcon=e=>(0,i.jsx)(r.J,{viewBox:"0 0 24 24",...e,children:(0,i.jsx)("path",{fill:"currentColor",d:"M21,5H3C2.621,5,2.275,5.214,2.105,5.553C1.937,5.892,1.973,6.297,2.2,6.6l9,12 c0.188,0.252,0.485,0.4,0.8,0.4s0.611-0.148,0.8-0.4l9-12c0.228-0.303,0.264-0.708,0.095-1.047C21.725,5.214,21.379,5,21,5z"})}),TriangleUpIcon=e=>(0,i.jsx)(r.J,{viewBox:"0 0 24 24",...e,children:(0,i.jsx)("path",{fill:"currentColor",d:"M12.8,5.4c-0.377-0.504-1.223-0.504-1.6,0l-9,12c-0.228,0.303-0.264,0.708-0.095,1.047 C2.275,18.786,2.621,19,3,19h18c0.379,0,0.725-0.214,0.895-0.553c0.169-0.339,0.133-0.744-0.095-1.047L12.8,5.4z"})}),o=n(2265);function useAttributeObserver(e,t,n,r){(0,o.useEffect)(()=>{var i;if(!e.current||!r)return;let o=null!=(i=e.current.ownerDocument.defaultView)?i:window,a=Array.isArray(t)?t:[t],s=new o.MutationObserver(e=>{for(let t of e)"attributes"===t.type&&t.attributeName&&a.includes(t.attributeName)&&n(t)});return s.observe(e.current,{attributes:!0,attributeFilter:a}),()=>s.disconnect()})}var a=n(37977),s=n(99323),l=n(10931),u=n(89656),c=n(67673),d=n(45663),f=n(16465),p=/^[Ee0-9+\-.]$/;function isFloatingPointNumericCharacter(e){return p.test(e)}function useNumberInput(e={}){let{focusInputOnChange:t=!0,clampValueOnBlur:n=!0,keepWithinRange:r=!0,min:i=Number.MIN_SAFE_INTEGER,max:p=Number.MAX_SAFE_INTEGER,step:h=1,isReadOnly:m,isDisabled:v,isRequired:g,isInvalid:y,pattern:b="[0-9]*(.[0-9]+)?",inputMode:x="decimal",allowMouseWheel:w,id:k,onChange:S,precision:C,name:E,"aria-describedby":P,"aria-label":T,"aria-labelledby":A,onFocus:M,onBlur:_,onInvalid:N,getAriaValueText:R,isValidCharacter:D,format:I,parse:j,...L}=e,O=(0,a.W)(M),F=(0,a.W)(_),V=(0,a.W)(N),B=(0,a.W)(null!=D?D:isFloatingPointNumericCharacter),W=(0,a.W)(R),$=(0,s.C)(e),{update:U,increment:H,decrement:z}=$,[G,q]=(0,o.useState)(!1),K=!(m||v),X=(0,o.useRef)(null),Z=(0,o.useRef)(null),Y=(0,o.useRef)(null),Q=(0,o.useRef)(null),J=(0,o.useCallback)(e=>e.split("").filter(B).join(""),[B]),ee=(0,o.useCallback)(e=>{var t;return null!=(t=null==j?void 0:j(e))?t:e},[j]),et=(0,o.useCallback)(e=>{var t;return(null!=(t=null==I?void 0:I(e))?t:e).toString()},[I]);(0,u.r)(()=>{$.valueAsNumber>p?null==V||V("rangeOverflow",et($.value),$.valueAsNumber):$.valueAsNumber{if(!X.current)return;let e=X.current.value!=$.value;if(e){let e=ee(X.current.value);$.setValue(J(e))}},[ee,J]);let en=(0,o.useCallback)((e=h)=>{K&&H(e)},[H,K,h]),er=(0,o.useCallback)((e=h)=>{K&&z(e)},[z,K,h]),ei=function(e,t){let[n,r]=(0,o.useState)(!1),[i,s]=(0,o.useState)(null),[l,u]=(0,o.useState)(!0),c=(0,o.useRef)(null),removeTimeout=()=>clearTimeout(c.current);!function(e,t){let n=(0,a.W)(e);(0,o.useEffect)(()=>{let e=null;return null!==t&&(e=window.setInterval(()=>n(),t)),()=>{e&&window.clearInterval(e)}},[t,n])}(()=>{"increment"===i&&e(),"decrement"===i&&t()},n?50:null);let d=(0,o.useCallback)(()=>{l&&e(),c.current=setTimeout(()=>{u(!1),r(!0),s("increment")},300)},[e,l]),f=(0,o.useCallback)(()=>{l&&t(),c.current=setTimeout(()=>{u(!1),r(!0),s("decrement")},300)},[t,l]),p=(0,o.useCallback)(()=>{u(!0),r(!1),removeTimeout()},[]);return(0,o.useEffect)(()=>()=>removeTimeout(),[]),{up:d,down:f,stop:p,isSpinning:n}}(en,er);useAttributeObserver(Y,"disabled",ei.stop,ei.isSpinning),useAttributeObserver(Q,"disabled",ei.stop,ei.isSpinning);let eo=(0,o.useCallback)(e=>{let t=e.nativeEvent;if(t.isComposing)return;let n=ee(e.currentTarget.value);U(J(n)),Z.current={start:e.currentTarget.selectionStart,end:e.currentTarget.selectionEnd}},[U,J,ee]),ea=(0,o.useCallback)(e=>{var t,n,r;null==O||O(e),Z.current&&(e.target.selectionStart=null!=(n=Z.current.start)?n:null==(t=e.currentTarget.value)?void 0:t.length,e.currentTarget.selectionEnd=null!=(r=Z.current.end)?r:e.currentTarget.selectionStart)},[O]),es=(0,o.useCallback)(e=>{if(e.nativeEvent.isComposing)return;!function(e,t){if(null==e.key)return!0;let n=e.ctrlKey||e.altKey||e.metaKey,r=1===e.key.length;return!r||!!n||t(e.key)}(e,B)&&e.preventDefault();let t=getStepFactor(e)*h,n=e.key,r={ArrowUp:()=>en(t),ArrowDown:()=>er(t),Home:()=>U(i),End:()=>U(p)}[n];r&&(e.preventDefault(),r(e))},[B,h,en,er,U,i,p]),getStepFactor=e=>{let t=1;return(e.metaKey||e.ctrlKey)&&(t=.1),e.shiftKey&&(t=10),t},el=(0,o.useMemo)(()=>{let e=null==W?void 0:W($.value);if(null!=e)return e;let t=$.value.toString();return t||void 0},[$.value,W]),eu=(0,o.useCallback)(()=>{let e=$.value;if(""===$.value)return;let t=/^[eE]/.test($.value.toString());t?$.setValue(""):($.valueAsNumberp&&(e=p),$.cast(e))},[$,p,i]),ec=(0,o.useCallback)(()=>{q(!1),n&&eu()},[n,q,eu]),ed=(0,o.useCallback)(()=>{t&&requestAnimationFrame(()=>{var e;null==(e=X.current)||e.focus()})},[t]),ef=(0,o.useCallback)(e=>{e.preventDefault(),ei.up(),ed()},[ed,ei]),ep=(0,o.useCallback)(e=>{e.preventDefault(),ei.down(),ed()},[ed,ei]);(0,l.O)(()=>X.current,"wheel",e=>{var t,n;let r=null!=(n=null==(t=X.current)?void 0:t.ownerDocument)?n:document,i=r.activeElement===X.current;if(!w||!i)return;e.preventDefault();let o=getStepFactor(e)*h,a=Math.sign(e.deltaY);-1===a?en(o):1===a&&er(o)},{passive:!1});let eh=(0,o.useCallback)((e={},t=null)=>{let n=v||r&&$.isAtMax;return{...e,ref:(0,d.lq)(t,Y),role:"button",tabIndex:-1,onPointerDown:(0,f.v0)(e.onPointerDown,e=>{0!==e.button||n||ef(e)}),onPointerLeave:(0,f.v0)(e.onPointerLeave,ei.stop),onPointerUp:(0,f.v0)(e.onPointerUp,ei.stop),disabled:n,"aria-disabled":(0,f.Qm)(n)}},[$.isAtMax,r,ef,ei.stop,v]),em=(0,o.useCallback)((e={},t=null)=>{let n=v||r&&$.isAtMin;return{...e,ref:(0,d.lq)(t,Q),role:"button",tabIndex:-1,onPointerDown:(0,f.v0)(e.onPointerDown,e=>{0!==e.button||n||ep(e)}),onPointerLeave:(0,f.v0)(e.onPointerLeave,ei.stop),onPointerUp:(0,f.v0)(e.onPointerUp,ei.stop),disabled:n,"aria-disabled":(0,f.Qm)(n)}},[$.isAtMin,r,ep,ei.stop,v]),ev=(0,o.useCallback)((e={},t=null)=>{var n,r,o,a;return{name:E,inputMode:x,type:"text",pattern:b,"aria-labelledby":A,"aria-label":T,"aria-describedby":P,id:k,disabled:v,...e,readOnly:null!=(n=e.readOnly)?n:m,"aria-readonly":null!=(r=e.readOnly)?r:m,"aria-required":null!=(o=e.required)?o:g,required:null!=(a=e.required)?a:g,ref:(0,d.lq)(X,t),value:et($.value),role:"spinbutton","aria-valuemin":i,"aria-valuemax":p,"aria-valuenow":Number.isNaN($.valueAsNumber)?void 0:$.valueAsNumber,"aria-invalid":(0,f.Qm)(null!=y?y:$.isOutOfRange),"aria-valuetext":el,autoComplete:"off",autoCorrect:"off",onChange:(0,f.v0)(e.onChange,eo),onKeyDown:(0,f.v0)(e.onKeyDown,es),onFocus:(0,f.v0)(e.onFocus,ea,()=>q(!0)),onBlur:(0,f.v0)(e.onBlur,F,ec)}},[E,x,b,A,T,et,P,k,v,g,m,y,$.value,$.valueAsNumber,$.isOutOfRange,i,p,el,eo,es,ea,F,ec]);return{value:et($.value),valueAsNumber:$.valueAsNumber,isFocused:G,isDisabled:v,isReadOnly:m,getIncrementButtonProps:eh,getDecrementButtonProps:em,getInputProps:ev,htmlProps:L}}var h=n(75992),m=n(310),v=n(58250),g=n(92013),y=n(50446),b=n(23145),[x,w]=(0,m.k)({name:"NumberInputStylesContext",errorMessage:"useNumberInputStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),[k,S]=(0,m.k)({name:"NumberInputContext",errorMessage:"useNumberInputContext: `context` is undefined. Seems you forgot to wrap number-input's components within "}),C=(0,v.forwardRef)(function(e,t){let n=(0,g.useMultiStyleConfig)("NumberInput",e),r=(0,y.Lr)(e),a=(0,h.K)(r),{htmlProps:s,...l}=useNumberInput(a),u=(0,o.useMemo)(()=>l,[l]);return(0,i.jsx)(k,{value:u,children:(0,i.jsx)(x,{value:n,children:(0,i.jsx)(b.chakra.div,{...s,ref:t,className:(0,f.cx)("chakra-numberinput",e.className),__css:{position:"relative",zIndex:0,...n.root}})})})});C.displayName="NumberInput";var E=(0,v.forwardRef)(function(e,t){let n=w();return(0,i.jsx)(b.chakra.div,{"aria-hidden":!0,ref:t,...e,__css:{display:"flex",flexDirection:"column",position:"absolute",top:"0",insetEnd:"0px",margin:"1px",height:"calc(100% - 2px)",zIndex:1,...n.stepperGroup}})});E.displayName="NumberInputStepper";var P=(0,v.forwardRef)(function(e,t){let{getInputProps:n}=S(),r=n(e,t),o=w();return(0,i.jsx)(b.chakra.input,{...r,className:(0,f.cx)("chakra-numberinput__field",e.className),__css:{width:"100%",...o.field}})});P.displayName="NumberInputField";var T=(0,b.chakra)("div",{baseStyle:{display:"flex",justifyContent:"center",alignItems:"center",flex:1,transitionProperty:"common",transitionDuration:"normal",userSelect:"none",cursor:"pointer",lineHeight:"normal"}}),A=(0,v.forwardRef)(function(e,t){var n;let r=w(),{getDecrementButtonProps:o}=S(),a=o(e,t);return(0,i.jsx)(T,{...a,__css:r.stepper,children:null!=(n=e.children)?n:(0,i.jsx)(TriangleDownIcon,{})})});A.displayName="NumberDecrementStepper";var M=(0,v.forwardRef)(function(e,t){var n;let{getIncrementButtonProps:r}=S(),o=r(e,t),a=w();return(0,i.jsx)(T,{...o,__css:a.stepper,children:null!=(n=e.children)?n:(0,i.jsx)(TriangleUpIcon,{})})});M.displayName="NumberIncrementStepper"},18234:function(e,t,n){"use strict";function toPrecision(e,t){let n=function(e){let t=parseFloat(e);return"number"!=typeof t||Number.isNaN(t)?0:t}(e),r=10**(null!=t?t:10);return n=Math.round(n*r)/r,t?n.toFixed(t):n.toString()}function countDecimalPlaces(e){if(!Number.isFinite(e))return 0;let t=1,n=0;for(;Math.round(e*t)/t!==e;)t*=10,n+=1;return n}function valueToPercent(e,t,n){return(e-t)*100/(n-t)}function percentToValue(e,t,n){return(n-t)*e+t}function roundValueToStep(e,t,n){let r=Math.round((e-t)/n)*n+t,i=countDecimalPlaces(n);return toPrecision(r,i)}function clampValue(e,t,n){return null==e?e:(n`"}),toArray=e=>null==e?void 0:e.split("");function validate(e,t){return("alphanumeric"===t?/^[a-zA-Z0-9]+$/i:/^[0-9]+$/).test(e)}function usePinInput(e={}){let{autoFocus:t,value:n,defaultValue:r,onChange:a,onComplete:s,placeholder:u="○",manageFocus:c=!0,otp:f=!1,id:p,isDisabled:h,isInvalid:m,type:v="number",mask:g}=e,y=(0,l.useId)(),b=null!=p?p:`pin-input-${y}`,x=d(),[w,k]=(0,l.useState)(!0),[S,C]=(0,l.useState)(-1),[E,P]=(0,i.T)({defaultValue:toArray(r)||[],value:toArray(n),onChange:e=>null==a?void 0:a(e.join(""))});(0,l.useEffect)(()=>{if(t){let e=x.first();e&&requestAnimationFrame(()=>{e.node.focus()})}},[x]);let T=(0,l.useCallback)(e=>{if(!w||!c)return;let t=x.next(e,!1);t&&requestAnimationFrame(()=>{t.node.focus()})},[x,w,c]),A=(0,l.useCallback)((e,t,n=!0)=>{let r=[...E];r[t]=e,P(r);let i=""!==e&&r.length===x.count()&&r.every(e=>null!=e&&""!==e);i?null==s||s(r.join("")):n&&T(t)},[E,P,T,s,x]),M=(0,l.useCallback)(()=>{var e;let t=Array(x.count()).fill("");P(t);let n=x.first();null==(e=null==n?void 0:n.node)||e.focus()},[x,P]),_=(0,l.useCallback)((e,t)=>{let n=t;return(null==e?void 0:e.length)>0&&(e[0]===t.charAt(0)?n=t.charAt(1):e[0]===t.charAt(1)&&(n=t.charAt(0))),n},[]),N=(0,l.useCallback)(e=>{let{index:t,...n}=e,r=S===t,i="number"===v?"tel":"text";return{"aria-label":"Please enter your pin code",inputMode:"number"===v?"numeric":"text",type:g?"password":i,...n,id:`${b}-${t}`,disabled:h,"aria-invalid":(0,o.Qm)(m),onChange:(0,o.v0)(n.onChange,e=>{let n=e.target.value,r=E[t],i=_(r,n);if(""===i){A("",t);return}if(n.length>2){if(validate(n,v)){let e=n.split("").filter((e,t)=>t{var n;if("Backspace"===e.key&&c){if(""===e.target.value){let e=x.prev(t,!1);e&&(A("",t-1,!1),null==(n=e.node)||n.focus(),k(!0))}else k(!1)}}),onFocus:(0,o.v0)(n.onFocus,()=>{C(t)}),onBlur:(0,o.v0)(n.onBlur,()=>{C(-1)}),value:E[t]||"",autoComplete:f?"one-time-code":"off",placeholder:r?"":u}},[x,S,_,b,h,g,m,c,s,f,u,A,P,v,E]);return{getInputProps:N,id:b,descendants:x,values:E,setValue:A,setValues:P,clear:M}}function usePinInputField(e={},t=null){let{getInputProps:n}=h(),{index:r,register:i}=f();return n({...e,ref:(0,s.lq)(i,t),index:r})}var m=n(92013),v=n(50446),g=n(58250),y=n(23145),b=n(61158),x=n(57437);function PinInput(e){let t=(0,m.useStyleConfig)("PinInput",e),{children:n,...r}=(0,v.Lr)(e),{descendants:i,...o}=usePinInput(r),a=(0,b.W)(n).map(e=>(0,l.cloneElement)(e,{__css:t}));return(0,x.jsx)(u,{value:i,children:(0,x.jsx)(p,{value:o,children:a})})}PinInput.displayName="PinInput";var w=(0,g.forwardRef)(function(e,t){let n=usePinInputField(e,t);return(0,x.jsx)(y.chakra.input,{...n,className:(0,o.cx)("chakra-pin-input",e.className)})});w.displayName="PinInputField"},75332:function(e,t,n){"use strict";n.r(t),n.d(t,{Popover:function(){return Popover},PopoverAnchor:function(){return PopoverAnchor},PopoverArrow:function(){return PopoverArrow},PopoverBody:function(){return P},PopoverCloseButton:function(){return A},PopoverContent:function(){return D},PopoverFooter:function(){return PopoverFooter},PopoverHeader:function(){return f},PopoverTrigger:function(){return PopoverTrigger},usePopover:function(){return usePopover},usePopoverContext:function(){return o},usePopoverStyles:function(){return s}});var r=n(310),[i,o]=(0,r.k)({name:"PopoverContext",errorMessage:"usePopoverContext: `context` is undefined. Seems you forgot to wrap all popover components within ``"}),[a,s]=(0,r.k)({name:"PopoverStylesContext",errorMessage:"usePopoverStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),l=n(58250),u=n(23145),c=n(16465),d=n(57437),f=(0,l.forwardRef)(function(e,t){let{getHeaderProps:n}=o(),r=s();return(0,d.jsx)(u.chakra.header,{...n(e,t),className:(0,c.cx)("chakra-popover__header",e.className),__css:r.header})});f.displayName="PopoverHeader";var p=n(2265);function PopoverTrigger(e){let t=p.Children.only(e.children),{getTriggerProps:n}=o();return(0,p.cloneElement)(t,n(t.props,t.ref))}PopoverTrigger.displayName="PopoverTrigger";var h=n(12937),m=n(38594),v=n(81958),g=n(61113),y=n(1521),b=n(15006),x=n(45663),w=n(21450),k={click:"click",hover:"hover"};function usePopover(e={}){let{closeOnBlur:t=!0,closeOnEsc:n=!0,initialFocusRef:r,id:i,returnFocusOnClose:o=!0,autoFocus:a=!0,arrowSize:s,arrowShadowColor:l,trigger:u=k.click,openDelay:d=200,closeDelay:f=200,isLazy:S,lazyBehavior:C="unmount",computePositionOnMount:E,...P}=e,{isOpen:T,onClose:A,onOpen:M,onToggle:_}=(0,g.q)(e),N=(0,p.useRef)(null),R=(0,p.useRef)(null),D=(0,p.useRef)(null),I=(0,p.useRef)(!1),j=(0,p.useRef)(!1);T&&(j.current=!0);let[L,O]=(0,p.useState)(!1),[F,V]=(0,p.useState)(!1),B=(0,p.useId)(),W=null!=i?i:B,[$,U,H,z]=["popover-trigger","popover-content","popover-header","popover-body"].map(e=>`${e}-${W}`),{referenceRef:G,getArrowProps:q,getPopperProps:K,getArrowInnerProps:X,forceUpdate:Z}=(0,y.D)({...P,enabled:T||!!E}),Y=(0,h.h)({isOpen:T,ref:D});(0,m.s)({enabled:T,ref:R}),(0,v.C)(D,{focusRef:R,visible:T,shouldFocus:o&&u===k.click}),(0,v.G)(D,{focusRef:r,visible:T,shouldFocus:a&&u===k.click});let Q=(0,w.k)({wasSelected:j.current,enabled:S,mode:C,isSelected:Y.present}),J=(0,p.useCallback)((e={},r=null)=>{let i={...e,style:{...e.style,transformOrigin:b.Dq.transformOrigin.varRef,[b.Dq.arrowSize.var]:s?`${s}px`:void 0,[b.Dq.arrowShadowColor.var]:l},ref:(0,x.lq)(D,r),children:Q?e.children:null,id:U,tabIndex:-1,role:"dialog",onKeyDown:(0,c.v0)(e.onKeyDown,e=>{n&&"Escape"===e.key&&A()}),onBlur:(0,c.v0)(e.onBlur,e=>{let n=getRelatedTarget(e),r=contains(D.current,n),i=contains(R.current,n);T&&t&&!r&&!i&&A()}),"aria-labelledby":L?H:void 0,"aria-describedby":F?z:void 0};return u===k.hover&&(i.role="tooltip",i.onMouseEnter=(0,c.v0)(e.onMouseEnter,()=>{I.current=!0}),i.onMouseLeave=(0,c.v0)(e.onMouseLeave,e=>{null!==e.nativeEvent.relatedTarget&&(I.current=!1,setTimeout(()=>A(),f))})),i},[Q,U,L,H,F,z,u,n,A,T,t,f,l,s]),ee=(0,p.useCallback)((e={},t=null)=>K({...e,style:{visibility:T?"visible":"hidden",...e.style}},t),[T,K]),et=(0,p.useCallback)((e,t=null)=>({...e,ref:(0,x.lq)(t,N,G)}),[N,G]),en=(0,p.useRef)(),er=(0,p.useRef)(),ei=(0,p.useCallback)(e=>{null==N.current&&G(e)},[G]),eo=(0,p.useCallback)((e={},n=null)=>{let r={...e,ref:(0,x.lq)(R,n,ei),id:$,"aria-haspopup":"dialog","aria-expanded":T,"aria-controls":U};return u===k.click&&(r.onClick=(0,c.v0)(e.onClick,_)),u===k.hover&&(r.onFocus=(0,c.v0)(e.onFocus,()=>{void 0===en.current&&M()}),r.onBlur=(0,c.v0)(e.onBlur,e=>{let n=getRelatedTarget(e),r=!contains(D.current,n);T&&t&&r&&A()}),r.onKeyDown=(0,c.v0)(e.onKeyDown,e=>{"Escape"===e.key&&A()}),r.onMouseEnter=(0,c.v0)(e.onMouseEnter,()=>{I.current=!0,en.current=window.setTimeout(()=>M(),d)}),r.onMouseLeave=(0,c.v0)(e.onMouseLeave,()=>{I.current=!1,en.current&&(clearTimeout(en.current),en.current=void 0),er.current=window.setTimeout(()=>{!1===I.current&&A()},f)})),r},[$,T,U,u,ei,_,M,t,A,d,f]);(0,p.useEffect)(()=>()=>{en.current&&clearTimeout(en.current),er.current&&clearTimeout(er.current)},[]);let ea=(0,p.useCallback)((e={},t=null)=>({...e,id:H,ref:(0,x.lq)(t,e=>{O(!!e)})}),[H]),es=(0,p.useCallback)((e={},t=null)=>({...e,id:z,ref:(0,x.lq)(t,e=>{V(!!e)})}),[z]);return{forceUpdate:Z,isOpen:T,onAnimationComplete:Y.onComplete,onClose:A,getAnchorProps:et,getArrowProps:q,getArrowInnerProps:X,getPopoverPositionerProps:ee,getPopoverProps:J,getTriggerProps:eo,getHeaderProps:ea,getBodyProps:es}}function contains(e,t){return e===t||(null==e?void 0:e.contains(t))}function getRelatedTarget(e){var t;let n=e.currentTarget.ownerDocument.activeElement;return null!=(t=e.relatedTarget)?t:n}var S=n(92013),C=n(50446),E=n(90865);function Popover(e){let t=(0,S.useMultiStyleConfig)("Popover",e),{children:n,...r}=(0,C.Lr)(e),o=(0,E.useTheme)(),s=usePopover({...r,direction:o.direction});return(0,d.jsx)(i,{value:s,children:(0,d.jsx)(a,{value:t,children:(0,c.Pu)(n,{isOpen:s.isOpen,onClose:s.onClose,forceUpdate:s.forceUpdate})})})}function PopoverAnchor(e){let t=p.Children.only(e.children),{getAnchorProps:n}=o();return(0,p.cloneElement)(t,n(t.props,t.ref))}Popover.displayName="Popover",PopoverAnchor.displayName="PopoverAnchor";var resolveVar=(e,t)=>t?`${e}.${t}, ${t}`:void 0;function PopoverArrow(e){var t;let{bg:n,bgColor:r,backgroundColor:i,shadow:a,boxShadow:l,shadowColor:f}=e,{getArrowProps:p,getArrowInnerProps:h}=o(),m=s(),v=null!=(t=null!=n?n:r)?t:i,g=null!=a?a:l;return(0,d.jsx)(u.chakra.div,{...p(),className:"chakra-popover__arrow-positioner",children:(0,d.jsx)(u.chakra.div,{className:(0,c.cx)("chakra-popover__arrow",e.className),...h(e),__css:{"--popper-arrow-shadow-color":resolveVar("colors",f),"--popper-arrow-bg":resolveVar("colors",v),"--popper-arrow-shadow":resolveVar("shadows",g),...m.arrow}})})}PopoverArrow.displayName="PopoverArrow";var P=(0,l.forwardRef)(function(e,t){let{getBodyProps:n}=o(),r=s();return(0,d.jsx)(u.chakra.div,{...n(e,t),className:(0,c.cx)("chakra-popover__body",e.className),__css:r.body})});P.displayName="PopoverBody";var T=n(96231),A=(0,l.forwardRef)(function(e,t){let{onClose:n}=o(),r=s();return(0,d.jsx)(T.P,{size:"sm",onClick:n,className:(0,c.cx)("chakra-popover__close-btn",e.className),__css:r.closeButton,ref:t,...e})});A.displayName="PopoverCloseButton";var M=n(72638),_={exit:{opacity:0,scale:.95,transition:{duration:.1,ease:[.4,0,1,1]}},enter:{scale:1,opacity:1,transition:{duration:.15,ease:[0,0,.2,1]}}},N=(0,u.chakra)(M.E.section),R=(0,l.forwardRef)(function(e,t){let{variants:n=_,...r}=e,{isOpen:i}=o();return(0,d.jsx)(N,{ref:t,variants:function(e){if(e)return{enter:{...e.enter,visibility:"visible"},exit:{...e.exit,transitionEnd:{visibility:"hidden"}}}}(n),initial:!1,animate:i?"enter":"exit",...r})});R.displayName="PopoverTransition";var D=(0,l.forwardRef)(function(e,t){let{rootProps:n,motionProps:r,...i}=e,{getPopoverProps:a,getPopoverPositionerProps:l,onAnimationComplete:f}=o(),p=s(),h={position:"relative",display:"flex",flexDirection:"column",...p.content};return(0,d.jsx)(u.chakra.div,{...l(n),__css:p.popper,className:"chakra-popover__popper",children:(0,d.jsx)(R,{...r,...a(i,t),onAnimationComplete:(0,c.PP)(f,i.onAnimationComplete),className:(0,c.cx)("chakra-popover__content",e.className),__css:h})})});function PopoverFooter(e){let t=s();return(0,d.jsx)(u.chakra.footer,{...e,className:(0,c.cx)("chakra-popover__footer",e.className),__css:t.footer})}D.displayName="PopoverContent",PopoverFooter.displayName="PopoverFooter"},15006:function(e,t,n){"use strict";n.d(t,{$B:function(){return getEventListenerOptions},Dq:function(){return r},Ke:function(){return getBoxShadow},mv:function(){return toTransformOrigin}});var toVar=(e,t)=>({var:e,varRef:t?`var(${e}, ${t})`:`var(${e})`}),r={arrowShadowColor:toVar("--popper-arrow-shadow-color"),arrowSize:toVar("--popper-arrow-size","8px"),arrowSizeHalf:toVar("--popper-arrow-size-half"),arrowBg:toVar("--popper-arrow-bg"),transformOrigin:toVar("--popper-transform-origin"),arrowOffset:toVar("--popper-arrow-offset")};function getBoxShadow(e){return e.includes("top")?"1px 1px 0px 0 var(--popper-arrow-shadow-color)":e.includes("bottom")?"-1px -1px 0px 0 var(--popper-arrow-shadow-color)":e.includes("right")?"-1px 1px 0px 0 var(--popper-arrow-shadow-color)":e.includes("left")?"1px -1px 0px 0 var(--popper-arrow-shadow-color)":void 0}var i={top:"bottom center","top-start":"bottom left","top-end":"bottom right",bottom:"top center","bottom-start":"top left","bottom-end":"top right",left:"right center","left-start":"right top","left-end":"right bottom",right:"left center","right-start":"left top","right-end":"left bottom"},toTransformOrigin=e=>i[e],o={scroll:!0,resize:!0};function getEventListenerOptions(e){return"object"==typeof e?{enabled:!0,options:{...o,...e}}:{enabled:e,options:o}}},1521:function(e,t,n){"use strict";n.d(t,{D:function(){return usePopper}});var r,i,o,a,s,l=n(15006),u={name:"matchWidth",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:({state:e})=>{e.styles.popper.width=`${e.rects.reference.width}px`},effect:({state:e})=>()=>{let t=e.elements.reference;e.elements.popper.style.width=`${t.offsetWidth}px`}},c={name:"transformOrigin",enabled:!0,phase:"write",fn:({state:e})=>{setTransformOrigin(e)},effect:({state:e})=>()=>{setTransformOrigin(e)}},setTransformOrigin=e=>{e.elements.popper.style.setProperty(l.Dq.transformOrigin.var,(0,l.mv)(e.placement))},d={name:"positionArrow",enabled:!0,phase:"afterWrite",fn:({state:e})=>{setArrowStyles(e)}},setArrowStyles=e=>{var t;if(!e.placement)return;let n=getArrowStyle(e.placement);if((null==(t=e.elements)?void 0:t.arrow)&&n){Object.assign(e.elements.arrow.style,{[n.property]:n.value,width:l.Dq.arrowSize.varRef,height:l.Dq.arrowSize.varRef,zIndex:-1});let t={[l.Dq.arrowSizeHalf.var]:`calc(${l.Dq.arrowSize.varRef} / 2 - 1px)`,[l.Dq.arrowOffset.var]:`calc(${l.Dq.arrowSizeHalf.varRef} * -1)`};for(let n in t)e.elements.arrow.style.setProperty(n,t[n])}},getArrowStyle=e=>e.startsWith("top")?{property:"bottom",value:l.Dq.arrowOffset.varRef}:e.startsWith("bottom")?{property:"top",value:l.Dq.arrowOffset.varRef}:e.startsWith("left")?{property:"right",value:l.Dq.arrowOffset.varRef}:e.startsWith("right")?{property:"left",value:l.Dq.arrowOffset.varRef}:void 0,f={name:"innerArrow",enabled:!0,phase:"main",requires:["arrow"],fn:({state:e})=>{setInnerArrowStyles(e)},effect:({state:e})=>()=>{setInnerArrowStyles(e)}},setInnerArrowStyles=e=>{if(!e.elements.arrow)return;let t=e.elements.arrow.querySelector("[data-popper-arrow-inner]");if(!t)return;let n=(0,l.Ke)(e.placement);n&&t.style.setProperty("--popper-arrow-default-shadow",n),Object.assign(t.style,{transform:"rotate(45deg)",background:l.Dq.arrowBg.varRef,top:0,left:0,width:"100%",height:"100%",position:"absolute",zIndex:"inherit",boxShadow:"var(--popper-arrow-shadow, var(--popper-arrow-default-shadow))"})},p={"start-start":{ltr:"left-start",rtl:"right-start"},"start-end":{ltr:"left-end",rtl:"right-end"},"end-start":{ltr:"right-start",rtl:"left-start"},"end-end":{ltr:"right-end",rtl:"left-end"},start:{ltr:"left",rtl:"right"},end:{ltr:"right",rtl:"left"}},h={"auto-start":"auto-end","auto-end":"auto-start","top-start":"top-end","top-end":"top-start","bottom-start":"bottom-end","bottom-end":"bottom-start"},m=n(45663);function getWindow(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function isElement(e){var t=getWindow(e).Element;return e instanceof t||e instanceof Element}function isHTMLElement(e){var t=getWindow(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function isShadowRoot(e){if("undefined"==typeof ShadowRoot)return!1;var t=getWindow(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}var v=Math.max,g=Math.min,y=Math.round;function getUAString(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function isLayoutViewport(){return!/^((?!chrome|android).)*safari/i.test(getUAString())}function getBoundingClientRect(e,t,n){void 0===t&&(t=!1),void 0===n&&(n=!1);var r=e.getBoundingClientRect(),i=1,o=1;t&&isHTMLElement(e)&&(i=e.offsetWidth>0&&y(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&y(r.height)/e.offsetHeight||1);var a=(isElement(e)?getWindow(e):window).visualViewport,s=!isLayoutViewport()&&n,l=(r.left+(s&&a?a.offsetLeft:0))/i,u=(r.top+(s&&a?a.offsetTop:0))/o,c=r.width/i,d=r.height/o;return{width:c,height:d,top:u,right:l+c,bottom:u+d,left:l,x:l,y:u}}function getWindowScroll(e){var t=getWindow(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function getNodeName(e){return e?(e.nodeName||"").toLowerCase():null}function getDocumentElement(e){return((isElement(e)?e.ownerDocument:e.document)||window.document).documentElement}function getWindowScrollBarX(e){return getBoundingClientRect(getDocumentElement(e)).left+getWindowScroll(e).scrollLeft}function getComputedStyle(e){return getWindow(e).getComputedStyle(e)}function isScrollParent(e){var t=getComputedStyle(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function getLayoutRect(e){var t=getBoundingClientRect(e),n=e.offsetWidth,r=e.offsetHeight;return 1>=Math.abs(t.width-n)&&(n=t.width),1>=Math.abs(t.height-r)&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function getParentNode(e){return"html"===getNodeName(e)?e:e.assignedSlot||e.parentNode||(isShadowRoot(e)?e.host:null)||getDocumentElement(e)}function listScrollParents(e,t){void 0===t&&(t=[]);var n,r=function getScrollParent(e){return["html","body","#document"].indexOf(getNodeName(e))>=0?e.ownerDocument.body:isHTMLElement(e)&&isScrollParent(e)?e:getScrollParent(getParentNode(e))}(e),i=r===(null==(n=e.ownerDocument)?void 0:n.body),o=getWindow(r),a=i?[o].concat(o.visualViewport||[],isScrollParent(r)?r:[]):r,s=t.concat(a);return i?s:s.concat(listScrollParents(getParentNode(a)))}function getTrueOffsetParent(e){return isHTMLElement(e)&&"fixed"!==getComputedStyle(e).position?e.offsetParent:null}function getOffsetParent(e){for(var t=getWindow(e),n=getTrueOffsetParent(e);n&&["table","td","th"].indexOf(getNodeName(n))>=0&&"static"===getComputedStyle(n).position;)n=getTrueOffsetParent(n);return n&&("html"===getNodeName(n)||"body"===getNodeName(n)&&"static"===getComputedStyle(n).position)?t:n||function(e){var t=/firefox/i.test(getUAString());if(/Trident/i.test(getUAString())&&isHTMLElement(e)&&"fixed"===getComputedStyle(e).position)return null;var n=getParentNode(e);for(isShadowRoot(n)&&(n=n.host);isHTMLElement(n)&&0>["html","body"].indexOf(getNodeName(n));){var r=getComputedStyle(n);if("none"!==r.transform||"none"!==r.perspective||"paint"===r.contain||-1!==["transform","perspective"].indexOf(r.willChange)||t&&"filter"===r.willChange||t&&r.filter&&"none"!==r.filter)return n;n=n.parentNode}return null}(e)||t}var b="bottom",x="right",w="left",k="auto",S=["top",b,x,w],C="start",E="viewport",P="popper",T=S.reduce(function(e,t){return e.concat([t+"-"+C,t+"-end"])},[]),A=[].concat(S,[k]).reduce(function(e,t){return e.concat([t,t+"-"+C,t+"-end"])},[]),M=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"],_={placement:"bottom",modifiers:[],strategy:"absolute"};function areValidElements(){for(var e=arguments.length,t=Array(e),n=0;n=0?"x":"y"}function computeOffsets(e){var t,n=e.reference,r=e.element,i=e.placement,o=i?getBasePlacement(i):null,a=i?getVariation(i):null,s=n.x+n.width/2-r.width/2,l=n.y+n.height/2-r.height/2;switch(o){case"top":t={x:s,y:n.y-r.height};break;case b:t={x:s,y:n.y+n.height};break;case x:t={x:n.x+n.width,y:l};break;case w:t={x:n.x-r.width,y:l};break;default:t={x:n.x,y:n.y}}var u=o?getMainAxisFromPlacement(o):null;if(null!=u){var c="y"===u?"height":"width";switch(a){case C:t[u]=t[u]-(n[c]/2-r[c]/2);break;case"end":t[u]=t[u]+(n[c]/2-r[c]/2)}}return t}var R={top:"auto",right:"auto",bottom:"auto",left:"auto"};function mapToStyles(e){var t,n,r,i,o,a,s,l=e.popper,u=e.popperRect,c=e.placement,d=e.variation,f=e.offsets,p=e.position,h=e.gpuAcceleration,m=e.adaptive,v=e.roundOffsets,g=e.isFixed,k=f.x,S=void 0===k?0:k,C=f.y,E=void 0===C?0:C,P="function"==typeof v?v({x:S,y:E}):{x:S,y:E};S=P.x,E=P.y;var T=f.hasOwnProperty("x"),A=f.hasOwnProperty("y"),M=w,_="top",N=window;if(m){var D=getOffsetParent(l),I="clientHeight",j="clientWidth";D===getWindow(l)&&"static"!==getComputedStyle(D=getDocumentElement(l)).position&&"absolute"===p&&(I="scrollHeight",j="scrollWidth"),("top"===c||(c===w||c===x)&&"end"===d)&&(_=b,E-=(g&&D===N&&N.visualViewport?N.visualViewport.height:D[I])-u.height,E*=h?1:-1),(c===w||("top"===c||c===b)&&"end"===d)&&(M=x,S-=(g&&D===N&&N.visualViewport?N.visualViewport.width:D[j])-u.width,S*=h?1:-1)}var L=Object.assign({position:p},m&&R),O=!0===v?(t={x:S,y:E},n=getWindow(l),r=t.x,i=t.y,{x:y(r*(o=n.devicePixelRatio||1))/o||0,y:y(i*o)/o||0}):{x:S,y:E};return(S=O.x,E=O.y,h)?Object.assign({},L,((s={})[_]=A?"0":"",s[M]=T?"0":"",s.transform=1>=(N.devicePixelRatio||1)?"translate("+S+"px, "+E+"px)":"translate3d("+S+"px, "+E+"px, 0)",s)):Object.assign({},L,((a={})[_]=A?E+"px":"",a[M]=T?S+"px":"",a.transform="",a))}var D={left:"right",right:"left",bottom:"top",top:"bottom"};function getOppositePlacement(e){return e.replace(/left|right|bottom|top/g,function(e){return D[e]})}var I={start:"end",end:"start"};function getOppositeVariationPlacement(e){return e.replace(/start|end/g,function(e){return I[e]})}function contains(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&isShadowRoot(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function rectToClientRect(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function getClientRectFromMixedType(e,t,n){var r,i,o,a,s,l,u,c,d,f;return t===E?rectToClientRect(function(e,t){var n=getWindow(e),r=getDocumentElement(e),i=n.visualViewport,o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;var u=isLayoutViewport();(u||!u&&"fixed"===t)&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s+getWindowScrollBarX(e),y:l}}(e,n)):isElement(t)?((r=getBoundingClientRect(t,!1,"fixed"===n)).top=r.top+t.clientTop,r.left=r.left+t.clientLeft,r.bottom=r.top+t.clientHeight,r.right=r.left+t.clientWidth,r.width=t.clientWidth,r.height=t.clientHeight,r.x=r.left,r.y=r.top,r):rectToClientRect((i=getDocumentElement(e),a=getDocumentElement(i),s=getWindowScroll(i),l=null==(o=i.ownerDocument)?void 0:o.body,u=v(a.scrollWidth,a.clientWidth,l?l.scrollWidth:0,l?l.clientWidth:0),c=v(a.scrollHeight,a.clientHeight,l?l.scrollHeight:0,l?l.clientHeight:0),d=-s.scrollLeft+getWindowScrollBarX(i),f=-s.scrollTop,"rtl"===getComputedStyle(l||a).direction&&(d+=v(a.clientWidth,l?l.clientWidth:0)-u),{width:u,height:c,x:d,y:f}))}function getFreshSideObject(){return{top:0,right:0,bottom:0,left:0}}function mergePaddingObject(e){return Object.assign({},getFreshSideObject(),e)}function expandToHashMap(e,t){return t.reduce(function(t,n){return t[n]=e,t},{})}function detectOverflow(e,t){void 0===t&&(t={});var n,r,i,o,a,s,l,u=t,c=u.placement,d=void 0===c?e.placement:c,f=u.strategy,p=void 0===f?e.strategy:f,h=u.boundary,m=u.rootBoundary,y=u.elementContext,w=void 0===y?P:y,k=u.altBoundary,C=u.padding,T=void 0===C?0:C,A=mergePaddingObject("number"!=typeof T?T:expandToHashMap(T,S)),M=e.rects.popper,_=e.elements[void 0!==k&&k?w===P?"reference":P:w],N=(n=isElement(_)?_:_.contextElement||getDocumentElement(e.elements.popper),s=(a=[].concat("clippingParents"===(r=void 0===h?"clippingParents":h)?(i=listScrollParents(getParentNode(n)),isElement(o=["absolute","fixed"].indexOf(getComputedStyle(n).position)>=0&&isHTMLElement(n)?getOffsetParent(n):n)?i.filter(function(e){return isElement(e)&&contains(e,o)&&"body"!==getNodeName(e)}):[]):[].concat(r),[void 0===m?E:m]))[0],(l=a.reduce(function(e,t){var r=getClientRectFromMixedType(n,t,p);return e.top=v(r.top,e.top),e.right=g(r.right,e.right),e.bottom=g(r.bottom,e.bottom),e.left=v(r.left,e.left),e},getClientRectFromMixedType(n,s,p))).width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l),R=getBoundingClientRect(e.elements.reference),D=computeOffsets({reference:R,element:M,strategy:"absolute",placement:d}),I=rectToClientRect(Object.assign({},M,D)),j=w===P?I:R,L={top:N.top-j.top+A.top,bottom:j.bottom-N.bottom+A.bottom,left:N.left-j.left+A.left,right:j.right-N.right+A.right},O=e.modifiersData.offset;if(w===P&&O){var F=O[d];Object.keys(L).forEach(function(e){var t=[x,b].indexOf(e)>=0?1:-1,n=["top",b].indexOf(e)>=0?"y":"x";L[e]+=F[n]*t})}return L}function within(e,t,n){return v(e,g(t,n))}function getSideOffsets(e,t,n){return void 0===n&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function isAnySideFullyClipped(e){return["top",x,b,w].some(function(t){return e[t]>=0})}var j=(o=void 0===(i=(r={defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,o=void 0===i||i,a=r.resize,s=void 0===a||a,l=getWindow(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&u.forEach(function(e){e.addEventListener("scroll",n.update,N)}),s&&l.addEventListener("resize",n.update,N),function(){o&&u.forEach(function(e){e.removeEventListener("scroll",n.update,N)}),s&&l.removeEventListener("resize",n.update,N)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,n=e.name;t.modifiersData[n]=computeOffsets({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=n.adaptive,o=n.roundOffsets,a=void 0===o||o,s={placement:getBasePlacement(t.placement),variation:getVariation(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:void 0===r||r,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,mapToStyles(Object.assign({},s,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:void 0===i||i,roundOffsets:a})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,mapToStyles(Object.assign({},s,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:a})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},{name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var n=t.styles[e]||{},r=t.attributes[e]||{},i=t.elements[e];isHTMLElement(i)&&getNodeName(i)&&(Object.assign(i.style,n),Object.keys(r).forEach(function(e){var t=r[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)}))})},effect:function(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(e){var r=t.elements[e],i=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:n[e]).reduce(function(e,t){return e[t]="",e},{});isHTMLElement(r)&&getNodeName(r)&&(Object.assign(r.style,o),Object.keys(i).forEach(function(e){r.removeAttribute(e)}))})}},requires:["computeStyles"]},{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,n=e.options,r=e.name,i=n.offset,o=void 0===i?[0,0]:i,a=A.reduce(function(e,n){var r,i,a,s,l,u;return e[n]=(r=t.rects,a=[w,"top"].indexOf(i=getBasePlacement(n))>=0?-1:1,l=(s="function"==typeof o?o(Object.assign({},r,{placement:n})):o)[0],u=s[1],l=l||0,u=(u||0)*a,[w,x].indexOf(i)>=0?{x:u,y:l}:{x:l,y:u}),e},{}),s=a[t.placement],l=s.x,u=s.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=a}},{name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,o=void 0===i||i,a=n.altAxis,s=void 0===a||a,l=n.fallbackPlacements,u=n.padding,c=n.boundary,d=n.rootBoundary,f=n.altBoundary,p=n.flipVariations,h=void 0===p||p,m=n.allowedAutoPlacements,v=t.options.placement,g=getBasePlacement(v)===v,y=l||(g||!h?[getOppositePlacement(v)]:function(e){if(getBasePlacement(e)===k)return[];var t=getOppositePlacement(e);return[getOppositeVariationPlacement(e),t,getOppositeVariationPlacement(t)]}(v)),E=[v].concat(y).reduce(function(e,n){var r,i,o,a,s,l,f,p,v,g,y,b;return e.concat(getBasePlacement(n)===k?(i=(r={placement:n,boundary:c,rootBoundary:d,padding:u,flipVariations:h,allowedAutoPlacements:m}).placement,o=r.boundary,a=r.rootBoundary,s=r.padding,l=r.flipVariations,p=void 0===(f=r.allowedAutoPlacements)?A:f,0===(y=(g=(v=getVariation(i))?l?T:T.filter(function(e){return getVariation(e)===v}):S).filter(function(e){return p.indexOf(e)>=0})).length&&(y=g),Object.keys(b=y.reduce(function(e,n){return e[n]=detectOverflow(t,{placement:n,boundary:o,rootBoundary:a,padding:s})[getBasePlacement(n)],e},{})).sort(function(e,t){return b[e]-b[t]})):n)},[]),P=t.rects.reference,M=t.rects.popper,_=new Map,N=!0,R=E[0],D=0;D=0,F=O?"width":"height",V=detectOverflow(t,{placement:I,boundary:c,rootBoundary:d,altBoundary:f,padding:u}),B=O?L?x:w:L?b:"top";P[F]>M[F]&&(B=getOppositePlacement(B));var W=getOppositePlacement(B),$=[];if(o&&$.push(V[j]<=0),s&&$.push(V[B]<=0,V[W]<=0),$.every(function(e){return e})){R=I,N=!1;break}_.set(I,$)}if(N)for(var U=h?3:1,_loop=function(e){var t=E.find(function(t){var n=_.get(t);if(n)return n.slice(0,e).every(function(e){return e})});if(t)return R=t,"break"},H=U;H>0&&"break"!==_loop(H);H--);t.placement!==R&&(t.modifiersData[r]._skip=!0,t.placement=R,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,o=n.altAxis,a=n.boundary,s=n.rootBoundary,l=n.altBoundary,u=n.padding,c=n.tether,d=void 0===c||c,f=n.tetherOffset,p=void 0===f?0:f,h=detectOverflow(t,{boundary:a,rootBoundary:s,padding:u,altBoundary:l}),m=getBasePlacement(t.placement),y=getVariation(t.placement),k=!y,S=getMainAxisFromPlacement(m),E="x"===S?"y":"x",P=t.modifiersData.popperOffsets,T=t.rects.reference,A=t.rects.popper,M="function"==typeof p?p(Object.assign({},t.rects,{placement:t.placement})):p,_="number"==typeof M?{mainAxis:M,altAxis:M}:Object.assign({mainAxis:0,altAxis:0},M),N=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,R={x:0,y:0};if(P){if(void 0===i||i){var D,I="y"===S?"top":w,j="y"===S?b:x,L="y"===S?"height":"width",O=P[S],F=O+h[I],V=O-h[j],B=d?-A[L]/2:0,W=y===C?T[L]:A[L],$=y===C?-A[L]:-T[L],U=t.elements.arrow,H=d&&U?getLayoutRect(U):{width:0,height:0},z=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:getFreshSideObject(),G=z[I],q=z[j],K=within(0,T[L],H[L]),X=k?T[L]/2-B-K-G-_.mainAxis:W-K-G-_.mainAxis,Z=k?-T[L]/2+B+K+q+_.mainAxis:$+K+q+_.mainAxis,Y=t.elements.arrow&&getOffsetParent(t.elements.arrow),Q=Y?"y"===S?Y.clientTop||0:Y.clientLeft||0:0,J=null!=(D=null==N?void 0:N[S])?D:0,ee=O+X-J-Q,et=O+Z-J,en=within(d?g(F,ee):F,O,d?v(V,et):V);P[S]=en,R[S]=en-O}if(void 0!==o&&o){var er,ei,eo="x"===S?"top":w,ea="x"===S?b:x,es=P[E],el="y"===E?"height":"width",eu=es+h[eo],ec=es-h[ea],ed=-1!==["top",w].indexOf(m),ef=null!=(ei=null==N?void 0:N[E])?ei:0,ep=ed?eu:es-T[el]-A[el]-ef+_.altAxis,eh=ed?es+T[el]+A[el]-ef-_.altAxis:ec,em=d&&ed?(er=within(ep,es,eh))>eh?eh:er:within(d?ep:eu,es,d?eh:ec);P[E]=em,R[E]=em-es}t.modifiersData[r]=R}},requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,n,r=e.state,i=e.name,o=e.options,a=r.elements.arrow,s=r.modifiersData.popperOffsets,l=getBasePlacement(r.placement),u=getMainAxisFromPlacement(l),c=[w,x].indexOf(l)>=0?"height":"width";if(a&&s){var d=mergePaddingObject("number"!=typeof(t="function"==typeof(t=o.padding)?t(Object.assign({},r.rects,{placement:r.placement})):t)?t:expandToHashMap(t,S)),f=getLayoutRect(a),p="y"===u?"top":w,h="y"===u?b:x,m=r.rects.reference[c]+r.rects.reference[u]-s[u]-r.rects.popper[c],v=s[u]-r.rects.reference[u],g=getOffsetParent(a),y=g?"y"===u?g.clientHeight||0:g.clientWidth||0:0,k=d[p],C=y-f[c]-d[h],E=y/2-f[c]/2+(m/2-v/2),P=within(k,E,C);r.modifiersData[i]=((n={})[u]=P,n.centerOffset=P-E,n)}},effect:function(e){var t=e.state,n=e.options.element,r=void 0===n?"[data-popper-arrow]":n;null!=r&&("string"!=typeof r||(r=t.elements.popper.querySelector(r)))&&contains(t.elements.popper,r)&&(t.elements.arrow=r)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=detectOverflow(t,{elementContext:"reference"}),s=detectOverflow(t,{altBoundary:!0}),l=getSideOffsets(a,r),u=getSideOffsets(s,i,o),c=isAnySideFullyClipped(l),d=isAnySideFullyClipped(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":d})}}]}).defaultModifiers)?[]:i,s=void 0===(a=r.defaultOptions)?_:a,function(e,t,n){void 0===n&&(n=s);var r,i={placement:"bottom",orderedModifiers:[],options:Object.assign({},_,s),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},a=[],l=!1,u={state:i,setOptions:function(n){var r,l,c,d,f,p="function"==typeof n?n(i.options):n;cleanupModifierEffects(),i.options=Object.assign({},s,i.options,p),i.scrollParents={reference:isElement(e)?listScrollParents(e):e.contextElement?listScrollParents(e.contextElement):[],popper:listScrollParents(t)};var h=(l=Object.keys(r=[].concat(o,i.options.modifiers).reduce(function(e,t){var n=e[t.name];return e[t.name]=n?Object.assign({},n,t,{options:Object.assign({},n.options,t.options),data:Object.assign({},n.data,t.data)}):t,e},{})).map(function(e){return r[e]}),c=new Map,d=new Set,f=[],l.forEach(function(e){c.set(e.name,e)}),l.forEach(function(e){d.has(e.name)||function sort(e){d.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!d.has(e)){var t=c.get(e);t&&sort(t)}}),f.push(e)}(e)}),M.reduce(function(e,t){return e.concat(f.filter(function(e){return e.phase===t}))},[]));return i.orderedModifiers=h.filter(function(e){return e.enabled}),i.orderedModifiers.forEach(function(e){var t=e.name,n=e.options,r=e.effect;if("function"==typeof r){var o=r({state:i,name:t,instance:u,options:void 0===n?{}:n});a.push(o||function(){})}}),u.update()},forceUpdate:function(){if(!l){var e,t,n,r,o,a,s,c,d,f,p,h,m=i.elements,v=m.reference,g=m.popper;if(areValidElements(v,g)){i.rects={reference:(t=getOffsetParent(g),n="fixed"===i.options.strategy,r=isHTMLElement(t),c=isHTMLElement(t)&&(a=y((o=t.getBoundingClientRect()).width)/t.offsetWidth||1,s=y(o.height)/t.offsetHeight||1,1!==a||1!==s),d=getDocumentElement(t),f=getBoundingClientRect(v,c,n),p={scrollLeft:0,scrollTop:0},h={x:0,y:0},(r||!r&&!n)&&(("body"!==getNodeName(t)||isScrollParent(d))&&(p=(e=t)!==getWindow(e)&&isHTMLElement(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:getWindowScroll(e)),isHTMLElement(t)?(h=getBoundingClientRect(t,!0),h.x+=t.clientLeft,h.y+=t.clientTop):d&&(h.x=getWindowScrollBarX(d))),{x:f.left+p.scrollLeft-h.x,y:f.top+p.scrollTop-h.y,width:f.width,height:f.height}),popper:getLayoutRect(g)},i.reset=!1,i.placement=i.options.placement,i.orderedModifiers.forEach(function(e){return i.modifiersData[e.name]=Object.assign({},e.data)});for(var b=0;b{}),T=(0,L.useCallback)(()=>{var e;t&&k.current&&S.current&&(null==(e=P.current)||e.call(P),C.current=j(k.current,S.current,{placement:E,modifiers:[f,d,c,{...u,enabled:!!x},{name:"eventListeners",...(0,l.$B)(a)},{name:"arrow",options:{padding:o}},{name:"offset",options:{offset:null!=s?s:[0,v]}},{name:"flip",enabled:!!g,options:{padding:8}},{name:"preventOverflow",enabled:!!b,options:{boundary:y}},...null!=n?n:[]],strategy:i}),C.current.forceUpdate(),P.current=C.current.destroy)},[E,t,n,x,a,o,s,v,g,b,y,i]);(0,L.useEffect)(()=>()=>{var e;k.current||S.current||(null==(e=C.current)||e.destroy(),C.current=null)},[]);let A=(0,L.useCallback)(e=>{k.current=e,T()},[T]),M=(0,L.useCallback)((e={},t=null)=>({...e,ref:(0,m.lq)(A,t)}),[A]),_=(0,L.useCallback)(e=>{S.current=e,T()},[T]),N=(0,L.useCallback)((e={},t=null)=>({...e,ref:(0,m.lq)(_,t),style:{...e.style,position:i,minWidth:x?void 0:"max-content",inset:"0 auto auto 0"}}),[i,_,x]),R=(0,L.useCallback)((e={},t=null)=>{let{size:n,shadowColor:r,bg:i,style:o,...a}=e;return{...a,ref:t,"data-popper-arrow":"",style:function(e){let{size:t,shadowColor:n,bg:r,style:i}=e,o={...i,position:"absolute"};return t&&(o["--popper-arrow-size"]=t),n&&(o["--popper-arrow-shadow-color"]=n),r&&(o["--popper-arrow-bg"]=r),o}(e)}},[]),D=(0,L.useCallback)((e={},t=null)=>({...e,ref:t,"data-popper-arrow-inner":""}),[]);return{update(){var e;null==(e=C.current)||e.update()},forceUpdate(){var e;null==(e=C.current)||e.forceUpdate()},transformOrigin:l.Dq.transformOrigin.varRef,referenceRef:A,popperRef:_,getPopperProps:N,getArrowProps:R,getArrowInnerProps:D,getReferenceProps:M}}},78282:function(e,t,n){"use strict";n.r(t),n.d(t,{popperCSSVars:function(){return i.Dq},usePopper:function(){return r.D}});var r=n(1521),i=n(15006)},2879:function(e,t,n){"use strict";n.d(t,{h:function(){return Portal}});var r=n(69782),i=n(67673),o=n(310),a=n(54887),s=n(2265),l=n(57437),[u,c]=(0,o.k)({strict:!1,name:"PortalContext"}),d="chakra-portal",Container=e=>(0,l.jsx)("div",{className:"chakra-portal-zIndex",style:{position:"absolute",zIndex:e.zIndex,top:0,left:0,right:0},children:e.children}),DefaultPortal=e=>{let{appendToParentPortal:t,children:n}=e,[o,f]=(0,s.useState)(null),p=(0,s.useRef)(null),[,h]=(0,s.useState)({});(0,s.useEffect)(()=>h({}),[]);let m=c(),v=(0,r.L)();(0,i.G)(()=>{if(!o)return;let e=o.ownerDocument,n=t&&null!=m?m:e.body;if(!n)return;p.current=e.createElement("div"),p.current.className=d,n.appendChild(p.current),h({});let r=p.current;return()=>{n.contains(r)&&n.removeChild(r)}},[o]);let g=(null==v?void 0:v.zIndex)?(0,l.jsx)(Container,{zIndex:null==v?void 0:v.zIndex,children:n}):n;return p.current?(0,a.createPortal)((0,l.jsx)(u,{value:p.current,children:g}),p.current):(0,l.jsx)("span",{ref:e=>{e&&f(e)}})},ContainerPortal=e=>{let{children:t,containerRef:n,appendToParentPortal:r}=e,o=n.current,c=null!=o?o:"undefined"!=typeof window?document.body:void 0,f=(0,s.useMemo)(()=>{let e=null==o?void 0:o.ownerDocument.createElement("div");return e&&(e.className=d),e},[o]),[,p]=(0,s.useState)({});return((0,i.G)(()=>p({}),[]),(0,i.G)(()=>{if(f&&c)return c.appendChild(f),()=>{c.removeChild(f)}},[f,c]),c&&f)?(0,a.createPortal)((0,l.jsx)(u,{value:r?f:null,children:t}),f):null};function Portal(e){let t={appendToParentPortal:!0,...e},{containerRef:n,...r}=t;return n?(0,l.jsx)(ContainerPortal,{containerRef:n,...r}):(0,l.jsx)(DefaultPortal,{...r})}Portal.className=d,Portal.selector=".chakra-portal",Portal.displayName="Portal"},69782:function(e,t,n){"use strict";n.d(t,{L:function(){return a},h:function(){return PortalManager}});var r=n(310),i=n(57437),[o,a]=(0,r.k)({strict:!1,name:"PortalManagerContext"});function PortalManager(e){let{children:t,zIndex:n}=e;return(0,i.jsx)(o,{value:{zIndex:n},children:t})}PortalManager.displayName="PortalManager"},38236:function(e,t,n){"use strict";n.r(t),n.d(t,{Portal:function(){return r.h},PortalManager:function(){return i.h},usePortalManager:function(){return i.L}});var r=n(2879),i=n(69782)},67774:function(e,t,n){"use strict";n.r(t),n.d(t,{CircularProgress:function(){return f},CircularProgressLabel:function(){return i},Progress:function(){return y},ProgressLabel:function(){return ProgressLabel},useProgressStyles:function(){return v}});var r=n(23145),i=(0,r.chakra)("div",{baseStyle:{fontSize:"0.24em",top:"50%",left:"50%",width:"100%",textAlign:"center",position:"absolute",transform:"translate(-50%, -50%)"}});i.displayName="CircularProgressLabel";var o=n(57437),Circle=e=>(0,o.jsx)(r.chakra.circle,{cx:50,cy:50,r:42,fill:"transparent",...e});Circle.displayName="Circle";var a=n(99538),s=(0,a.F4)({"0%":{strokeDasharray:"1, 400",strokeDashoffset:"0"},"50%":{strokeDasharray:"400, 400",strokeDashoffset:"-100"},"100%":{strokeDasharray:"400, 400",strokeDashoffset:"-260"}}),l=(0,a.F4)({"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}}),u=(0,a.F4)({"0%":{left:"-40%"},"100%":{left:"100%"}}),c=(0,a.F4)({from:{backgroundPosition:"1rem 0"},to:{backgroundPosition:"0 0"}});function getProgressProps(e){let{value:t=0,min:n,max:r,valueText:i,getValueText:o,isIndeterminate:a,role:s="progressbar"}=e,l=(t-n)*100/(r-n);return{bind:{"data-indeterminate":a?"":void 0,"aria-valuemax":r,"aria-valuemin":n,"aria-valuenow":a?void 0:t,"aria-valuetext":(()=>{if(null!=t)return"function"==typeof o?o(t,l):i})(),role:s},percent:l,value:t}}var Shape=e=>{let{size:t,isIndeterminate:n,...i}=e;return(0,o.jsx)(r.chakra.svg,{viewBox:"0 0 100 100",__css:{width:t,height:t,animation:n?`${l} 2s linear infinite`:void 0},...i})};Shape.displayName="Shape";var d=n(58250),f=(0,d.forwardRef)((e,t)=>{var n;let{size:i="48px",max:a=100,min:l=0,valueText:u,getValueText:c,value:d,capIsRound:f,children:p,thickness:h="10px",color:m="#0078d4",trackColor:v="#edebe9",isIndeterminate:g,...y}=e,b=getProgressProps({min:l,max:a,value:d,valueText:u,getValueText:c,isIndeterminate:g}),x=g?void 0:(null!=(n=b.percent)?n:0)*2.64,w=null==x?void 0:`${x} ${264-x}`,k=g?{css:{animation:`${s} 1.5s linear infinite`}}:{strokeDashoffset:66,strokeDasharray:w,transitionProperty:"stroke-dasharray, stroke",transitionDuration:"0.6s",transitionTimingFunction:"ease"};return(0,o.jsxs)(r.chakra.div,{ref:t,className:"chakra-progress",...b.bind,...y,__css:{display:"inline-block",position:"relative",verticalAlign:"middle",fontSize:i},children:[(0,o.jsxs)(Shape,{size:i,isIndeterminate:g,children:[(0,o.jsx)(Circle,{stroke:v,strokeWidth:h,className:"chakra-progress__track"}),(0,o.jsx)(Circle,{stroke:m,strokeWidth:h,className:"chakra-progress__indicator",strokeLinecap:f?"round":void 0,opacity:0!==b.value||g?void 0:0,...k})]}),p]})});f.displayName="CircularProgress";var p=n(50446),h=n(92013),[m,v]=(0,n(310).k)({name:"ProgressStylesContext",errorMessage:"useProgressStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),g=(0,d.forwardRef)((e,t)=>{let{min:n,max:i,value:a,isIndeterminate:s,role:l,...u}=e,c=getProgressProps({value:a,min:n,max:i,isIndeterminate:s,role:l}),d=v(),f={height:"100%",...d.filledTrack};return(0,o.jsx)(r.chakra.div,{ref:t,style:{width:`${c.percent}%`,...u.style},...c.bind,...u,__css:f})}),y=(0,d.forwardRef)((e,t)=>{var n;let{value:i,min:a=0,max:s=100,hasStripe:l,isAnimated:d,children:f,borderRadius:v,isIndeterminate:y,"aria-label":b,"aria-labelledby":x,"aria-valuetext":w,title:k,role:S,...C}=(0,p.Lr)(e),E=(0,h.useMultiStyleConfig)("Progress",e),P=null!=v?v:null==(n=E.track)?void 0:n.borderRadius,T={animation:`${c} 1s linear infinite`},A=!y&&l,M={...A&&d&&T,...y&&{position:"absolute",willChange:"left",minWidth:"50%",animation:`${u} 1s ease infinite normal none running`}},_={overflow:"hidden",position:"relative",...E.track};return(0,o.jsx)(r.chakra.div,{ref:t,borderRadius:P,__css:_,...C,children:(0,o.jsxs)(m,{value:E,children:[(0,o.jsx)(g,{"aria-label":b,"aria-labelledby":x,"aria-valuetext":w,min:a,max:s,value:i,isIndeterminate:y,css:M,borderRadius:P,title:k,role:S}),f]})})});y.displayName="Progress";var ProgressLabel=e=>{let t=v(),n={top:"50%",left:"50%",width:"100%",textAlign:"center",position:"absolute",transform:"translate(-50%, -50%)",...t.label};return(0,o.jsx)(r.chakra.div,{...e,__css:n})};ProgressLabel.displayName="ProgressLabel"},22745:function(e,t,n){"use strict";n.r(t),n.d(t,{Radio:function(){return y},RadioGroup:function(){return f},useRadio:function(){return useRadio},useRadioGroup:function(){return useRadioGroup},useRadioGroupContext:function(){return d}});var r=n(16465),i=n(45663),o=n(2265);function useRadioGroup(e={}){let{onChange:t,value:n,defaultValue:a,name:s,isDisabled:l,isFocusable:u,isNative:c,...d}=e,[f,p]=(0,o.useState)(a||""),h=void 0!==n,m=h?n:f,v=(0,o.useRef)(null),g=(0,o.useCallback)(()=>{let e=v.current;if(!e)return;let t="input:not(:disabled):checked",n=e.querySelector(t);if(n){n.focus();return}t="input:not(:disabled)";let r=e.querySelector(t);null==r||r.focus()},[]),y=(0,o.useId)(),b=`radio-${y}`,x=s||b,w=(0,o.useCallback)(e=>{let n=e&&(0,r.Kn)(e)&&(0,r.Kn)(e.target)?e.target.value:e;h||p(n),null==t||t(String(n))},[t,h]),k=(0,o.useCallback)((e={},t=null)=>({...e,ref:(0,i.lq)(t,v),role:"radiogroup"}),[]),S=(0,o.useCallback)((e={},t=null)=>{let n=c?"checked":"isChecked";return{...e,ref:t,name:x,[n]:null!=m?e.value===m:void 0,onChange(e){w(e)},"data-radiogroup":!0}},[c,x,w,m]);return{getRootProps:k,getRadioProps:S,name:x,ref:v,focus:g,setValue:p,value:m,onChange:w,isDisabled:l,isFocusable:u,htmlProps:d}}var a=n(58250),s=n(23145),l=n(310),u=n(57437),[c,d]=(0,l.k)({name:"RadioGroupContext",strict:!1}),f=(0,a.forwardRef)((e,t)=>{let{colorScheme:n,size:i,variant:a,children:l,className:d,isDisabled:f,isFocusable:p,...h}=e,{value:m,onChange:v,getRootProps:g,name:y,htmlProps:b}=useRadioGroup(h),x=(0,o.useMemo)(()=>({name:y,size:i,onChange:v,colorScheme:n,value:m,variant:a,isDisabled:f,isFocusable:p}),[y,i,v,n,m,a,f,p]);return(0,u.jsx)(c,{value:x,children:(0,u.jsx)(s.chakra.div,{...g(b,t),className:(0,r.cx)("chakra-radio-group",d),children:l})})});f.displayName="RadioGroup";var p=n(68975),h=n(29522),m={border:"0",clip:"rect(0, 0, 0, 0)",height:"1px",width:"1px",margin:"-1px",padding:"0",overflow:"hidden",whiteSpace:"nowrap",position:"absolute"};function useRadio(e={}){let{defaultChecked:t,isChecked:n,isFocusable:i,isDisabled:a,isReadOnly:s,isRequired:l,onChange:u,isInvalid:c,name:f,value:v,id:g,"data-radiogroup":y,"aria-describedby":b,...x}=e,w=`radio-${(0,o.useId)()}`,k=(0,p.NJ)(),S=d(),C=k&&!(S||y)?k.id:w;C=null!=g?g:C;let E=null!=a?a:null==k?void 0:k.isDisabled,P=null!=s?s:null==k?void 0:k.isReadOnly,T=null!=l?l:null==k?void 0:k.isRequired,A=null!=c?c:null==k?void 0:k.isInvalid,[M,_]=(0,o.useState)(!1),[N,R]=(0,o.useState)(!1),[D,I]=(0,o.useState)(!1),[j,L]=(0,o.useState)(!1),[O,F]=(0,o.useState)(!!t),V=void 0!==n,B=V?n:O;(0,o.useEffect)(()=>(0,h.BT)(_),[]);let W=(0,o.useCallback)(e=>{if(P||E){e.preventDefault();return}V||F(e.target.checked),null==u||u(e)},[V,E,P,u]),$=(0,o.useCallback)(e=>{" "===e.key&&L(!0)},[L]),U=(0,o.useCallback)(e=>{" "===e.key&&L(!1)},[L]),H=(0,o.useCallback)((e={},t=null)=>({...e,ref:t,"data-active":(0,r.PB)(j),"data-hover":(0,r.PB)(D),"data-disabled":(0,r.PB)(E),"data-invalid":(0,r.PB)(A),"data-checked":(0,r.PB)(B),"data-focus":(0,r.PB)(N),"data-focus-visible":(0,r.PB)(N&&M),"data-readonly":(0,r.PB)(P),"aria-hidden":!0,onMouseDown:(0,r.v0)(e.onMouseDown,()=>L(!0)),onMouseUp:(0,r.v0)(e.onMouseUp,()=>L(!1)),onMouseEnter:(0,r.v0)(e.onMouseEnter,()=>I(!0)),onMouseLeave:(0,r.v0)(e.onMouseLeave,()=>I(!1))}),[j,D,E,A,B,N,P,M]),{onFocus:z,onBlur:G}=null!=k?k:{},q=(0,o.useCallback)((e={},t=null)=>{let n=E&&!i;return{...e,id:C,ref:t,type:"radio",name:f,value:v,onChange:(0,r.v0)(e.onChange,W),onBlur:(0,r.v0)(G,e.onBlur,()=>R(!1)),onFocus:(0,r.v0)(z,e.onFocus,()=>R(!0)),onKeyDown:(0,r.v0)(e.onKeyDown,$),onKeyUp:(0,r.v0)(e.onKeyUp,U),checked:B,disabled:n,readOnly:P,required:T,"aria-invalid":(0,r.Qm)(A),"aria-disabled":(0,r.Qm)(n),"aria-required":(0,r.Qm)(T),"data-readonly":(0,r.PB)(P),"aria-describedby":b,style:m}},[E,i,C,f,v,W,G,z,$,U,B,P,T,A,b]);return{state:{isInvalid:A,isFocused:N,isChecked:B,isActive:j,isHovered:D,isDisabled:E,isReadOnly:P,isRequired:T},getCheckboxProps:H,getRadioProps:H,getInputProps:q,getLabelProps:(e={},t=null)=>({...e,ref:t,onMouseDown:(0,r.v0)(e.onMouseDown,stopEvent),"data-disabled":(0,r.PB)(E),"data-checked":(0,r.PB)(B),"data-invalid":(0,r.PB)(A)}),getRootProps:(e,t=null)=>({...e,ref:t,"data-disabled":(0,r.PB)(E),"data-checked":(0,r.PB)(B),"data-invalid":(0,r.PB)(A)}),htmlProps:x}}function stopEvent(e){e.preventDefault(),e.stopPropagation()}var v=n(92013),g=n(50446),y=(0,a.forwardRef)((e,t)=>{var n;let i=d(),{onChange:o,value:a}=e,l=(0,v.useMultiStyleConfig)("Radio",{...i,...e}),c=(0,g.Lr)(e),{spacing:f="0.5rem",children:p,isDisabled:h=null==i?void 0:i.isDisabled,isFocusable:m=null==i?void 0:i.isFocusable,inputProps:y,...b}=c,x=e.isChecked;(null==i?void 0:i.value)!=null&&null!=a&&(x=i.value===a);let w=o;(null==i?void 0:i.onChange)&&null!=a&&(w=(0,r.PP)(i.onChange,o));let k=null!=(n=null==e?void 0:e.name)?n:null==i?void 0:i.name,{getInputProps:S,getCheckboxProps:C,getLabelProps:E,getRootProps:P,htmlProps:T}=useRadio({...b,isChecked:x,isFocusable:m,isDisabled:h,onChange:w,name:k}),[A,M]=function(e,t){let n={},r={};for(let[i,o]of Object.entries(e))t.includes(i)?n[i]=o:r[i]=o;return[n,r]}(T,g.oE),_=C(M),N=S(y,t),R=E(),D=Object.assign({},A,P()),I={display:"inline-flex",alignItems:"center",verticalAlign:"top",cursor:"pointer",position:"relative",...l.container},j={display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,...l.control},L={userSelect:"none",marginStart:f,...l.label};return(0,u.jsxs)(s.chakra.label,{className:"chakra-radio",...D,__css:I,children:[(0,u.jsx)("input",{className:"chakra-radio__input",...N}),(0,u.jsx)(s.chakra.span,{className:"chakra-radio__control",..._,__css:j}),p&&(0,u.jsx)(s.chakra.span,{className:"chakra-radio__label",...R,__css:L,children:p})]})});y.displayName="Radio"},61158:function(e,t,n){"use strict";n.d(t,{W:function(){return getValidChildren}});var r=n(2265);function getValidChildren(e){return r.Children.toArray(e).filter(e=>(0,r.isValidElement)(e))}},52733:function(e,t,n){"use strict";n.d(t,{O:function(){return useEnvironment},u:function(){return EnvironmentProvider}});var r=n(67673),i=n(2265),o=n(57437),a=(0,i.createContext)({getDocument:()=>document,getWindow:()=>window});function useEnvironment({defer:e}={}){let[,t]=(0,i.useReducer)(e=>e+1,0);return(0,r.G)(()=>{e&&t()},[e]),(0,i.useContext)(a)}function EnvironmentProvider(e){let{children:t,environment:n,disabled:r}=e,s=(0,i.useRef)(null),l=(0,i.useMemo)(()=>n||{getDocument:()=>{var e,t;return null!=(t=null==(e=s.current)?void 0:e.ownerDocument)?t:document},getWindow:()=>{var e,t;return null!=(t=null==(e=s.current)?void 0:e.ownerDocument.defaultView)?t:window}},[n]),u=!r||!n;return(0,o.jsxs)(a.Provider,{value:l,children:[t,u&&(0,o.jsx)("span",{id:"__chakra_env",hidden:!0,ref:s})]})}a.displayName="EnvironmentContext",EnvironmentProvider.displayName="EnvironmentProvider"},81104:function(e,t,n){"use strict";n.r(t),n.d(t,{EnvironmentProvider:function(){return r.u},useEnvironment:function(){return r.O}});var r=n(52733)},12937:function(e,t,n){"use strict";n.d(t,{h:function(){return useAnimationState}});var r=n(2265),i=n(10931),o=n(65346);function useAnimationState(e){let{isOpen:t,ref:n}=e,[a,s]=(0,r.useState)(t),[l,u]=(0,r.useState)(!1);(0,r.useEffect)(()=>{l||(s(t),u(!0))},[t,l,a]),(0,i.O)(()=>n.current,"animationend",()=>{s(t)});let c=!t&&!a;return{present:!c,onComplete(){var e;let t=(0,o.kR)(n.current),r=new t.CustomEvent("animationend",{bubbles:!0});null==(e=n.current)||e.dispatchEvent(r)}}}},37977:function(e,t,n){"use strict";n.d(t,{W:function(){return useCallbackRef}});var r=n(2265);function useCallbackRef(e,t=[]){let n=(0,r.useRef)(e);return(0,r.useEffect)(()=>{n.current=e}),(0,r.useCallback)((...e)=>{var t;return null==(t=n.current)?void 0:t.call(n,...e)},t)}},27771:function(e,t,n){"use strict";n.d(t,{T:function(){return useControllableState}});var r=n(2265),i=n(37977);function useControllableState(e){let{value:t,defaultValue:n,onChange:o,shouldUpdate:a=(e,t)=>e!==t}=e,s=(0,i.W)(o),l=(0,i.W)(a),[u,c]=(0,r.useState)(n),d=void 0!==t,f=d?t:u,p=(0,i.W)(e=>{let t="function"==typeof e?e(f):e;l(f,t)&&(d||c(t),s(t))},[d,s,f,l]);return[f,p]}},61113:function(e,t,n){"use strict";n.d(t,{q:function(){return useDisclosure}});var r=n(37977),i=n(2265);function useDisclosure(e={}){let{onClose:t,onOpen:n,isOpen:o,id:a}=e,s=(0,r.W)(n),l=(0,r.W)(t),[u,c]=(0,i.useState)(e.defaultIsOpen||!1),d=void 0!==o?o:u,f=void 0!==o,p=(0,i.useId)(),h=null!=a?a:`disclosure-${p}`,m=(0,i.useCallback)(()=>{f||c(!1),null==l||l()},[f,l]),v=(0,i.useCallback)(()=>{f||c(!0),null==s||s()},[f,s]),g=(0,i.useCallback)(()=>{d?m():v()},[d,v,m]);return{isOpen:d,onOpen:v,onClose:m,onToggle:g,isControlled:f,getButtonProps:function(e={}){return{...e,"aria-expanded":d,"aria-controls":h,onClick(t){var n;null==(n=e.onClick)||n.call(e,t),g()}}},getDisclosureProps:function(e={}){return{...e,hidden:!d,id:h}}}}},10931:function(e,t,n){"use strict";n.d(t,{O:function(){return useEventListener}});var r=n(2265),i=n(37977);function useEventListener(e,t,n,o){let a=(0,i.W)(n);return(0,r.useEffect)(()=>{let r="function"==typeof e?e():null!=e?e:document;if(n&&r)return r.addEventListener(t,a,o),()=>{r.removeEventListener(t,a,o)}},[t,e,o,a,n]),()=>{let n="function"==typeof e?e():null!=e?e:document;null==n||n.removeEventListener(t,a,o)}}},81958:function(e,t,n){"use strict";n.d(t,{C:function(){return useFocusOnHide},G:function(){return useFocusOnShow}});var r=n(65346),i=n(38955),o=n(58878),a=n(10931),s=n(67673),l=n(89656),u=n(2265);function useFocusOnHide(e,t){let{shouldFocus:n,visible:o,focusRef:a}=t,s=n&&!o;(0,l.r)(()=>{let t;if(!s||function(e){let t=e.current;if(!t)return!1;let n=(0,r.vY)(t);return!(!n||t.contains(n))&&!!(0,i.Wq)(n)}(e))return;let n=(null==a?void 0:a.current)||e.current;if(n)return t=requestAnimationFrame(()=>{n.focus({preventScroll:!0})}),()=>{cancelAnimationFrame(t)}},[s,e,a])}var c={preventScroll:!0,shouldFocus:!1};function useFocusOnShow(e,t=c){let{focusRef:n,preventScroll:r,shouldFocus:i,visible:d}=t,f="current"in e?e.current:e,p=i&&d,h=(0,u.useRef)(p),m=(0,u.useRef)(d);(0,s.G)(()=>{!m.current&&d&&(h.current=p),m.current=d},[d,p]);let v=(0,u.useCallback)(()=>{if(d&&f&&h.current&&(h.current=!1,!f.contains(document.activeElement))){if(null==n?void 0:n.current)requestAnimationFrame(()=>{var e;null==(e=n.current)||e.focus({preventScroll:r})});else{let e=(0,o.t5)(f);e.length>0&&requestAnimationFrame(()=>{e[0].focus({preventScroll:r})})}}},[d,r,f,n]);(0,l.r)(()=>{v()},[v]),(0,a.O)(f,"transitionend",v)}},38594:function(e,t,n){"use strict";n.d(t,{s:function(){return useFocusOnPointerDown}});var r=n(10931),isDom=()=>"undefined"!=typeof window,vn=e=>isDom()&&e.test(navigator.vendor),pt=e=>isDom()&&e.test(function(){var e;let t=navigator.userAgentData;return null!=(e=null==t?void 0:t.platform)?e:navigator.platform}()),isApple=()=>pt(/mac|iphone|ipad|ipod/i),isSafari=()=>isApple()&&vn(/apple/i);function useFocusOnPointerDown(e){let{ref:t,elements:n,enabled:i}=e,doc=()=>{var e,n;return null!=(n=null==(e=t.current)?void 0:e.ownerDocument)?n:document};(0,r.O)(doc,"pointerdown",e=>{if(!isSafari()||!i)return;let r=e.target,o=(null!=n?n:[t]).some(e=>{let t="current"in e?e.current:e;return(null==t?void 0:t.contains(r))||t===r});doc().activeElement!==r&&o&&(e.preventDefault(),r.focus())})}},67673:function(e,t,n){"use strict";n.d(t,{G:function(){return i}});var r=n(2265),i=(null==globalThis?void 0:globalThis.document)?r.useLayoutEffect:r.useEffect},89656:function(e,t,n){"use strict";n.d(t,{r:function(){return useUpdateEffect}});var r=n(2265);function useUpdateEffect(e,t){let n=(0,r.useRef)(!1),i=(0,r.useRef)(!1);(0,r.useEffect)(()=>{let t=n.current,r=t&&i.current;if(r)return e();i.current=!0},t),(0,r.useEffect)(()=>(n.current=!0,()=>{n.current=!1}),[])}},13610:function(e,t,n){"use strict";n.r(t),n.d(t,{ChakraBaseProvider:function(){return f},ChakraProvider:function(){return d}});var r=n(96671),i=n(69782),o=n(33962),a=n(1051),s=n(52733),l=n(57437),ChakraProvider=e=>{let{children:t,colorModeManager:n,portalZIndex:u,resetScope:c,resetCSS:d=!0,theme:f={},environment:p,cssVarsRoot:h,disableEnvironment:m,disableGlobalStyle:v}=e,g=(0,l.jsx)(s.u,{environment:p,disabled:m,children:t});return(0,l.jsx)(o.ThemeProvider,{theme:f,cssVarsRoot:h,children:(0,l.jsxs)(a.SG,{colorModeManager:n,options:f.config,children:[d?(0,l.jsx)(r.mA,{scope:c}):(0,l.jsx)(r.f,{}),!v&&(0,l.jsx)(o.GlobalStyle,{}),u?(0,l.jsx)(i.h,{zIndex:u,children:g}):g]})})},u=n(62952),c=n(37493),createChakraProvider=e=>function({children:t,theme:n=e,toastOptions:r,...i}){return(0,l.jsxs)(ChakraProvider,{theme:n,...i,children:[(0,l.jsx)(c.Qi,{value:null==r?void 0:r.defaultOptions,children:t}),(0,l.jsx)(c.VW,{...r})]})},d=createChakraProvider(u.rS),f=createChakraProvider(u.wE)},74400:function(e,t,n){"use strict";n.r(t),n.d(t,{Select:function(){return f},SelectField:function(){return s}});var r=n(16465),i=n(58250),o=n(23145),a=n(57437),s=(0,i.forwardRef)(function(e,t){let{children:n,placeholder:i,className:s,...l}=e;return(0,a.jsxs)(o.chakra.select,{...l,ref:t,className:(0,r.cx)("chakra-select",s),children:[i&&(0,a.jsx)("option",{value:"",children:i}),n]})});s.displayName="SelectField";var l=n(75992),u=n(92013),c=n(50446),d=n(2265),f=(0,i.forwardRef)((e,t)=>{var n;let i=(0,u.useMultiStyleConfig)("Select",e),{rootProps:d,placeholder:f,icon:p,color:h,height:m,h:v,minH:g,minHeight:y,iconColor:b,iconSize:x,...w}=(0,c.Lr)(e),[k,S]=function(e,t){let n={},r={};for(let[i,o]of Object.entries(e))t.includes(i)?n[i]=o:r[i]=o;return[n,r]}(w,c.oE),C=(0,l.Y)(S),E={paddingEnd:"2rem",...i.field,_focus:{zIndex:"unset",...null==(n=i.field)?void 0:n._focus}};return(0,a.jsxs)(o.chakra.div,{className:"chakra-select__wrapper",__css:{width:"100%",height:"fit-content",position:"relative",color:h},...k,...d,children:[(0,a.jsx)(s,{ref:t,height:null!=v?v:m,minH:null!=g?g:y,placeholder:f,...C,__css:E,children:e.children}),(0,a.jsx)(SelectIcon,{"data-disabled":(0,r.PB)(C.disabled),...(b||h)&&{color:b||h},__css:i.icon,...x&&{fontSize:x},children:p})]})});f.displayName="Select";var DefaultIcon=e=>(0,a.jsx)("svg",{viewBox:"0 0 24 24",...e,children:(0,a.jsx)("path",{fill:"currentColor",d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})}),p=(0,o.chakra)("div",{baseStyle:{position:"absolute",display:"inline-flex",alignItems:"center",justifyContent:"center",pointerEvents:"none",top:"50%",transform:"translateY(-50%)"}}),SelectIcon=e=>{let{children:t=(0,a.jsx)(DefaultIcon,{}),...n}=e,r=(0,d.cloneElement)(t,{role:"presentation",className:"chakra-select__icon",focusable:!1,"aria-hidden":!0,style:{width:"1em",height:"1em",color:"currentColor"}});return(0,a.jsx)(p,{...n,className:"chakra-select__icon-wrapper",children:(0,d.isValidElement)(t)?r:null})};SelectIcon.displayName="SelectIcon"},74794:function(e,t,n){"use strict";n.r(t),n.d(t,{Skeleton:function(){return g},SkeletonCircle:function(){return SkeletonCircle},SkeletonText:function(){return SkeletonText}});var r=n(2265),i=n(16465),o=n(23145),a=n(50446),s=n(99538),l=n(58250),u=n(92013),c=n(12704),d=n(57437),f=(0,o.chakra)("div",{baseStyle:{boxShadow:"none",backgroundClip:"padding-box",cursor:"default",color:"transparent",pointerEvents:"none",userSelect:"none","&::before, &::after, *":{visibility:"hidden"}}}),p=(0,a.gJ)("skeleton-start-color"),h=(0,a.gJ)("skeleton-end-color"),m=(0,s.F4)({from:{opacity:0},to:{opacity:1}}),v=(0,s.F4)({from:{borderColor:p.reference,background:p.reference},to:{borderColor:h.reference,background:h.reference}}),g=(0,l.forwardRef)((e,t)=>{let n={...e,fadeDuration:"number"==typeof e.fadeDuration?e.fadeDuration:.4,speed:"number"==typeof e.speed?e.speed:.8},s=(0,u.useStyleConfig)("Skeleton",n),l=function(){let e=(0,r.useRef)(!0);return(0,r.useEffect)(()=>{e.current=!1},[]),e.current}(),{startColor:g="",endColor:y="",isLoaded:b,fadeDuration:x,speed:w,className:k,fitContent:S,...C}=(0,a.Lr)(n),[E,P]=(0,c.useToken)("colors",[g,y]),T=function(e){let t=(0,r.useRef)();return(0,r.useEffect)(()=>{t.current=e},[e]),t.current}(b),A=(0,i.cx)("chakra-skeleton",k),M={...E&&{[p.variable]:E},...P&&{[h.variable]:P}};if(b){let e=l||T?"none":`${m} ${x}s`;return(0,d.jsx)(o.chakra.div,{ref:t,className:A,__css:{animation:e},...C})}return(0,d.jsx)(f,{ref:t,className:A,...C,__css:{width:S?"fit-content":void 0,...s,...M,_dark:{...s._dark,...M},animation:`${w}s linear infinite alternate ${v}`}})});g.displayName="Skeleton";var SkeletonCircle=({size:e="2rem",...t})=>(0,d.jsx)(g,{borderRadius:"full",boxSize:e,...t});SkeletonCircle.displayName="SkeletonCircle";var y=n(63087),SkeletonText=e=>{let{noOfLines:t=3,spacing:n="0.5rem",skeletonHeight:r="0.5rem",className:a,startColor:s,endColor:l,isLoaded:u,fadeDuration:c,speed:f,variant:p,size:h,colorScheme:m,children:v,...b}=e,x=(0,y.S)("number"==typeof t?[t]:t)||3,w=Array(x).fill(1).map((e,t)=>t+1),getWidth=e=>x>1&&e===w.length?"80%":"100%",k=(0,i.cx)("chakra-skeleton__group",a);return(0,d.jsx)(o.chakra.div,{className:k,...b,children:w.map((e,t)=>{if(u&&t>0)return null;let i=u?null:{mb:e===w.length?"0":n,width:getWidth(e),height:r};return(0,d.jsx)(g,{startColor:s,endColor:l,isLoaded:u,fadeDuration:c,speed:f,variant:p,size:h,colorScheme:m,...i,children:0===t?v:void 0},w.length.toString()+e)})})};SkeletonText.displayName="SkeletonText"},1959:function(e,t,n){"use strict";n.r(t),n.d(t,{SkipNavContent:function(){return c},SkipNavLink:function(){return u}});var r=n(58250),i=n(92013),o=n(50446),a=n(23145),s=n(57437),l="chakra-skip-nav",u=(0,r.forwardRef)(function(e,t){let n=(0,i.useStyleConfig)("SkipLink",e),{id:r=l,...u}=(0,o.Lr)(e);return(0,s.jsx)(a.chakra.a,{...u,ref:t,href:`#${r}`,__css:{userSelect:"none",border:"0",height:"1px",width:"1px",margin:"-1px",padding:"0",outline:"0",overflow:"hidden",position:"absolute",clip:"rect(0 0 0 0)",...n,_focus:{clip:"auto",width:"auto",height:"auto",...n._focus}}})});u.displayName="SkipNavLink";var c=(0,r.forwardRef)(function(e,t){let{id:n=l,...r}=e;return(0,s.jsx)(a.chakra.div,{ref:t,id:n,tabIndex:-1,style:{outline:0},...r})});c.displayName="SkipNavContent"},14114:function(e,t,n){"use strict";n.r(t),n.d(t,{RangeSlider:function(){return E},RangeSliderFilledTrack:function(){return A},RangeSliderMark:function(){return M},RangeSliderProvider:function(){return w},RangeSliderThumb:function(){return P},RangeSliderTrack:function(){return T},Slider:function(){return I},SliderFilledTrack:function(){return O},SliderMark:function(){return F},SliderProvider:function(){return _},SliderThumb:function(){return j},SliderTrack:function(){return L},useRangeSlider:function(){return useRangeSlider},useRangeSliderContext:function(){return k},useRangeSliderStyles:function(){return C},useSlider:function(){return useSlider},useSliderContext:function(){return N},useSliderStyles:function(){return D}});var dataAttr=e=>e?"":void 0,ariaAttr=e=>!!e||void 0,cx=(...e)=>e.filter(Boolean).join(" ");function callAllHandlers(...e){return function(t){e.some(e=>(null==e||e(t),null==t?void 0:t.defaultPrevented))}}function orient(e){let{orientation:t,vertical:n,horizontal:r}=e;return"vertical"===t?n:r}var r={width:0,height:0},normalize=e=>e||r;function getStyles(e){let{orientation:t,thumbPercents:n,thumbRects:i,isReversed:o}=e,a="vertical"===t?i.reduce((e,t)=>normalize(e).height>normalize(t).height?e:t,r):i.reduce((e,t)=>normalize(e).width>normalize(t).width?e:t,r),s={position:"relative",touchAction:"none",WebkitTapHighlightColor:"rgba(0,0,0,0)",userSelect:"none",outline:0,...orient({orientation:t,vertical:a?{paddingLeft:a.width/2,paddingRight:a.width/2}:{},horizontal:a?{paddingTop:a.height/2,paddingBottom:a.height/2}:{}})},l={position:"absolute",...orient({orientation:t,vertical:{left:"50%",transform:"translateX(-50%)",height:"100%"},horizontal:{top:"50%",transform:"translateY(-50%)",width:"100%"}})},u=1===n.length,c=[0,o?100-n[0]:n[0]],d=u?c:n,f=d[0];!u&&o&&(f=100-f);let p=Math.abs(d[d.length-1]-d[0]),h={...l,...orient({orientation:t,vertical:o?{height:`${p}%`,top:`${f}%`}:{height:`${p}%`,bottom:`${f}%`},horizontal:o?{width:`${p}%`,right:`${f}%`}:{width:`${p}%`,left:`${f}%`}})};return{trackStyle:l,innerTrackStyle:h,rootStyle:s,getThumbStyle:e=>{var o;let a=null!=(o=i[e])?o:r;return{position:"absolute",userSelect:"none",WebkitUserSelect:"none",MozUserSelect:"none",msUserSelect:"none",touchAction:"none",...orient({orientation:t,vertical:{bottom:`calc(${n[e]}% - ${a.height/2}px)`},horizontal:{left:`calc(${n[e]}% - ${a.width/2}px)`}})}}}}function getIsReversed(e){let{isReversed:t,direction:n,orientation:r}=e;return"ltr"===n||"vertical"===r?t:!t}function isTouchEvent(e){let t=!!e.touches;return t}function getEventPoint(e,t="page"){return isTouchEvent(e)?function(e,t="page"){let n=e.touches[0]||e.changedTouches[0];return{x:n[`${t}X`],y:n[`${t}Y`]}}(e,t):function(e,t="page"){return{x:e[`${t}X`],y:e[`${t}Y`]}}(e,t)}function addPointerEvent(e,t,n,r){var i;return i=function(e,t=!1){function listener(t){e(t,{point:getEventPoint(t)})}let n=t?e=>{let t=function(e){var t;let n=null!=(t=e.view)?t:window;return void 0!==n.PointerEvent&&e instanceof n.PointerEvent?!("mouse"!==e.pointerType):e instanceof n.MouseEvent}(e);(!t||t&&0===e.button)&&listener(e)}:listener;return n}(n,"pointerdown"===t),e.addEventListener(t,i,r),()=>{e.removeEventListener(t,i,r)}}var i=n(98361),o=Object.defineProperty,__defNormalProp=(e,t,n)=>t in e?o(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__publicField=(e,t,n)=>(__defNormalProp(e,"symbol"!=typeof t?t+"":t,n),n),a=class{constructor(e,t,n){var r;if(__publicField(this,"history",[]),__publicField(this,"startEvent",null),__publicField(this,"lastEvent",null),__publicField(this,"lastEventInfo",null),__publicField(this,"handlers",{}),__publicField(this,"removeListeners",()=>{}),__publicField(this,"threshold",3),__publicField(this,"win"),__publicField(this,"updatePoint",()=>{if(!(this.lastEvent&&this.lastEventInfo))return;let e=getPanInfo(this.lastEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){if("number"==typeof e&&"number"==typeof t)return distance1D(e,t);if(isPoint(e)&&isPoint(t)){let n=distance1D(e.x,t.x),r=distance1D(e.y,t.y);return Math.sqrt(n**2+r**2)}return 0}(e.offset,{x:0,y:0})>=this.threshold;if(!t&&!n)return;let{timestamp:r}=(0,i.$B)();this.history.push({...e.point,timestamp:r});let{onStart:o,onMove:a}=this.handlers;t||(null==o||o(this.lastEvent,e),this.startEvent=this.lastEvent),null==a||a(this.lastEvent,e)}),__publicField(this,"onPointerMove",(e,t)=>{this.lastEvent=e,this.lastEventInfo=t,i.ZP.update(this.updatePoint,!0)}),__publicField(this,"onPointerUp",(e,t)=>{let n=getPanInfo(t,this.history),{onEnd:r,onSessionEnd:i}=this.handlers;null==i||i(e,n),this.end(),r&&this.startEvent&&(null==r||r(e,n))}),this.win=null!=(r=e.view)?r:window,isTouchEvent(e)&&e.touches.length>1)return;this.handlers=t,n&&(this.threshold=n),e.stopPropagation(),e.preventDefault();let o={point:getEventPoint(e)},{timestamp:a}=(0,i.$B)();this.history=[{...o.point,timestamp:a}];let{onSessionStart:s}=t;null==s||s(e,getPanInfo(o,this.history)),this.removeListeners=function(...e){return t=>e.reduce((e,t)=>t(e),t)}(addPointerEvent(this.win,"pointermove",this.onPointerMove),addPointerEvent(this.win,"pointerup",this.onPointerUp),addPointerEvent(this.win,"pointercancel",this.onPointerUp))}updateHandlers(e){this.handlers=e}end(){var e;null==(e=this.removeListeners)||e.call(this),i.qY.update(this.updatePoint)}};function subtract(e,t){return{x:e.x-t.x,y:e.y-t.y}}function getPanInfo(e,t){return{point:e.point,delta:subtract(e.point,t[t.length-1]),offset:subtract(e.point,t[0]),velocity:function(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=e[e.length-1];for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>toMilliseconds(.1)));)n--;if(!r)return{x:0,y:0};let o=(i.timestamp-r.timestamp)/1e3;if(0===o)return{x:0,y:0};let a={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}(t,0)}}var toMilliseconds=e=>1e3*e;function distance1D(e,t){return Math.abs(e-t)}function isPoint(e){return"x"in e&&"y"in e}var s=n(2265);function useLatestRef(e){let t=(0,s.useRef)(null);return t.current=e,t}function usePanEvent(e,t){let{onPan:n,onPanStart:r,onPanEnd:i,onPanSessionStart:o,onPanSessionEnd:l,threshold:u}=t,c=!!(n||r||i||o||l),d=(0,s.useRef)(null),f=useLatestRef({onSessionStart:o,onSessionEnd:l,onStart:r,onMove:n,onEnd(e,t){d.current=null,null==i||i(e,t)}});(0,s.useEffect)(()=>{var e;null==(e=d.current)||e.updateHandlers(f.current)}),(0,s.useEffect)(()=>{let t=e.current;if(t&&c)return addPointerEvent(t,"pointerdown",function(e){d.current=new a(e,f.current,u)})},[e,c,f,u]),(0,s.useEffect)(()=>()=>{var e;null==(e=d.current)||e.end(),d.current=null},[])}var l=n(27771),u=n(37977),c=n(89656),d=n(45663),f=n(18234),p=(null==globalThis?void 0:globalThis.document)?s.useLayoutEffect:s.useEffect;function useSizes({getNodes:e,observeMutation:t=!0}){let[n,r]=(0,s.useState)([]),[i,o]=(0,s.useState)(0);return p(()=>{let n=e(),i=n.map((e,t)=>(function(e,t){if(!e){t(void 0);return}t({width:e.offsetWidth,height:e.offsetHeight});let n=e.ownerDocument.defaultView??window,r=new n.ResizeObserver(n=>{let r,i;if(!Array.isArray(n)||!n.length)return;let[o]=n;if("borderBoxSize"in o){let e=o.borderBoxSize,t=Array.isArray(e)?e[0]:e;r=t.inlineSize,i=t.blockSize}else r=e.offsetWidth,i=e.offsetHeight;t({width:r,height:i})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)})(e,e=>{r(n=>[...n.slice(0,t),e,...n.slice(t+1)])}));if(t){let e=n[0];i.push(function(e,t){var n,r;if(!e||!e.parentElement)return;let i=null!=(r=null==(n=e.ownerDocument)?void 0:n.defaultView)?r:window,o=new i.MutationObserver(()=>{t()});return o.observe(e.parentElement,{childList:!0}),()=>{o.disconnect()}}(e,()=>{o(e=>e+1)}))}return()=>{i.forEach(e=>{null==e||e()})}},[i]),n}function useRangeSlider(e){var t,n;let{min:r=0,max:i=100,onChange:o,value:a,defaultValue:p,isReversed:h,direction:m="ltr",orientation:v="horizontal",id:g,isDisabled:y,isReadOnly:b,onChangeStart:x,onChangeEnd:w,step:k=1,getAriaValueText:S,"aria-valuetext":C,"aria-label":E,"aria-labelledby":P,name:T,focusThumbOnChange:A=!0,minStepsBetweenThumbs:M=0,..._}=e,N=(0,u.W)(x),R=(0,u.W)(w),D=(0,u.W)(S),I=getIsReversed({isReversed:h,direction:m,orientation:v}),[j,L]=(0,l.T)({value:a,defaultValue:null!=p?p:[25,75],onChange:o});if(!Array.isArray(j))throw TypeError(`[range-slider] You passed an invalid value for \`value\` or \`defaultValue\`, expected \`Array\` but got \`${typeof j}\``);let[O,F]=(0,s.useState)(!1),[V,B]=(0,s.useState)(!1),[W,$]=(0,s.useState)(-1),U=!(y||b),H=(0,s.useRef)(j),z=j.map(e=>(0,f.HU)(e,r,i)),G=(n=M*k,z.map((e,t)=>{let o=0===t?r:z[t-1]+n,a=t===z.length-1?i:z[t+1]-n;return{min:o,max:a}})),q=(0,s.useRef)({eventSource:null,value:[],valueBounds:[]});q.current.value=z,q.current.valueBounds=G;let K=z.map(e=>i-e+r),X=I?K:z,Z=X.map(e=>(0,f.Rg)(e,r,i)),Y="vertical"===v,Q=(0,s.useRef)(null),J=(0,s.useRef)(null),ee=useSizes({getNodes(){let e=J.current,t=null==e?void 0:e.querySelectorAll("[role=slider]");return t?Array.from(t):[]}}),et=(0,s.useId)(),en=(t=null!=g?g:et,{root:`slider-root-${t}`,getThumb:e=>`slider-thumb-${t}-${e}`,getInput:e=>`slider-input-${t}-${e}`,track:`slider-track-${t}`,innerTrack:`slider-filled-track-${t}`,getMarker:e=>`slider-marker-${t}-${e}`,output:`slider-output-${t}`}),er=(0,s.useCallback)(e=>{var t,n;if(!Q.current)return;q.current.eventSource="pointer";let o=Q.current.getBoundingClientRect(),{clientX:a,clientY:s}=null!=(n=null==(t=e.touches)?void 0:t[0])?n:e,l=Y?o.bottom-s:a-o.left,u=Y?o.height:o.width,c=l/u;return I&&(c=1-c),(0,f.WS)(c,r,i)},[Y,I,i,r]),ei=(i-r)/10,eo=k||(i-r)/100,ea=(0,s.useMemo)(()=>({setValueAtIndex(e,t){if(!U)return;let n=q.current.valueBounds[e];t=parseFloat((0,f.WP)(t,n.min,eo)),t=(0,f.HU)(t,n.min,n.max);let r=[...q.current.value];r[e]=t,L(r)},setActiveIndex:$,stepUp(e,t=eo){let n=q.current.value[e],r=I?n-t:n+t;ea.setValueAtIndex(e,r)},stepDown(e,t=eo){let n=q.current.value[e],r=I?n+t:n-t;ea.setValueAtIndex(e,r)},reset(){L(H.current)}}),[eo,I,L,U]),es=(0,s.useCallback)(e=>{let t=e.key,n={ArrowRight:()=>ea.stepUp(W),ArrowUp:()=>ea.stepUp(W),ArrowLeft:()=>ea.stepDown(W),ArrowDown:()=>ea.stepDown(W),PageUp:()=>ea.stepUp(W,ei),PageDown:()=>ea.stepDown(W,ei),Home:()=>{let{min:e}=G[W];ea.setValueAtIndex(W,e)},End:()=>{let{max:e}=G[W];ea.setValueAtIndex(W,e)}}[t];n&&(e.preventDefault(),e.stopPropagation(),n(e),q.current.eventSource="keyboard")},[ea,W,ei,G]),{getThumbStyle:el,rootStyle:eu,trackStyle:ec,innerTrackStyle:ed}=(0,s.useMemo)(()=>getStyles({isReversed:I,orientation:v,thumbRects:ee,thumbPercents:Z}),[I,v,Z,ee]),ef=(0,s.useCallback)(e=>{var t;let n=null!=e?e:W;if(-1!==n&&A){let e=en.getThumb(n),r=null==(t=J.current)?void 0:t.ownerDocument.getElementById(e);r&&setTimeout(()=>r.focus())}},[A,W,en]);(0,c.r)(()=>{"keyboard"===q.current.eventSource&&(null==R||R(q.current.value))},[z,R]);let onPanSessionStart=e=>{let t=er(e)||0,n=q.current.value.map(e=>Math.abs(e-t)),r=Math.min(...n),i=n.indexOf(r),o=n.filter(e=>e===r),a=o.length>1;a&&t>q.current.value[i]&&(i=i+o.length-1),$(i),ea.setValueAtIndex(i,t),ef(i)},onPan=e=>{if(-1==W)return;let t=er(e)||0;$(W),ea.setValueAtIndex(W,t),ef(W)};usePanEvent(J,{onPanSessionStart(e){U&&(F(!0),onPanSessionStart(e),null==N||N(q.current.value))},onPanSessionEnd(){U&&(F(!1),null==R||R(q.current.value))},onPan(e){U&&onPan(e)}});let ep=(0,s.useCallback)((e={},t=null)=>({...e,..._,id:en.root,ref:(0,d.lq)(t,J),tabIndex:-1,"aria-disabled":ariaAttr(y),"data-focused":dataAttr(V),style:{...e.style,...eu}}),[_,y,V,eu,en]),eh=(0,s.useCallback)((e={},t=null)=>({...e,ref:(0,d.lq)(t,Q),id:en.track,"data-disabled":dataAttr(y),style:{...e.style,...ec}}),[y,ec,en]),em=(0,s.useCallback)((e={},t=null)=>({...e,ref:t,id:en.innerTrack,style:{...e.style,...ed}}),[ed,en]),ev=(0,s.useCallback)((e,t=null)=>{var n;let{index:r,...i}=e,o=z[r];if(null==o)throw TypeError(`[range-slider > thumb] Cannot find value at index \`${r}\`. The \`value\` or \`defaultValue\` length is : ${z.length}`);let a=G[r];return{...i,ref:t,role:"slider",tabIndex:U?0:void 0,id:en.getThumb(r),"data-active":dataAttr(O&&W===r),"aria-valuetext":null!=(n=null==D?void 0:D(o))?n:null==C?void 0:C[r],"aria-valuemin":a.min,"aria-valuemax":a.max,"aria-valuenow":o,"aria-orientation":v,"aria-disabled":ariaAttr(y),"aria-readonly":ariaAttr(b),"aria-label":null==E?void 0:E[r],"aria-labelledby":(null==E?void 0:E[r])?void 0:null==P?void 0:P[r],style:{...e.style,...el(r)},onKeyDown:callAllHandlers(e.onKeyDown,es),onFocus:callAllHandlers(e.onFocus,()=>{B(!0),$(r)}),onBlur:callAllHandlers(e.onBlur,()=>{B(!1),$(-1)})}},[en,z,G,U,O,W,D,C,v,y,b,E,P,el,es,B]),eg=(0,s.useCallback)((e={},t=null)=>({...e,ref:t,id:en.output,htmlFor:z.map((e,t)=>en.getThumb(t)).join(" "),"aria-live":"off"}),[en,z]),ey=(0,s.useCallback)((e,t=null)=>{let{value:n,...o}=e,a=!(ni),s=n>=z[0]&&n<=z[z.length-1],l=(0,f.Rg)(n,r,i);l=I?100-l:l;let u={position:"absolute",pointerEvents:"none",...orient({orientation:v,vertical:{bottom:`${l}%`},horizontal:{left:`${l}%`}})};return{...o,ref:t,id:en.getMarker(e.value),role:"presentation","aria-hidden":!0,"data-disabled":dataAttr(y),"data-invalid":dataAttr(!a),"data-highlighted":dataAttr(s),style:{...e.style,...u}}},[y,I,i,r,v,z,en]),eb=(0,s.useCallback)((e,t=null)=>{let{index:n,...r}=e;return{...r,ref:t,id:en.getInput(n),type:"hidden",value:z[n],name:Array.isArray(T)?T[n]:`${T}-${n}`}},[T,z,en]);return{state:{value:z,isFocused:V,isDragging:O,getThumbPercent:e=>Z[e],getThumbMinValue:e=>G[e].min,getThumbMaxValue:e=>G[e].max},actions:ea,getRootProps:ep,getTrackProps:eh,getInnerTrackProps:em,getThumbProps:ev,getMarkerProps:ey,getInputProps:eb,getOutputProps:eg}}var h=n(310),m=n(58250),v=n(92013),g=n(50446),y=n(90865),b=n(23145),x=n(57437),[w,k]=(0,h.k)({name:"SliderContext",errorMessage:"useSliderContext: `context` is undefined. Seems you forgot to wrap all slider components within "}),[S,C]=(0,h.k)({name:"RangeSliderStylesContext",errorMessage:"useRangeSliderStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),E=(0,m.forwardRef)(function(e,t){let n={orientation:"horizontal",...e},r=(0,v.useMultiStyleConfig)("Slider",n),i=(0,g.Lr)(n),{direction:o}=(0,y.useTheme)();i.direction=o;let{getRootProps:a,...l}=useRangeSlider(i),u=(0,s.useMemo)(()=>({...l,name:n.name}),[l,n.name]);return(0,x.jsx)(w,{value:u,children:(0,x.jsx)(S,{value:r,children:(0,x.jsx)(b.chakra.div,{...a({},t),className:"chakra-slider",__css:r.container,children:n.children})})})});E.displayName="RangeSlider";var P=(0,m.forwardRef)(function(e,t){let{getThumbProps:n,getInputProps:r,name:i}=k(),o=C(),a=n(e,t);return(0,x.jsxs)(b.chakra.div,{...a,className:cx("chakra-slider__thumb",e.className),__css:o.thumb,children:[a.children,i&&(0,x.jsx)("input",{...r({index:e.index})})]})});P.displayName="RangeSliderThumb";var T=(0,m.forwardRef)(function(e,t){let{getTrackProps:n}=k(),r=C(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:cx("chakra-slider__track",e.className),__css:r.track,"data-testid":"chakra-range-slider-track"})});T.displayName="RangeSliderTrack";var A=(0,m.forwardRef)(function(e,t){let{getInnerTrackProps:n}=k(),r=C(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:"chakra-slider__filled-track",__css:r.filledTrack})});A.displayName="RangeSliderFilledTrack";var M=(0,m.forwardRef)(function(e,t){let{getMarkerProps:n}=k(),r=C(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:cx("chakra-slider__marker",e.className),__css:r.mark})});function useSlider(e){var t;let{min:n=0,max:r=100,onChange:i,value:o,defaultValue:a,isReversed:p,direction:h="ltr",orientation:m="horizontal",id:v,isDisabled:g,isReadOnly:y,onChangeStart:b,onChangeEnd:x,step:w=1,getAriaValueText:k,"aria-valuetext":S,"aria-label":C,"aria-labelledby":E,name:P,focusThumbOnChange:T=!0,...A}=e,M=(0,u.W)(b),_=(0,u.W)(x),N=(0,u.W)(k),R=getIsReversed({isReversed:p,direction:h,orientation:m}),[D,I]=(0,l.T)({value:o,defaultValue:null!=a?a:r{var t,n;if(!K.current)return;let r=q.current;r.eventSource="pointer";let i=K.current.getBoundingClientRect(),{clientX:o,clientY:a}=null!=(n=null==(t=e.touches)?void 0:t[0])?n:e,s=G?i.bottom-a:o-i.left,l=G?i.height:i.width,u=s/l;R&&(u=1-u);let c=(0,f.WS)(u,r.min,r.max);return r.step&&(c=parseFloat((0,f.WP)(c,r.min,r.step))),c=(0,f.HU)(c,r.min,r.max)},[G,R,q]),en=(0,s.useCallback)(e=>{let t=q.current;t.isInteractive&&(e=parseFloat((0,f.WP)(e,t.min,W)),I(e=(0,f.HU)(e,t.min,t.max)))},[W,I,q]),er=(0,s.useMemo)(()=>({stepUp(e=W){let t=R?$-e:$+e;en(t)},stepDown(e=W){let t=R?$+e:$-e;en(t)},reset(){en(a||0)},stepTo(e){en(e)}}),[en,R,$,W,a]),ei=(0,s.useCallback)(e=>{let t=q.current,n={ArrowRight:()=>er.stepUp(),ArrowUp:()=>er.stepUp(),ArrowLeft:()=>er.stepDown(),ArrowDown:()=>er.stepDown(),PageUp:()=>er.stepUp(B),PageDown:()=>er.stepDown(B),Home:()=>en(t.min),End:()=>en(t.max)}[e.key];n&&(e.preventDefault(),e.stopPropagation(),n(e),t.eventSource="keyboard")},[er,en,B,q]),eo=null!=(t=null==N?void 0:N($))?t:S,ea=function(e){let[t]=useSizes({observeMutation:!1,getNodes(){let t="object"==typeof e&&null!==e&&"current"in e?e.current:e;return[t]}});return t}(X),{getThumbStyle:es,rootStyle:el,trackStyle:eu,innerTrackStyle:ec}=(0,s.useMemo)(()=>{let e=q.current,t=null!=ea?ea:{width:0,height:0};return getStyles({isReversed:R,orientation:e.orientation,thumbRects:[t],thumbPercents:[z]})},[R,ea,z,q]),ed=(0,s.useCallback)(()=>{let e=q.current;e.focusThumbOnChange&&setTimeout(()=>{var e;return null==(e=X.current)?void 0:e.focus()})},[q]);function setValueFromPointer(e){let t=et(e);null!=t&&t!==q.current.value&&I(t)}(0,c.r)(()=>{let e=q.current;ed(),"keyboard"===e.eventSource&&(null==_||_(e.value))},[$,_]),usePanEvent(Z,{onPanSessionStart(e){let t=q.current;t.isInteractive&&(L(!0),ed(),setValueFromPointer(e),null==M||M(t.value))},onPanSessionEnd(){let e=q.current;e.isInteractive&&(L(!1),null==_||_(e.value))},onPan(e){let t=q.current;t.isInteractive&&setValueFromPointer(e)}});let ef=(0,s.useCallback)((e={},t=null)=>({...e,...A,ref:(0,d.lq)(t,Z),tabIndex:-1,"aria-disabled":ariaAttr(g),"data-focused":dataAttr(O),style:{...e.style,...el}}),[A,g,O,el]),ep=(0,s.useCallback)((e={},t=null)=>({...e,ref:(0,d.lq)(t,K),id:ee,"data-disabled":dataAttr(g),style:{...e.style,...eu}}),[g,ee,eu]),eh=(0,s.useCallback)((e={},t=null)=>({...e,ref:t,style:{...e.style,...ec}}),[ec]),em=(0,s.useCallback)((e={},t=null)=>({...e,ref:(0,d.lq)(t,X),role:"slider",tabIndex:V?0:void 0,id:J,"data-active":dataAttr(j),"aria-valuetext":eo,"aria-valuemin":n,"aria-valuemax":r,"aria-valuenow":$,"aria-orientation":m,"aria-disabled":ariaAttr(g),"aria-readonly":ariaAttr(y),"aria-label":C,"aria-labelledby":C?void 0:E,style:{...e.style,...es(0)},onKeyDown:callAllHandlers(e.onKeyDown,ei),onFocus:callAllHandlers(e.onFocus,()=>F(!0)),onBlur:callAllHandlers(e.onBlur,()=>F(!1))}),[V,J,j,eo,n,r,$,m,g,y,C,E,es,ei]),ev=(0,s.useCallback)((e,t=null)=>{let i=!(e.valuer),o=$>=e.value,a=(0,f.Rg)(e.value,n,r),s={position:"absolute",pointerEvents:"none",...function(e){let{orientation:t,vertical:n,horizontal:r}=e;return"vertical"===t?n:r}({orientation:m,vertical:{bottom:R?`${100-a}%`:`${a}%`},horizontal:{left:R?`${100-a}%`:`${a}%`}})};return{...e,ref:t,role:"presentation","aria-hidden":!0,"data-disabled":dataAttr(g),"data-invalid":dataAttr(!i),"data-highlighted":dataAttr(o),style:{...e.style,...s}}},[g,R,r,n,m,$]),eg=(0,s.useCallback)((e={},t=null)=>({...e,ref:t,type:"hidden",value:$,name:P}),[P,$]);return{state:{value:$,isFocused:O,isDragging:j},actions:er,getRootProps:ef,getTrackProps:ep,getInnerTrackProps:eh,getThumbProps:em,getMarkerProps:ev,getInputProps:eg}}M.displayName="RangeSliderMark";var[_,N]=(0,h.k)({name:"SliderContext",hookName:"useSliderContext",providerName:""}),[R,D]=(0,h.k)({name:"SliderStylesContext",hookName:"useSliderStyles",providerName:""}),I=(0,m.forwardRef)((e,t)=>{var n;let r={...e,orientation:null!=(n=null==e?void 0:e.orientation)?n:"horizontal"},i=(0,v.useMultiStyleConfig)("Slider",r),o=(0,g.Lr)(r),{direction:a}=(0,y.useTheme)();o.direction=a;let{getInputProps:s,getRootProps:l,...u}=useSlider(o),c=l(),d=s({},t);return(0,x.jsx)(_,{value:u,children:(0,x.jsx)(R,{value:i,children:(0,x.jsxs)(b.chakra.div,{...c,className:cx("chakra-slider",r.className),__css:i.container,children:[r.children,(0,x.jsx)("input",{...d})]})})})});I.displayName="Slider";var j=(0,m.forwardRef)((e,t)=>{let{getThumbProps:n}=N(),r=D(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:cx("chakra-slider__thumb",e.className),__css:r.thumb})});j.displayName="SliderThumb";var L=(0,m.forwardRef)((e,t)=>{let{getTrackProps:n}=N(),r=D(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:cx("chakra-slider__track",e.className),__css:r.track})});L.displayName="SliderTrack";var O=(0,m.forwardRef)((e,t)=>{let{getInnerTrackProps:n}=N(),r=D(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:cx("chakra-slider__filled-track",e.className),__css:r.filledTrack})});O.displayName="SliderFilledTrack";var F=(0,m.forwardRef)((e,t)=>{let{getMarkerProps:n}=N(),r=D(),i=n(e,t);return(0,x.jsx)(b.chakra.div,{...i,className:cx("chakra-slider__marker",e.className),__css:r.mark})});F.displayName="SliderMark"},3223:function(e,t,n){"use strict";n.r(t),n.d(t,{Spinner:function(){return r.$}});var r=n(83109)},12065:function(e,t,n){"use strict";n.r(t),n.d(t,{Stat:function(){return f},StatArrow:function(){return StatArrow},StatDownArrow:function(){return StatDownArrow},StatGroup:function(){return h},StatHelpText:function(){return m},StatLabel:function(){return v},StatNumber:function(){return g},StatUpArrow:function(){return StatUpArrow},useStatStyles:function(){return d}});var r=n(310),i=n(58250),o=n(92013),a=n(50446),s=n(23145),l=n(16465),u=n(57437),[c,d]=(0,r.k)({name:"StatStylesContext",errorMessage:"useStatStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),f=(0,i.forwardRef)(function(e,t){let n=(0,o.useMultiStyleConfig)("Stat",e),r={position:"relative",flex:"1 1 0%",...n.container},{className:i,children:d,...f}=(0,a.Lr)(e);return(0,u.jsx)(c,{value:n,children:(0,u.jsx)(s.chakra.div,{ref:t,...f,className:(0,l.cx)("chakra-stat",i),__css:r,children:(0,u.jsx)("dl",{children:d})})})});f.displayName="Stat";var p=n(16248),StatDownArrow=e=>(0,u.jsx)(p.J,{color:"red.400",...e,children:(0,u.jsx)("path",{fill:"currentColor",d:"M21,5H3C2.621,5,2.275,5.214,2.105,5.553C1.937,5.892,1.973,6.297,2.2,6.6l9,12 c0.188,0.252,0.485,0.4,0.8,0.4s0.611-0.148,0.8-0.4l9-12c0.228-0.303,0.264-0.708,0.095-1.047C21.725,5.214,21.379,5,21,5z"})});function StatUpArrow(e){return(0,u.jsx)(p.J,{color:"green.400",...e,children:(0,u.jsx)("path",{fill:"currentColor",d:"M12.8,5.4c-0.377-0.504-1.223-0.504-1.6,0l-9,12c-0.228,0.303-0.264,0.708-0.095,1.047 C2.275,18.786,2.621,19,3,19h18c0.379,0,0.725-0.214,0.895-0.553c0.169-0.339,0.133-0.744-0.095-1.047L12.8,5.4z"})})}function StatArrow(e){let{type:t,"aria-label":n,...r}=e,i=d(),o="increase"===t?StatUpArrow:StatDownArrow;return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(s.chakra.span,{srOnly:!0,children:n||("increase"===t?"increased by":"decreased by")}),(0,u.jsx)(o,{"aria-hidden":!0,...r,__css:i.icon})]})}StatDownArrow.displayName="StatDownArrow",StatUpArrow.displayName="StatUpArrow",StatArrow.displayName="StatArrow";var h=(0,i.forwardRef)(function(e,t){return(0,u.jsx)(s.chakra.div,{...e,ref:t,role:"group",className:(0,l.cx)("chakra-stat__group",e.className),__css:{display:"flex",flexWrap:"wrap",justifyContent:"space-around",alignItems:"flex-start"}})});h.displayName="StatGroup";var m=(0,i.forwardRef)(function(e,t){let n=d();return(0,u.jsx)(s.chakra.dd,{ref:t,...e,className:(0,l.cx)("chakra-stat__help-text",e.className),__css:n.helpText})});m.displayName="StatHelpText";var v=(0,i.forwardRef)(function(e,t){let n=d();return(0,u.jsx)(s.chakra.dt,{ref:t,...e,className:(0,l.cx)("chakra-stat__label",e.className),__css:n.label})});v.displayName="StatLabel";var g=(0,i.forwardRef)(function(e,t){let n=d();return(0,u.jsx)(s.chakra.dd,{ref:t,...e,className:(0,l.cx)("chakra-stat__number",e.className),__css:{...n.number,fontFeatureSettings:"pnum",fontVariantNumeric:"proportional-nums"}})});g.displayName="StatNumber"},67939:function(e,t,n){"use strict";n.r(t),n.d(t,{Step:function(){return h},StepDescription:function(){return b},StepIcon:function(){return StepIcon},StepIndicator:function(){return StepIndicator},StepIndicatorContent:function(){return StepIndicatorContent},StepNumber:function(){return w},StepSeparator:function(){return k},StepStatus:function(){return StepStatus},StepTitle:function(){return p},Stepper:function(){return y},useStepContext:function(){return a},useStepperStyles:function(){return l},useSteps:function(){return useSteps}});var r=n(310),i=n(33962),[o,a]=(0,r.k)({name:"StepContext"}),[s,l]=(0,i.createStylesContext)("Stepper"),u=n(16465),c=n(58250),d=n(23145),f=n(57437),p=(0,c.forwardRef)(function(e,t){let{status:n}=a(),r=l();return(0,f.jsx)(d.chakra.h3,{ref:t,"data-status":n,...e,__css:r.title,className:(0,u.cx)("chakra-step__title",e.className)})}),h=(0,c.forwardRef)(function(e,t){let{orientation:n,status:r,showLastSeparator:i}=a(),o=l();return(0,f.jsx)(d.chakra.div,{ref:t,"data-status":r,"data-orientation":n,"data-stretch":(0,u.PB)(i),__css:o.step,...e,className:(0,u.cx)("chakra-step",e.className)})}),m=n(92013),v=n(50446),g=n(2265),y=(0,c.forwardRef)(function(e,t){let n=(0,m.useMultiStyleConfig)("Stepper",e),{children:r,index:i,orientation:a="horizontal",showLastSeparator:l=!1,...c}=(0,v.Lr)(e),p=g.Children.toArray(r),h=p.length;return(0,f.jsx)(d.chakra.div,{ref:t,"aria-label":"Progress","data-orientation":a,...c,__css:n.stepper,className:(0,u.cx)("chakra-stepper",e.className),children:(0,f.jsx)(s,{value:n,children:p.map((e,t)=>(0,f.jsx)(o,{value:{index:t,status:ti?"incomplete":"active",orientation:a,showLastSeparator:l,count:h,isFirst:0===t,isLast:t===h-1},children:e},t))})})});function useSteps(e={}){let{index:t=0,count:n}=e,[r,i]=(0,g.useState)(t),o="number"==typeof n?n-1:0;return{activeStep:r,setActiveStep:i,activeStepPercent:r/o,isActiveStep:e=>e===r,isCompleteStep:e=>ee>r,getStatus:e=>er?"incomplete":"active",goToNext(){i(e=>"number"==typeof n?Math.min(n,e+1):e+1)},goToPrevious(){i(e=>Math.max(0,e-1))}}}var b=(0,c.forwardRef)(function(e,t){let{status:n}=a(),r=l();return(0,f.jsx)(d.chakra.p,{ref:t,"data-status":n,...e,className:(0,u.cx)("chakra-step__description",e.className),__css:r.description})});function StepStatus(e){let{complete:t,incomplete:n,active:r}=e,i=a(),o=null;switch(i.status){case"complete":o=(0,u.Pu)(t,i);break;case"incomplete":o=(0,u.Pu)(n,i);break;case"active":o=(0,u.Pu)(r,i)}return o?(0,f.jsx)(f.Fragment,{children:o}):null}function CheckIcon(e){return(0,f.jsx)("svg",{stroke:"currentColor",fill:"currentColor",strokeWidth:"0",viewBox:"0 0 20 20","aria-hidden":"true",height:"1em",width:"1em",...e,children:(0,f.jsx)("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"})})}var x=n(16248);function StepIcon(e){let{status:t}=a(),n=l();return(0,f.jsx)(x.J,{as:"complete"===t?CheckIcon:void 0,__css:n.icon,...e,className:(0,u.cx)("chakra-step__icon",e.className)})}var w=(0,c.forwardRef)(function(e,t){let{children:n,...r}=e,{status:i,index:o}=a(),s=l();return(0,f.jsx)(d.chakra.div,{ref:t,"data-status":i,__css:s.number,...r,className:(0,u.cx)("chakra-step__number",e.className),children:n||o+1})});function StepIndicator(e){let{status:t}=a(),n=l();return(0,f.jsx)(d.chakra.div,{"data-status":t,...e,__css:n.indicator,className:(0,u.cx)("chakra-step__indicator",e.className)})}function StepIndicatorContent(){return(0,f.jsx)(StepStatus,{complete:(0,f.jsx)(StepIcon,{}),incomplete:(0,f.jsx)(w,{}),active:(0,f.jsx)(w,{})})}var k=(0,c.forwardRef)(function(e,t){let{orientation:n,status:r,isLast:i,showLastSeparator:o}=a(),s=l();return i&&!o?null:(0,f.jsx)(d.chakra.div,{ref:t,role:"separator","data-orientation":n,"data-status":r,__css:s.separator,...e,className:(0,u.cx)("chakra-step__separator",e.className)})})},38531:function(e,t,n){"use strict";n.r(t),n.d(t,{Switch:function(){return d}});var r=n(6816),i=n(16465),o=n(58250),a=n(92013),s=n(50446),l=n(23145),u=n(2265),c=n(57437),d=(0,o.forwardRef)(function(e,t){let n=(0,a.useMultiStyleConfig)("Switch",e),{spacing:o="0.5rem",children:d,...f}=(0,s.Lr)(e),{getIndicatorProps:p,getInputProps:h,getCheckboxProps:m,getRootProps:v,getLabelProps:g}=(0,r.O)(f),y=(0,u.useMemo)(()=>({display:"inline-block",position:"relative",verticalAlign:"middle",lineHeight:0,...n.container}),[n.container]),b=(0,u.useMemo)(()=>({display:"inline-flex",flexShrink:0,justifyContent:"flex-start",boxSizing:"content-box",cursor:"pointer",...n.track}),[n.track]),x=(0,u.useMemo)(()=>({userSelect:"none",marginStart:o,...n.label}),[o,n.label]);return(0,c.jsxs)(l.chakra.label,{...v(),className:(0,i.cx)("chakra-switch",e.className),__css:y,children:[(0,c.jsx)("input",{className:"chakra-switch__input",...h({},t)}),(0,c.jsx)(l.chakra.span,{...m(),className:"chakra-switch__track",__css:b,children:(0,c.jsx)(l.chakra.span,{__css:n.thumb,className:"chakra-switch__thumb",...p()})}),d&&(0,c.jsx)(l.chakra.span,{className:"chakra-switch__label",...g(),__css:x,children:d})]})});d.displayName="Switch"},67998:function(e,t,n){"use strict";n.r(t)},33962:function(e,t,n){"use strict";n.r(t),n.d(t,{CSSVars:function(){return CSSVars},GlobalStyle:function(){return GlobalStyle},StylesProvider:function(){return d},ThemeProvider:function(){return ThemeProvider},createStylesContext:function(){return createStylesContext},useStyles:function(){return f}});var r=n(85035),i=n(2265);function createContext(e={}){let{strict:t=!0,errorMessage:n="useContext: `context` is undefined. Seems you forgot to wrap component within the Provider",name:r}=e,o=(0,i.createContext)(void 0);return o.displayName=r,[o.Provider,function useContext(){var e;let r=(0,i.useContext)(o);if(!r&&t){let t=Error(n);throw t.name="ContextError",null==(e=Error.captureStackTrace)||e.call(Error,t,useContext),t}return r},o]}var o=n(50446),a=n(19307),s=n(62788),l=n(65673),u=n(99538),c=n(57437);function ThemeProvider(e){let{cssVarsRoot:t,theme:n,children:r}=e,a=(0,i.useMemo)(()=>(0,o.c0)(n),[n]);return(0,c.jsxs)(l.a,{theme:a,children:[(0,c.jsx)(CSSVars,{root:t}),r]})}function CSSVars({root:e=":host, :root"}){let t=[e,"[data-theme]"].join(",");return(0,c.jsx)(u.xB,{styles:e=>({[t]:e.__cssVars})})}var[d,f]=createContext({name:"StylesContext",errorMessage:"useStyles: `styles` is undefined. Seems you forgot to wrap the components in `` "});function createStylesContext(e){return createContext({name:`${e}StylesContext`,errorMessage:`useStyles: "styles" is undefined. Seems you forgot to wrap the components in "<${e} />" `})}function GlobalStyle(){let{colorMode:e}=(0,r.If)();return(0,c.jsx)(u.xB,{styles:t=>{let n=(0,a.Wf)(t,"styles.global"),r=(0,s.Pu)(n,{theme:t,colorMode:e});if(!r)return;let i=(0,o.iv)(r)(t);return i}})}},57474:function(e,t,n){"use strict";n.r(t),n.d(t,{Table:function(){return f},TableCaption:function(){return m},TableContainer:function(){return v},Tbody:function(){return g},Td:function(){return y},Tfoot:function(){return b},Th:function(){return x},Thead:function(){return p},Tr:function(){return h},useTableStyles:function(){return d}});var r=n(58250),i=n(92013),o=n(50446),a=n(23145),s=n(16465),l=n(310),u=n(57437),[c,d]=(0,l.k)({name:"TableStylesContext",errorMessage:"useTableStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),f=(0,r.forwardRef)((e,t)=>{let n=(0,i.useMultiStyleConfig)("Table",e),{className:r,layout:l,...d}=(0,o.Lr)(e);return(0,u.jsx)(c,{value:n,children:(0,u.jsx)(a.chakra.table,{ref:t,__css:{tableLayout:l,...n.table},className:(0,s.cx)("chakra-table",r),...d})})});f.displayName="Table";var p=(0,r.forwardRef)((e,t)=>{let n=d();return(0,u.jsx)(a.chakra.thead,{...e,ref:t,__css:n.thead})}),h=(0,r.forwardRef)((e,t)=>{let n=d();return(0,u.jsx)(a.chakra.tr,{...e,ref:t,__css:n.tr})}),m=(0,r.forwardRef)((e,t)=>{let{placement:n="bottom",...r}=e,i=d();return(0,u.jsx)(a.chakra.caption,{...r,ref:t,__css:{...i.caption,captionSide:n}})});m.displayName="TableCaption";var v=(0,r.forwardRef)((e,t)=>{var n;let{overflow:r,overflowX:i,className:o,...l}=e;return(0,u.jsx)(a.chakra.div,{ref:t,className:(0,s.cx)("chakra-table__container",o),...l,__css:{display:"block",whiteSpace:"nowrap",WebkitOverflowScrolling:"touch",overflowX:null!=(n=null!=r?r:i)?n:"auto",overflowY:"hidden",maxWidth:"100%"}})}),g=(0,r.forwardRef)((e,t)=>{let n=d();return(0,u.jsx)(a.chakra.tbody,{...e,ref:t,__css:n.tbody})}),y=(0,r.forwardRef)(({isNumeric:e,...t},n)=>{let r=d();return(0,u.jsx)(a.chakra.td,{...t,ref:n,__css:r.td,"data-is-numeric":e})}),b=(0,r.forwardRef)((e,t)=>{let n=d();return(0,u.jsx)(a.chakra.tfoot,{...e,ref:t,__css:n.tfoot})}),x=(0,r.forwardRef)(({isNumeric:e,...t},n)=>{let r=d();return(0,u.jsx)(a.chakra.th,{...t,ref:n,__css:r.th,"data-is-numeric":e})})},15391:function(e,t,n){"use strict";n.r(t),n.d(t,{Tab:function(){return D},TabIndicator:function(){return M},TabList:function(){return _},TabPanel:function(){return N},TabPanels:function(){return R},Tabs:function(){return A},TabsDescendantsProvider:function(){return p},TabsProvider:function(){return g},useTab:function(){return useTab},useTabIndicator:function(){return useTabIndicator},useTabList:function(){return useTabList},useTabPanel:function(){return useTabPanel},useTabPanels:function(){return useTabPanels},useTabs:function(){return useTabs},useTabsContext:function(){return y},useTabsDescendant:function(){return v},useTabsDescendants:function(){return m},useTabsDescendantsContext:function(){return h},useTabsStyles:function(){return T}});var r=n(13079),i=n(64763),o=n(310),a=n(67673),s=n(27771),l=n(61158),u=n(45663),c=n(21450),d=n(16465),f=n(2265),[p,h,m,v]=(0,i.n)();function useTabs(e){var t;let{defaultIndex:n,onChange:r,index:i,isManual:o,isLazy:a,lazyBehavior:l="unmount",orientation:u="horizontal",direction:c="ltr",...d}=e,[p,h]=(0,f.useState)(null!=n?n:0),[v,g]=(0,s.T)({defaultValue:null!=n?n:0,value:i,onChange:r});(0,f.useEffect)(()=>{null!=i&&h(i)},[i]);let y=m(),b=(0,f.useId)(),x=null!=(t=e.id)?t:b,w=`tabs-${x}`;return{id:w,selectedIndex:v,focusedIndex:p,setSelectedIndex:g,setFocusedIndex:h,isManual:o,isLazy:a,lazyBehavior:l,orientation:u,descendants:y,direction:c,htmlProps:d}}var[g,y]=(0,o.k)({name:"TabsContext",errorMessage:"useTabsContext: `context` is undefined. Seems you forgot to wrap all tabs components within "});function useTabList(e){let{focusedIndex:t,orientation:n,direction:r}=y(),i=h(),o=(0,f.useCallback)(e=>{let nextTab=()=>{var e;let n=i.nextEnabled(t);n&&(null==(e=n.node)||e.focus())},prevTab=()=>{var e;let n=i.prevEnabled(t);n&&(null==(e=n.node)||e.focus())},o="horizontal"===n,a="vertical"===n,s=e.key,l="ltr"===r?"ArrowLeft":"ArrowRight",u="ltr"===r?"ArrowRight":"ArrowLeft",c={[l]:()=>o&&prevTab(),[u]:()=>o&&nextTab(),ArrowDown:()=>a&&nextTab(),ArrowUp:()=>a&&prevTab(),Home:()=>{var e;let t=i.firstEnabled();t&&(null==(e=t.node)||e.focus())},End:()=>{var e;let t=i.lastEnabled();t&&(null==(e=t.node)||e.focus())}}[s];c&&(e.preventDefault(),c(e))},[i,t,n,r]);return{...e,role:"tablist","aria-orientation":n,onKeyDown:(0,d.v0)(e.onKeyDown,o)}}function useTab(e){let{isDisabled:t=!1,isFocusable:n=!1,...i}=e,{setSelectedIndex:o,isManual:a,id:s,setFocusedIndex:l,selectedIndex:c}=y(),{index:f,register:p}=v({disabled:t&&!n}),h=f===c,m=(0,r.h)({...i,ref:(0,u.lq)(p,e.ref),isDisabled:t,isFocusable:n,onClick:(0,d.v0)(e.onClick,()=>{o(f)})});return{...m,id:makeTabId(s,f),role:"tab",tabIndex:h?0:-1,type:"button","aria-selected":h,"aria-controls":makeTabPanelId(s,f),onFocus:t?void 0:(0,d.v0)(e.onFocus,()=>{l(f);let e=t&&n;a||e||o(f)})}}var[b,x]=(0,o.k)({});function useTabPanels(e){let t=y(),{id:n,selectedIndex:r}=t,i=(0,l.W)(e.children),o=i.map((e,t)=>(0,f.createElement)(b,{key:t,value:{isSelected:t===r,id:makeTabPanelId(n,t),tabId:makeTabId(n,t),selectedIndex:r}},e));return{...e,children:o}}function useTabPanel(e){let{children:t,...n}=e,{isLazy:r,lazyBehavior:i}=y(),{isSelected:o,id:a,tabId:s}=x(),l=(0,f.useRef)(!1);o&&(l.current=!0);let u=(0,c.k)({wasSelected:l.current,isSelected:o,enabled:r,mode:i});return{tabIndex:0,...n,children:u?t:null,role:"tabpanel","aria-labelledby":s,hidden:!o,id:a}}function useTabIndicator(){let e=y(),t=h(),{selectedIndex:n,orientation:r}=e,i="horizontal"===r,o="vertical"===r,[s,l]=(0,f.useState)(()=>i?{left:0,width:0}:o?{top:0,height:0}:void 0),[u,c]=(0,f.useState)(!1);return(0,a.G)(()=>{if(null==n)return;let e=t.item(n);if(null==e)return;i&&l({left:e.node.offsetLeft,width:e.node.offsetWidth}),o&&l({top:e.node.offsetTop,height:e.node.offsetHeight});let r=requestAnimationFrame(()=>{c(!0)});return()=>{r&&cancelAnimationFrame(r)}},[n,i,o,t]),{position:"absolute",transitionProperty:"left, right, top, bottom, height, width",transitionDuration:u?"200ms":"0ms",transitionTimingFunction:"cubic-bezier(0, 0, 0.2, 1)",...s}}function makeTabId(e,t){return`${e}--tab-${t}`}function makeTabPanelId(e,t){return`${e}--tabpanel-${t}`}var w=n(58250),k=n(92013),S=n(50446),C=n(23145),E=n(57437),[P,T]=(0,o.k)({name:"TabsStylesContext",errorMessage:"useTabsStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),A=(0,w.forwardRef)(function(e,t){let n=(0,k.useMultiStyleConfig)("Tabs",e),{children:r,className:i,...o}=(0,S.Lr)(e),{htmlProps:a,descendants:s,...l}=useTabs(o),u=(0,f.useMemo)(()=>l,[l]),{isFitted:c,...h}=a,m={position:"relative",...n.root};return(0,E.jsx)(p,{value:s,children:(0,E.jsx)(g,{value:u,children:(0,E.jsx)(P,{value:n,children:(0,E.jsx)(C.chakra.div,{className:(0,d.cx)("chakra-tabs",i),ref:t,...h,__css:m,children:r})})})})});A.displayName="Tabs";var M=(0,w.forwardRef)(function(e,t){let n=useTabIndicator(),r={...e.style,...n},i=T();return(0,E.jsx)(C.chakra.div,{ref:t,...e,className:(0,d.cx)("chakra-tabs__tab-indicator",e.className),style:r,__css:i.indicator})});M.displayName="TabIndicator";var _=(0,w.forwardRef)(function(e,t){let n=useTabList({...e,ref:t}),r=T(),i={display:"flex",...r.tablist};return(0,E.jsx)(C.chakra.div,{...n,className:(0,d.cx)("chakra-tabs__tablist",e.className),__css:i})});_.displayName="TabList";var N=(0,w.forwardRef)(function(e,t){let n=useTabPanel({...e,ref:t}),r=T();return(0,E.jsx)(C.chakra.div,{outline:"0",...n,className:(0,d.cx)("chakra-tabs__tab-panel",e.className),__css:r.tabpanel})});N.displayName="TabPanel";var R=(0,w.forwardRef)(function(e,t){let n=useTabPanels(e),r=T();return(0,E.jsx)(C.chakra.div,{...n,width:"100%",ref:t,className:(0,d.cx)("chakra-tabs__tab-panels",e.className),__css:r.tabpanels})});R.displayName="TabPanels";var D=(0,w.forwardRef)(function(e,t){let n=T(),r=useTab({...e,ref:t}),i={outline:"0",display:"flex",alignItems:"center",justifyContent:"center",...n.tab};return(0,E.jsx)(C.chakra.button,{...r,className:(0,d.cx)("chakra-tabs__tab",e.className),__css:i})});D.displayName="Tab"},82812:function(e,t,n){"use strict";n.r(t),n.d(t,{Tag:function(){return f},TagCloseButton:function(){return v},TagLabel:function(){return p},TagLeftIcon:function(){return h},TagRightIcon:function(){return m},useTagStyles:function(){return d}});var r=n(16248),i=n(310),o=n(58250),a=n(92013),s=n(50446),l=n(23145),u=n(57437),[c,d]=(0,i.k)({name:"TagStylesContext",errorMessage:"useTagStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),f=(0,o.forwardRef)((e,t)=>{let n=(0,a.useMultiStyleConfig)("Tag",e),r=(0,s.Lr)(e),i={display:"inline-flex",verticalAlign:"top",alignItems:"center",maxWidth:"100%",...n.container};return(0,u.jsx)(c,{value:n,children:(0,u.jsx)(l.chakra.span,{ref:t,...r,__css:i})})});f.displayName="Tag";var p=(0,o.forwardRef)((e,t)=>{let n=d();return(0,u.jsx)(l.chakra.span,{ref:t,noOfLines:1,...e,__css:n.label})});p.displayName="TagLabel";var h=(0,o.forwardRef)((e,t)=>(0,u.jsx)(r.J,{ref:t,verticalAlign:"top",marginEnd:"0.5rem",...e}));h.displayName="TagLeftIcon";var m=(0,o.forwardRef)((e,t)=>(0,u.jsx)(r.J,{ref:t,verticalAlign:"top",marginStart:"0.5rem",...e}));m.displayName="TagRightIcon";var TagCloseIcon=e=>(0,u.jsx)(r.J,{verticalAlign:"inherit",viewBox:"0 0 512 512",...e,children:(0,u.jsx)("path",{fill:"currentColor",d:"M289.94 256l95-95A24 24 0 00351 127l-95 95-95-95a24 24 0 00-34 34l95 95-95 95a24 24 0 1034 34l95-95 95 95a24 24 0 0034-34z"})});TagCloseIcon.displayName="TagCloseIcon";var v=(0,o.forwardRef)((e,t)=>{let{isDisabled:n,children:r,...i}=e,o=d(),a={display:"flex",alignItems:"center",justifyContent:"center",outline:"0",...o.closeButton};return(0,u.jsx)(l.chakra.button,{ref:t,"aria-label":"close",...i,type:"button",disabled:n,__css:a,children:r||(0,u.jsx)(TagCloseIcon,{})})});v.displayName="TagCloseButton"},71846:function(e,t,n){"use strict";n.r(t),n.d(t,{Textarea:function(){return d}});var r=n(75992),i=n(58250),o=n(92013),a=n(50446),s=n(23145),l=n(16465),u=n(57437),c=["h","minH","height","minHeight"],d=(0,i.forwardRef)((e,t)=>{let n=(0,o.useStyleConfig)("Textarea",e),{className:i,rows:d,...f}=(0,a.Lr)(e),p=(0,r.Y)(f),h=d?function(e,t=[]){let n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}(n,c):n;return(0,u.jsx)(s.chakra.textarea,{ref:t,rows:d,...p,className:(0,l.cx)("chakra-textarea",i),__css:h})});d.displayName="Textarea"},37493:function(e,t,n){"use strict";n.d(t,{Qi:function(){return g},VW:function(){return ToastProvider},OX:function(){return y}});var r=n(54591),i=n(2265),o=n(37977),a=n(89656),s=n(16465),l=n(77196),u=n(72638),c=n(23145),d=n(57437),f={initial:e=>{let{position:t}=e,n=["top","bottom"].includes(t)?"y":"x",r=["top-right","bottom-right"].includes(t)?1:-1;return"bottom"===t&&(r=1),{opacity:0,[n]:24*r}},animate:{opacity:1,y:0,x:0,scale:1,transition:{duration:.4,ease:[.4,0,.2,1]}},exit:{opacity:0,scale:.85,transition:{duration:.2,ease:[.4,0,1,1]}}},p=(0,i.memo)(e=>{let{id:t,message:n,onCloseComplete:p,onRequestRemove:h,requestClose:m=!1,position:v="bottom",duration:g=5e3,containerStyle:y,motionVariants:b=f,toastSpacing:x="0.5rem"}=e,[w,k]=(0,i.useState)(g),S=(0,l.hO)();(0,a.r)(()=>{S||null==p||p()},[S]),(0,a.r)(()=>{k(g)},[g]);let close=()=>{S&&h()};(0,i.useEffect)(()=>{S&&m&&h()},[S,m,h]),function(e,t){let n=(0,o.W)(e);(0,i.useEffect)(()=>{if(null==t)return;let e=null;return e=window.setTimeout(()=>{n()},t),()=>{e&&window.clearTimeout(e)}},[t,n])}(close,w);let C=(0,i.useMemo)(()=>({pointerEvents:"auto",maxWidth:560,minWidth:300,margin:x,...y}),[y,x]),E=(0,i.useMemo)(()=>(0,r.sv)(v),[v]);return(0,d.jsx)(u.E.div,{layout:!0,className:"chakra-toast",variants:b,initial:"initial",animate:"animate",exit:"exit",onHoverStart:()=>k(null),onHoverEnd:()=>k(g),custom:{position:v},style:E,children:(0,d.jsx)(c.chakra.div,{role:"status","aria-atomic":"true",className:"chakra-toast__inner",__css:C,children:(0,s.Pu)(n,{id:t,onClose:close})})})});p.displayName="ToastComponent";var h=n(69659),m=n(62167),v=n(2879),[g,y]=(0,n(310).k)({name:"ToastOptionsContext",strict:!1}),ToastProvider=e=>{let t=(0,i.useSyncExternalStore)(h.fp.subscribe,h.fp.getState,h.fp.getState),{motionVariants:n,component:o=p,portalProps:a}=e,s=Object.keys(t),l=s.map(e=>{let i=t[e];return(0,d.jsx)("div",{role:"region","aria-live":"polite","aria-label":"Notifications",id:`chakra-toast-manager-${e}`,style:(0,r.IW)(e),children:(0,d.jsx)(m.M,{initial:!1,children:i.map(e=>(0,d.jsx)(o,{motionVariants:n,...e},e.id))})},e)});return(0,d.jsx)(v.h,{...a,children:l})}},69659:function(e,t,n){"use strict";n.d(t,{Cj:function(){return createToastFn},Cq:function(){return createRenderToast},FN:function(){return Toast},fp:function(){return p}});var r=n(54591),i=n(73578),o=n(45550),a=n(25303),s=n(62035),l=n(30609),u=n(23145),c=n(96231),d=n(16465),f=n(57437),p=function(e){let t=e,n=new Set,setState=e=>{t=e(t),n.forEach(e=>e())};return{getState:()=>t,subscribe:t=>(n.add(t),()=>{setState(()=>e),n.delete(t)}),removeToast:(e,t)=>{setState(n=>({...n,[t]:n[t].filter(t=>t.id!=e)}))},notify:(e,t)=>{let n=function(e,t={}){var n,r;h+=1;let i=null!=(n=t.id)?n:h,o=null!=(r=t.position)?r:"bottom";return{id:i,message:e,position:o,duration:t.duration,onCloseComplete:t.onCloseComplete,onRequestRemove:()=>p.removeToast(String(i),o),status:t.status,requestClose:!1,containerStyle:t.containerStyle}}(e,t),{position:r,id:i}=n;return setState(e=>{var t,i;let o=r.includes("top"),a=o?[n,...null!=(t=e[r])?t:[]]:[...null!=(i=e[r])?i:[],n];return{...e,[r]:a}}),i},update:(e,t)=>{e&&setState(n=>{let i={...n},{position:o,index:a}=(0,r.Dn)(i,e);return o&&-1!==a&&(i[o][a]={...i[o][a],...t,message:createRenderToast(t)}),i})},closeAll:({positions:e}={})=>{setState(t=>(null!=e?e:["bottom","bottom-right","bottom-left","top","top-left","top-right"]).reduce((e,n)=>(e[n]=t[n].map(e=>({...e,requestClose:!0})),e),{...t}))},close:e=>{setState(t=>{let n=(0,r.ym)(t,e);return n?{...t,[n]:t[n].map(t=>t.id==e?{...t,requestClose:!0}:t)}:t})},isActive:e=>!!(0,r.Dn)(p.getState(),e).position}}({top:[],"top-left":[],"top-right":[],"bottom-left":[],bottom:[],"bottom-right":[]}),h=0,Toast=e=>{let{status:t,variant:n="solid",id:r,title:i,isClosable:d,onClose:p,description:h,colorScheme:m,icon:v}=e,g=r?{root:`toast-${r}`,title:`toast-${r}-title`,description:`toast-${r}-description`}:void 0;return(0,f.jsxs)(o.b,{addRole:!1,status:t,variant:n,id:null==g?void 0:g.root,alignItems:"start",borderRadius:"md",boxShadow:"lg",paddingEnd:8,textAlign:"start",width:"auto",colorScheme:m,children:[(0,f.jsx)(a.z,{children:v}),(0,f.jsxs)(u.chakra.div,{flex:"1",maxWidth:"100%",children:[i&&(0,f.jsx)(s.C,{id:null==g?void 0:g.title,children:i}),h&&(0,f.jsx)(l.X,{id:null==g?void 0:g.description,display:"block",children:h})]}),d&&(0,f.jsx)(c.P,{size:"sm",onClick:p,position:"absolute",insetEnd:1,top:1})]})};function createRenderToast(e={}){let{render:t,toastComponent:n=Toast}=e;return r=>"function"==typeof t?t({...r,...e}):(0,f.jsx)(n,{...r,...e})}function createToastFn(e,t){let normalizeToastOptions=n=>{var r;return{...t,...n,position:(0,i.R)(null!=(r=null==n?void 0:n.position)?r:null==t?void 0:t.position,e)}},toast=e=>{let t=normalizeToastOptions(e),n=createRenderToast(t);return p.notify(n,t)};return toast.update=(e,t)=>{p.update(e,normalizeToastOptions(t))},toast.promise=(e,t)=>{let n=toast({...t.loading,status:"loading",duration:null});e.then(e=>toast.update(n,{status:"success",duration:5e3,...(0,d.Pu)(t.success,e)})).catch(e=>toast.update(n,{status:"error",duration:5e3,...(0,d.Pu)(t.error,e)}))},toast.closeAll=p.closeAll,toast.close=p.close,toast.isActive=p.isActive,toast}},54591:function(e,t,n){"use strict";n.d(t,{Dn:function(){return findToast},IW:function(){return getToastListStyle},sv:function(){return getToastStyle},ym:function(){return getToastPosition}});var findById=(e,t)=>e.find(e=>e.id===t);function findToast(e,t){let n=getToastPosition(e,t),r=n?e[n].findIndex(e=>e.id===t):-1;return{position:n,index:r}}function getToastPosition(e,t){for(let[n,r]of Object.entries(e))if(findById(r,t))return n}function getToastStyle(e){let t=e.includes("right"),n=e.includes("left"),r="center";return t&&(r="flex-end"),n&&(r="flex-start"),{display:"flex",flexDirection:"column",alignItems:r}}function getToastListStyle(e){let t=e.includes("top")?"env(safe-area-inset-top, 0px)":void 0,n=e.includes("bottom")?"env(safe-area-inset-bottom, 0px)":void 0,r=e.includes("left")?void 0:"env(safe-area-inset-right, 0px)",i=e.includes("right")?void 0:"env(safe-area-inset-left, 0px)";return{position:"fixed",zIndex:"var(--toast-z-index, 5500)",pointerEvents:"none",display:"flex",flexDirection:"column",margin:"top"===e||"bottom"===e?"0 auto":void 0,top:t,bottom:n,right:r,left:i}}},73578:function(e,t,n){"use strict";function getToastPlacement(e,t){var n;let r=null!=e?e:"bottom",i={"top-start":{ltr:"top-left",rtl:"top-right"},"top-end":{ltr:"top-right",rtl:"top-left"},"bottom-start":{ltr:"bottom-left",rtl:"bottom-right"},"bottom-end":{ltr:"bottom-right",rtl:"bottom-left"}}[r];return null!=(n=null==i?void 0:i[t])?n:r}n.d(t,{R:function(){return getToastPlacement}})},91917:function(e,t,n){"use strict";n.r(t),n.d(t,{Toast:function(){return i.FN},ToastOptionProvider:function(){return r.Qi},ToastProvider:function(){return r.VW},createRenderToast:function(){return i.Cq},createStandaloneToast:function(){return createStandaloneToast},createToastFn:function(){return i.Cj},getToastPlacement:function(){return f.R},useToast:function(){return useToast}});var r=n(37493),i=n(69659),o=n(12704),a=n(2265);function useToast(e){let{theme:t}=(0,o.useChakra)(),n=(0,r.OX)();return(0,a.useMemo)(()=>(0,i.Cj)(t.direction,{...n,...e}),[e,t.direction,n])}var s=n(33962),l=n(85035),u=n(62952),c=n(57437),d={theme:u.rS,colorMode:"light",toggleColorMode:()=>{},setColorMode:()=>{},defaultOptions:{duration:5e3,variant:"solid"},forced:!1};function createStandaloneToast({theme:e=d.theme,colorMode:t=d.colorMode,toggleColorMode:n=d.toggleColorMode,setColorMode:o=d.setColorMode,defaultOptions:a=d.defaultOptions,motionVariants:u,toastSpacing:f,component:p,forced:h}=d){let m={colorMode:t,setColorMode:o,toggleColorMode:n,forced:h};return{ToastContainer:()=>(0,c.jsx)(s.ThemeProvider,{theme:e,children:(0,c.jsx)(l.kc.Provider,{value:m,children:(0,c.jsx)(r.VW,{defaultOptions:a,motionVariants:u,toastSpacing:f,component:p})})}),toast:(0,i.Cj)(e.direction,a)}}var f=n(73578)},92776:function(e,t,n){"use strict";n.r(t),n.d(t,{Tooltip:function(){return S},useTooltip:function(){return useTooltip}});var r={exit:{scale:.85,opacity:0,transition:{opacity:{duration:.15,easings:"easeInOut"},scale:{duration:.2,easings:"easeInOut"}}},enter:{scale:1,opacity:1,transition:{opacity:{easings:"easeOut",duration:.2},scale:{duration:.2,ease:[.175,.885,.4,1.1]}}}},i=n(65346),o=n(1521),a=n(15006),s=n(61113),l=n(10931),u=n(45663),c=n(16465),d=n(2265),getDoc=e=>{var t;return(null==(t=e.current)?void 0:t.ownerDocument)||document},getWin=e=>{var t,n;return(null==(n=null==(t=e.current)?void 0:t.ownerDocument)?void 0:n.defaultView)||window};function useTooltip(e={}){let{openDelay:t=0,closeDelay:n=0,closeOnClick:r=!0,closeOnMouseDown:p,closeOnScroll:h,closeOnPointerDown:m=p,closeOnEsc:v=!0,onOpen:g,onClose:y,placement:b,id:x,isOpen:w,defaultIsOpen:k,arrowSize:S=10,arrowShadowColor:C,arrowPadding:E,modifiers:P,isDisabled:T,gutter:A,offset:M,direction:_,...N}=e,{isOpen:R,onOpen:D,onClose:I}=(0,s.q)({isOpen:w,defaultIsOpen:k,onOpen:g,onClose:y}),{referenceRef:j,getPopperProps:L,getArrowInnerProps:O,getArrowProps:F}=(0,o.D)({enabled:R,placement:b,arrowPadding:E,modifiers:P,gutter:A,offset:M,direction:_}),V=(0,d.useId)(),B=`tooltip-${null!=x?x:V}`,W=(0,d.useRef)(null),$=(0,d.useRef)(),U=(0,d.useCallback)(()=>{$.current&&(clearTimeout($.current),$.current=void 0)},[]),H=(0,d.useRef)(),z=(0,d.useCallback)(()=>{H.current&&(clearTimeout(H.current),H.current=void 0)},[]),G=(0,d.useCallback)(()=>{z(),I()},[I,z]),q=((0,d.useEffect)(()=>{let e=getDoc(W);return e.addEventListener(f,G),()=>e.removeEventListener(f,G)},[G,W]),()=>{let e=getDoc(W),t=getWin(W);e.dispatchEvent(new t.CustomEvent(f))}),K=(0,d.useCallback)(()=>{if(!T&&!$.current){R&&q();let e=getWin(W);$.current=e.setTimeout(D,t)}},[q,T,R,D,t]),X=(0,d.useCallback)(()=>{U();let e=getWin(W);H.current=e.setTimeout(G,n)},[n,G,U]),Z=(0,d.useCallback)(()=>{R&&r&&X()},[r,X,R]),Y=(0,d.useCallback)(()=>{R&&m&&X()},[m,X,R]),Q=(0,d.useCallback)(e=>{R&&"Escape"===e.key&&X()},[R,X]);(0,l.O)(()=>getDoc(W),"keydown",v?Q:void 0),(0,l.O)(()=>{let e=W.current;if(!e)return null;let t=function getScrollParent(e){return["html","body","#document"].includes(e.localName)?e.ownerDocument.body:(0,i.Re)(e)&&function(e){let t=e.ownerDocument.defaultView||window,{overflow:n,overflowX:r,overflowY:i}=t.getComputedStyle(e);return/auto|scroll|overlay|hidden/.test(n+i+r)}(e)?e:getScrollParent("html"===e.localName?e:e.assignedSlot||e.parentElement||e.ownerDocument.documentElement)}(e);return"body"===t.localName?getWin(W):t},"scroll",()=>{R&&h&&G()},{passive:!0,capture:!0}),(0,d.useEffect)(()=>{T&&(U(),R&&I())},[T,R,I,U]),(0,d.useEffect)(()=>()=>{U(),z()},[U,z]),(0,l.O)(()=>W.current,"pointerleave",X);let J=(0,d.useCallback)((e={},t=null)=>{let n={...e,ref:(0,u.lq)(W,t,j),onPointerEnter:(0,c.v0)(e.onPointerEnter,e=>{"touch"!==e.pointerType&&K()}),onClick:(0,c.v0)(e.onClick,Z),onPointerDown:(0,c.v0)(e.onPointerDown,Y),onFocus:(0,c.v0)(e.onFocus,K),onBlur:(0,c.v0)(e.onBlur,X),"aria-describedby":R?B:void 0};return n},[K,X,Y,R,B,Z,j]),ee=(0,d.useCallback)((e={},t=null)=>L({...e,style:{...e.style,[a.Dq.arrowSize.var]:S?`${S}px`:void 0,[a.Dq.arrowShadowColor.var]:C}},t),[L,S,C]),et=(0,d.useCallback)((e={},t=null)=>{let n={...e.style,position:"relative",transformOrigin:a.Dq.transformOrigin.varRef};return{ref:t,...N,...e,id:B,role:"tooltip",style:n}},[N,B]);return{isOpen:R,show:K,hide:X,getTriggerProps:J,getTooltipProps:et,getTooltipPositionerProps:ee,getArrowProps:F,getArrowInnerProps:O}}var f="chakra-ui:close-tooltip",p=n(2879),h=n(23145),m=n(58250),v=n(92013),g=n(50446),y=n(90865),b=n(72638),x=n(62167),w=n(57437),k=(0,h.chakra)(b.E.div),S=(0,m.forwardRef)((e,t)=>{var n,i;let o;let s=(0,v.useStyleConfig)("Tooltip",e),l=(0,g.Lr)(e),u=(0,y.useTheme)(),{children:c,label:f,shouldWrapChildren:m,"aria-label":b,hasArrow:S,bg:C,portalProps:E,background:P,backgroundColor:T,bgColor:A,motionProps:M,..._}=l,N=null!=(i=null!=(n=null!=P?P:T)?n:C)?i:A;if(N){s.bg=N;let e=(0,g.K1)(u,"colors",N);s[a.Dq.arrowBg.var]=e}let R=useTooltip({..._,direction:u.direction}),D="string"==typeof c||m;if(D)o=(0,w.jsx)(h.chakra.span,{display:"inline-block",tabIndex:0,...R.getTriggerProps(),children:c});else{let e=d.Children.only(c);o=(0,d.cloneElement)(e,R.getTriggerProps(e.props,e.ref))}let I=!!b,j=R.getTooltipProps({},t),L=I?function(e,t=[]){let n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}(j,["role","id"]):j,O=function(e,t){let n={};for(let r of t)r in e&&(n[r]=e[r]);return n}(j,["role","id"]);return f?(0,w.jsxs)(w.Fragment,{children:[o,(0,w.jsx)(x.M,{children:R.isOpen&&(0,w.jsx)(p.h,{...E,children:(0,w.jsx)(h.chakra.div,{...R.getTooltipPositionerProps(),__css:{zIndex:s.zIndex,pointerEvents:"none"},children:(0,w.jsxs)(k,{variants:r,initial:"exit",animate:"enter",exit:"exit",...M,...L,__css:s,children:[f,I&&(0,w.jsx)(h.chakra.span,{srOnly:!0,...O,children:b}),S&&(0,w.jsx)(h.chakra.div,{"data-popper-arrow":!0,className:"chakra-tooltip__arrow-wrapper",children:(0,w.jsx)(h.chakra.div,{"data-popper-arrow-inner":!0,className:"chakra-tooltip__arrow",__css:{bg:s.bg}})})]})})})})]}):(0,w.jsx)(w.Fragment,{children:c})});S.displayName="Tooltip"},24278:function(e,t,n){"use strict";n.d(t,{Lj:function(){return r},Sh:function(){return o},js:function(){return getSlideTransition},p$:function(){return a}});var r={ease:[.25,.1,.25,1],easeIn:[.4,0,1,1],easeOut:[0,0,.2,1],easeInOut:[.4,0,.2,1]},i={slideLeft:{position:{left:0,top:0,bottom:0,width:"100%"},enter:{x:0,y:0},exit:{x:"-100%",y:0}},slideRight:{position:{right:0,top:0,bottom:0,width:"100%"},enter:{x:0,y:0},exit:{x:"100%",y:0}},slideUp:{position:{top:0,left:0,right:0,maxWidth:"100vw"},enter:{x:0,y:0},exit:{x:0,y:"-100%"}},slideDown:{position:{bottom:0,left:0,right:0,maxWidth:"100vw"},enter:{x:0,y:0},exit:{x:0,y:"100%"}}};function getSlideTransition(e){var t;let n=null!=(t=null==e?void 0:e.direction)?t:"right";switch(n){case"right":default:return i.slideRight;case"left":return i.slideLeft;case"bottom":return i.slideDown;case"top":return i.slideUp}}var o={enter:{duration:.2,ease:r.easeOut},exit:{duration:.1,ease:r.easeIn}},a={enter:(e,t)=>({...e,delay:"number"==typeof t?t:null==t?void 0:t.enter}),exit:(e,t)=>({...e,delay:"number"==typeof t?t:null==t?void 0:t.exit})}},80834:function(e,t,n){"use strict";n.d(t,{R:function(){return c},X:function(){return u}});var r=n(24278),i=n(16465),o=n(62167),a=n(72638),s=n(2265),l=n(57437),u={initial:"initial",animate:"enter",exit:"exit",variants:{initial:({offsetX:e,offsetY:t,transition:n,transitionEnd:i,delay:o})=>{var a;return{opacity:0,x:e,y:t,transition:null!=(a=null==n?void 0:n.exit)?a:r.p$.exit(r.Sh.exit,o),transitionEnd:null==i?void 0:i.exit}},enter:({transition:e,transitionEnd:t,delay:n})=>{var i;return{opacity:1,x:0,y:0,transition:null!=(i=null==e?void 0:e.enter)?i:r.p$.enter(r.Sh.enter,n),transitionEnd:null==t?void 0:t.enter}},exit:({offsetY:e,offsetX:t,transition:n,transitionEnd:i,reverse:o,delay:a})=>{var s;let l={x:t,y:e};return{opacity:0,transition:null!=(s=null==n?void 0:n.exit)?s:r.p$.exit(r.Sh.exit,a),...o?{...l,transitionEnd:null==i?void 0:i.exit}:{transitionEnd:{...l,...null==i?void 0:i.exit}}}}}},c=(0,s.forwardRef)(function(e,t){let{unmountOnExit:n,in:r,reverse:s=!0,className:c,offsetX:d=0,offsetY:f=8,transition:p,transitionEnd:h,delay:m,...v}=e,g=!n||r&&n,y=r||n?"enter":"exit",b={offsetX:d,offsetY:f,reverse:s,transition:p,transitionEnd:h,delay:m};return(0,l.jsx)(o.M,{custom:b,children:g&&(0,l.jsx)(a.E.div,{ref:t,className:(0,i.cx)("chakra-offset-slide",c),custom:b,...u,animate:y,...v})})});c.displayName="SlideFade"},23002:function(e,t,n){"use strict";n.d(t,{M:function(){return d}});var r=n(24278),i=n(16465),o=n(62167),a=n(72638),s=n(2265),l=n(57437),u={exit:{duration:.15,ease:r.Lj.easeInOut},enter:{type:"spring",damping:25,stiffness:180}},c={exit:({direction:e,transition:t,transitionEnd:n,delay:i})=>{var o;let{exit:a}=(0,r.js)({direction:e});return{...a,transition:null!=(o=null==t?void 0:t.exit)?o:r.p$.exit(u.exit,i),transitionEnd:null==n?void 0:n.exit}},enter:({direction:e,transitionEnd:t,transition:n,delay:i})=>{var o;let{enter:a}=(0,r.js)({direction:e});return{...a,transition:null!=(o=null==n?void 0:n.enter)?o:r.p$.enter(u.enter,i),transitionEnd:null==t?void 0:t.enter}}},d=(0,s.forwardRef)(function(e,t){let{direction:n="right",style:s,unmountOnExit:u,in:d,className:f,transition:p,transitionEnd:h,delay:m,motionProps:v,...g}=e,y=(0,r.js)({direction:n}),b=Object.assign({position:"fixed"},y.position,s),x=!u||d&&u,w=d||u?"enter":"exit",k={transitionEnd:h,transition:p,direction:n,delay:m};return(0,l.jsx)(o.M,{custom:k,children:x&&(0,l.jsx)(a.E.div,{...g,ref:t,initial:"exit",className:(0,i.cx)("chakra-slide",f),animate:w,exit:"exit",custom:k,variants:c,style:b,...v})})});d.displayName="Slide"},43138:function(e,t,n){"use strict";n.d(t,{U:function(){return d}});var r=n(24278),i=n(16465),o=n(62167),a=n(72638),s=n(2265),l=n(57437),isNumeric=e=>null!=e&&parseInt(e.toString(),10)>0,u={exit:{height:{duration:.2,ease:r.Lj.ease},opacity:{duration:.3,ease:r.Lj.ease}},enter:{height:{duration:.3,ease:r.Lj.ease},opacity:{duration:.4,ease:r.Lj.ease}}},c={exit:({animateOpacity:e,startingHeight:t,transition:n,transitionEnd:i,delay:o})=>{var a;return{...e&&{opacity:isNumeric(t)?1:0},height:t,transitionEnd:null==i?void 0:i.exit,transition:null!=(a=null==n?void 0:n.exit)?a:r.p$.exit(u.exit,o)}},enter:({animateOpacity:e,endingHeight:t,transition:n,transitionEnd:i,delay:o})=>{var a;return{...e&&{opacity:1},height:t,transitionEnd:null==i?void 0:i.enter,transition:null!=(a=null==n?void 0:n.enter)?a:r.p$.enter(u.enter,o)}}},d=(0,s.forwardRef)((e,t)=>{let{in:n,unmountOnExit:r,animateOpacity:u=!0,startingHeight:d=0,endingHeight:f="auto",style:p,className:h,transition:m,transitionEnd:v,...g}=e,[y,b]=(0,s.useState)(!1);(0,s.useEffect)(()=>{let e=setTimeout(()=>{b(!0)});return()=>clearTimeout(e)},[]),(0,i.ZK)({condition:Number(d)>0&&!!r,message:"startingHeight and unmountOnExit are mutually exclusive. You can't use them together"});let x=parseFloat(d.toString())>0,w={startingHeight:d,endingHeight:f,animateOpacity:u,transition:y?m:{enter:{duration:0}},transitionEnd:{enter:null==v?void 0:v.enter,exit:r?null==v?void 0:v.exit:{...null==v?void 0:v.exit,display:x?"block":"none"}}},k=!r||n,S=n||r?"enter":"exit";return(0,l.jsx)(o.M,{initial:!1,custom:w,children:k&&(0,l.jsx)(a.E.div,{ref:t,...g,className:(0,i.cx)("chakra-collapse",h),style:{overflow:"hidden",display:"block",...p},custom:w,variants:c,initial:!!r&&"exit",animate:S,exit:"exit"})})});d.displayName="Collapse"},20921:function(e,t,n){"use strict";n.d(t,{M:function(){return c},Q:function(){return u}});var r=n(24278),i=n(16465),o=n(62167),a=n(72638),s=n(2265),l=n(57437),u={initial:"exit",animate:"enter",exit:"exit",variants:{exit:({reverse:e,initialScale:t,transition:n,transitionEnd:i,delay:o})=>{var a;return{opacity:0,...e?{scale:t,transitionEnd:null==i?void 0:i.exit}:{transitionEnd:{scale:t,...null==i?void 0:i.exit}},transition:null!=(a=null==n?void 0:n.exit)?a:r.p$.exit(r.Sh.exit,o)}},enter:({transitionEnd:e,transition:t,delay:n})=>{var i;return{opacity:1,scale:1,transition:null!=(i=null==t?void 0:t.enter)?i:r.p$.enter(r.Sh.enter,n),transitionEnd:null==e?void 0:e.enter}}}},c=(0,s.forwardRef)(function(e,t){let{unmountOnExit:n,in:r,reverse:s=!0,initialScale:c=.95,className:d,transition:f,transitionEnd:p,delay:h,...m}=e,v=!n||r&&n,g=r||n?"enter":"exit",y={initialScale:c,reverse:s,transition:f,transitionEnd:p,delay:h};return(0,l.jsx)(o.M,{custom:y,children:v&&(0,l.jsx)(a.E.div,{ref:t,className:(0,i.cx)("chakra-offset-slide",d),...u,animate:g,custom:y,...m})})});c.displayName="ScaleFade"},11243:function(e,t,n){"use strict";n.d(t,{p:function(){return c},u:function(){return u}});var r=n(24278),i=n(16465),o=n(62167),a=n(72638),s=n(2265),l=n(57437),u={initial:"exit",animate:"enter",exit:"exit",variants:{enter:({transition:e,transitionEnd:t,delay:n}={})=>{var i;return{opacity:1,transition:null!=(i=null==e?void 0:e.enter)?i:r.p$.enter(r.Sh.enter,n),transitionEnd:null==t?void 0:t.enter}},exit:({transition:e,transitionEnd:t,delay:n}={})=>{var i;return{opacity:0,transition:null!=(i=null==e?void 0:e.exit)?i:r.p$.exit(r.Sh.exit,n),transitionEnd:null==t?void 0:t.exit}}}},c=(0,s.forwardRef)(function(e,t){let{unmountOnExit:n,in:r,className:s,transition:c,transitionEnd:d,delay:f,...p}=e,h=r||n?"enter":"exit",m=!n||r&&n,v={transition:c,transitionEnd:d,delay:f};return(0,l.jsx)(o.M,{custom:v,children:m&&(0,l.jsx)(a.E.div,{ref:t,className:(0,i.cx)("chakra-fade",s),custom:v,...u,animate:h,...p})})});c.displayName="Fade"},3499:function(e,t,n){"use strict";n.r(t),n.d(t,{Collapse:function(){return r.U},EASINGS:function(){return l.Lj},Fade:function(){return i.p},ScaleFade:function(){return o.M},Slide:function(){return s.M},SlideFade:function(){return a.R},fadeConfig:function(){return i.u},getSlideTransition:function(){return l.js},scaleFadeConfig:function(){return o.Q},slideFadeConfig:function(){return a.X},withDelay:function(){return l.p$}});var r=n(43138),i=n(11243),o=n(20921),a=n(80834),s=n(23002),l=n(24278)},14954:function(e,t,n){"use strict";n.d(t,{N:function(){return r}});var r={border:"0",clip:"rect(0, 0, 0, 0)",height:"1px",width:"1px",margin:"-1px",padding:"0",overflow:"hidden",whiteSpace:"nowrap",position:"absolute"}},42029:function(e,t,n){"use strict";n.r(t),n.d(t,{VisuallyHidden:function(){return o},VisuallyHiddenInput:function(){return a},visuallyHiddenStyle:function(){return r.N}});var r=n(14954),i=n(23145),o=(0,i.chakra)("span",{baseStyle:r.N});o.displayName="VisuallyHidden";var a=(0,i.chakra)("input",{baseStyle:r.N});a.displayName="VisuallyHiddenInput"},26266:function(e,t,n){"use strict";n.d(t,{J0:function(){return i},RJ:function(){return a},ue:function(){return r},v8:function(){return l},ws:function(){return o},yu:function(){return s}});var r={id:8453,network:"base",name:"Base",nativeCurrency:{name:"Base",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://mainnet.base.org"]},public:{http:["https://mainnet.base.org"]}},blockExplorers:{blockscout:{name:"Basescout",url:"https://base.blockscout.com"},default:{name:"Basescan",url:"https://basescan.org"},etherscan:{name:"Basescan",url:"https://basescan.org"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:5022}}},i={id:84531,network:"base-goerli",name:"Base Goerli",nativeCurrency:{name:"Base Goerli",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://goerli.base.org"]},public:{http:["https://goerli.base.org"]}},blockExplorers:{etherscan:{name:"Basescan",url:"https://goerli.basescan.org"},default:{name:"Basescan",url:"https://goerli.basescan.org"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:1376988}},testnet:!0},o={id:5,network:"goerli",name:"Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-goerli.g.alchemy.com/v2"],webSocket:["wss://eth-goerli.g.alchemy.com/v2"]},infura:{http:["https://goerli.infura.io/v3"],webSocket:["wss://goerli.infura.io/ws/v3"]},default:{http:["https://rpc.ankr.com/eth_goerli"]},public:{http:["https://rpc.ankr.com/eth_goerli"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://goerli.etherscan.io"},default:{name:"Etherscan",url:"https://goerli.etherscan.io"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0x56522D00C410a43BFfDF00a9A569489297385790",blockCreated:8765204},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:6507670}},testnet:!0},a={id:1,network:"homestead",name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-mainnet.g.alchemy.com/v2"],webSocket:["wss://eth-mainnet.g.alchemy.com/v2"]},infura:{http:["https://mainnet.infura.io/v3"],webSocket:["wss://mainnet.infura.io/ws/v3"]},default:{http:["https://cloudflare-eth.com"]},public:{http:["https://cloudflare-eth.com"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://etherscan.io"},default:{name:"Etherscan",url:"https://etherscan.io"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0xc0497E381f536Be9ce14B0dD3817cBcAe57d2F62",blockCreated:16966585},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}},s={id:137,name:"Polygon",network:"matic",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{alchemy:{http:["https://polygon-mainnet.g.alchemy.com/v2"],webSocket:["wss://polygon-mainnet.g.alchemy.com/v2"]},infura:{http:["https://polygon-mainnet.infura.io/v3"],webSocket:["wss://polygon-mainnet.infura.io/ws/v3"]},default:{http:["https://polygon-rpc.com"]},public:{http:["https://polygon-rpc.com"]}},blockExplorers:{etherscan:{name:"PolygonScan",url:"https://polygonscan.com"},default:{name:"PolygonScan",url:"https://polygonscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:25770160}}},l={id:80001,name:"Polygon Mumbai",network:"maticmum",nativeCurrency:{name:"MATIC",symbol:"MATIC",decimals:18},rpcUrls:{alchemy:{http:["https://polygon-mumbai.g.alchemy.com/v2"],webSocket:["wss://polygon-mumbai.g.alchemy.com/v2"]},infura:{http:["https://polygon-mumbai.infura.io/v3"],webSocket:["wss://polygon-mumbai.infura.io/ws/v3"]},default:{http:["https://matic-mumbai.chainstacklabs.com"]},public:{http:["https://matic-mumbai.chainstacklabs.com"]}},blockExplorers:{etherscan:{name:"PolygonScan",url:"https://mumbai.polygonscan.com"},default:{name:"PolygonScan",url:"https://mumbai.polygonscan.com"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:25770160}},testnet:!0}},12005:function(e,t,n){"use strict";function infuraProvider({apiKey:e}){return function(t){let n=t.rpcUrls.infura?.http[0],r=t.rpcUrls.infura?.webSocket?.[0];return n?{chain:{...t,rpcUrls:{...t.rpcUrls,default:{http:[`${n}/${e}`]}}},rpcUrls:{http:[`${n}/${e}`],webSocket:[`${r}/${e}`]}}:null}}n.d(t,{$:function(){return infuraProvider}})},29522:function(e,t,n){"use strict";n.d(t,{BT:function(){return trackFocusVisible}});var isDom=()=>"undefined"!=typeof document,r=!1,i=null,o=!1,a=!1,s=new Set;function trigger(e,t){s.forEach(n=>n(e,t))}var l="undefined"!=typeof window&&null!=window.navigator&&/^Mac/.test(window.navigator.platform);function onKeyboardEvent(e){o=!0,e.metaKey||!l&&e.altKey||e.ctrlKey||"Control"===e.key||"Shift"===e.key||"Meta"===e.key||(i="keyboard",trigger("keyboard",e))}function onPointerEvent(e){if(i="pointer","mousedown"===e.type||"pointerdown"===e.type){o=!0;let t=e.composedPath?e.composedPath()[0]:e.target,n=!1;try{n=t.matches(":focus-visible")}catch{}n||trigger("pointer",e)}}function onClickEvent(e){(0===e.mozInputSource&&e.isTrusted||0===e.detail&&!e.pointerType)&&(o=!0,i="virtual")}function onWindowFocus(e){e.target!==window&&e.target!==document&&(o||a||(i="virtual",trigger("virtual",e)),o=!1,a=!1)}function onWindowBlur(){o=!1,a=!0}function isFocusVisible(){return"pointer"!==i}function trackFocusVisible(e){!function(){if(!isDom()||r)return;let{focus:e}=HTMLElement.prototype;HTMLElement.prototype.focus=function(...t){o=!0,e.apply(this,t)},document.addEventListener("keydown",onKeyboardEvent,!0),document.addEventListener("keyup",onKeyboardEvent,!0),document.addEventListener("click",onClickEvent,!0),window.addEventListener("focus",onWindowFocus,!0),window.addEventListener("blur",onWindowBlur,!1),"undefined"!=typeof PointerEvent?(document.addEventListener("pointerdown",onPointerEvent,!0),document.addEventListener("pointermove",onPointerEvent,!0),document.addEventListener("pointerup",onPointerEvent,!0)):(document.addEventListener("mousedown",onPointerEvent,!0),document.addEventListener("mousemove",onPointerEvent,!0),document.addEventListener("mouseup",onPointerEvent,!0)),r=!0}(),e(isFocusVisible());let handler=()=>e(isFocusVisible());return s.add(handler),()=>{s.delete(handler)}}},62167:function(e,t,n){"use strict";n.d(t,{M:function(){return AnimatePresence}});var r=n(2265),i=n(538);function useIsMounted(){let e=(0,r.useRef)(!1);return(0,i.L)(()=>(e.current=!0,()=>{e.current=!1}),[]),e}var o=n(72363),a=n(38243),s=n(10961);let PopChildMeasure=class PopChildMeasure extends r.Component{getSnapshotBeforeUpdate(e){let t=this.props.childRef.current;if(t&&e.isPresent&&!this.props.isPresent){let e=this.props.sizeRef.current;e.height=t.offsetHeight||0,e.width=t.offsetWidth||0,e.top=t.offsetTop,e.left=t.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}};function PopChild({children:e,isPresent:t}){let n=(0,r.useId)(),i=(0,r.useRef)(null),o=(0,r.useRef)({width:0,height:0,top:0,left:0});return(0,r.useInsertionEffect)(()=>{let{width:e,height:r,top:a,left:s}=o.current;if(t||!i.current||!e||!r)return;i.current.dataset.motionPopId=n;let l=document.createElement("style");return document.head.appendChild(l),l.sheet&&l.sheet.insertRule(` + [data-motion-pop-id="${n}"] { + position: absolute !important; + width: ${e}px !important; + height: ${r}px !important; + top: ${a}px !important; + left: ${s}px !important; + } + `),()=>{document.head.removeChild(l)}},[t]),r.createElement(PopChildMeasure,{isPresent:t,childRef:i,sizeRef:o},r.cloneElement(e,{ref:i}))}let PresenceChild=({children:e,initial:t,isPresent:n,onExitComplete:i,custom:o,presenceAffectsLayout:l,mode:u})=>{let c=(0,s.h)(newChildrenMap),d=(0,r.useId)(),f=(0,r.useMemo)(()=>({id:d,initial:t,isPresent:n,custom:o,onExitComplete:e=>{for(let t of(c.set(e,!0),c.values()))if(!t)return;i&&i()},register:e=>(c.set(e,!1),()=>c.delete(e))}),l?void 0:[n]);return(0,r.useMemo)(()=>{c.forEach((e,t)=>c.set(t,!1))},[n]),r.useEffect(()=>{n||c.size||!i||i()},[n]),"popLayout"===u&&(e=r.createElement(PopChild,{isPresent:n},e)),r.createElement(a.O.Provider,{value:f},e)};function newChildrenMap(){return new Map}var l=n(781),u=n(46567);let getChildKey=e=>e.key||"",AnimatePresence=({children:e,custom:t,initial:n=!0,onExitComplete:a,exitBeforeEnter:s,presenceAffectsLayout:c=!0,mode:d="sync"})=>{var f;(0,u.k)(!s,"Replace exitBeforeEnter with mode='wait'");let p=(0,r.useContext)(l.p).forceRender||function(){let e=useIsMounted(),[t,n]=(0,r.useState)(0),i=(0,r.useCallback)(()=>{e.current&&n(t+1)},[t]),a=(0,r.useCallback)(()=>o.Wi.postRender(i),[i]);return[a,t]}()[0],h=useIsMounted(),m=function(e){let t=[];return r.Children.forEach(e,e=>{(0,r.isValidElement)(e)&&t.push(e)}),t}(e),v=m,g=(0,r.useRef)(new Map).current,y=(0,r.useRef)(v),b=(0,r.useRef)(new Map).current,x=(0,r.useRef)(!0);if((0,i.L)(()=>{x.current=!1,function(e,t){e.forEach(e=>{let n=getChildKey(e);t.set(n,e)})}(m,b),y.current=v}),f=()=>{x.current=!0,b.clear(),g.clear()},(0,r.useEffect)(()=>()=>f(),[]),x.current)return r.createElement(r.Fragment,null,v.map(e=>r.createElement(PresenceChild,{key:getChildKey(e),isPresent:!0,initial:!!n&&void 0,presenceAffectsLayout:c,mode:d},e)));v=[...v];let w=y.current.map(getChildKey),k=m.map(getChildKey),S=w.length;for(let e=0;e{if(-1!==k.indexOf(n))return;let i=b.get(n);if(!i)return;let o=w.indexOf(n),s=e;s||(s=r.createElement(PresenceChild,{key:getChildKey(i),isPresent:!1,onExitComplete:()=>{b.delete(n),g.delete(n);let e=y.current.findIndex(e=>e.key===n);if(y.current.splice(e,1),!g.size){if(y.current=m,!1===h.current)return;p(),a&&a()}},custom:t,presenceAffectsLayout:c,mode:d},i),g.set(n,s)),v.splice(o,0,s)}),v=v.map(e=>{let t=e.key;return g.has(t)?e:r.createElement(PresenceChild,{key:getChildKey(e),isPresent:!0,presenceAffectsLayout:c,mode:d},e)}),r.createElement(r.Fragment,null,g.size?v:v.map(e=>(0,r.cloneElement)(e)))}},77196:function(e,t,n){"use strict";n.d(t,{hO:function(){return useIsPresent},oO:function(){return usePresence}});var r=n(2265),i=n(38243);function usePresence(){let e=(0,r.useContext)(i.O);if(null===e)return[!0,null];let{isPresent:t,onExitComplete:n,register:o}=e,a=(0,r.useId)();return(0,r.useEffect)(()=>o(a),[]),!t&&n?[!1,()=>n&&n(a)]:[!0]}function useIsPresent(){var e;return null===(e=(0,r.useContext)(i.O))||e.isPresent}},781:function(e,t,n){"use strict";n.d(t,{p:function(){return i}});var r=n(2265);let i=(0,r.createContext)({})},38243:function(e,t,n){"use strict";n.d(t,{O:function(){return i}});var r=n(2265);let i=(0,r.createContext)(null)},72363:function(e,t,n){"use strict";n.d(t,{Pn:function(){return a},Wi:function(){return o},frameData:function(){return s},S6:function(){return l}});var r=n(26977);let Queue=class Queue{constructor(){this.order=[],this.scheduled=new Set}add(e){if(!this.scheduled.has(e))return this.scheduled.add(e),this.order.push(e),!0}remove(e){let t=this.order.indexOf(e);-1!==t&&(this.order.splice(t,1),this.scheduled.delete(e))}clear(){this.order.length=0,this.scheduled.clear()}};let i=["prepare","read","update","preRender","render","postRender"],{schedule:o,cancel:a,state:s,steps:l}=function(e,t){let n=!1,r=!0,o={delta:0,timestamp:0,isProcessing:!1},a=i.reduce((e,t)=>(e[t]=function(e){let t=new Queue,n=new Queue,r=0,i=!1,o=!1,a=new WeakSet,s={schedule:(e,o=!1,s=!1)=>{let l=s&&i,u=l?t:n;return o&&a.add(e),u.add(e)&&l&&i&&(r=t.order.length),e},cancel:e=>{n.remove(e),a.delete(e)},process:l=>{if(i){o=!0;return}if(i=!0,[t,n]=[n,t],n.clear(),r=t.order.length)for(let n=0;nn=!0),e),{}),processStep=e=>a[e].process(o),processBatch=()=>{let a=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(a-o.timestamp,40),1),o.timestamp=a,o.isProcessing=!0,i.forEach(processStep),o.isProcessing=!1,n&&t&&(r=!1,e(processBatch))},wake=()=>{n=!0,r=!0,o.isProcessing||e(processBatch)},s=i.reduce((e,t)=>{let r=a[t];return e[t]=(e,t=!1,i=!1)=>(n||wake(),r.schedule(e,t,i)),e},{});return{schedule:s,cancel:e=>i.forEach(t=>a[t].cancel(e)),state:o,steps:a}}("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:r.Z,!0)},72638:function(e,t,n){"use strict";let r;n.d(t,{E:function(){return tp}});var i,o,a=n(2265);let s=(0,a.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),l=(0,a.createContext)({});var u=n(38243),c=n(538);let d=(0,a.createContext)({strict:!1});function isRefObject(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function isVariantLabel(e){return"string"==typeof e||Array.isArray(e)}function isAnimationControls(e){return"object"==typeof e&&"function"==typeof e.start}let f=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],p=["initial",...f];function isControllingVariants(e){return isAnimationControls(e.animate)||p.some(t=>isVariantLabel(e[t]))}function isVariantNode(e){return!!(isControllingVariants(e)||e.variants)}function variantLabelsAsDependency(e){return Array.isArray(e)?e.join(" "):e}let h={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},m={};for(let e in h)m[e]={isEnabled:t=>h[e].some(e=>!!t[e])};var v=n(16613),g=n(781);let y=(0,a.createContext)({}),b=Symbol.for("motionComponentSymbol"),x=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function isSVGComponent(e){if("string"!=typeof e||e.includes("-"));else if(x.indexOf(e)>-1||/[A-Z]/.test(e))return!0;return!1}let w={},k=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],S=new Set(k);function isForcedMotionValue(e,{layout:t,layoutId:n}){return S.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!w[e]||"opacity"===e)}let isMotionValue=e=>!!(e&&e.getVelocity),C={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},E=k.length,checkStringStartsWith=e=>t=>"string"==typeof t&&t.startsWith(e),P=checkStringStartsWith("--"),T=checkStringStartsWith("var(--"),getValueAsType=(e,t)=>t&&"number"==typeof e?t.transform(e):e,clamp=(e,t,n)=>Math.min(Math.max(n,e),t),A={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},M={...A,transform:e=>clamp(0,1,e)},_={...A,default:1},sanitize=e=>Math.round(1e5*e)/1e5,N=/(-)?([\d]*\.?[\d])+/g,R=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,D=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function isString(e){return"string"==typeof e}let createUnitType=e=>({test:t=>isString(t)&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),I=createUnitType("deg"),j=createUnitType("%"),L=createUnitType("px"),O=createUnitType("vh"),F=createUnitType("vw"),V={...j,parse:e=>j.parse(e)/100,transform:e=>j.transform(100*e)},B={...A,transform:Math.round},W={borderWidth:L,borderTopWidth:L,borderRightWidth:L,borderBottomWidth:L,borderLeftWidth:L,borderRadius:L,radius:L,borderTopLeftRadius:L,borderTopRightRadius:L,borderBottomRightRadius:L,borderBottomLeftRadius:L,width:L,maxWidth:L,height:L,maxHeight:L,size:L,top:L,right:L,bottom:L,left:L,padding:L,paddingTop:L,paddingRight:L,paddingBottom:L,paddingLeft:L,margin:L,marginTop:L,marginRight:L,marginBottom:L,marginLeft:L,rotate:I,rotateX:I,rotateY:I,rotateZ:I,scale:_,scaleX:_,scaleY:_,scaleZ:_,skew:I,skewX:I,skewY:I,distance:L,translateX:L,translateY:L,translateZ:L,x:L,y:L,z:L,perspective:L,transformPerspective:L,opacity:M,originX:V,originY:V,originZ:L,zIndex:B,fillOpacity:M,strokeOpacity:M,numOctaves:B};function buildHTMLStyles(e,t,n,r){let{style:i,vars:o,transform:a,transformOrigin:s}=e,l=!1,u=!1,c=!0;for(let e in t){let n=t[e];if(P(e)){o[e]=n;continue}let r=W[e],d=getValueAsType(n,r);if(S.has(e)){if(l=!0,a[e]=d,!c)continue;n!==(r.default||0)&&(c=!1)}else e.startsWith("origin")?(u=!0,s[e]=d):i[e]=d}if(!t.transform&&(l||r?i.transform=function(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,i){let o="";for(let t=0;t({style:{},transform:{},transformOrigin:{},vars:{}});function copyRawValuesOnly(e,t,n){for(let r in t)isMotionValue(t[r])||isForcedMotionValue(r,n)||(e[r]=t[r])}function useHTMLProps(e,t,n){let r={},i=function(e,t,n){let r=e.style||{},i={};return copyRawValuesOnly(i,r,e),Object.assign(i,function({transformTemplate:e},t,n){return(0,a.useMemo)(()=>{let r=createHtmlRenderState();return buildHTMLStyles(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}(e,t,n)),e.transformValues?e.transformValues(i):i}(e,t,n);return e.drag&&!1!==e.dragListener&&(r.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=!0===e.drag?"none":`pan-${"x"===e.drag?"y":"x"}`),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=i,r}let $=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","transformValues","custom","inherit","onLayoutAnimationStart","onLayoutAnimationComplete","onLayoutMeasure","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","ignoreStrict","viewport"]);function isValidMotionProp(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||$.has(e)}let shouldForward=e=>!isValidMotionProp(e);try{(i=require("@emotion/is-prop-valid").default)&&(shouldForward=e=>e.startsWith("on")?!isValidMotionProp(e):i(e))}catch(e){}function calcOrigin(e,t,n){return"string"==typeof e?e:L.transform(t+n*e)}let U={offset:"stroke-dashoffset",array:"stroke-dasharray"},H={offset:"strokeDashoffset",array:"strokeDasharray"};function buildSVGAttrs(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:o,pathLength:a,pathSpacing:s=1,pathOffset:l=0,...u},c,d,f){if(buildHTMLStyles(e,u,c,f),d){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:p,style:h,dimensions:m}=e;p.transform&&(m&&(h.transform=p.transform),delete p.transform),m&&(void 0!==i||void 0!==o||h.transform)&&(h.transformOrigin=function(e,t,n){let r=calcOrigin(t,e.x,e.width),i=calcOrigin(n,e.y,e.height);return`${r} ${i}`}(m,void 0!==i?i:.5,void 0!==o?o:.5)),void 0!==t&&(p.x=t),void 0!==n&&(p.y=n),void 0!==r&&(p.scale=r),void 0!==a&&function(e,t,n=1,r=0,i=!0){e.pathLength=1;let o=i?U:H;e[o.offset]=L.transform(-r);let a=L.transform(t),s=L.transform(n);e[o.array]=`${a} ${s}`}(p,a,s,l,!1)}let createSvgRenderState=()=>({...createHtmlRenderState(),attrs:{}}),isSVGTag=e=>"string"==typeof e&&"svg"===e.toLowerCase();function useSVGProps(e,t,n,r){let i=(0,a.useMemo)(()=>{let n=createSvgRenderState();return buildSVGAttrs(n,t,{enableHardwareAcceleration:!1},isSVGTag(r),e.transformTemplate),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let t={};copyRawValuesOnly(t,e.style,e),i.style={...t,...i.style}}return i}let camelToDash=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase();function renderHTML(e,{style:t,vars:n},r,i){for(let o in Object.assign(e.style,t,i&&i.getProjectionStyles(r)),n)e.style.setProperty(o,n[o])}let z=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function renderSVG(e,t,n,r){for(let n in renderHTML(e,t,void 0,r),t.attrs)e.setAttribute(z.has(n)?n:camelToDash(n),t.attrs[n])}function scrapeMotionValuesFromProps(e,t){let{style:n}=e,r={};for(let i in n)(isMotionValue(n[i])||t.style&&isMotionValue(t.style[i])||isForcedMotionValue(i,e))&&(r[i]=n[i]);return r}function scrape_motion_values_scrapeMotionValuesFromProps(e,t){let n=scrapeMotionValuesFromProps(e,t);for(let r in e)if(isMotionValue(e[r])||isMotionValue(t[r])){let t=-1!==k.indexOf(r)?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[t]=e[r]}return n}function resolveVariantFromProps(e,t,n,r={},i={}){return"function"==typeof t&&(t=t(void 0!==n?n:e.custom,r,i)),"string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t&&(t=t(void 0!==n?n:e.custom,r,i)),t}var G=n(10961);let isKeyframesTarget=e=>Array.isArray(e),isCustomValue=e=>!!(e&&"object"==typeof e&&e.mix&&e.toValue),resolveFinalValueInKeyframes=e=>isKeyframesTarget(e)?e[e.length-1]||0:e;function resolveMotionValue(e){let t=isMotionValue(e)?e.get():e;return isCustomValue(t)?t.toValue():t}let makeUseVisualState=e=>(t,n)=>{let r=(0,a.useContext)(l),i=(0,a.useContext)(u.O),make=()=>(function({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,i,o){let a={latestValues:function(e,t,n,r){let i={},o=r(e,{});for(let e in o)i[e]=resolveMotionValue(o[e]);let{initial:a,animate:s}=e,l=isControllingVariants(e),u=isVariantNode(e);t&&u&&!l&&!1!==e.inherit&&(void 0===a&&(a=t.initial),void 0===s&&(s=t.animate));let c=!!n&&!1===n.initial;c=c||!1===a;let d=c?s:a;if(d&&"boolean"!=typeof d&&!isAnimationControls(d)){let t=Array.isArray(d)?d:[d];t.forEach(t=>{let n=resolveVariantFromProps(e,t);if(!n)return;let{transitionEnd:r,transition:o,...a}=n;for(let e in a){let t=a[e];if(Array.isArray(t)){let e=c?t.length-1:0;t=t[e]}null!==t&&(i[e]=t)}for(let e in r)i[e]=r[e]})}return i}(r,i,o,e),renderState:t()};return n&&(a.mount=e=>n(r,e,a)),a})(e,t,r,i);return n?make():(0,G.h)(make)};var q=n(72363);let K={useVisualState:makeUseVisualState({scrapeMotionValuesFromProps:scrape_motion_values_scrapeMotionValuesFromProps,createRenderState:createSvgRenderState,onMount:(e,t,{renderState:n,latestValues:r})=>{q.Wi.read(()=>{try{n.dimensions="function"==typeof t.getBBox?t.getBBox():t.getBoundingClientRect()}catch(e){n.dimensions={x:0,y:0,width:0,height:0}}}),q.Wi.render(()=>{buildSVGAttrs(n,r,{enableHardwareAcceleration:!1},isSVGTag(t.tagName),e.transformTemplate),renderSVG(t,n)})}})},X={useVisualState:makeUseVisualState({scrapeMotionValuesFromProps:scrapeMotionValuesFromProps,createRenderState:createHtmlRenderState})};function addDomEvent(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}let isPrimaryPointer=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary;function extractEventInfo(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}let addPointerInfo=e=>t=>isPrimaryPointer(t)&&e(t,extractEventInfo(t));function addPointerEvent(e,t,n,r){return addDomEvent(e,t,addPointerInfo(n),r)}let combineFunctions=(e,t)=>n=>t(e(n)),pipe=(...e)=>e.reduce(combineFunctions);function createLock(e){let t=null;return()=>null===t&&(t=e,()=>{t=null})}let Z=createLock("dragHorizontal"),Y=createLock("dragVertical");function getGlobalLock(e){let t=!1;if("y"===e)t=Y();else if("x"===e)t=Z();else{let e=Z(),n=Y();e&&n?t=()=>{e(),n()}:(e&&e(),n&&n())}return t}function isDragActive(){let e=getGlobalLock(!0);return!e||(e(),!1)}let Feature=class Feature{constructor(e){this.isMounted=!1,this.node=e}update(){}};function addHoverEvent(e,t){let n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End");return addPointerEvent(e.current,n,(n,i)=>{if("touch"===n.type||isDragActive())return;let o=e.getProps();e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",t),o[r]&&q.Wi.update(()=>o[r](n,i))},{passive:!e.getProps()[r]})}let isNodeOrChild=(e,t)=>!!t&&(e===t||isNodeOrChild(e,t.parentElement));var Q=n(26977);function fireSyntheticPointerEvent(e,t){if(!t)return;let n=new PointerEvent("pointer"+e);t(n,extractEventInfo(n))}let J=new WeakMap,ee=new WeakMap,fireObserverCallback=e=>{let t=J.get(e.target);t&&t(e)},fireAllObserverCallbacks=e=>{e.forEach(fireObserverCallback)},et={some:0,all:1};function shallowCompare(e,t){if(!Array.isArray(t))return!1;let n=t.length;if(n!==e.length)return!1;for(let r=0;rt[n]=e.get()),t}(e),function(e){let t={};return e.values.forEach((e,n)=>t[n]=e.getVelocity()),t}(e))}let en="data-"+camelToDash("framerAppearId");var er=n(46567);let secondsToMilliseconds=e=>1e3*e,millisecondsToSeconds=e=>e/1e3,ei={current:!1},isBezierDefinition=e=>Array.isArray(e)&&"number"==typeof e[0],cubicBezierAsString=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,eo={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:cubicBezierAsString([0,.65,.55,1]),circOut:cubicBezierAsString([.55,0,1,.45]),backIn:cubicBezierAsString([.31,.01,.66,-.59]),backOut:cubicBezierAsString([.33,1.53,.69,.99])},calcBezier=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function cubicBezier(e,t,n,r){if(e===t&&n===r)return Q.Z;let getTForX=t=>(function(e,t,n,r,i){let o,a;let s=0;do(o=calcBezier(a=t+(n-t)/2,r,i)-e)>0?n=a:t=a;while(Math.abs(o)>1e-7&&++s<12);return a})(t,0,1,e,n);return e=>0===e||1===e?e:calcBezier(getTForX(e),t,r)}let ea=cubicBezier(.42,0,1,1),es=cubicBezier(0,0,.58,1),el=cubicBezier(.42,0,.58,1),isEasingArray=e=>Array.isArray(e)&&"number"!=typeof e[0],mirrorEasing=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,reverseEasing=e=>t=>1-e(1-t),circIn=e=>1-Math.sin(Math.acos(e)),eu=reverseEasing(circIn),ec=mirrorEasing(eu),ed=cubicBezier(.33,1.53,.69,.99),ef=reverseEasing(ed),ep=mirrorEasing(ef),eh={linear:Q.Z,easeIn:ea,easeInOut:el,easeOut:es,circIn:circIn,circInOut:ec,circOut:eu,backIn:ef,backInOut:ep,backOut:ed,anticipate:e=>(e*=2)<1?.5*ef(e):.5*(2-Math.pow(2,-10*(e-1)))},easingDefinitionToFunction=e=>{if(Array.isArray(e)){(0,er.k)(4===e.length,"Cubic bezier arrays must contain four numerical values.");let[t,n,r,i]=e;return cubicBezier(t,n,r,i)}return"string"==typeof e?((0,er.k)(void 0!==eh[e],`Invalid easing type '${e}'`),eh[e]):e},isColorString=(e,t)=>n=>!!(isString(n)&&D.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),splitColor=(e,t,n)=>r=>{if(!isString(r))return r;let[i,o,a,s]=r.match(N);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(a),alpha:void 0!==s?parseFloat(s):1}},clampRgbUnit=e=>clamp(0,255,e),em={...A,transform:e=>Math.round(clampRgbUnit(e))},ev={test:isColorString("rgb","red"),parse:splitColor("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+em.transform(e)+", "+em.transform(t)+", "+em.transform(n)+", "+sanitize(M.transform(r))+")"},eg={test:isColorString("#"),parse:function(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}},transform:ev.transform},ey={test:isColorString("hsl","hue"),parse:splitColor("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+j.transform(sanitize(t))+", "+j.transform(sanitize(n))+", "+sanitize(M.transform(r))+")"},eb={test:e=>ev.test(e)||eg.test(e)||ey.test(e),parse:e=>ev.test(e)?ev.parse(e):ey.test(e)?ey.parse(e):eg.parse(e),transform:e=>isString(e)?e:e.hasOwnProperty("red")?ev.transform(e):ey.transform(e)},mix=(e,t,n)=>-n*e+n*t+e;function hueToRgb(e,t,n){return(n<0&&(n+=1),n>1&&(n-=1),n<1/6)?e+(t-e)*6*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}let mixLinearColor=(e,t,n)=>{let r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},ex=[eg,ev,ey],getColorType=e=>ex.find(t=>t.test(e));function asRGBA(e){let t=getColorType(e);(0,er.k)(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`);let n=t.parse(e);return t===ey&&(n=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let i=0,o=0,a=0;if(t/=100){let r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;i=hueToRgb(s,r,e+1/3),o=hueToRgb(s,r,e),a=hueToRgb(s,r,e-1/3)}else i=o=a=n;return{red:Math.round(255*i),green:Math.round(255*o),blue:Math.round(255*a),alpha:r}}(n)),n}let mixColor=(e,t)=>{let n=asRGBA(e),r=asRGBA(t),i={...n};return e=>(i.red=mixLinearColor(n.red,r.red,e),i.green=mixLinearColor(n.green,r.green,e),i.blue=mixLinearColor(n.blue,r.blue,e),i.alpha=mix(n.alpha,r.alpha,e),ev.transform(i))},ew={regex:/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,countKey:"Vars",token:"${v}",parse:Q.Z},ek={regex:R,countKey:"Colors",token:"${c}",parse:eb.parse},eS={regex:N,countKey:"Numbers",token:"${n}",parse:A.parse};function tokenise(e,{regex:t,countKey:n,token:r,parse:i}){let o=e.tokenised.match(t);o&&(e["num"+n]=o.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...o.map(i)))}function analyseComplexValue(e){let t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&tokenise(n,ew),tokenise(n,ek),tokenise(n,eS),n}function parseComplexValue(e){return analyseComplexValue(e).values}function createTransformer(e){let{values:t,numColors:n,numVars:r,tokenised:i}=analyseComplexValue(e),o=t.length;return e=>{let t=i;for(let i=0;i"number"==typeof e?0:e,eC={test:function(e){var t,n;return isNaN(e)&&isString(e)&&((null===(t=e.match(N))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(R))||void 0===n?void 0:n.length)||0)>0},parse:parseComplexValue,createTransformer,getAnimatableNone:function(e){let t=parseComplexValue(e),n=createTransformer(e);return n(t.map(convertNumbersToZero))}},mixImmediate=(e,t)=>n=>`${n>0?t:e}`;function getMixer(e,t){return"number"==typeof e?n=>mix(e,t,n):eb.test(e)?mixColor(e,t):e.startsWith("var(")?mixImmediate(e,t):mixComplex(e,t)}let mixArray=(e,t)=>{let n=[...e],r=n.length,i=e.map((e,n)=>getMixer(e,t[n]));return e=>{for(let t=0;t{let n={...e,...t},r={};for(let i in n)void 0!==e[i]&&void 0!==t[i]&&(r[i]=getMixer(e[i],t[i]));return e=>{for(let t in r)n[t]=r[t](e);return n}},mixComplex=(e,t)=>{let n=eC.createTransformer(t),r=analyseComplexValue(e),i=analyseComplexValue(t),o=r.numVars===i.numVars&&r.numColors===i.numColors&&r.numNumbers>=i.numNumbers;return o?pipe(mixArray(r.values,i.values),n):((0,er.K)(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),mixImmediate(e,t))},progress=(e,t,n)=>{let r=t-e;return 0===r?1:(n-e)/r},mixNumber=(e,t)=>n=>mix(e,t,n);function interpolate(e,t,{clamp:n=!0,ease:r,mixer:i}={}){let o=e.length;if((0,er.k)(o===t.length,"Both input and output ranges must be the same length"),1===o)return()=>t[0];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());let a=function(e,t,n){let r=[],i=n||function(e){if("number"==typeof e);else if("string"==typeof e)return eb.test(e)?mixColor:mixComplex;else if(Array.isArray(e))return mixArray;else if("object"==typeof e)return mixObject;return mixNumber}(e[0]),o=e.length-1;for(let n=0;n{let n=0;if(s>1)for(;ninterpolator(clamp(e[0],e[o-1],t)):interpolator}function keyframes({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){let i=isEasingArray(r)?r.map(easingDefinitionToFunction):easingDefinitionToFunction(r),o={done:!1,value:t[0]},a=(n&&n.length===t.length?n:function(e){let t=[0];return function(e,t){let n=e[e.length-1];for(let r=1;r<=t;r++){let i=progress(0,t,r);e.push(mix(n,1,i))}}(t,e.length-1),t}(t)).map(t=>t*e),s=interpolate(a,t,{ease:Array.isArray(i)?i:t.map(()=>i||el).splice(0,t.length-1)});return{calculatedDuration:e,next:t=>(o.value=s(t),o.done=t>=e,o)}}function calcGeneratorVelocity(e,t,n){var r,i;let o=Math.max(t-5,0);return r=n-e(o),(i=t-o)?r*(1e3/i):0}function calcAngularFreq(e,t){return e*Math.sqrt(1-t*t)}let eE=["duration","bounce"],eP=["stiffness","damping","mass"];function isSpringType(e,t){return t.some(t=>void 0!==e[t])}function spring({keyframes:e,restDelta:t,restSpeed:n,...r}){let i;let o=e[0],a=e[e.length-1],s={done:!1,value:o},{stiffness:l,damping:u,mass:c,velocity:d,duration:f,isResolvedFromDuration:p}=function(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!isSpringType(e,eP)&&isSpringType(e,eE)){let n=function({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,o;(0,er.K)(e<=secondsToMilliseconds(10),"Spring duration must be 10 seconds or less");let a=1-t;a=clamp(.05,1,a),e=clamp(.01,10,millisecondsToSeconds(e)),a<1?(i=t=>{let r=t*a,i=r*e,o=calcAngularFreq(t,a);return .001-(r-n)/o*Math.exp(-i)},o=t=>{let r=t*a,o=r*e,s=Math.pow(a,2)*Math.pow(t,2)*e,l=calcAngularFreq(Math.pow(t,2),a),u=-i(t)+.001>0?-1:1;return u*((o*n+n-s)*Math.exp(-o))/l}):(i=t=>{let r=Math.exp(-t*e),i=(t-n)*e+1;return -.001+r*i},o=t=>{let r=Math.exp(-t*e),i=(n-t)*(e*e);return r*i});let s=5/e,l=function(e,t,n){let r=n;for(let n=1;n<12;n++)r-=e(r)/t(r);return r}(i,o,s);if(e=secondsToMilliseconds(e),isNaN(l))return{stiffness:100,damping:10,duration:e};{let t=Math.pow(l,2)*r;return{stiffness:t,damping:2*a*Math.sqrt(r*t),duration:e}}}(e);(t={...t,...n,velocity:0,mass:1}).isResolvedFromDuration=!0}return t}(r),h=d?-millisecondsToSeconds(d):0,m=u/(2*Math.sqrt(l*c)),v=a-o,g=millisecondsToSeconds(Math.sqrt(l/c)),y=5>Math.abs(v);if(n||(n=y?.01:2),t||(t=y?.005:.5),m<1){let e=calcAngularFreq(g,m);i=t=>{let n=Math.exp(-m*g*t);return a-n*((h+m*g*v)/e*Math.sin(e*t)+v*Math.cos(e*t))}}else if(1===m)i=e=>a-Math.exp(-g*e)*(v+(h+g*v)*e);else{let e=g*Math.sqrt(m*m-1);i=t=>{let n=Math.exp(-m*g*t),r=Math.min(e*t,300);return a-n*((h+m*g*v)*Math.sinh(r)+e*v*Math.cosh(r))/e}}return{calculatedDuration:p&&f||null,next:e=>{let r=i(e);if(p)s.done=e>=f;else{let o=h;0!==e&&(o=m<1?calcGeneratorVelocity(i,e,r):0);let l=Math.abs(o)<=n,u=Math.abs(a-r)<=t;s.done=l&&u}return s.value=s.done?a:r,s}}}function inertia({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:a,min:s,max:l,restDelta:u=.5,restSpeed:c}){let d,f;let p=e[0],h={done:!1,value:p},isOutOfBounds=e=>void 0!==s&&el,nearestBoundary=e=>void 0===s?l:void 0===l?s:Math.abs(s-e)-m*Math.exp(-e/r),calcLatest=e=>g+calcDelta(e),applyFriction=e=>{let t=calcDelta(e),n=calcLatest(e);h.done=Math.abs(t)<=u,h.value=h.done?g:n},checkCatchBoundary=e=>{isOutOfBounds(h.value)&&(d=e,f=spring({keyframes:[h.value,nearestBoundary(h.value)],velocity:calcGeneratorVelocity(calcLatest,e,h.value),damping:i,stiffness:o,restDelta:u,restSpeed:c}))};return checkCatchBoundary(0),{calculatedDuration:null,next:e=>{let t=!1;return(f||void 0!==d||(t=!0,applyFriction(e),checkCatchBoundary(e)),void 0!==d&&e>d)?f.next(e-d):(t||applyFriction(e),h)}}}let frameloopDriver=e=>{let passTimestamp=({timestamp:t})=>e(t);return{start:()=>q.Wi.update(passTimestamp,!0),stop:()=>(0,q.Pn)(passTimestamp),now:()=>q.frameData.isProcessing?q.frameData.timestamp:performance.now()}};function calcGeneratorDuration(e){let t=0,n=e.next(t);for(;!n.done&&t<2e4;)t+=50,n=e.next(t);return t>=2e4?1/0:t}let eT={decay:inertia,inertia:inertia,tween:keyframes,keyframes:keyframes,spring:spring};function animateValue({autoplay:e=!0,delay:t=0,driver:n=frameloopDriver,keyframes:r,type:i="keyframes",repeat:o=0,repeatDelay:a=0,repeatType:s="loop",onPlay:l,onStop:u,onComplete:c,onUpdate:d,...f}){let p,h,m,v,g,y=1,b=!1,updateFinishedPromise=()=>{h=new Promise(e=>{p=e})};updateFinishedPromise();let x=eT[i]||keyframes;x!==keyframes&&"number"!=typeof r[0]&&(v=interpolate([0,100],r,{clamp:!1}),r=[0,100]);let w=x({...f,keyframes:r});"mirror"===s&&(g=x({...f,keyframes:[...r].reverse(),velocity:-(f.velocity||0)}));let k="idle",S=null,C=null,E=null;null===w.calculatedDuration&&o&&(w.calculatedDuration=calcGeneratorDuration(w));let{calculatedDuration:P}=w,T=1/0,A=1/0;null!==P&&(A=(T=P+a)*(o+1)-a);let M=0,tick=e=>{if(null===C)return;y>0&&(C=Math.min(C,e)),y<0&&(C=Math.min(e-A/y,C)),M=null!==S?S:Math.round(e-C)*y;let n=M-t*(y>=0?1:-1),i=y>=0?n<0:n>A;M=Math.max(n,0),"finished"===k&&null===S&&(M=A);let l=M,u=w;if(o){let e=M/T,t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,o+1);let r=!!(t%2);r&&("reverse"===s?(n=1-n,a&&(n-=a/T)):"mirror"===s&&(u=g));let i=clamp(0,1,n);M>A&&(i="reverse"===s&&r?1:0),l=i*T}let c=i?{done:!1,value:r[0]}:u.next(l);v&&(c.value=v(c.value));let{done:f}=c;i||null===P||(f=y>=0?M>=A:M<=0);let p=null===S&&("finished"===k||"running"===k&&f);return d&&d(c.value),p&&finish(),c},stopAnimationDriver=()=>{m&&m.stop(),m=void 0},cancel=()=>{k="idle",stopAnimationDriver(),p(),updateFinishedPromise(),C=E=null},finish=()=>{k="finished",c&&c(),stopAnimationDriver(),p()},play=()=>{if(b)return;m||(m=n(tick));let e=m.now();l&&l(),null!==S?C=e-S:C&&"finished"!==k||(C=e),"finished"===k&&updateFinishedPromise(),E=C,S=null,k="running",m.start()};e&&play();let _={then:(e,t)=>h.then(e,t),get time(){return millisecondsToSeconds(M)},set time(newTime){M=newTime=secondsToMilliseconds(newTime),null===S&&m&&0!==y?C=m.now()-newTime/y:S=newTime},get duration(){let e=null===w.calculatedDuration?calcGeneratorDuration(w):w.calculatedDuration;return millisecondsToSeconds(e)},get speed(){return y},set speed(newSpeed){if(newSpeed===y||!m)return;y=newSpeed,_.time=millisecondsToSeconds(M)},get state(){return k},play,pause:()=>{k="paused",S=M},stop:()=>{b=!0,"idle"!==k&&(k="idle",u&&u(),cancel())},cancel:()=>{null!==E&&tick(E),cancel()},complete:()=>{k="finished"},sample:e=>(C=0,tick(e))};return _}let eA=(o=()=>Object.hasOwnProperty.call(Element.prototype,"animate"),()=>(void 0===r&&(r=o()),r)),eM=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),requiresPregeneratedKeyframes=(e,t)=>"spring"===t.type||"backgroundColor"===e||!function isWaapiSupportedEasing(e){return!!(!e||"string"==typeof e&&eo[e]||isBezierDefinition(e)||Array.isArray(e)&&e.every(isWaapiSupportedEasing))}(t.ease),e_={type:"spring",stiffness:500,damping:25,restSpeed:10},criticallyDampedSpring=e=>({type:"spring",stiffness:550,damping:0===e?2*Math.sqrt(550):30,restSpeed:10}),eN={type:"keyframes",duration:.8},eR={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},getDefaultTransition=(e,{keyframes:t})=>t.length>2?eN:S.has(e)?e.startsWith("scale")?criticallyDampedSpring(t[1]):e_:eR,isAnimatable=(e,t)=>"zIndex"!==e&&!!("number"==typeof t||Array.isArray(t)||"string"==typeof t&&(eC.test(t)||"0"===t)&&!t.startsWith("url(")),eD=new Set(["brightness","contrast","saturate","opacity"]);function applyDefaultFilter(e){let[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;let[r]=n.match(N)||[];if(!r)return e;let i=n.replace(r,""),o=eD.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}let eI=/([a-z-]*)\(.*?\)/g,ej={...eC,getAnimatableNone:e=>{let t=e.match(eI);return t?t.map(applyDefaultFilter).join(" "):e}},eL={...W,color:eb,backgroundColor:eb,outlineColor:eb,fill:eb,stroke:eb,borderColor:eb,borderTopColor:eb,borderRightColor:eb,borderBottomColor:eb,borderLeftColor:eb,filter:ej,WebkitFilter:ej},getDefaultValueType=e=>eL[e];function animatable_none_getAnimatableNone(e,t){let n=getDefaultValueType(e);return n!==ej&&(n=eC),n.getAnimatableNone?n.getAnimatableNone(t):void 0}let isZeroValueString=e=>/^0[^.\s]+$/.test(e);function getValueTransition(e,t){return e[t]||e.default||e}let animateMotionValue=(e,t,n,r={})=>i=>{let o=getValueTransition(r,e)||{},a=o.delay||r.delay||0,{elapsed:s=0}=r;s-=secondsToMilliseconds(a);let l=function(e,t,n,r){let i,o;let a=isAnimatable(t,n);i=Array.isArray(n)?[...n]:[null,n];let s=void 0!==r.from?r.from:e.get(),l=[];for(let e=0;e{t.set(e),o.onUpdate&&o.onUpdate(e)},onComplete:()=>{i(),o.onComplete&&o.onComplete()}};if(!function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:a,repeatDelay:s,from:l,elapsed:u,...c}){return!!Object.keys(c).length}(o)&&(p={...p,...getDefaultTransition(e,p)}),p.duration&&(p.duration=secondsToMilliseconds(p.duration)),p.repeatDelay&&(p.repeatDelay=secondsToMilliseconds(p.repeatDelay)),!d||!f||ei.current||!1===o.type)return function({keyframes:e,delay:t,onUpdate:n,onComplete:r}){let setValue=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:Q.Z,pause:Q.Z,stop:Q.Z,then:e=>(e(),Promise.resolve()),cancel:Q.Z,complete:Q.Z});return t?animateValue({keyframes:[0,1],duration:0,delay:t,onComplete:setValue}):setValue()}(ei.current?{...p,delay:0}:p);if(t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){let n=function(e,t,{onUpdate:n,onComplete:r,...i}){let o,a;let s=eA()&&eM.has(t)&&!i.repeatDelay&&"mirror"!==i.repeatType&&0!==i.damping&&"inertia"!==i.type;if(!s)return!1;let l=!1,updateFinishedPromise=()=>{a=new Promise(e=>{o=e})};updateFinishedPromise();let{keyframes:u,duration:c=300,ease:d,times:f}=i;if(requiresPregeneratedKeyframes(t,i)){let e=animateValue({...i,repeat:0,delay:0}),t={done:!1,value:u[0]},n=[],r=0;for(;!t.done&&r<2e4;)t=e.sample(r),n.push(t.value),r+=10;f=void 0,u=n,c=r-10,d="linear"}let p=function(e,t,n,{delay:r=0,duration:i,repeat:o=0,repeatType:a="loop",ease:s,times:l}={}){let u={[t]:n};l&&(u.offset=l);let c=function mapEasingToNativeEasing(e){if(e)return isBezierDefinition(e)?cubicBezierAsString(e):Array.isArray(e)?e.map(mapEasingToNativeEasing):eo[e]}(s);return Array.isArray(c)&&(u.easing=c),e.animate(u,{delay:r,duration:i,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:o+1,direction:"reverse"===a?"alternate":"normal"})}(e.owner.current,t,u,{...i,duration:c,ease:d,times:f});i.syncStart&&(p.startTime=q.frameData.isProcessing?q.frameData.timestamp:document.timeline?document.timeline.currentTime:performance.now());let cancelAnimation=()=>p.cancel(),safeCancel=()=>{q.Wi.update(cancelAnimation),o(),updateFinishedPromise()};return p.onfinish=()=>{e.set(function(e,{repeat:t,repeatType:n="loop"}){let r=t&&"loop"!==n&&t%2==1?0:e.length-1;return e[r]}(u,i)),r&&r(),safeCancel()},{then:(e,t)=>a.then(e,t),attachTimeline:e=>(p.timeline=e,p.onfinish=null,Q.Z),get time(){return millisecondsToSeconds(p.currentTime||0)},set time(newTime){p.currentTime=secondsToMilliseconds(newTime)},get speed(){return p.playbackRate},set speed(newSpeed){p.playbackRate=newSpeed},get duration(){return millisecondsToSeconds(c)},play:()=>{l||(p.play(),(0,q.Pn)(cancelAnimation))},pause:()=>p.pause(),stop:()=>{if(l=!0,"idle"===p.playState)return;let{currentTime:t}=p;if(t){let n=animateValue({...i,autoplay:!1});e.setWithVelocity(n.sample(t-10).value,n.sample(t).value,10)}safeCancel()},complete:()=>p.finish(),cancel:safeCancel}}(t,e,p);if(n)return n}return animateValue(p)};function isWillChangeMotionValue(e){return!!(isMotionValue(e)&&e.add)}let isNumericalString=e=>/^\-?\d*\.?\d+$/.test(e);function addUniqueItem(e,t){-1===e.indexOf(t)&&e.push(t)}function removeItem(e,t){let n=e.indexOf(t);n>-1&&e.splice(n,1)}let SubscriptionManager=class SubscriptionManager{constructor(){this.subscriptions=[]}add(e){return addUniqueItem(this.subscriptions,e),()=>removeItem(this.subscriptions,e)}notify(e,t,n){let r=this.subscriptions.length;if(r){if(1===r)this.subscriptions[0](e,t,n);else for(let i=0;i!isNaN(parseFloat(e)),eO={current:void 0};let MotionValue=class MotionValue{constructor(e,t={}){this.version="10.16.4",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(e,t=!0)=>{this.prev=this.current,this.current=e;let{delta:n,timestamp:r}=q.frameData;this.lastUpdated!==r&&(this.timeDelta=n,this.lastUpdated=r,q.Wi.postRender(this.scheduleVelocityCheck)),this.prev!==this.current&&this.events.change&&this.events.change.notify(this.current),this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>q.Wi.postRender(this.velocityCheck),this.velocityCheck=({timestamp:e})=>{e!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=e,this.canTrackVelocity=isFloat(this.current),this.owner=t.owner}onChange(e){return this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new SubscriptionManager);let n=this.events[e].add(t);return"change"===e?()=>{n(),q.Wi.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=e,this.timeDelta=n}jump(e){this.updateAndNotify(e),this.prev=e,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return eO.current&&eO.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){var e,t;return this.canTrackVelocity?(e=parseFloat(this.current)-parseFloat(this.prev),(t=this.timeDelta)?e*(1e3/t):0):0}start(e){return this.stop(),new Promise(t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function motionValue(e,t){return new MotionValue(e,t)}let testValueType=e=>t=>t.test(e),eF=[A,L,j,I,F,O,{test:e=>"auto"===e,parse:e=>e}],findDimensionValueType=e=>eF.find(testValueType(e)),eV=[...eF,eb,eC],findValueType=e=>eV.find(testValueType(e));function animateTarget(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o=e.getDefaultTransition(),transitionEnd:a,...s}=e.makeTargetAnimatable(t),l=e.getValue("willChange");r&&(o=r);let u=[],c=i&&e.animationState&&e.animationState.getState()[i];for(let t in s){let r=e.getValue(t),i=s[t];if(!r||void 0===i||c&&function({protectedKeys:e,needsAnimating:t},n){let r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}(c,t))continue;let a={delay:n,elapsed:0,...o};if(window.HandoffAppearAnimations&&!r.hasAnimated){let n=e.getProps()[en];n&&(a.elapsed=window.HandoffAppearAnimations(n,t,r,q.Wi),a.syncStart=!0)}r.start(animateMotionValue(t,r,i,e.shouldReduceMotion&&S.has(t)?{type:!1}:a));let d=r.animation;isWillChangeMotionValue(l)&&(l.add(t),d.then(()=>l.remove(t))),u.push(d)}return a&&Promise.all(u).then(()=>{a&&function(e,t){let n=resolveVariant(e,t),{transitionEnd:r={},transition:i={},...o}=n?e.makeTargetAnimatable(n,!1):{};for(let t in o={...o,...r}){let n=resolveFinalValueInKeyframes(o[t]);e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,motionValue(n))}}(e,a)}),u}function animateVariant(e,t,n={}){let r=resolveVariant(e,t,n.custom),{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);let o=r?()=>Promise.all(animateTarget(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(r=0)=>{let{delayChildren:o=0,staggerChildren:a,staggerDirection:s}=i;return function(e,t,n=0,r=0,i=1,o){let a=[],s=(e.variantChildren.size-1)*r,l=1===i?(e=0)=>e*r:(e=0)=>s-e*r;return Array.from(e.variantChildren).sort(sortByTreeOrder).forEach((e,r)=>{e.notify("AnimationStart",t),a.push(animateVariant(e,t,{...o,delay:n+l(r)}).then(()=>e.notify("AnimationComplete",t)))}),Promise.all(a)}(e,t,o+r,a,s,n)}:()=>Promise.resolve(),{when:s}=i;if(!s)return Promise.all([o(),a(n.delay)]);{let[e,t]="beforeChildren"===s?[o,a]:[a,o];return e().then(()=>t())}}function sortByTreeOrder(e,t){return e.sortNodePosition(t)}let eB=[...f].reverse(),eW=f.length;function createTypeState(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}let e$=0,distance=(e,t)=>Math.abs(e-t);let PanSession=class PanSession{constructor(e,t,{transformPagePoint:n}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let e=getPanInfo(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){let n=distance(e.x,t.x),r=distance(e.y,t.y);return Math.sqrt(n**2+r**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;let{point:r}=e,{timestamp:i}=q.frameData;this.history.push({...r,timestamp:i});let{onStart:o,onMove:a}=this.handlers;t||(o&&o(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),a&&a(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=transformPoint(t,this.transformPagePoint),q.Wi.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{if(this.end(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let{onEnd:n,onSessionEnd:r}=this.handlers,i=getPanInfo("pointercancel"===e.type?this.lastMoveEventInfo:transformPoint(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,i),r&&r(e,i)},!isPrimaryPointer(e))return;this.handlers=t,this.transformPagePoint=n;let r=extractEventInfo(e),i=transformPoint(r,this.transformPagePoint),{point:o}=i,{timestamp:a}=q.frameData;this.history=[{...o,timestamp:a}];let{onSessionStart:s}=t;s&&s(e,getPanInfo(i,this.history)),this.removeListeners=pipe(addPointerEvent(window,"pointermove",this.handlePointerMove),addPointerEvent(window,"pointerup",this.handlePointerUp),addPointerEvent(window,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),(0,q.Pn)(this.updatePoint)}};function transformPoint(e,t){return t?{point:t(e.point)}:e}function subtractPoint(e,t){return{x:e.x-t.x,y:e.y-t.y}}function getPanInfo({point:e},t){return{point:e,delta:subtractPoint(e,lastDevicePoint(t)),offset:subtractPoint(e,t[0]),velocity:function(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=lastDevicePoint(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>secondsToMilliseconds(.1)));)n--;if(!r)return{x:0,y:0};let o=millisecondsToSeconds(i.timestamp-r.timestamp);if(0===o)return{x:0,y:0};let a={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}(t,0)}}function lastDevicePoint(e){return e[e.length-1]}function calcLength(e){return e.max-e.min}function isNear(e,t=0,n=.01){return Math.abs(e-t)<=n}function calcAxisDelta(e,t,n,r=.5){e.origin=r,e.originPoint=mix(t.min,t.max,e.origin),e.scale=calcLength(n)/calcLength(t),(isNear(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=mix(n.min,n.max,e.origin)-e.originPoint,(isNear(e.translate)||isNaN(e.translate))&&(e.translate=0)}function calcBoxDelta(e,t,n,r){calcAxisDelta(e.x,t.x,n.x,r?r.originX:void 0),calcAxisDelta(e.y,t.y,n.y,r?r.originY:void 0)}function calcRelativeAxis(e,t,n){e.min=n.min+t.min,e.max=e.min+calcLength(t)}function calcRelativeAxisPosition(e,t,n){e.min=t.min-n.min,e.max=e.min+calcLength(t)}function calcRelativePosition(e,t,n){calcRelativeAxisPosition(e.x,t.x,n.x),calcRelativeAxisPosition(e.y,t.y,n.y)}function calcRelativeAxisConstraints(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function calcViewportAxisConstraints(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min({translate:0,scale:1,origin:0,originPoint:0}),createDelta=()=>({x:createAxisDelta(),y:createAxisDelta()}),createAxis=()=>({min:0,max:0}),createBox=()=>({x:createAxis(),y:createAxis()});function eachAxis(e){return[e("x"),e("y")]}function convertBoundingBoxToBox({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function isIdentityScale(e){return void 0===e||1===e}function hasScale({scale:e,scaleX:t,scaleY:n}){return!isIdentityScale(e)||!isIdentityScale(t)||!isIdentityScale(n)}function hasTransform(e){return hasScale(e)||has2DTranslate(e)||e.z||e.rotate||e.rotateX||e.rotateY}function has2DTranslate(e){var t,n;return(t=e.x)&&"0%"!==t||(n=e.y)&&"0%"!==n}function applyPointDelta(e,t,n,r,i){return void 0!==i&&(e=r+i*(e-r)),r+n*(e-r)+t}function applyAxisDelta(e,t=0,n=1,r,i){e.min=applyPointDelta(e.min,t,n,r,i),e.max=applyPointDelta(e.max,t,n,r,i)}function applyBoxDelta(e,{x:t,y:n}){applyAxisDelta(e.x,t.translate,t.scale,t.originPoint),applyAxisDelta(e.y,n.translate,n.scale,n.originPoint)}function snapToDefault(e){return Number.isInteger(e)?e:e>1.0000000000001||e<.999999999999?e:1}function translateAxis(e,t){e.min=e.min+t,e.max=e.max+t}function transformAxis(e,t,[n,r,i]){let o=void 0!==t[i]?t[i]:.5,a=mix(e.min,e.max,o);applyAxisDelta(e,t[n],t[r],a,t.scale)}let eU=["x","scaleX","originX"],eH=["y","scaleY","originY"];function transformBox(e,t){transformAxis(e.x,t,eU),transformAxis(e.y,t,eH)}function measureViewportBox(e,t){return convertBoundingBoxToBox(function(e,t){if(!t)return e;let n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}let ez=new WeakMap;let VisualElementDragControls=class VisualElementDragControls{constructor(e){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=createBox(),this.visualElement=e}start(e,{snapToCursor:t=!1}={}){let{presenceContext:n}=this.visualElement;n&&!1===n.isPresent||(this.panSession=new PanSession(e,{onSessionStart:e=>{this.stopAnimation(),t&&this.snapToCursor(extractEventInfo(e,"page").point)},onStart:(e,t)=>{let{drag:n,dragPropagation:r,onDragStart:i}=this.getProps();if(n&&!r&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=getGlobalLock(n),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),eachAxis(e=>{let t=this.getAxisMotionValue(e).get()||0;if(j.test(t)){let{projection:n}=this.visualElement;if(n&&n.layout){let r=n.layout.layoutBox[e];if(r){let e=calcLength(r);t=e*(parseFloat(t)/100)}}}this.originPoint[e]=t}),i&&q.Wi.update(()=>i(e,t),!1,!0);let{animationState:o}=this.visualElement;o&&o.setActive("whileDrag",!0)},onMove:(e,t)=>{let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:o}=this.getProps();if(!n&&!this.openGlobalLock)return;let{offset:a}=t;if(r&&null===this.currentDirection){this.currentDirection=function(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}(a),null!==this.currentDirection&&i&&i(this.currentDirection);return}this.updateAxis("x",t.point,a),this.updateAxis("y",t.point,a),this.visualElement.render(),o&&o(e,t)},onSessionEnd:(e,t)=>this.stop(e,t)},{transformPagePoint:this.visualElement.getTransformPagePoint()}))}stop(e,t){let n=this.isDragging;if(this.cancel(),!n)return;let{velocity:r}=t;this.startAnimation(r);let{onDragEnd:i}=this.getProps();i&&q.Wi.update(()=>i(e,t))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){let{drag:r}=this.getProps();if(!n||!shouldDrag(e,r,this.currentDirection))return;let i=this.getAxisMotionValue(e),o=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(o=function(e,{min:t,max:n},r){return void 0!==t&&en&&(e=r?mix(n,e,r.max):Math.min(e,n)),e}(o,this.constraints[e],this.elastic[e])),i.set(o)}resolveConstraints(){let{dragConstraints:e,dragElastic:t}=this.getProps(),{layout:n}=this.visualElement.projection||{},r=this.constraints;e&&isRefObject(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&n?this.constraints=function(e,{top:t,left:n,bottom:r,right:i}){return{x:calcRelativeAxisConstraints(e.x,n,i),y:calcRelativeAxisConstraints(e.y,t,r)}}(n.layoutBox,e):this.constraints=!1,this.elastic=function(e=.35){return!1===e?e=0:!0===e&&(e=.35),{x:resolveAxisElastic(e,"left","right"),y:resolveAxisElastic(e,"top","bottom")}}(t),r!==this.constraints&&n&&this.constraints&&!this.hasMutatedConstraints&&eachAxis(e=>{this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){let n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(n.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){var e;let{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!isRefObject(t))return!1;let r=t.current;(0,er.k)(null!==r,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:i}=this.visualElement;if(!i||!i.layout)return!1;let o=function(e,t,n){let r=measureViewportBox(e,n),{scroll:i}=t;return i&&(translateAxis(r.x,i.offset.x),translateAxis(r.y,i.offset.y)),r}(r,i.root,this.visualElement.getTransformPagePoint()),a={x:calcViewportAxisConstraints((e=i.layout.layoutBox).x,o.x),y:calcViewportAxisConstraints(e.y,o.y)};if(n){let e=n(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(a));this.hasMutatedConstraints=!!e,e&&(a=convertBoundingBoxToBox(e))}return a}startAnimation(e){let{drag:t,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),s=this.constraints||{},l=eachAxis(a=>{if(!shouldDrag(a,t,this.currentDirection))return;let l=s&&s[a]||{};o&&(l={min:0,max:0});let u={type:"inertia",velocity:n?e[a]:0,bounceStiffness:r?200:1e6,bounceDamping:r?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...i,...l};return this.startAxisValueAnimation(a,u)});return Promise.all(l).then(a)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return n.start(animateMotionValue(e,n,0,t))}stopAnimation(){eachAxis(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){let t="_drag"+e.toUpperCase(),n=this.visualElement.getProps(),r=n[t];return r||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){eachAxis(t=>{let{drag:n}=this.getProps();if(!shouldDrag(t,n,this.currentDirection))return;let{projection:r}=this.visualElement,i=this.getAxisMotionValue(t);if(r&&r.layout){let{min:n,max:o}=r.layout.layoutBox[t];i.set(e[t]-mix(n,o,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!isRefObject(t)||!n||!this.constraints)return;this.stopAnimation();let r={x:0,y:0};eachAxis(e=>{let t=this.getAxisMotionValue(e);if(t){let n=t.get();r[e]=function(e,t){let n=.5,r=calcLength(e),i=calcLength(t);return i>r?n=progress(t.min,t.max-r,e.min):r>i&&(n=progress(e.min,e.max-i,t.min)),clamp(0,1,n)}({min:n,max:n},this.constraints[e])}});let{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),eachAxis(t=>{if(!shouldDrag(t,e,null))return;let n=this.getAxisMotionValue(t),{min:i,max:o}=this.constraints[t];n.set(mix(i,o,r[t]))})}addListeners(){if(!this.visualElement.current)return;ez.set(this.visualElement,this);let e=this.visualElement.current,t=addPointerEvent(e,"pointerdown",e=>{let{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)}),measureDragConstraints=()=>{let{dragConstraints:e}=this.getProps();isRefObject(e)&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",measureDragConstraints);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),measureDragConstraints();let i=addDomEvent(window,"resize",()=>this.scalePositionWithinConstraints()),o=n.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(eachAxis(t=>{let n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))}),this.visualElement.render())});return()=>{i(),t(),r(),o&&o()}}getProps(){let e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:o=.35,dragMomentum:a=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:o,dragMomentum:a}}};function shouldDrag(e,t,n){return(!0===t||t===e)&&(null===n||n===e)}let asyncHandler=e=>(t,n)=>{e&&q.Wi.update(()=>e(t,n))};var eG=n(77196);let eq={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function pixelsToPercent(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}let eK={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!L.test(e))return e;e=parseFloat(e)}let n=pixelsToPercent(e,t.target.x),r=pixelsToPercent(e,t.target.y);return`${n}% ${r}%`}};let MeasureLayoutWithContext=class MeasureLayoutWithContext extends a.Component{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;Object.assign(w,eX),i&&(t.group&&t.group.add(i),n&&n.register&&r&&n.register(i),i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),eq.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,visualElement:n,drag:r,isPresent:i}=this.props,o=n.projection;return o&&(o.isPresent=i,r||e.layoutDependency!==t||void 0===t?o.willUpdate():this.safeToRemove(),e.isPresent===i||(i?o.promote():o.relegate()||q.Wi.postRender(()=>{let e=o.getStack();e&&e.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),queueMicrotask(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}};function MeasureLayout(e){let[t,n]=(0,eG.oO)(),r=(0,a.useContext)(g.p);return a.createElement(MeasureLayoutWithContext,{...e,layoutGroup:r,switchLayoutGroup:(0,a.useContext)(y),isPresent:t,safeToRemove:n})}let eX={borderRadius:{...eK,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:eK,borderTopRightRadius:eK,borderBottomLeftRadius:eK,borderBottomRightRadius:eK,boxShadow:{correct:(e,{treeScale:t,projectionDelta:n})=>{let r=eC.parse(e);if(r.length>5)return e;let i=eC.createTransformer(e),o="number"!=typeof r[0]?1:0,a=n.x.scale*t.x,s=n.y.scale*t.y;r[0+o]/=a,r[1+o]/=s;let l=mix(a,s,.5);return"number"==typeof r[2+o]&&(r[2+o]/=l),"number"==typeof r[3+o]&&(r[3+o]/=l),i(r)}}},eZ=["TopLeft","TopRight","BottomLeft","BottomRight"],eY=eZ.length,asNumber=e=>"string"==typeof e?parseFloat(e):e,isPx=e=>"number"==typeof e||L.test(e);function getRadius(e,t){return void 0!==e[t]?e[t]:e.borderRadius}let eQ=compress(0,.5,eu),eJ=compress(.5,.95,Q.Z);function compress(e,t,n){return r=>rt?1:n(progress(e,t,r))}function copyAxisInto(e,t){e.min=t.min,e.max=t.max}function copyBoxInto(e,t){copyAxisInto(e.x,t.x),copyAxisInto(e.y,t.y)}function removePointDelta(e,t,n,r,i){return e-=t,e=r+1/n*(e-r),void 0!==i&&(e=r+1/i*(e-r)),e}function removeAxisTransforms(e,t,[n,r,i],o,a){!function(e,t=0,n=1,r=.5,i,o=e,a=e){if(j.test(t)){t=parseFloat(t);let e=mix(a.min,a.max,t/100);t=e-a.min}if("number"!=typeof t)return;let s=mix(o.min,o.max,r);e===o&&(s-=t),e.min=removePointDelta(e.min,t,n,s,i),e.max=removePointDelta(e.max,t,n,s,i)}(e,t[n],t[r],t[i],t.scale,o,a)}let e0=["x","scaleX","originX"],e1=["y","scaleY","originY"];function removeBoxTransforms(e,t,n,r){removeAxisTransforms(e.x,t,e0,n?n.x:void 0,r?r.x:void 0),removeAxisTransforms(e.y,t,e1,n?n.y:void 0,r?r.y:void 0)}function isAxisDeltaZero(e){return 0===e.translate&&1===e.scale}function isDeltaZero(e){return isAxisDeltaZero(e.x)&&isAxisDeltaZero(e.y)}function boxEqualsRounded(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function aspectRatio(e){return calcLength(e.x)/calcLength(e.y)}let NodeStack=class NodeStack{constructor(){this.members=[]}add(e){addUniqueItem(this.members,e),e.scheduleRender()}remove(e){if(removeItem(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){let t;let n=this.members.findIndex(t=>e===t);if(0===n)return!1;for(let e=n;e>=0;e--){let n=this.members[e];if(!1!==n.isPresent){t=n;break}}return!!t&&(this.promote(t),!0)}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);let{crossfade:r}=e.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach(e=>{let{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(e=>{e.instance&&e.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};function buildProjectionTransform(e,t,n){let r="",i=e.x.translate/t.x,o=e.y.translate/t.y;if((i||o)&&(r=`translate3d(${i}px, ${o}px, 0) `),(1!==t.x||1!==t.y)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){let{rotate:e,rotateX:t,rotateY:i}=n;e&&(r+=`rotate(${e}deg) `),t&&(r+=`rotateX(${t}deg) `),i&&(r+=`rotateY(${i}deg) `)}let a=e.x.scale*t.x,s=e.y.scale*t.y;return(1!==a||1!==s)&&(r+=`scale(${a}, ${s})`),r||"none"}let compareByDepth=(e,t)=>e.depth-t.depth;let FlatTree=class FlatTree{constructor(){this.children=[],this.isDirty=!1}add(e){addUniqueItem(this.children,e),this.isDirty=!0}remove(e){removeItem(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(compareByDepth),this.isDirty=!1,this.children.forEach(e)}};let e2=["","X","Y","Z"],e5=0,e6={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function createProjectionNode({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(e={},n=null==t?void 0:t()){this.id=e5++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{e6.totalNodes=e6.resolvedTargetDeltas=e6.recalculatedProjection=0,this.nodes.forEach(propagateDirtyNodes),this.nodes.forEach(resolveTargetDelta),this.nodes.forEach(calcProjection),this.nodes.forEach(cleanDirtyNodes),window.MotionDebug&&window.MotionDebug.record(e6)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;ethis.root.updateBlockedByResize=!1;e(t,()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){let n=performance.now(),checkElapsed=({timestamp:r})=>{let i=r-n;i>=t&&((0,q.Pn)(checkElapsed),e(i-t))};return q.Wi.read(checkElapsed,!0),()=>(0,q.Pn)(checkElapsed)}(resizeUnblockUpdate,250),eq.hasAnimatedSinceResize&&(eq.hasAnimatedSinceResize=!1,this.nodes.forEach(finishAnimation))})}r&&this.root.registerSharedNode(r,this),!1!==this.options.animate&&o&&(r||i)&&this.addEventListener("didUpdate",({delta:e,hasLayoutChanged:t,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let i=this.options.transition||o.getDefaultTransition()||e3,{onLayoutAnimationStart:a,onLayoutAnimationComplete:s}=o.getProps(),l=!this.targetLayout||!boxEqualsRounded(this.targetLayout,r)||n,u=!t&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||u||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,u);let t={...getValueTransition(i,"layout"),onPlay:a,onComplete:s};(o.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||finishAnimation(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,(0,q.Pn)(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){!this.isUpdateBlocked()&&(this.isUpdating=!0,this.nodes&&this.nodes.forEach(resetRotation),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(this.root.isUpdating||this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;ethis.update()))}clearAllSnapshots(){this.nodes.forEach(clearSnapshot),this.sharedNodes.forEach(removeLeadSnapshots)}scheduleUpdateProjection(){q.Wi.preRender(this.updateProjection,!1,!0)}scheduleCheckAfterUnmount(){q.Wi.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;e{let r=t/1e3;if(mixAxisDelta(a.x,e.x,r),mixAxisDelta(a.y,e.y,r),this.setTargetDelta(a),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){var l,u,d,h;calcRelativePosition(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),d=this.relativeTarget,h=this.relativeTargetOrigin,mixAxis(d.x,h.x,s.x,r),mixAxis(d.y,h.y,s.y,r),n&&(l=this.relativeTarget,u=n,l.x.min===u.x.min&&l.x.max===u.x.max&&l.y.min===u.y.min&&l.y.max===u.y.max)&&(this.isProjectionDirty=!1),n||(n=createBox()),copyBoxInto(n,this.relativeTarget)}c&&(this.animationValues=o,function(e,t,n,r,i,o){i?(e.opacity=mix(0,void 0!==n.opacity?n.opacity:1,eQ(r)),e.opacityExit=mix(void 0!==t.opacity?t.opacity:1,0,eJ(r))):o&&(e.opacity=mix(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let i=0;i{eq.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){let r=isMotionValue(e)?e:motionValue(e);return r.start(animateMotionValue("",r,1e3,n)),r.animation}(0,0,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,target:n,layout:r,latestValues:i}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&shouldAnimatePositionOnly(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||createBox();let t=calcLength(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;let r=calcLength(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}copyBoxInto(t,n),transformBox(t,i),calcBoxDelta(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new NodeStack);let n=this.sharedNodes.get(e);n.add(t);let r=t.options.initialPromotionConfig;t.promote({transition:r?r.transition:void 0,preserveFollowOpacity:r&&r.shouldPreserveFollowOpacity?r.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return!e||e.lead===this}getLead(){var e;let{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;let{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){let r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){let e=this.getStack();return!!e&&e.relegate(this)}resetRotation(){let{visualElement:e}=this.options;if(!e)return;let t=!1,{latestValues:n}=e;if((n.rotate||n.rotateX||n.rotateY||n.rotateZ)&&(t=!0),!t)return;let r={};for(let t=0;t{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()}),this.root.nodes.forEach(clearMeasurements),this.root.sharedNodes.clear()}}}function updateLayout(e){e.updateLayout()}function notifyLayoutUpdate(e){var t;let n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){let{layoutBox:t,measuredBox:r}=e.layout,{animationType:i}=e.options,o=n.source!==e.layout.source;"size"===i?eachAxis(e=>{let r=o?n.measuredBox[e]:n.layoutBox[e],i=calcLength(r);r.min=t[e].min,r.max=r.min+i}):shouldAnimatePositionOnly(i,n.layoutBox,t)&&eachAxis(r=>{let i=o?n.measuredBox[r]:n.layoutBox[r],a=calcLength(t[r]);i.max=i.min+a,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+a)});let a=createDelta();calcBoxDelta(a,t,n.layoutBox);let s=createDelta();o?calcBoxDelta(s,e.applyTransform(r,!0),n.measuredBox):calcBoxDelta(s,t,n.layoutBox);let l=!isDeltaZero(a),u=!1;if(!e.resumeFrom){let r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){let{snapshot:i,layout:o}=r;if(i&&o){let a=createBox();calcRelativePosition(a,n.layoutBox,i.layoutBox);let s=createBox();calcRelativePosition(s,t,o.layoutBox),boxEqualsRounded(a,s)||(u=!0),r.options.layoutRoot&&(e.relativeTarget=s,e.relativeTargetOrigin=a,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:s,layoutDelta:a,hasLayoutChanged:l,hasRelativeTargetChanged:u})}else if(e.isLead()){let{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function propagateDirtyNodes(e){e6.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function cleanDirtyNodes(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function clearSnapshot(e){e.clearSnapshot()}function clearMeasurements(e){e.clearMeasurements()}function clearIsLayoutDirty(e){e.isLayoutDirty=!1}function resetTransformStyle(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function finishAnimation(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function resolveTargetDelta(e){e.resolveTargetDelta()}function calcProjection(e){e.calcProjection()}function resetRotation(e){e.resetRotation()}function removeLeadSnapshots(e){e.removeLeadSnapshot()}function mixAxisDelta(e,t,n){e.translate=mix(t.translate,0,n),e.scale=mix(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function mixAxis(e,t,n,r){e.min=mix(t.min,n.min,r),e.max=mix(t.max,n.max,r)}function hasOpacityCrossfade(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}let e3={duration:.45,ease:[.4,0,.1,1]},userAgentContains=e=>"undefined"!=typeof navigator&&navigator.userAgent.toLowerCase().includes(e),e4=userAgentContains("applewebkit/")&&!userAgentContains("chrome/")?Math.round:Q.Z;function roundAxis(e){e.min=e4(e.min),e.max=e4(e.max)}function shouldAnimatePositionOnly(e,t,n){return"position"===e||"preserve-aspect"===e&&!isNear(aspectRatio(t),aspectRatio(n),.2)}let e7=createProjectionNode({attachResizeListener:(e,t)=>addDomEvent(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),e9={current:void 0},e8=createProjectionNode({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!e9.current){let e=new e7({});e.mount(window),e.setOptions({layoutScroll:!0}),e9.current=e}return e9.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>"fixed"===window.getComputedStyle(e).position}),te=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function getVariableValue(e,t,n=1){(0,er.k)(n<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);let[r,i]=function(e){let t=te.exec(e);if(!t)return[,];let[,n,r]=t;return[n,r]}(e);if(!r)return;let o=window.getComputedStyle(t).getPropertyValue(r);if(o){let e=o.trim();return isNumericalString(e)?parseFloat(e):e}return T(i)?getVariableValue(i,t,n+1):i}let tt=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),isPositionalKey=e=>tt.has(e),hasPositionalKey=e=>Object.keys(e).some(isPositionalKey),isNumOrPxType=e=>e===A||e===L,getPosFromMatrix=(e,t)=>parseFloat(e.split(", ")[t]),getTranslateFromMatrix=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;let i=r.match(/^matrix3d\((.+)\)$/);if(i)return getPosFromMatrix(i[1],t);{let t=r.match(/^matrix\((.+)\)$/);return t?getPosFromMatrix(t[1],e):0}},tn=new Set(["x","y","z"]),tr=k.filter(e=>!tn.has(e)),ti={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:getTranslateFromMatrix(4,13),y:getTranslateFromMatrix(5,14)};ti.translateX=ti.x,ti.translateY=ti.y;let convertChangedValueTypes=(e,t,n)=>{let r=t.measureViewportBox(),i=t.current,o=getComputedStyle(i),{display:a}=o,s={};"none"===a&&t.setStaticValue("display",e.display||"block"),n.forEach(e=>{s[e]=ti[e](r,o)}),t.render();let l=t.measureViewportBox();return n.forEach(n=>{let r=t.getValue(n);r&&r.jump(s[n]),e[n]=ti[n](l,o)}),e},checkAndConvertChangedValueTypes=(e,t,n={},r={})=>{t={...t},r={...r};let i=Object.keys(t).filter(isPositionalKey),o=[],a=!1,s=[];if(i.forEach(i=>{let l;let u=e.getValue(i);if(!e.hasValue(i))return;let c=n[i],d=findDimensionValueType(c),f=t[i];if(isKeyframesTarget(f)){let e=f.length,t=null===f[0]?1:0;d=findDimensionValueType(c=f[t]);for(let n=t;n{let r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}(e),a=!0),s.push(i),r[i]=void 0!==r[i]?r[i]:t[i],u.jump(f))}}),!s.length)return{target:t,transitionEnd:r};{let n=s.indexOf("height")>=0?window.pageYOffset:null,i=convertChangedValueTypes(t,e,s);return o.length&&o.forEach(([t,n])=>{e.getValue(t).set(n)}),e.render(),v.j&&null!==n&&window.scrollTo({top:n}),{target:i,transitionEnd:r}}},parseDomVariant=(e,t,n,r)=>{var i,o;let a=function(e,{...t},n){let r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};for(let i in n&&(n={...n}),e.values.forEach(e=>{let t=e.get();if(!T(t))return;let n=getVariableValue(t,r);n&&e.set(n)}),t){let e=t[i];if(!T(e))continue;let o=getVariableValue(e,r);o&&(t[i]=o,n||(n={}),void 0===n[i]&&(n[i]=e))}return{target:t,transitionEnd:n}}(e,t,r);return t=a.target,r=a.transitionEnd,i=t,o=r,hasPositionalKey(i)?checkAndConvertChangedValueTypes(e,i,n,o):{target:i,transitionEnd:o}},to={current:null},ta={current:!1},ts=new WeakMap,tl=Object.keys(m),tu=tl.length,tc=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],td=p.length;let VisualElement=class VisualElement{constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,visualState:i},o={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.scheduleRender=()=>q.Wi.render(this.render,!1,!0);let{latestValues:a,renderState:s}=i;this.latestValues=a,this.baseTarget={...a},this.initialValues=t.initial?{...a}:{},this.renderState=s,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.options=o,this.isControllingVariants=isControllingVariants(t),this.isVariantNode=isVariantNode(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);let{willChange:l,...u}=this.scrapeMotionValuesFromProps(t,{});for(let e in u){let t=u[e];void 0!==a[e]&&isMotionValue(t)&&(t.set(a[e],!1),isWillChangeMotionValue(l)&&l.add(e))}}scrapeMotionValuesFromProps(e,t){return{}}mount(e){this.current=e,ts.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((e,t)=>this.bindToMotionValue(t,e)),ta.current||function(){if(ta.current=!0,v.j){if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),setReducedMotionPreferences=()=>to.current=e.matches;e.addListener(setReducedMotionPreferences),setReducedMotionPreferences()}else to.current=!1}}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||to.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){for(let e in ts.delete(this.current),this.projection&&this.projection.unmount(),(0,q.Pn)(this.notifyUpdate),(0,q.Pn)(this.render),this.valueSubscriptions.forEach(e=>e()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this),this.events)this.events[e].clear();for(let e in this.features)this.features[e].unmount();this.current=null}bindToMotionValue(e,t){let n=S.has(e),r=t.on("change",t=>{this.latestValues[e]=t,this.props.onUpdate&&q.Wi.update(this.notifyUpdate,!1,!0),n&&this.projection&&(this.projection.isTransformDirty=!0)}),i=t.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(e,()=>{r(),i()})}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}loadFeatures({children:e,...t},n,r,i){let o,a;for(let e=0;ethis.scheduleRender(),animationType:"string"==typeof n?n:"both",initialPromotionConfig:i,layoutScroll:s,layoutRoot:l})}return a}updateFeatures(){for(let e in this.features){let t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):createBox()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}makeTargetAnimatable(e,t=!0){return this.makeTargetAnimatableFromInstance(e,this.props,t)}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;tt.variantChildren.delete(e)}addValue(e,t){t!==this.values.get(e)&&(this.removeValue(e),this.bindToMotionValue(e,t)),this.values.set(e,t),this.latestValues[e]=t.get()}removeValue(e){this.values.delete(e);let t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=motionValue(t,{owner:this}),this.addValue(e,n)),n}readValue(e){var t;return void 0===this.latestValues[e]&&this.current?null!==(t=this.getBaseTargetFromProps(this.props,e))&&void 0!==t?t:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e]}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;let{initial:n}=this.props,r="string"==typeof n||"object"==typeof n?null===(t=resolveVariantFromProps(this.props,n))||void 0===t?void 0:t[e]:void 0;if(n&&void 0!==r)return r;let i=this.getBaseTargetFromProps(this.props,e);return void 0===i||isMotionValue(i)?void 0!==this.initialValues[e]&&void 0===r?void 0:this.baseTarget[e]:i}on(e,t){return this.events[e]||(this.events[e]=new SubscriptionManager),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}};let DOMVisualElement=class DOMVisualElement extends VisualElement{sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}makeTargetAnimatableFromInstance({transition:e,transitionEnd:t,...n},{transformValues:r},i){let o=function(e,t,n){let r={};for(let i in e){let e=function(e,t){if(!t)return;let n=t[e]||t.default||t;return n.from}(i,t);if(void 0!==e)r[i]=e;else{let e=n.getValue(i);e&&(r[i]=e.get())}}return r}(n,e||{},this);if(r&&(t&&(t=r(t)),n&&(n=r(n)),o&&(o=r(o))),i){!function(e,t,n){var r,i;let o=Object.keys(t).filter(t=>!e.hasValue(t)),a=o.length;if(a)for(let s=0;s{this.current&&(this.current.textContent=`${e}`)}))}renderInstance(e,t,n,r){renderHTML(e,t,n,r)}};let SVGVisualElement=class SVGVisualElement extends DOMVisualElement{constructor(){super(...arguments),this.isSVGTag=!1}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(S.has(t)){let e=getDefaultValueType(t);return e&&e.default||0}return t=z.has(t)?t:camelToDash(t),e.getAttribute(t)}measureInstanceViewportBox(){return createBox()}scrapeMotionValuesFromProps(e,t){return scrape_motion_values_scrapeMotionValuesFromProps(e,t)}build(e,t,n,r){buildSVGAttrs(e,t,n,this.isSVGTag,r.transformTemplate)}renderInstance(e,t,n,r){renderSVG(e,t,n,r)}mount(e){this.isSVGTag=isSVGTag(e.tagName),super.mount(e)}};let create_visual_element_createDomVisualElement=(e,t)=>isSVGComponent(e)?new SVGVisualElement(t,{enableHardwareAcceleration:!1}):new HTMLVisualElement(t,{enableHardwareAcceleration:!0}),tf={animation:{Feature:class extends Feature{constructor(e){super(e),e.animationState||(e.animationState=function(e){let animate=t=>Promise.all(t.map(({animation:t,options:n})=>(function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t)){let i=t.map(t=>animateVariant(e,t,n));r=Promise.all(i)}else if("string"==typeof t)r=animateVariant(e,t,n);else{let i="function"==typeof t?resolveVariant(e,t,n.custom):t;r=Promise.all(animateTarget(e,i,n))}return r.then(()=>e.notify("AnimationComplete",t))})(e,t,n))),t={animate:createTypeState(!0),whileInView:createTypeState(),whileHover:createTypeState(),whileTap:createTypeState(),whileDrag:createTypeState(),whileFocus:createTypeState(),exit:createTypeState()},n=!0,buildResolvedTypeValues=(t,n)=>{let r=resolveVariant(e,n);if(r){let{transition:e,transitionEnd:n,...i}=r;t={...t,...i,...n}}return t};function animateChanges(r,i){let o=e.getProps(),a=e.getVariantContext(!0)||{},s=[],l=new Set,u={},c=1/0;for(let f=0;fc&&v,w=Array.isArray(m)?m:[m],k=w.reduce(buildResolvedTypeValues,{});!1===g&&(k={});let{prevResolvedValues:S={}}=h,C={...S,...k},markToAnimate=e=>{x=!0,l.delete(e),h.needsAnimating[e]=!0};for(let e in C){let t=k[e],n=S[e];u.hasOwnProperty(e)||(t!==n?isKeyframesTarget(t)&&isKeyframesTarget(n)?!shallowCompare(t,n)||b?markToAnimate(e):h.protectedKeys[e]=!0:void 0!==t?markToAnimate(e):l.add(e):void 0!==t&&l.has(e)?markToAnimate(e):h.protectedKeys[e]=!0)}h.prevProp=m,h.prevResolvedValues=k,h.isActive&&(u={...u,...k}),n&&e.blockInitialAnimation&&(x=!1),x&&!y&&s.push(...w.map(e=>({animation:e,options:{type:p,...r}})))}if(l.size){let t={};l.forEach(n=>{let r=e.getBaseTarget(n);void 0!==r&&(t[n]=r)}),s.push({animation:t})}let f=!!s.length;return n&&!1===o.initial&&!e.manuallyAnimateOnMount&&(f=!1),n=!1,f?animate(s):Promise.resolve()}return{animateChanges,setActive:function(n,r,i){var o;if(t[n].isActive===r)return Promise.resolve();null===(o=e.variantChildren)||void 0===o||o.forEach(e=>{var t;return null===(t=e.animationState)||void 0===t?void 0:t.setActive(n,r)}),t[n].isActive=r;let a=animateChanges(i,n);for(let e in t)t[e].protectedKeys={};return a},setAnimateFunction:function(t){animate=t(e)},getState:()=>t}}(e))}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();this.unmount(),isAnimationControls(e)&&(this.unmount=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){}}},exit:{Feature:class extends Feature{constructor(){super(...arguments),this.id=e$++}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:t,custom:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===r)return;let i=this.node.animationState.setActive("exit",!e,{custom:null!=n?n:this.node.getProps().custom});t&&!e&&i.then(()=>t(this.id))}mount(){let{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}},inView:{Feature:class extends Feature{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:i}=e,o={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:et[r]};return function(e,t,n){let r=function({root:e,...t}){let n=e||document;ee.has(n)||ee.set(n,{});let r=ee.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(fireAllObserverCallbacks,{root:e,...t})),r[i]}(t);return J.set(e,n),r.observe(e),()=>{J.delete(e),r.unobserve(e)}}(this.node.current,o,e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),o=t?n:r;o&&o(e)})}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;let{props:e,prevProps:t}=this.node,n=["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t));n&&this.startObserver()}unmount(){}}},tap:{Feature:class extends Feature{constructor(){super(...arguments),this.removeStartListeners=Q.Z,this.removeEndListeners=Q.Z,this.removeAccessibleListeners=Q.Z,this.startPointerPress=(e,t)=>{if(this.removeEndListeners(),this.isPressing)return;let n=this.node.getProps(),r=addPointerEvent(window,"pointerup",(e,t)=>{if(!this.checkPressEnd())return;let{onTap:n,onTapCancel:r}=this.node.getProps();q.Wi.update(()=>{isNodeOrChild(this.node.current,e.target)?n&&n(e,t):r&&r(e,t)})},{passive:!(n.onTap||n.onPointerUp)}),i=addPointerEvent(window,"pointercancel",(e,t)=>this.cancelPress(e,t),{passive:!(n.onTapCancel||n.onPointerCancel)});this.removeEndListeners=pipe(r,i),this.startPress(e,t)},this.startAccessiblePress=()=>{let e=addDomEvent(this.node.current,"keydown",e=>{"Enter"!==e.key||this.isPressing||(this.removeEndListeners(),this.removeEndListeners=addDomEvent(this.node.current,"keyup",e=>{"Enter"===e.key&&this.checkPressEnd()&&fireSyntheticPointerEvent("up",(e,t)=>{let{onTap:n}=this.node.getProps();n&&q.Wi.update(()=>n(e,t))})}),fireSyntheticPointerEvent("down",(e,t)=>{this.startPress(e,t)}))}),t=addDomEvent(this.node.current,"blur",()=>{this.isPressing&&fireSyntheticPointerEvent("cancel",(e,t)=>this.cancelPress(e,t))});this.removeAccessibleListeners=pipe(e,t)}}startPress(e,t){this.isPressing=!0;let{onTapStart:n,whileTap:r}=this.node.getProps();r&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),n&&q.Wi.update(()=>n(e,t))}checkPressEnd(){this.removeEndListeners(),this.isPressing=!1;let e=this.node.getProps();return e.whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!isDragActive()}cancelPress(e,t){if(!this.checkPressEnd())return;let{onTapCancel:n}=this.node.getProps();n&&q.Wi.update(()=>n(e,t))}mount(){let e=this.node.getProps(),t=addPointerEvent(this.node.current,"pointerdown",this.startPointerPress,{passive:!(e.onTapStart||e.onPointerStart)}),n=addDomEvent(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=pipe(t,n)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}},focus:{Feature:class extends Feature{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=pipe(addDomEvent(this.node.current,"focus",()=>this.onFocus()),addDomEvent(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}},hover:{Feature:class extends Feature{mount(){this.unmount=pipe(addHoverEvent(this.node,!0),addHoverEvent(this.node,!1))}unmount(){}}},pan:{Feature:class extends Feature{constructor(){super(...arguments),this.removePointerDownListener=Q.Z}onPointerDown(e){this.session=new PanSession(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint()})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:asyncHandler(e),onStart:asyncHandler(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&q.Wi.update(()=>r(e,t))}}}mount(){this.removePointerDownListener=addPointerEvent(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends Feature{constructor(e){super(e),this.removeGroupControls=Q.Z,this.removeListeners=Q.Z,this.controls=new VisualElementDragControls(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Q.Z}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:e8,MeasureLayout:MeasureLayout},layout:{ProjectionNode:e8,MeasureLayout:MeasureLayout}},tp=function(e){function custom(t,n={}){return function({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:i}){e&&function(e){for(let t in e)m[t]={...m[t],...e[t]}}(e);let o=(0,a.forwardRef)(function(o,f){var p;let h;let m={...(0,a.useContext)(s),...o,layoutId:function({layoutId:e}){let t=(0,a.useContext)(g.p).id;return t&&void 0!==e?t+"-"+e:e}(o)},{isStatic:b}=m,x=function(e){let{initial:t,animate:n}=function(e,t){if(isControllingVariants(e)){let{initial:t,animate:n}=e;return{initial:!1===t||isVariantLabel(t)?t:void 0,animate:isVariantLabel(n)?n:void 0}}return!1!==e.inherit?t:{}}(e,(0,a.useContext)(l));return(0,a.useMemo)(()=>({initial:t,animate:n}),[variantLabelsAsDependency(t),variantLabelsAsDependency(n)])}(o),w=r(o,b);if(!b&&v.j){x.visualElement=function(e,t,n,r){let{visualElement:i}=(0,a.useContext)(l),o=(0,a.useContext)(d),f=(0,a.useContext)(u.O),p=(0,a.useContext)(s).reducedMotion,h=(0,a.useRef)();r=r||o.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:i,props:n,presenceContext:f,blockInitialAnimation:!!f&&!1===f.initial,reducedMotionConfig:p}));let m=h.current;(0,a.useInsertionEffect)(()=>{m&&m.update(n,f)});let v=(0,a.useRef)(!!window.HandoffAppearAnimations);return(0,c.L)(()=>{m&&(m.render(),v.current&&m.animationState&&m.animationState.animateChanges())}),(0,a.useEffect)(()=>{m&&(m.updateFeatures(),!v.current&&m.animationState&&m.animationState.animateChanges(),window.HandoffAppearAnimations=void 0,v.current=!1)}),m}(i,w,m,t);let n=(0,a.useContext)(y),r=(0,a.useContext)(d).strict;x.visualElement&&(h=x.visualElement.loadFeatures(m,r,e,n))}return a.createElement(l.Provider,{value:x},h&&x.visualElement?a.createElement(h,{visualElement:x.visualElement,...m}):null,n(i,o,(p=x.visualElement,(0,a.useCallback)(e=>{e&&w.mount&&w.mount(e),p&&(e?p.mount(e):p.unmount()),f&&("function"==typeof f?f(e):isRefObject(f)&&(f.current=e))},[p])),w,b,x.visualElement))});return o[b]=i,o}(e(t,n))}if("undefined"==typeof Proxy)return custom;let t=new Map;return new Proxy(custom,{get:(e,n)=>(t.has(n)||t.set(n,custom(n)),t.get(n))})}((e,t)=>(function(e,{forwardMotionProps:t=!1},n,r){let i=isSVGComponent(e)?K:X;return{...i,preloadedFeatures:n,useRender:function(e=!1){return(t,n,r,{latestValues:i},o)=>{let s=isSVGComponent(t)?useSVGProps:useHTMLProps,l=s(n,i,o,t),u=function(e,t,n){let r={};for(let i in e)("values"!==i||"object"!=typeof e.values)&&(shouldForward(i)||!0===n&&isValidMotionProp(i)||!t&&!isValidMotionProp(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}(n,"string"==typeof t,e),c={...u,...l,ref:r},{children:d}=n,f=(0,a.useMemo)(()=>isMotionValue(d)?d.get():d,[d]);return(0,a.createElement)(t,{...c,children:f})}}(t),createVisualElement:r,Component:e}})(e,t,tf,create_visual_element_createDomVisualElement))},46567:function(e,t,n){"use strict";n.d(t,{K:function(){return i},k:function(){return o}});var r=n(26977);let i=r.Z,o=r.Z},16613:function(e,t,n){"use strict";n.d(t,{j:function(){return r}});let r="undefined"!=typeof document},26977:function(e,t,n){"use strict";n.d(t,{Z:function(){return noop}});let noop=e=>e},10961:function(e,t,n){"use strict";n.d(t,{h:function(){return useConstant}});var r=n(2265);function useConstant(e){let t=(0,r.useRef)(null);return null===t.current&&(t.current=e()),t.current}},538:function(e,t,n){"use strict";n.d(t,{L:function(){return o}});var r=n(2265),i=n(16613);let o=i.j?r.useLayoutEffect:r.useEffect},98361:function(e,t,n){"use strict";n.d(t,{qY:function(){return p},ZP:function(){return h},$B:function(){return getFrameData}});let r=1/60*1e3,i="undefined"!=typeof performance?()=>performance.now():()=>Date.now(),o="undefined"!=typeof window?e=>window.requestAnimationFrame(e):e=>setTimeout(()=>e(i()),r),a=!0,s=!1,l=!1,u={delta:0,timestamp:0},c=["read","update","preRender","render","postRender"],d=c.reduce((e,t)=>(e[t]=function(e){let t=[],n=[],r=0,i=!1,o=!1,a=new WeakSet,s={schedule:(e,o=!1,s=!1)=>{let l=s&&i,u=l?t:n;return o&&a.add(e),-1===u.indexOf(e)&&(u.push(e),l&&i&&(r=t.length)),e},cancel:e=>{let t=n.indexOf(e);-1!==t&&n.splice(t,1),a.delete(e)},process:l=>{if(i){o=!0;return}if(i=!0,[t,n]=[n,t],n.length=0,r=t.length)for(let n=0;ns=!0),e),{}),f=c.reduce((e,t)=>{let n=d[t];return e[t]=(e,t=!1,r=!1)=>(s||startLoop(),n.schedule(e,t,r)),e},{}),p=c.reduce((e,t)=>(e[t]=d[t].cancel,e),{});c.reduce((e,t)=>(e[t]=()=>d[t].process(u),e),{});let processStep=e=>d[e].process(u),processFrame=e=>{s=!1,u.delta=a?r:Math.max(Math.min(e-u.timestamp,40),1),u.timestamp=e,l=!0,c.forEach(processStep),l=!1,s&&(a=!1,o(processFrame))},startLoop=()=>{s=!0,a=!0,l||o(processFrame)},getFrameData=()=>u;var h=f}}]); \ No newline at end of file diff --git a/_next/static/chunks/777.8ebd521a6b67f3bc.js b/_next/static/chunks/777.8ebd521a6b67f3bc.js new file mode 100644 index 0000000..efd269f --- /dev/null +++ b/_next/static/chunks/777.8ebd521a6b67f3bc.js @@ -0,0 +1,22 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[777],{88777:function(e,t,l){l.r(t),l.d(t,{WcmModal:function(){return rn},WcmQrCode:function(){return tb}});/** + * @license + * Copyright 2019 Google LLC + * SPDX-License-Identifier: BSD-3-Clause + */let o=window,n=o.ShadowRoot&&(void 0===o.ShadyCSS||o.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,s=Symbol(),c=new WeakMap;let css_tag_o=class css_tag_o{constructor(e,t,l){if(this._$cssResult$=!0,l!==s)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=e,this.t=t}get styleSheet(){let e=this.o,t=this.t;if(n&&void 0===e){let l=void 0!==t&&1===t.length;l&&(e=c.get(t)),void 0===e&&((this.o=e=new CSSStyleSheet).replaceSync(this.cssText),l&&c.set(t,e))}return e}toString(){return this.cssText}};let r=e=>new css_tag_o("string"==typeof e?e:e+"",void 0,s),i=(e,...t)=>{let l=1===e.length?e[0]:t.reduce((t,l,o)=>t+(e=>{if(!0===e._$cssResult$)return e.cssText;if("number"==typeof e)return e;throw Error("Value passed to 'css' function must be a 'css' function result: "+e+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(l)+e[o+1],e[0]);return new css_tag_o(l,e,s)},S=(e,t)=>{n?e.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet):t.forEach(t=>{let l=document.createElement("style"),n=o.litNonce;void 0!==n&&l.setAttribute("nonce",n),l.textContent=t.cssText,e.appendChild(l)})},d=n?e=>e:e=>e instanceof CSSStyleSheet?(e=>{let t="";for(let l of e.cssRules)t+=l.cssText;return r(t)})(e):e,m=window,h=m.trustedTypes,p=h?h.emptyScript:"",g=m.reactiveElementPolyfillSupport,f={toAttribute(e,t){switch(t){case Boolean:e=e?p:null;break;case Object:case Array:e=null==e?e:JSON.stringify(e)}return e},fromAttribute(e,t){let l=e;switch(t){case Boolean:l=null!==e;break;case Number:l=null===e?null:Number(e);break;case Object:case Array:try{l=JSON.parse(e)}catch(e){l=null}}return l}},a=(e,t)=>t!==e&&(t==t||e==e),b={attribute:!0,type:String,converter:f,reflect:!1,hasChanged:a},y="finalized";let u=class u extends HTMLElement{constructor(){super(),this._$Ei=new Map,this.isUpdatePending=!1,this.hasUpdated=!1,this._$El=null,this._$Eu()}static addInitializer(e){var t;this.finalize(),(null!==(t=this.h)&&void 0!==t?t:this.h=[]).push(e)}static get observedAttributes(){this.finalize();let e=[];return this.elementProperties.forEach((t,l)=>{let o=this._$Ep(l,t);void 0!==o&&(this._$Ev.set(o,l),e.push(o))}),e}static createProperty(e,t=b){if(t.state&&(t.attribute=!1),this.finalize(),this.elementProperties.set(e,t),!t.noAccessor&&!this.prototype.hasOwnProperty(e)){let l="symbol"==typeof e?Symbol():"__"+e,o=this.getPropertyDescriptor(e,l,t);void 0!==o&&Object.defineProperty(this.prototype,e,o)}}static getPropertyDescriptor(e,t,l){return{get(){return this[t]},set(o){let n=this[e];this[t]=o,this.requestUpdate(e,n,l)},configurable:!0,enumerable:!0}}static getPropertyOptions(e){return this.elementProperties.get(e)||b}static finalize(){if(this.hasOwnProperty(y))return!1;this[y]=!0;let e=Object.getPrototypeOf(this);if(e.finalize(),void 0!==e.h&&(this.h=[...e.h]),this.elementProperties=new Map(e.elementProperties),this._$Ev=new Map,this.hasOwnProperty("properties")){let e=this.properties,t=[...Object.getOwnPropertyNames(e),...Object.getOwnPropertySymbols(e)];for(let l of t)this.createProperty(l,e[l])}return this.elementStyles=this.finalizeStyles(this.styles),!0}static finalizeStyles(e){let t=[];if(Array.isArray(e)){let l=new Set(e.flat(1/0).reverse());for(let e of l)t.unshift(d(e))}else void 0!==e&&t.push(d(e));return t}static _$Ep(e,t){let l=t.attribute;return!1===l?void 0:"string"==typeof l?l:"string"==typeof e?e.toLowerCase():void 0}_$Eu(){var e;this._$E_=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$Eg(),this.requestUpdate(),null===(e=this.constructor.h)||void 0===e||e.forEach(e=>e(this))}addController(e){var t,l;(null!==(t=this._$ES)&&void 0!==t?t:this._$ES=[]).push(e),void 0!==this.renderRoot&&this.isConnected&&(null===(l=e.hostConnected)||void 0===l||l.call(e))}removeController(e){var t;null===(t=this._$ES)||void 0===t||t.splice(this._$ES.indexOf(e)>>>0,1)}_$Eg(){this.constructor.elementProperties.forEach((e,t)=>{this.hasOwnProperty(t)&&(this._$Ei.set(t,this[t]),delete this[t])})}createRenderRoot(){var e;let t=null!==(e=this.shadowRoot)&&void 0!==e?e:this.attachShadow(this.constructor.shadowRootOptions);return S(t,this.constructor.elementStyles),t}connectedCallback(){var e;void 0===this.renderRoot&&(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),null===(e=this._$ES)||void 0===e||e.forEach(e=>{var t;return null===(t=e.hostConnected)||void 0===t?void 0:t.call(e)})}enableUpdating(e){}disconnectedCallback(){var e;null===(e=this._$ES)||void 0===e||e.forEach(e=>{var t;return null===(t=e.hostDisconnected)||void 0===t?void 0:t.call(e)})}attributeChangedCallback(e,t,l){this._$AK(e,l)}_$EO(e,t,l=b){var o;let n=this.constructor._$Ep(e,l);if(void 0!==n&&!0===l.reflect){let s=(void 0!==(null===(o=l.converter)||void 0===o?void 0:o.toAttribute)?l.converter:f).toAttribute(t,l.type);this._$El=e,null==s?this.removeAttribute(n):this.setAttribute(n,s),this._$El=null}}_$AK(e,t){var l;let o=this.constructor,n=o._$Ev.get(e);if(void 0!==n&&this._$El!==n){let e=o.getPropertyOptions(n),s="function"==typeof e.converter?{fromAttribute:e.converter}:void 0!==(null===(l=e.converter)||void 0===l?void 0:l.fromAttribute)?e.converter:f;this._$El=n,this[n]=s.fromAttribute(t,e.type),this._$El=null}}requestUpdate(e,t,l){let o=!0;void 0!==e&&(((l=l||this.constructor.getPropertyOptions(e)).hasChanged||a)(this[e],t)?(this._$AL.has(e)||this._$AL.set(e,t),!0===l.reflect&&this._$El!==e&&(void 0===this._$EC&&(this._$EC=new Map),this._$EC.set(e,l))):o=!1),!this.isUpdatePending&&o&&(this._$E_=this._$Ej())}async _$Ej(){this.isUpdatePending=!0;try{await this._$E_}catch(e){Promise.reject(e)}let e=this.scheduleUpdate();return null!=e&&await e,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var e;if(!this.isUpdatePending)return;this.hasUpdated,this._$Ei&&(this._$Ei.forEach((e,t)=>this[t]=e),this._$Ei=void 0);let t=!1,l=this._$AL;try{(t=this.shouldUpdate(l))?(this.willUpdate(l),null===(e=this._$ES)||void 0===e||e.forEach(e=>{var t;return null===(t=e.hostUpdate)||void 0===t?void 0:t.call(e)}),this.update(l)):this._$Ek()}catch(e){throw t=!1,this._$Ek(),e}t&&this._$AE(l)}willUpdate(e){}_$AE(e){var t;null===(t=this._$ES)||void 0===t||t.forEach(e=>{var t;return null===(t=e.hostUpdated)||void 0===t?void 0:t.call(e)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(e)),this.updated(e)}_$Ek(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$E_}shouldUpdate(e){return!0}update(e){void 0!==this._$EC&&(this._$EC.forEach((e,t)=>this._$EO(t,this[t],e)),this._$EC=void 0),this._$Ek()}updated(e){}firstUpdated(e){}};u[y]=!0,u.elementProperties=new Map,u.elementStyles=[],u.shadowRootOptions={mode:"open"},null==g||g({ReactiveElement:u}),(null!==(ed=m.reactiveElementVersions)&&void 0!==ed?ed:m.reactiveElementVersions=[]).push("1.6.3");let _=window,x=_.trustedTypes,$=x?x.createPolicy("lit-html",{createHTML:e=>e}):void 0,C="$lit$",A=`lit$${(Math.random()+"").slice(9)}$`,E="?"+A,O=`<${E}>`,T=document,lit_html_u=()=>T.createComment(""),lit_html_d=e=>null===e||"object"!=typeof e&&"function"!=typeof e,I=Array.isArray,v=e=>I(e)||"function"==typeof(null==e?void 0:e[Symbol.iterator]),W="[ \n\f\r]",j=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,U=/-->/g,B=/>/g,G=RegExp(`>|${W}(?:([^\\s"'>=/]+)(${W}*=${W}*(?:[^ +\f\r"'\`<>=]|("|')|))|$)`,"g"),Y=/'/g,Q=/"/g,X=/^(?:script|style|textarea|title)$/i,w=e=>(t,...l)=>({_$litType$:e,strings:t,values:l}),J=w(1),ee=w(2),et=Symbol.for("lit-noChange"),er=Symbol.for("lit-nothing"),ei=new WeakMap,el=T.createTreeWalker(T,129,null,!1);function P(e,t){if(!Array.isArray(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==$?$.createHTML(t):t}let V=(e,t)=>{let l=e.length-1,o=[],n,s=2===t?"":"",c=j;for(let t=0;t"===m[0]?(c=null!=n?n:j,h=-1):void 0===m[1]?h=-2:(h=c.lastIndex-m[2].length,d=m[1],c=void 0===m[3]?G:'"'===m[3]?Q:Y):c===Q||c===Y?c=G:c===U||c===B?c=j:(c=G,n=void 0);let g=c===G&&e[t+1].startsWith("/>")?" ":"";s+=c===j?l+O:h>=0?(o.push(d),l.slice(0,h)+C+l.slice(h)+A+g):l+A+(-2===h?(o.push(void 0),t):g)}return[P(e,s+(e[l]||"")+(2===t?"":"")),o]};let N=class N{constructor({strings:e,_$litType$:t},l){let o;this.parts=[];let n=0,s=0,c=e.length-1,d=this.parts,[m,h]=V(e,t);if(this.el=N.createElement(m,l),el.currentNode=this.el.content,2===t){let e=this.el.content,t=e.firstChild;t.remove(),e.append(...t.childNodes)}for(;null!==(o=el.nextNode())&&d.length0){o.textContent=x?x.emptyScript:"";for(let l=0;l2||""!==l[0]||""!==l[1]?(this._$AH=Array(l.length-1).fill(new String),this.strings=l):this._$AH=er}get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}_$AI(e,t=this,l,o){let n=this.strings,s=!1;if(void 0===n)(s=!lit_html_d(e=lit_html_S(this,e,t,0))||e!==this._$AH&&e!==et)&&(this._$AH=e);else{let o,c;let d=e;for(e=n[0],o=0;o{var o,n;let s=null!==(o=null==l?void 0:l.renderBefore)&&void 0!==o?o:t,c=s._$litPart$;if(void 0===c){let e=null!==(n=null==l?void 0:l.renderBefore)&&void 0!==n?n:null;s._$litPart$=c=new R(t.insertBefore(lit_html_u(),e),e,void 0,null!=l?l:{})}return c._$AI(e),c};let lit_element_s=class lit_element_s extends u{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var e,t;let l=super.createRenderRoot();return null!==(e=(t=this.renderOptions).renderBefore)&&void 0!==e||(t.renderBefore=l.firstChild),l}update(e){let t=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(e),this._$Do=D(t,this.renderRoot,this.renderOptions)}connectedCallback(){var e;super.connectedCallback(),null===(e=this._$Do)||void 0===e||e.setConnected(!0)}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this._$Do)||void 0===e||e.setConnected(!1)}render(){return et}};lit_element_s.finalized=!0,lit_element_s._$litElement$=!0,null===(eh=globalThis.litElementHydrateSupport)||void 0===eh||eh.call(globalThis,{LitElement:lit_element_s});let en=globalThis.litElementPolyfillSupport;null==en||en({LitElement:lit_element_s}),(null!==(ep=globalThis.litElementVersions)&&void 0!==ep?ep:globalThis.litElementVersions=[]).push("3.3.3");/** + * @license + * Copyright 2017 Google LLC + * SPDX-License-Identifier: BSD-3-Clause + */let custom_element_e=e=>t=>"function"==typeof t?(customElements.define(e,t),t):((e,t)=>{let{kind:l,elements:o}=t;return{kind:l,elements:o,finisher(t){customElements.define(e,t)}}})(e,t),property_i=(e,t)=>"method"!==t.kind||!t.descriptor||"value"in t.descriptor?{kind:"field",key:Symbol(),placement:"own",descriptor:{},originalKey:t.key,initializer(){"function"==typeof t.initializer&&(this[t.key]=t.initializer.call(this))},finisher(l){l.createProperty(t.key,e)}}:{...t,finisher(l){l.createProperty(t.key,e)}},property_e=(e,t,l)=>{t.constructor.createProperty(l,e)};function property_n(e){return(t,l)=>void 0!==l?property_e(e,t,l):property_i(e,t)}/** + * @license + * Copyright 2017 Google LLC + * SPDX-License-Identifier: BSD-3-Clause + */function state_t(e){return property_n({...e,state:!0})}null!=(null===(eu=window.HTMLSlotElement)||void 0===eu?void 0:eu.prototype.assignedElements)||((e,t)=>e.assignedNodes(t).filter(e=>e.nodeType===Node.ELEMENT_NODE));let directive_i=class directive_i{constructor(e){}get _$AU(){return this._$AM._$AU}_$AT(e,t,l){this._$Ct=e,this._$AM=t,this._$Ci=l}_$AS(e,t){return this.update(e,t)}update(e,t){return this.render(...t)}};/** + * @license + * Copyright 2018 Google LLC + * SPDX-License-Identifier: BSD-3-Clause + */let es=(ec=class extends directive_i{constructor(e){var t;if(super(e),1!==e.type||"class"!==e.name||(null===(t=e.strings)||void 0===t?void 0:t.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(e){return" "+Object.keys(e).filter(t=>e[t]).join(" ")+" "}update(e,[t]){var l,o;if(void 0===this.it){for(let o in this.it=new Set,void 0!==e.strings&&(this.nt=new Set(e.strings.join(" ").split(/\s/).filter(e=>""!==e))),t)!t[o]||(null===(l=this.nt)||void 0===l?void 0:l.has(o))||this.it.add(o);return this.render(t)}let n=e.element.classList;for(let e in this.it.forEach(e=>{e in t||(n.remove(e),this.it.delete(e))}),t){let l=!!t[e];l===this.it.has(e)||(null===(o=this.nt)||void 0===o?void 0:o.has(e))||(l?(n.add(e),this.it.add(e)):(n.remove(e),this.it.delete(e)))}return et}},(...e)=>({_$litDirective$:ec,values:e}));var ec,ed,em,eh,ep,eu,eg=l(39670);let ew={duration:.3,delay:0,endDelay:0,repeat:0,easing:"ease"},ev={ms:e=>1e3*e,s:e=>e/1e3},noop=()=>{},noopReturn=e=>e;function stopAnimation(e,t=!0){if(e&&"finished"!==e.playState)try{e.stop?e.stop():(t&&e.commitStyles(),e.cancel())}catch(e){}}let createAnimation=e=>e(),withControls=(e,t,l=ew.duration)=>new Proxy({animations:e.map(createAnimation).filter(Boolean),duration:l,options:t},ef),getActiveAnimation=e=>e.animations[0],ef={get:(e,t)=>{let l=getActiveAnimation(e);switch(t){case"duration":return e.duration;case"currentTime":return ev.s((null==l?void 0:l[t])||0);case"playbackRate":case"playState":return null==l?void 0:l[t];case"finished":return e.finished||(e.finished=Promise.all(e.animations.map(selectFinished)).catch(noop)),e.finished;case"stop":return()=>{e.animations.forEach(e=>stopAnimation(e))};case"forEachNative":return t=>{e.animations.forEach(l=>t(l,e))};default:return void 0===(null==l?void 0:l[t])?void 0:()=>e.animations.forEach(e=>e[t]())}},set:(e,t,l)=>{switch(t){case"currentTime":l=ev.ms(l);case"playbackRate":for(let o=0;oe.finished,isEasingGenerator=e=>"object"==typeof e&&!!e.createAnimation,is_number_es_isNumber=e=>"number"==typeof e,isEasingList=e=>Array.isArray(e)&&!is_number_es_isNumber(e[0]),mix=(e,t,l)=>-l*e+l*t+e,progress=(e,t,l)=>t-e==0?1:(l-e)/(t-e);function fillOffset(e,t){let l=e[e.length-1];for(let o=1;o<=t;o++){let n=progress(0,t,o);e.push(mix(l,1,n))}}let wrap=(e,t,l)=>{let o=t-e;return((l-e)%o+o)%o+e},clamp=(e,t,l)=>Math.min(Math.max(l,e),t),calcBezier=(e,t,l)=>(((1-3*l+3*t)*e+(3*l-6*t))*e+3*t)*e;function cubicBezier(e,t,l,o){if(e===t&&l===o)return noopReturn;let getTForX=t=>(function(e,t,l,o,n){let s,c;let d=0;do(s=calcBezier(c=t+(l-t)/2,o,n)-e)>0?l=c:t=c;while(Math.abs(s)>1e-7&&++d<12);return c})(t,0,1,e,l);return e=>0===e||1===e?e:calcBezier(getTForX(e),t,o)}let steps=(e,t="end")=>l=>{l="end"===t?Math.min(l,.999):Math.max(l,.001);let o=l*e,n="end"===t?Math.floor(o):Math.ceil(o);return clamp(0,1,n/e)},isFunction=e=>"function"==typeof e,isCubicBezier=e=>Array.isArray(e)&&is_number_es_isNumber(e[0]),eb={ease:cubicBezier(.25,.1,.25,1),"ease-in":cubicBezier(.42,0,1,1),"ease-in-out":cubicBezier(.42,0,.58,1),"ease-out":cubicBezier(0,0,.58,1)},ey=/\((.*?)\)/;function easing_es_getEasingFunction(e){if(isFunction(e))return e;if(isCubicBezier(e))return cubicBezier(...e);if(eb[e])return eb[e];if(e.startsWith("steps")){let t=ey.exec(e);if(t){let e=t[1].split(",");return steps(parseFloat(e[0]),e[1].trim())}}return noopReturn}let Animation=class Animation{constructor(e,t=[0,1],{easing:l,duration:o=ew.duration,delay:n=ew.delay,endDelay:s=ew.endDelay,repeat:c=ew.repeat,offset:d,direction:m="normal"}={}){if(this.startTime=null,this.rate=1,this.t=0,this.cancelTimestamp=null,this.easing=noopReturn,this.duration=0,this.totalDuration=0,this.repeat=0,this.playState="idle",this.finished=new Promise((e,t)=>{this.resolve=e,this.reject=t}),isEasingGenerator(l=l||ew.easing)){let e=l.createAnimation(t);l=e.easing,t=e.keyframes||t,o=e.duration||o}this.repeat=c,this.easing=isEasingList(l)?noopReturn:easing_es_getEasingFunction(l),this.updateDuration(o);let h=function(e,t=function(e){let t=[0];return fillOffset(t,e-1),t}(e.length),l=noopReturn){let o=e.length,n=o-t.length;return n>0&&fillOffset(t,n),n=>{var s;let c=0;for(;c{var l;let o=0;o=void 0!==this.pauseTime?this.pauseTime:(t-this.startTime)*this.rate,this.t=o,o/=1e3,o=Math.max(o-n,0),"finished"===this.playState&&void 0===this.pauseTime&&(o=this.totalDuration);let c=o/this.duration,d=Math.floor(c),p=c%1;!p&&c>=1&&(p=1),1===p&&d--;let g=d%2;("reverse"===m||"alternate"===m&&g||"alternate-reverse"===m&&!g)&&(p=1-p);let f=o>=this.totalDuration?1:Math.min(p,1),b=h(this.easing(f));e(b);let y=void 0===this.pauseTime&&("finished"===this.playState||o>=this.totalDuration+s);y?(this.playState="finished",null===(l=this.resolve)||void 0===l||l.call(this,b)):"idle"!==this.playState&&(this.frameRequestId=requestAnimationFrame(this.tick))},this.play()}play(){let e=performance.now();this.playState="running",void 0!==this.pauseTime?this.startTime=e-this.pauseTime:this.startTime||(this.startTime=e),this.cancelTimestamp=this.startTime,this.pauseTime=void 0,this.frameRequestId=requestAnimationFrame(this.tick)}pause(){this.playState="paused",this.pauseTime=this.t}finish(){this.playState="finished",this.tick(0)}stop(){var e;this.playState="idle",void 0!==this.frameRequestId&&cancelAnimationFrame(this.frameRequestId),null===(e=this.reject)||void 0===e||e.call(this,!1)}cancel(){this.stop(),this.tick(this.cancelTimestamp)}reverse(){this.rate*=-1}commitStyles(){}updateDuration(e){this.duration=e,this.totalDuration=e*(this.repeat+1)}get currentTime(){return this.t}set currentTime(e){void 0!==this.pauseTime||0===this.rate?this.pauseTime=e:this.startTime=performance.now()-e/this.rate}get playbackRate(){return this.rate}set playbackRate(e){this.rate=e}};var invariant=function(){};let MotionValue=class MotionValue{setAnimation(e){this.animation=e,null==e||e.finished.then(()=>this.clearAnimation()).catch(()=>{})}clearAnimation(){this.animation=this.generator=void 0}};let e_=new WeakMap;function getAnimationData(e){return e_.has(e)||e_.set(e,{transforms:[],values:new Map}),e_.get(e)}let ex=["","X","Y","Z"],e$={x:"translateX",y:"translateY",z:"translateZ"},eC={syntax:"",initialValue:"0deg",toDefaultUnit:e=>e+"deg"},eA={translate:{syntax:"",initialValue:"0px",toDefaultUnit:e=>e+"px"},rotate:eC,scale:{syntax:"",initialValue:1,toDefaultUnit:noopReturn},skew:eC},eE=new Map,asTransformCssVar=e=>`--motion-${e}`,eO=["x","y","z"];["translate","scale","rotate","skew"].forEach(e=>{ex.forEach(t=>{eO.push(e+t),eE.set(asTransformCssVar(e+t),eA[e])})});let compareTransformOrder=(e,t)=>eO.indexOf(e)-eO.indexOf(t),ek=new Set(eO),isTransform=e=>ek.has(e),addTransformToElement=(e,t)=>{var l;e$[t]&&(t=e$[t]);let{transforms:o}=getAnimationData(e);l=t,-1===o.indexOf(l)&&o.push(l),e.style.transform=buildTransformTemplate(o)},buildTransformTemplate=e=>e.sort(compareTransformOrder).reduce(transformListToString,"").trim(),transformListToString=(e,t)=>`${e} ${t}(var(${asTransformCssVar(t)}))`,isCssVar=e=>e.startsWith("--"),eT=new Set,testAnimation=(e,t)=>document.createElement("div").animate(e,t),eI={cssRegisterProperty:()=>"undefined"!=typeof CSS&&Object.hasOwnProperty.call(CSS,"registerProperty"),waapi:()=>Object.hasOwnProperty.call(Element.prototype,"animate"),partialKeyframes:()=>{try{testAnimation({opacity:[1]})}catch(e){return!1}return!0},finished:()=>!!testAnimation({opacity:[0,1]},{duration:.001}).finished,linearEasing:()=>{try{testAnimation({opacity:0},{easing:"linear(0, 1)"})}catch(e){return!1}return!0}},eS={},eR={};for(let e in eI)eR[e]=()=>(void 0===eS[e]&&(eS[e]=eI[e]()),eS[e]);let generateLinearEasingPoints=(e,t)=>{let l="",o=Math.round(t/.015);for(let t=0;tisFunction(e)?eR.linearEasing()?`linear(${generateLinearEasingPoints(e,t)})`:ew.easing:isCubicBezier(e)?cubicBezierAsString(e):e,cubicBezierAsString=([e,t,l,o])=>`cubic-bezier(${e}, ${t}, ${l}, ${o})`,keyframesList=e=>Array.isArray(e)?e:[e];function getStyleName(e){return e$[e]&&(e=e$[e]),isTransform(e)?asTransformCssVar(e):e}let eP={get:(e,t)=>{let l=isCssVar(t=getStyleName(t))?e.style.getPropertyValue(t):getComputedStyle(e)[t];if(!l&&0!==l){let e=eE.get(t);e&&(l=e.initialValue)}return l},set:(e,t,l)=>{isCssVar(t=getStyleName(t))?e.style.setProperty(t,l):e.style[t]=l}},isString=e=>"string"==typeof e,getOptions=(e,t)=>e[t]?Object.assign(Object.assign({},e),e[t]):Object.assign({},e),animate=function(e,t,l={}){var o,n,s,c,d;"string"==typeof(o=e)?n?(null!==(s=n[o])&&void 0!==s||(n[o]=document.querySelectorAll(o)),o=n[o]):o=document.querySelectorAll(o):o instanceof Element&&(o=[o]),e=Array.from(o||[]);let m=e.length;invariant(!!m,"No valid element provided."),invariant(!!t,"No keyframes defined.");let h=[];for(let o=0;o{let readInitialValue=()=>{var t,l;return null!==(l=null!==(t=eP.get(e,O))&&void 0!==t?t:null==I?void 0:I.initialValue)&&void 0!==l?l:0},s=function(e,t){for(let l=0;lt+e)}return o}(s,I);if(isEasingGenerator(b)){let e=b.createAnimation(s,"opacity"!==t,readInitialValue,O,T);b=e.easing,s=e.keyframes||s,h=e.duration||h}if(isCssVar(O)&&(eR.cssRegisterProperty()?function(e){if(!eT.has(e)){eT.add(e);try{let{syntax:t,initialValue:l}=eE.has(e)?eE.get(e):{};CSS.registerProperty({name:e,inherits:!1,syntax:t,initialValue:l})}catch(e){}}}(O):E=!1),A&&!eR.linearEasing()&&(isFunction(b)||isEasingList(b)&&b.some(isFunction))&&(E=!1),E){I&&(s=s.map(e=>is_number_es_isNumber(e)?I.toDefaultUnit(e):e)),1===s.length&&(!eR.partialKeyframes()||m)&&s.unshift(readInitialValue());let t={delay:ev.ms(p),duration:ev.ms(h),endDelay:ev.ms(g),easing:isEasingList(b)?void 0:convertEasing(b,h),direction:_,iterations:f+1,fill:"both"};(c=e.animate({[O]:s,offset:x,easing:isEasingList(b)?b.map(e=>convertEasing(e,h)):void 0},t)).finished||(c.finished=new Promise((e,t)=>{c.onfinish=e,c.oncancel=t}));let l=s[s.length-1];c.finished.then(()=>{y||(eP.set(e,O,l),c.cancel())}).catch(noop),$||(c.playbackRate=1.000001)}else if(n&&A)1===(s=s.map(e=>"string"==typeof e?parseFloat(e):e)).length&&s.unshift(parseFloat(readInitialValue())),c=new n(t=>{eP.set(e,O,C?C(t):t)},s,Object.assign(Object.assign({},o),{duration:h,easing:b}));else{let t=s[s.length-1];eP.set(e,O,I&&is_number_es_isNumber(t)?I.toDefaultUnit(t):t)}return m&&d(e,t,s,{duration:h,delay:p,easing:b,repeat:f,offset:x},"motion-one"),T.setAnimation(c),c}}(n,e,t[e],s,Animation);h.push(p)}}return withControls(h,l,l.duration)};function animateProgress(e,t={}){return withControls([()=>{let l=new Animation(e,[0,1],t);return l.finished.catch(()=>{}),l}],t,t.duration)}function animate_es_animate(e,t,l){let o=isFunction(e)?animateProgress:animate;return o(e,t,l)}/** + * @license + * Copyright 2018 Google LLC + * SPDX-License-Identifier: BSD-3-Clause + */let if_defined_l=e=>null!=e?e:er;var eM=l(75298),eL=Object.defineProperty,eW=Object.getOwnPropertySymbols,eN=Object.prototype.hasOwnProperty,ej=Object.prototype.propertyIsEnumerable,Ue=(e,t,l)=>t in e?eL(e,t,{enumerable:!0,configurable:!0,writable:!0,value:l}):e[t]=l,ve=(e,t)=>{for(var l in t||(t={}))eN.call(t,l)&&Ue(e,l,t[l]);if(eW)for(var l of eW(t))ej.call(t,l)&&Ue(e,l,t[l]);return e};function He(){return{"--wcm-accent-color":"#3396FF","--wcm-accent-fill-color":"#FFFFFF","--wcm-z-index":"89","--wcm-background-color":"#3396FF","--wcm-background-border-radius":"8px","--wcm-container-border-radius":"30px","--wcm-wallet-icon-border-radius":"15px","--wcm-wallet-icon-large-border-radius":"30px","--wcm-wallet-icon-small-border-radius":"7px","--wcm-input-border-radius":"28px","--wcm-button-border-radius":"10px","--wcm-notification-border-radius":"36px","--wcm-secondary-button-border-radius":"28px","--wcm-icon-button-border-radius":"50%","--wcm-button-hover-highlight-border-radius":"10px","--wcm-text-big-bold-size":"20px","--wcm-text-big-bold-weight":"600","--wcm-text-big-bold-line-height":"24px","--wcm-text-big-bold-letter-spacing":"-0.03em","--wcm-text-big-bold-text-transform":"none","--wcm-text-xsmall-bold-size":"10px","--wcm-text-xsmall-bold-weight":"700","--wcm-text-xsmall-bold-line-height":"12px","--wcm-text-xsmall-bold-letter-spacing":"0.02em","--wcm-text-xsmall-bold-text-transform":"uppercase","--wcm-text-xsmall-regular-size":"12px","--wcm-text-xsmall-regular-weight":"600","--wcm-text-xsmall-regular-line-height":"14px","--wcm-text-xsmall-regular-letter-spacing":"-0.03em","--wcm-text-xsmall-regular-text-transform":"none","--wcm-text-small-thin-size":"14px","--wcm-text-small-thin-weight":"500","--wcm-text-small-thin-line-height":"16px","--wcm-text-small-thin-letter-spacing":"-0.03em","--wcm-text-small-thin-text-transform":"none","--wcm-text-small-regular-size":"14px","--wcm-text-small-regular-weight":"600","--wcm-text-small-regular-line-height":"16px","--wcm-text-small-regular-letter-spacing":"-0.03em","--wcm-text-small-regular-text-transform":"none","--wcm-text-medium-regular-size":"16px","--wcm-text-medium-regular-weight":"600","--wcm-text-medium-regular-line-height":"20px","--wcm-text-medium-regular-letter-spacing":"-0.03em","--wcm-text-medium-regular-text-transform":"none","--wcm-font-family":"-apple-system, system-ui, BlinkMacSystemFont, 'Segoe UI', Roboto, Ubuntu, 'Helvetica Neue', sans-serif","--wcm-font-feature-settings":"'tnum' on, 'lnum' on, 'case' on","--wcm-success-color":"rgb(38,181,98)","--wcm-error-color":"rgb(242, 90, 103)","--wcm-overlay-background-color":"rgba(0, 0, 0, 0.3)","--wcm-overlay-backdrop-filter":"none"}}let eD={getPreset:e=>He()[e],setTheme(){let e=document.querySelector(":root"),{themeVariables:t}=eg.ThemeCtrl.state;if(e){let l=ve(ve(ve({},function(){var e;let t=null!=(e=eg.ThemeCtrl.state.themeMode)?e:"dark",l={light:{foreground:{1:"rgb(20,20,20)",2:"rgb(121,134,134)",3:"rgb(158,169,169)"},background:{1:"rgb(255,255,255)",2:"rgb(241,243,243)",3:"rgb(228,231,231)"},overlay:"rgba(0,0,0,0.1)"},dark:{foreground:{1:"rgb(228,231,231)",2:"rgb(148,158,158)",3:"rgb(110,119,119)"},background:{1:"rgb(20,20,20)",2:"rgb(39,42,42)",3:"rgb(59,64,64)"},overlay:"rgba(255,255,255,0.1)"}}[t];return{"--wcm-color-fg-1":l.foreground[1],"--wcm-color-fg-2":l.foreground[2],"--wcm-color-fg-3":l.foreground[3],"--wcm-color-bg-1":l.background[1],"--wcm-color-bg-2":l.background[2],"--wcm-color-bg-3":l.background[3],"--wcm-color-overlay":l.overlay}}()),He()),t);Object.entries(l).forEach(([t,l])=>e.style.setProperty(t,l))}},globalCss:i`*,::after,::before{margin:0;padding:0;box-sizing:border-box;font-style:normal;text-rendering:optimizeSpeed;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;-webkit-tap-highlight-color:transparent;backface-visibility:hidden}button{cursor:pointer;display:flex;justify-content:center;align-items:center;position:relative;border:none;background-color:transparent;transition:all .2s ease}@media (hover:hover) and (pointer:fine){button:active{transition:all .1s ease;transform:scale(.93)}}button::after{content:'';position:absolute;top:0;bottom:0;left:0;right:0;transition:background-color,.2s ease}button:disabled{cursor:not-allowed}button svg,button wcm-text{position:relative;z-index:1}input{border:none;outline:0;appearance:none}img{display:block}::selection{color:var(--wcm-accent-fill-color);background:var(--wcm-accent-color)}`},ez=i`button{border-radius:var(--wcm-secondary-button-border-radius);height:28px;padding:0 10px;background-color:var(--wcm-accent-color)}button path{fill:var(--wcm-accent-fill-color)}button::after{border-radius:inherit;border:1px solid var(--wcm-color-overlay)}button:disabled::after{background-color:transparent}.wcm-icon-left svg{margin-right:5px}.wcm-icon-right svg{margin-left:5px}button:active::after{background-color:var(--wcm-color-overlay)}.wcm-ghost,.wcm-ghost:active::after,.wcm-outline{background-color:transparent}.wcm-ghost:active{opacity:.5}@media(hover:hover){button:hover::after{background-color:var(--wcm-color-overlay)}.wcm-ghost:hover::after{background-color:transparent}.wcm-ghost:hover{opacity:.5}}button:disabled{background-color:var(--wcm-color-bg-3);pointer-events:none}.wcm-ghost::after{border-color:transparent}.wcm-ghost path{fill:var(--wcm-color-fg-2)}.wcm-outline path{fill:var(--wcm-accent-color)}.wcm-outline:disabled{background-color:transparent;opacity:.5}`;var eU=Object.defineProperty,eH=Object.getOwnPropertyDescriptor,F=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?eH(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&eU(t,l,s),s};let eB=class extends lit_element_s{constructor(){super(...arguments),this.disabled=!1,this.iconLeft=void 0,this.iconRight=void 0,this.onClick=()=>null,this.variant="default"}render(){let e={"wcm-icon-left":void 0!==this.iconLeft,"wcm-icon-right":void 0!==this.iconRight,"wcm-ghost":"ghost"===this.variant,"wcm-outline":"outline"===this.variant},t="inverse";return"ghost"===this.variant&&(t="secondary"),"outline"===this.variant&&(t="accent"),J``}};eB.styles=[eD.globalCss,ez],F([property_n({type:Boolean})],eB.prototype,"disabled",2),F([property_n()],eB.prototype,"iconLeft",2),F([property_n()],eB.prototype,"iconRight",2),F([property_n()],eB.prototype,"onClick",2),F([property_n()],eB.prototype,"variant",2),eB=F([custom_element_e("wcm-button")],eB);let eV=i`:host{display:inline-block}button{padding:0 15px 1px;height:40px;border-radius:var(--wcm-button-border-radius);color:var(--wcm-accent-fill-color);background-color:var(--wcm-accent-color)}button::after{content:'';top:0;bottom:0;left:0;right:0;position:absolute;background-color:transparent;border-radius:inherit;transition:background-color .2s ease;border:1px solid var(--wcm-color-overlay)}button:active::after{background-color:var(--wcm-color-overlay)}button:disabled{padding-bottom:0;background-color:var(--wcm-color-bg-3);color:var(--wcm-color-fg-3)}.wcm-secondary{color:var(--wcm-accent-color);background-color:transparent}.wcm-secondary::after{display:none}@media(hover:hover){button:hover::after{background-color:var(--wcm-color-overlay)}}`;var eZ=Object.defineProperty,eF=Object.getOwnPropertyDescriptor,ue=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?eF(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&eZ(t,l,s),s};let eq=class extends lit_element_s{constructor(){super(...arguments),this.disabled=!1,this.variant="primary"}render(){let e={"wcm-secondary":"secondary"===this.variant};return J``}};eq.styles=[eD.globalCss,eV],ue([property_n({type:Boolean})],eq.prototype,"disabled",2),ue([property_n()],eq.prototype,"variant",2),eq=ue([custom_element_e("wcm-button-big")],eq);let eK=i`:host{background-color:var(--wcm-color-bg-2);border-top:1px solid var(--wcm-color-bg-3)}div{padding:10px 20px;display:inherit;flex-direction:inherit;align-items:inherit;width:inherit;justify-content:inherit}`;var eG=Object.defineProperty,eY=Object.getOwnPropertyDescriptor;let eQ=class extends lit_element_s{render(){return J`
`}};eQ.styles=[eD.globalCss,eK],eQ=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?eY(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&eG(t,l,s),s})([custom_element_e("wcm-info-footer")],eQ);let eX={CROSS_ICON:ee``,WALLET_CONNECT_LOGO:ee``,WALLET_CONNECT_ICON:ee``,WALLET_CONNECT_ICON_COLORED:ee``,BACK_ICON:ee``,COPY_ICON:ee``,RETRY_ICON:ee``,DESKTOP_ICON:ee``,MOBILE_ICON:ee``,ARROW_DOWN_ICON:ee``,ARROW_UP_RIGHT_ICON:ee``,ARROW_RIGHT_ICON:ee``,QRCODE_ICON:ee``,SCAN_ICON:ee``,CHECKMARK_ICON:ee``,SEARCH_ICON:ee``,WALLET_PLACEHOLDER:ee``,GLOBE_ICON:ee``},eJ=i`.wcm-toolbar-placeholder{top:0;bottom:0;left:0;right:0;width:100%;position:absolute;display:block;pointer-events:none;height:100px;border-radius:calc(var(--wcm-background-border-radius) * .9);background-color:var(--wcm-background-color);background-position:center;background-size:cover}.wcm-toolbar{height:38px;display:flex;position:relative;margin:5px 15px 5px 5px;justify-content:space-between;align-items:center}.wcm-toolbar img,.wcm-toolbar svg{height:28px;object-position:left center;object-fit:contain}#wcm-wc-logo path{fill:var(--wcm-accent-fill-color)}button{width:28px;height:28px;border-radius:var(--wcm-icon-button-border-radius);border:0;display:flex;justify-content:center;align-items:center;cursor:pointer;background-color:var(--wcm-color-bg-1);box-shadow:0 0 0 1px var(--wcm-color-overlay)}button:active{background-color:var(--wcm-color-bg-2)}button svg{display:block;object-position:center}button path{fill:var(--wcm-color-fg-1)}.wcm-toolbar div{display:flex}@media(hover:hover){button:hover{background-color:var(--wcm-color-bg-2)}}`;var e0=Object.defineProperty,e1=Object.getOwnPropertyDescriptor;let e2=class extends lit_element_s{render(){return J`
${eX.WALLET_CONNECT_LOGO}
`}};e2.styles=[eD.globalCss,eJ],e2=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?e1(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&e0(t,l,s),s})([custom_element_e("wcm-modal-backcard")],e2);let e5=i`main{padding:20px;padding-top:0;width:100%}`;var e3=Object.defineProperty,e4=Object.getOwnPropertyDescriptor;let e7=class extends lit_element_s{render(){return J`
`}};e7.styles=[eD.globalCss,e5],e7=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?e4(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&e3(t,l,s),s})([custom_element_e("wcm-modal-content")],e7);let e6=i`footer{padding:10px;display:flex;flex-direction:column;align-items:inherit;justify-content:inherit;border-top:1px solid var(--wcm-color-bg-2)}`;var e8=Object.defineProperty,e9=Object.getOwnPropertyDescriptor;let tt=class extends lit_element_s{render(){return J`
`}};tt.styles=[eD.globalCss,e6],tt=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?e9(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&e8(t,l,s),s})([custom_element_e("wcm-modal-footer")],tt);let tr=i`header{display:flex;justify-content:center;align-items:center;padding:20px;position:relative}.wcm-border{border-bottom:1px solid var(--wcm-color-bg-2);margin-bottom:20px}header button{padding:15px 20px}header button:active{opacity:.5}@media(hover:hover){header button:hover{opacity:.5}}.wcm-back-btn{position:absolute;left:0}.wcm-action-btn{position:absolute;right:0}path{fill:var(--wcm-accent-color)}`;var ti=Object.defineProperty,tl=Object.getOwnPropertyDescriptor,te=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tl(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&ti(t,l,s),s};let to=class extends lit_element_s{constructor(){super(...arguments),this.title="",this.onAction=void 0,this.actionIcon=void 0,this.border=!1}backBtnTemplate(){return J``}actionBtnTemplate(){return J``}render(){let e={"wcm-border":this.border},t=eg.AV.state.history.length>1,l=this.title?J`${this.title}`:J``;return J`
${t?this.backBtnTemplate():null} ${l} ${this.onAction?this.actionBtnTemplate():null}
`}};to.styles=[eD.globalCss,tr],te([property_n()],to.prototype,"title",2),te([property_n()],to.prototype,"onAction",2),te([property_n()],to.prototype,"actionIcon",2),te([property_n({type:Boolean})],to.prototype,"border",2),to=te([custom_element_e("wcm-modal-header")],to);let ta={MOBILE_BREAKPOINT:600,WCM_RECENT_WALLET_DATA:"WCM_RECENT_WALLET_DATA",EXPLORER_WALLET_URL:"https://explorer.walletconnect.com/?type=wallet",getShadowRootElement(e,t){let l=e.renderRoot.querySelector(t);if(!l)throw Error(`${t} not found`);return l},getWalletIcon({id:e,image_id:t}){let{walletImages:l}=eg.ConfigCtrl.state;return null!=l&&l[e]?l[e]:t?eg.ExplorerCtrl.getWalletImageUrl(t):""},getWalletName:(e,t=!1)=>t&&e.length>8?`${e.substring(0,8)}..`:e,isMobileAnimation:()=>window.innerWidth<=ta.MOBILE_BREAKPOINT,async preloadImage(e){let t=new Promise((t,l)=>{let o=new Image;o.onload=t,o.onerror=l,o.crossOrigin="anonymous",o.src=e});return Promise.race([t,eg.zv.wait(3e3)])},getErrorMessage:e=>e instanceof Error?e.message:"Unknown Error",debounce(e,t=500){let l;return(...o)=>{l&&clearTimeout(l),l=setTimeout(function(){e(...o)},t)}},handleMobileLinking(e){let t;let{walletConnectUri:l}=eg.OptionsCtrl.state,{mobile:o,name:n}=e,s=o?.native,c=o?.universal;ta.setRecentWallet(e),l&&(t="",s?t=eg.zv.formatUniversalUrl(s,l,n):c&&(t=eg.zv.formatNativeUrl(c,l,n)),eg.zv.openHref(t,"_self"))},handleAndroidLinking(){let{walletConnectUri:e}=eg.OptionsCtrl.state;e&&(eg.zv.setWalletConnectAndroidDeepLink(e),eg.zv.openHref(e,"_self"))},async handleUriCopy(){let{walletConnectUri:e}=eg.OptionsCtrl.state;if(e)try{await navigator.clipboard.writeText(e),eg.ToastCtrl.openToast("Link copied","success")}catch{eg.ToastCtrl.openToast("Failed to copy","error")}},getCustomImageUrls(){let{walletImages:e}=eg.ConfigCtrl.state,t=Object.values(e??{});return Object.values(t)},truncate:(e,t=8)=>e.length<=t?e:`${e.substring(0,4)}...${e.substring(e.length-4)}`,setRecentWallet(e){try{localStorage.setItem(ta.WCM_RECENT_WALLET_DATA,JSON.stringify(e))}catch{console.info("Unable to set recent wallet")}},getRecentWallet(){try{let e=localStorage.getItem(ta.WCM_RECENT_WALLET_DATA);return e?JSON.parse(e):void 0}catch{console.info("Unable to get recent wallet")}},caseSafeIncludes:(e,t)=>e.toUpperCase().includes(t.toUpperCase()),openWalletExplorerUrl(){eg.zv.openHref(ta.EXPLORER_WALLET_URL,"_blank")},getCachedRouterWalletPlatforms(){let{desktop:e,mobile:t}=eg.zv.getWalletRouterData(),l=!!e?.native,o=!!e?.universal,n=!!t?.native||!!t?.universal;return{isDesktop:l,isMobile:n,isWeb:o}},goToConnectingView(e){eg.AV.setData({Wallet:e});let t=eg.zv.isMobile(),{isDesktop:l,isWeb:o,isMobile:n}=ta.getCachedRouterWalletPlatforms();t?n?eg.AV.push("MobileConnecting"):o?eg.AV.push("WebConnecting"):eg.AV.push("InstallWallet"):l?eg.AV.push("DesktopConnecting"):o?eg.AV.push("WebConnecting"):n?eg.AV.push("MobileQrcodeConnecting"):eg.AV.push("InstallWallet")}},tn=i`.wcm-router{overflow:hidden;will-change:transform}.wcm-content{display:flex;flex-direction:column}`;var ts=Object.defineProperty,tc=Object.getOwnPropertyDescriptor,$e=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tc(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&ts(t,l,s),s};let td=class extends lit_element_s{constructor(){super(),this.view=eg.AV.state.view,this.prevView=eg.AV.state.view,this.unsubscribe=void 0,this.oldHeight="0px",this.resizeObserver=void 0,this.unsubscribe=eg.AV.subscribe(e=>{this.view!==e.view&&this.onChangeRoute()})}firstUpdated(){this.resizeObserver=new ResizeObserver(([e])=>{let t=`${e.contentRect.height}px`;"0px"!==this.oldHeight&&animate_es_animate(this.routerEl,{height:[this.oldHeight,t]},{duration:.2}),this.oldHeight=t}),this.resizeObserver.observe(this.contentEl)}disconnectedCallback(){var e,t;null==(e=this.unsubscribe)||e.call(this),null==(t=this.resizeObserver)||t.disconnect()}get routerEl(){return ta.getShadowRootElement(this,".wcm-router")}get contentEl(){return ta.getShadowRootElement(this,".wcm-content")}viewTemplate(){switch(this.view){case"ConnectWallet":return J``;case"DesktopConnecting":return J``;case"MobileConnecting":return J``;case"WebConnecting":return J``;case"MobileQrcodeConnecting":return J``;case"WalletExplorer":return J``;case"Qrcode":return J``;case"InstallWallet":return J``;default:return J`
Not Found
`}}async onChangeRoute(){await animate_es_animate(this.routerEl,{opacity:[1,0],scale:[1,1.02]},{duration:.15,delay:.1}).finished,this.view=eg.AV.state.view,animate_es_animate(this.routerEl,{opacity:[0,1],scale:[.99,1]},{duration:.37,delay:.05})}render(){return J`
${this.viewTemplate()}
`}};td.styles=[eD.globalCss,tn],$e([state_t()],td.prototype,"view",2),$e([state_t()],td.prototype,"prevView",2),td=$e([custom_element_e("wcm-modal-router")],td);let tm=i`div{height:36px;width:max-content;display:flex;justify-content:center;align-items:center;padding:9px 15px 11px;position:absolute;top:12px;box-shadow:0 6px 14px -6px rgba(10,16,31,.3),0 10px 32px -4px rgba(10,16,31,.15);z-index:2;left:50%;transform:translateX(-50%);pointer-events:none;backdrop-filter:blur(20px) saturate(1.8);-webkit-backdrop-filter:blur(20px) saturate(1.8);border-radius:var(--wcm-notification-border-radius);border:1px solid var(--wcm-color-overlay);background-color:var(--wcm-color-overlay)}svg{margin-right:5px}@-moz-document url-prefix(){div{background-color:var(--wcm-color-bg-3)}}.wcm-success path{fill:var(--wcm-accent-color)}.wcm-error path{fill:var(--wcm-error-color)}`;var th=Object.defineProperty,tp=Object.getOwnPropertyDescriptor,ze=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tp(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&th(t,l,s),s};let tu=class extends lit_element_s{constructor(){super(),this.open=!1,this.unsubscribe=void 0,this.timeout=void 0,this.unsubscribe=eg.ToastCtrl.subscribe(e=>{e.open?(this.open=!0,this.timeout=setTimeout(()=>eg.ToastCtrl.closeToast(),2200)):(this.open=!1,clearTimeout(this.timeout))})}disconnectedCallback(){var e;null==(e=this.unsubscribe)||e.call(this),clearTimeout(this.timeout),eg.ToastCtrl.closeToast()}render(){let{message:e,variant:t}=eg.ToastCtrl.state;return this.open?J`
${"success"===t?eX.CHECKMARK_ICON:null} ${"error"===t?eX.CROSS_ICON:null}${e}
`:null}};function Ce(e,t,l){return e!==t&&(e-t<0?t-e:e-t)<=l+.1}tu.styles=[eD.globalCss,tm],ze([state_t()],tu.prototype,"open",2),tu=ze([custom_element_e("wcm-modal-toast")],tu);let tg={generate(e,t,l){let o="#141414",n=[],s=function(e,t){let l=Array.prototype.slice.call(eM.create(e,{errorCorrectionLevel:"Q"}).modules.data,0),o=Math.sqrt(l.length);return l.reduce((e,t,l)=>(l%o==0?e.push([t]):e[e.length-1].push(t))&&e,[])}(e,0),c=t/s.length,d=[{x:0,y:0},{x:1,y:0},{x:0,y:1}];d.forEach(({x:e,y:t})=>{let l=(s.length-7)*c*e,m=(s.length-7)*c*t;for(let e=0;e`)}});let m=Math.floor((l+25)/c),h=s.length/2-m/2,p=s.length/2+m/2-1,g=[];s.forEach((e,t)=>{e.forEach((e,l)=>{if(s[t][l]&&!(t<7&&l<7||t>s.length-8&&l<7||t<7&&l>s.length-8)&&!(t>h&&th&&l{f[e]?f[e].push(t):f[e]=[t]}),Object.entries(f).map(([e,t])=>{let l=t.filter(e=>t.every(t=>!Ce(e,t,c)));return[Number(e),l]}).forEach(([e,t])=>{t.forEach(t=>{n.push(ee``)})}),Object.entries(f).filter(([e,t])=>t.length>1).map(([e,t])=>{let l=t.filter(e=>t.some(t=>Ce(e,t,c)));return[Number(e),l]}).map(([e,t])=>{t.sort((e,t)=>et.some(t=>Ce(e,t,c)));t?t.push(e):l.push([e])}return[e,l.map(e=>[e[0],e[e.length-1]])]}).forEach(([e,t])=>{t.forEach(([t,l])=>{n.push(ee``)})}),n}},tw=i`@keyframes fadeIn{0%{opacity:0}100%{opacity:1}}div{position:relative;user-select:none;display:block;overflow:hidden;aspect-ratio:1/1;animation:fadeIn ease .2s}.wcm-dark{background-color:#fff;border-radius:var(--wcm-container-border-radius);padding:18px;box-shadow:0 2px 5px #000}svg:first-child,wcm-wallet-image{position:absolute;top:50%;left:50%;transform:translateY(-50%) translateX(-50%)}wcm-wallet-image{transform:translateY(-50%) translateX(-50%)}wcm-wallet-image{width:25%;height:25%;border-radius:var(--wcm-wallet-icon-border-radius)}svg:first-child{transform:translateY(-50%) translateX(-50%) scale(.9)}svg:first-child path:first-child{fill:var(--wcm-accent-color)}svg:first-child path:last-child{stroke:var(--wcm-color-overlay)}`;var tv=Object.defineProperty,tf=Object.getOwnPropertyDescriptor,q=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tf(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tv(t,l,s),s};let tb=class extends lit_element_s{constructor(){super(...arguments),this.uri="",this.size=0,this.imageId=void 0,this.walletId=void 0,this.imageUrl=void 0}svgTemplate(){let e="light"===eg.ThemeCtrl.state.themeMode?this.size:this.size-36;return ee`${tg.generate(this.uri,e,e/4)}`}render(){let e={"wcm-dark":"dark"===eg.ThemeCtrl.state.themeMode};return J`
${this.walletId||this.imageUrl?J``:eX.WALLET_CONNECT_ICON_COLORED} ${this.svgTemplate()}
`}};tb.styles=[eD.globalCss,tw],q([property_n()],tb.prototype,"uri",2),q([property_n({type:Number})],tb.prototype,"size",2),q([property_n()],tb.prototype,"imageId",2),q([property_n()],tb.prototype,"walletId",2),q([property_n()],tb.prototype,"imageUrl",2),tb=q([custom_element_e("wcm-qrcode")],tb);let ty=i`:host{position:relative;height:28px;width:80%}input{width:100%;height:100%;line-height:28px!important;border-radius:var(--wcm-input-border-radius);font-style:normal;font-family:-apple-system,system-ui,BlinkMacSystemFont,'Segoe UI',Roboto,Ubuntu,'Helvetica Neue',sans-serif;font-feature-settings:'case' on;font-weight:500;font-size:16px;letter-spacing:-.03em;padding:0 10px 0 34px;transition:.2s all ease;color:var(--wcm-color-fg-1);background-color:var(--wcm-color-bg-3);box-shadow:inset 0 0 0 1px var(--wcm-color-overlay);caret-color:var(--wcm-accent-color)}input::placeholder{color:var(--wcm-color-fg-2)}svg{left:10px;top:4px;pointer-events:none;position:absolute;width:20px;height:20px}input:focus-within{box-shadow:inset 0 0 0 1px var(--wcm-accent-color)}path{fill:var(--wcm-color-fg-2)}`;var t_=Object.defineProperty,tx=Object.getOwnPropertyDescriptor,Fe=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tx(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&t_(t,l,s),s};let t$=class extends lit_element_s{constructor(){super(...arguments),this.onChange=()=>null}render(){return J` ${eX.SEARCH_ICON}`}};t$.styles=[eD.globalCss,ty],Fe([property_n()],t$.prototype,"onChange",2),t$=Fe([custom_element_e("wcm-search-input")],t$);let tC=i`@keyframes rotate{100%{transform:rotate(360deg)}}@keyframes dash{0%{stroke-dasharray:1,150;stroke-dashoffset:0}50%{stroke-dasharray:90,150;stroke-dashoffset:-35}100%{stroke-dasharray:90,150;stroke-dashoffset:-124}}svg{animation:rotate 2s linear infinite;display:flex;justify-content:center;align-items:center}svg circle{stroke-linecap:round;animation:dash 1.5s ease infinite;stroke:var(--wcm-accent-color)}`;var tA=Object.defineProperty,tE=Object.getOwnPropertyDescriptor;let tO=class extends lit_element_s{render(){return J``}};tO.styles=[eD.globalCss,tC],tO=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?tE(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tA(t,l,s),s})([custom_element_e("wcm-spinner")],tO);let tk=i`span{font-style:normal;font-family:var(--wcm-font-family);font-feature-settings:var(--wcm-font-feature-settings)}.wcm-xsmall-bold{font-family:var(--wcm-text-xsmall-bold-font-family);font-weight:var(--wcm-text-xsmall-bold-weight);font-size:var(--wcm-text-xsmall-bold-size);line-height:var(--wcm-text-xsmall-bold-line-height);letter-spacing:var(--wcm-text-xsmall-bold-letter-spacing);text-transform:var(--wcm-text-xsmall-bold-text-transform)}.wcm-xsmall-regular{font-family:var(--wcm-text-xsmall-regular-font-family);font-weight:var(--wcm-text-xsmall-regular-weight);font-size:var(--wcm-text-xsmall-regular-size);line-height:var(--wcm-text-xsmall-regular-line-height);letter-spacing:var(--wcm-text-xsmall-regular-letter-spacing);text-transform:var(--wcm-text-xsmall-regular-text-transform)}.wcm-small-thin{font-family:var(--wcm-text-small-thin-font-family);font-weight:var(--wcm-text-small-thin-weight);font-size:var(--wcm-text-small-thin-size);line-height:var(--wcm-text-small-thin-line-height);letter-spacing:var(--wcm-text-small-thin-letter-spacing);text-transform:var(--wcm-text-small-thin-text-transform)}.wcm-small-regular{font-family:var(--wcm-text-small-regular-font-family);font-weight:var(--wcm-text-small-regular-weight);font-size:var(--wcm-text-small-regular-size);line-height:var(--wcm-text-small-regular-line-height);letter-spacing:var(--wcm-text-small-regular-letter-spacing);text-transform:var(--wcm-text-small-regular-text-transform)}.wcm-medium-regular{font-family:var(--wcm-text-medium-regular-font-family);font-weight:var(--wcm-text-medium-regular-weight);font-size:var(--wcm-text-medium-regular-size);line-height:var(--wcm-text-medium-regular-line-height);letter-spacing:var(--wcm-text-medium-regular-letter-spacing);text-transform:var(--wcm-text-medium-regular-text-transform)}.wcm-big-bold{font-family:var(--wcm-text-big-bold-font-family);font-weight:var(--wcm-text-big-bold-weight);font-size:var(--wcm-text-big-bold-size);line-height:var(--wcm-text-big-bold-line-height);letter-spacing:var(--wcm-text-big-bold-letter-spacing);text-transform:var(--wcm-text-big-bold-text-transform)}:host(*){color:var(--wcm-color-fg-1)}.wcm-color-primary{color:var(--wcm-color-fg-1)}.wcm-color-secondary{color:var(--wcm-color-fg-2)}.wcm-color-tertiary{color:var(--wcm-color-fg-3)}.wcm-color-inverse{color:var(--wcm-accent-fill-color)}.wcm-color-accnt{color:var(--wcm-accent-color)}.wcm-color-error{color:var(--wcm-error-color)}`;var tT=Object.defineProperty,tI=Object.getOwnPropertyDescriptor,Oe=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tI(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tT(t,l,s),s};let tS=class extends lit_element_s{constructor(){super(...arguments),this.variant="medium-regular",this.color="primary"}render(){let e={"wcm-big-bold":"big-bold"===this.variant,"wcm-medium-regular":"medium-regular"===this.variant,"wcm-small-regular":"small-regular"===this.variant,"wcm-small-thin":"small-thin"===this.variant,"wcm-xsmall-regular":"xsmall-regular"===this.variant,"wcm-xsmall-bold":"xsmall-bold"===this.variant,"wcm-color-primary":"primary"===this.color,"wcm-color-secondary":"secondary"===this.color,"wcm-color-tertiary":"tertiary"===this.color,"wcm-color-inverse":"inverse"===this.color,"wcm-color-accnt":"accent"===this.color,"wcm-color-error":"error"===this.color};return J``}};tS.styles=[eD.globalCss,tk],Oe([property_n()],tS.prototype,"variant",2),Oe([property_n()],tS.prototype,"color",2),tS=Oe([custom_element_e("wcm-text")],tS);let tR=i`button{width:100%;height:100%;border-radius:var(--wcm-button-hover-highlight-border-radius);display:flex;align-items:flex-start}button:active{background-color:var(--wcm-color-overlay)}@media(hover:hover){button:hover{background-color:var(--wcm-color-overlay)}}button>div{width:80px;padding:5px 0;display:flex;flex-direction:column;align-items:center}wcm-text{width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-align:center}wcm-wallet-image{height:60px;width:60px;transition:all .2s ease;border-radius:var(--wcm-wallet-icon-border-radius);margin-bottom:5px}.wcm-sublabel{margin-top:2px}`;var tP=Object.defineProperty,tM=Object.getOwnPropertyDescriptor,dist_=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tM(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tP(t,l,s),s};let tL=class extends lit_element_s{constructor(){super(...arguments),this.onClick=()=>null,this.name="",this.walletId="",this.label=void 0,this.imageId=void 0,this.installed=!1,this.recent=!1}sublabelTemplate(){return this.recent?J`RECENT`:this.installed?J`INSTALLED`:null}handleClick(){eg.uA.click({name:"WALLET_BUTTON",walletId:this.walletId}),this.onClick()}render(){var e;return J``}};tL.styles=[eD.globalCss,tR],dist_([property_n()],tL.prototype,"onClick",2),dist_([property_n()],tL.prototype,"name",2),dist_([property_n()],tL.prototype,"walletId",2),dist_([property_n()],tL.prototype,"label",2),dist_([property_n()],tL.prototype,"imageId",2),dist_([property_n({type:Boolean})],tL.prototype,"installed",2),dist_([property_n({type:Boolean})],tL.prototype,"recent",2),tL=dist_([custom_element_e("wcm-wallet-button")],tL);let tW=i`:host{display:block}div{overflow:hidden;position:relative;border-radius:inherit;width:100%;height:100%;background-color:var(--wcm-color-overlay)}svg{position:relative;width:100%;height:100%}div::after{content:'';position:absolute;top:0;bottom:0;left:0;right:0;border-radius:inherit;border:1px solid var(--wcm-color-overlay)}div img{width:100%;height:100%;object-fit:cover;object-position:center}#wallet-placeholder-fill{fill:var(--wcm-color-bg-3)}#wallet-placeholder-dash{stroke:var(--wcm-color-overlay)}`;var tN=Object.defineProperty,tj=Object.getOwnPropertyDescriptor,se=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tj(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tN(t,l,s),s};let tD=class extends lit_element_s{constructor(){super(...arguments),this.walletId="",this.imageId=void 0,this.imageUrl=void 0}render(){var e;let t=null!=(e=this.imageUrl)&&e.length?this.imageUrl:ta.getWalletIcon({id:this.walletId,image_id:this.imageId});return J`${t.length?J`
${this.id}
`:eX.WALLET_PLACEHOLDER}`}};tD.styles=[eD.globalCss,tW],se([property_n()],tD.prototype,"walletId",2),se([property_n()],tD.prototype,"imageId",2),se([property_n()],tD.prototype,"imageUrl",2),tD=se([custom_element_e("wcm-wallet-image")],tD);var tz=Object.defineProperty,tU=Object.getOwnPropertyDescriptor,qe=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tU(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tz(t,l,s),s};let tH=class extends lit_element_s{constructor(){super(),this.preload=!0,this.preloadData()}async loadImages(e){try{null!=e&&e.length&&await Promise.all(e.map(async e=>ta.preloadImage(e)))}catch{console.info("Unsuccessful attempt at preloading some images",e)}}async preloadListings(){if(eg.ConfigCtrl.state.enableExplorer){await eg.ExplorerCtrl.getRecomendedWallets(),eg.OptionsCtrl.setIsDataLoaded(!0);let{recomendedWallets:e}=eg.ExplorerCtrl.state,t=e.map(e=>ta.getWalletIcon(e));await this.loadImages(t)}else eg.OptionsCtrl.setIsDataLoaded(!0)}async preloadCustomImages(){let e=ta.getCustomImageUrls();await this.loadImages(e)}async preloadData(){try{this.preload&&(this.preload=!1,await Promise.all([this.preloadListings(),this.preloadCustomImages()]))}catch(e){console.error(e),eg.ToastCtrl.openToast("Failed preloading","error")}}};qe([state_t()],tH.prototype,"preload",2),tH=qe([custom_element_e("wcm-explorer-context")],tH);var tB=Object.defineProperty,tV=Object.getOwnPropertyDescriptor;let tZ=class extends lit_element_s{constructor(){super(),this.unsubscribeTheme=void 0,eD.setTheme(),this.unsubscribeTheme=eg.ThemeCtrl.subscribe(eD.setTheme)}disconnectedCallback(){var e;null==(e=this.unsubscribeTheme)||e.call(this)}};tZ=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?tV(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tB(t,l,s),s})([custom_element_e("wcm-theme-context")],tZ);let tF=i`@keyframes scroll{0%{transform:translate3d(0,0,0)}100%{transform:translate3d(calc(-70px * 9),0,0)}}.wcm-slider{position:relative;overflow-x:hidden;padding:10px 0;margin:0 -20px;width:calc(100% + 40px)}.wcm-track{display:flex;width:calc(70px * 18);animation:scroll 20s linear infinite;opacity:.7}.wcm-track svg{margin:0 5px}wcm-wallet-image{width:60px;height:60px;margin:0 5px;border-radius:var(--wcm-wallet-icon-border-radius)}.wcm-grid{display:grid;grid-template-columns:repeat(4,80px);justify-content:space-between}.wcm-title{display:flex;align-items:center;margin-bottom:10px}.wcm-title svg{margin-right:6px}.wcm-title path{fill:var(--wcm-accent-color)}wcm-modal-footer .wcm-title{padding:0 10px}wcm-button-big{position:absolute;top:50%;left:50%;transform:translateY(-50%) translateX(-50%);filter:drop-shadow(0 0 17px var(--wcm-color-bg-1))}wcm-info-footer{flex-direction:column;align-items:center;display:flex;width:100%;padding:5px 0}wcm-info-footer wcm-text{text-align:center;margin-bottom:15px}#wallet-placeholder-fill{fill:var(--wcm-color-bg-3)}#wallet-placeholder-dash{stroke:var(--wcm-color-overlay)}`;var tq=Object.defineProperty,tK=Object.getOwnPropertyDescriptor;let tG=class extends lit_element_s{onGoToQrcode(){eg.AV.push("Qrcode")}render(){let{recomendedWallets:e}=eg.ExplorerCtrl.state,t=[...e,...e],l=2*eg.zv.RECOMMENDED_WALLET_AMOUNT;return J`
${eX.MOBILE_ICON}WalletConnect
${[...Array(l)].map((e,l)=>{let o=t[l%t.length];return o?J``:eX.WALLET_PLACEHOLDER})}
Select Wallet
Choose WalletConnect to see supported apps on your device`}};tG.styles=[eD.globalCss,tF],tG=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?tK(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tq(t,l,s),s})([custom_element_e("wcm-android-wallet-selection")],tG);let tY=i`@keyframes loading{to{stroke-dashoffset:0}}@keyframes shake{10%,90%{transform:translate3d(-1px,0,0)}20%,80%{transform:translate3d(1px,0,0)}30%,50%,70%{transform:translate3d(-2px,0,0)}40%,60%{transform:translate3d(2px,0,0)}}:host{display:flex;flex-direction:column;align-items:center}div{position:relative;width:110px;height:110px;display:flex;justify-content:center;align-items:center;margin:40px 0 20px 0;transform:translate3d(0,0,0)}svg{position:absolute;width:110px;height:110px;fill:none;stroke:transparent;stroke-linecap:round;stroke-width:2px;top:0;left:0}use{stroke:var(--wcm-accent-color);animation:loading 1s linear infinite}wcm-wallet-image{border-radius:var(--wcm-wallet-icon-large-border-radius);width:90px;height:90px}wcm-text{margin-bottom:40px}.wcm-error svg{stroke:var(--wcm-error-color)}.wcm-error use{display:none}.wcm-error{animation:shake .4s cubic-bezier(.36,.07,.19,.97) both}.wcm-stale svg,.wcm-stale use{display:none}`;var tQ=Object.defineProperty,tX=Object.getOwnPropertyDescriptor,K=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?tX(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&tQ(t,l,s),s};let tJ=class extends lit_element_s{constructor(){super(...arguments),this.walletId=void 0,this.imageId=void 0,this.isError=!1,this.isStale=!1,this.label=""}svgLoaderTemplate(){var e,t;let l=null!=(t=null==(e=eg.ThemeCtrl.state.themeVariables)?void 0:e["--wcm-wallet-icon-large-border-radius"])?t:eD.getPreset("--wcm-wallet-icon-large-border-radius"),o=0;o=(l.includes("%")?.88*parseInt(l,10):parseInt(l,10))*1.17;let n=317-1.57*o,s=425-1.8*o;return J``}render(){let e={"wcm-error":this.isError,"wcm-stale":this.isStale};return J`
${this.svgLoaderTemplate()}
${this.isError?"Connection declined":this.label}`}};tJ.styles=[eD.globalCss,tY],K([property_n()],tJ.prototype,"walletId",2),K([property_n()],tJ.prototype,"imageId",2),K([property_n({type:Boolean})],tJ.prototype,"isError",2),K([property_n({type:Boolean})],tJ.prototype,"isStale",2),K([property_n()],tJ.prototype,"label",2),tJ=K([custom_element_e("wcm-connector-waiting")],tJ);let t0={manualWallets(){var e,t;let{mobileWallets:l,desktopWallets:o}=eg.ConfigCtrl.state,n=null==(e=t0.recentWallet())?void 0:e.id,s=eg.zv.isMobile()?l:o,c=s?.filter(e=>n!==e.id);return null!=(t=eg.zv.isMobile()?c?.map(({id:e,name:t,links:l})=>({id:e,name:t,mobile:l,links:l})):c?.map(({id:e,name:t,links:l})=>({id:e,name:t,desktop:l,links:l})))?t:[]},recentWallet:()=>ta.getRecentWallet(),recomendedWallets(e=!1){var t;let l=e||null==(t=t0.recentWallet())?void 0:t.id,{recomendedWallets:o}=eg.ExplorerCtrl.state;return o.filter(e=>l!==e.id)}},t1={onConnecting(e){ta.goToConnectingView(e)},manualWalletsTemplate(){return t0.manualWallets().map(e=>J``)},recomendedWalletsTemplate(e=!1){return t0.recomendedWallets(e).map(e=>J``)},recentWalletTemplate(){let e=t0.recentWallet();if(e)return J``}},t2=i`.wcm-grid{display:grid;grid-template-columns:repeat(4,80px);justify-content:space-between}.wcm-desktop-title,.wcm-mobile-title{display:flex;align-items:center}.wcm-mobile-title{justify-content:space-between;margin-bottom:20px;margin-top:-10px}.wcm-desktop-title{margin-bottom:10px;padding:0 10px}.wcm-subtitle{display:flex;align-items:center}.wcm-subtitle:last-child path{fill:var(--wcm-color-fg-3)}.wcm-desktop-title svg,.wcm-mobile-title svg{margin-right:6px}.wcm-desktop-title path,.wcm-mobile-title path{fill:var(--wcm-accent-color)}`;var t5=Object.defineProperty,t3=Object.getOwnPropertyDescriptor;let t4=class extends lit_element_s{render(){let{explorerExcludedWalletIds:e,enableExplorer:t}=eg.ConfigCtrl.state,l=t1.manualWalletsTemplate(),o=t1.recomendedWalletsTemplate(),n=[t1.recentWalletTemplate(),...l,...o];n=n.filter(Boolean);let s=n.length>4||"ALL"!==e&&t,c=[];c=s?n.slice(0,3):n;let d=!!c.length;return J`
${eX.MOBILE_ICON}Mobile
${eX.SCAN_ICON}Scan with your wallet
${d?J`
${eX.DESKTOP_ICON}Desktop
${c} ${s?J``:null}
`:null}`}};t4.styles=[eD.globalCss,t2],t4=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?t3(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&t5(t,l,s),s})([custom_element_e("wcm-desktop-wallet-selection")],t4);let t7=i`div{background-color:var(--wcm-color-bg-2);padding:10px 20px 15px 20px;border-top:1px solid var(--wcm-color-bg-3);text-align:center}a{color:var(--wcm-accent-color);text-decoration:none;transition:opacity .2s ease-in-out;display:inline}a:active{opacity:.8}@media(hover:hover){a:hover{opacity:.8}}`;var t6=Object.defineProperty,t8=Object.getOwnPropertyDescriptor;let t9=class extends lit_element_s{render(){let{termsOfServiceUrl:e,privacyPolicyUrl:t}=eg.ConfigCtrl.state;return e??t?J`
By connecting your wallet to this app, you agree to the app's ${e?J`Terms of Service`:null} ${e&&t?"and":null} ${t?J`Privacy Policy`:null}
`:null}};t9.styles=[eD.globalCss,t7],t9=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?t8(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&t6(t,l,s),s})([custom_element_e("wcm-legal-notice")],t9);let re=i`div{display:grid;grid-template-columns:repeat(4,80px);margin:0 -10px;justify-content:space-between;row-gap:10px}`;var rt=Object.defineProperty,rr=Object.getOwnPropertyDescriptor;let ri=class extends lit_element_s{onQrcode(){eg.AV.push("Qrcode")}render(){let{explorerExcludedWalletIds:e,enableExplorer:t}=eg.ConfigCtrl.state,l=t1.manualWalletsTemplate(),o=t1.recomendedWalletsTemplate(),n=[t1.recentWalletTemplate(),...l,...o];n=n.filter(Boolean);let s=n.length>8||"ALL"!==e&&t,c=[];c=s?n.slice(0,7):n;let d=!!c.length;return J`${d?J`
${c} ${s?J``:null}
`:null}`}};ri.styles=[eD.globalCss,re],ri=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?rr(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rt(t,l,s),s})([custom_element_e("wcm-mobile-wallet-selection")],ri);let rl=i`:host{all:initial}.wcm-overlay{top:0;bottom:0;left:0;right:0;position:fixed;z-index:var(--wcm-z-index);overflow:hidden;display:flex;justify-content:center;align-items:center;opacity:0;pointer-events:none;background-color:var(--wcm-overlay-background-color);backdrop-filter:var(--wcm-overlay-backdrop-filter)}@media(max-height:720px) and (orientation:landscape){.wcm-overlay{overflow:scroll;align-items:flex-start;padding:20px 0}}.wcm-active{pointer-events:auto}.wcm-container{position:relative;max-width:360px;width:100%;outline:0;border-radius:var(--wcm-background-border-radius) var(--wcm-background-border-radius) var(--wcm-container-border-radius) var(--wcm-container-border-radius);border:1px solid var(--wcm-color-overlay);overflow:hidden}.wcm-card{width:100%;position:relative;border-radius:var(--wcm-container-border-radius);overflow:hidden;box-shadow:0 6px 14px -6px rgba(10,16,31,.12),0 10px 32px -4px rgba(10,16,31,.1),0 0 0 1px var(--wcm-color-overlay);background-color:var(--wcm-color-bg-1);color:var(--wcm-color-fg-1)}@media(max-width:600px){.wcm-container{max-width:440px;border-radius:var(--wcm-background-border-radius) var(--wcm-background-border-radius) 0 0}.wcm-card{border-radius:var(--wcm-container-border-radius) var(--wcm-container-border-radius) 0 0}.wcm-overlay{align-items:flex-end}}@media(max-width:440px){.wcm-container{border:0}}`;var ro=Object.defineProperty,ra=Object.getOwnPropertyDescriptor,Re=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?ra(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&ro(t,l,s),s};let rn=class extends lit_element_s{constructor(){super(),this.open=!1,this.active=!1,this.unsubscribeModal=void 0,this.abortController=void 0,this.unsubscribeModal=eg.jb.subscribe(e=>{e.open?this.onOpenModalEvent():this.onCloseModalEvent()})}disconnectedCallback(){var e;null==(e=this.unsubscribeModal)||e.call(this)}get overlayEl(){return ta.getShadowRootElement(this,".wcm-overlay")}get containerEl(){return ta.getShadowRootElement(this,".wcm-container")}toggleBodyScroll(e){if(document.querySelector("body")){if(e){let e=document.getElementById("wcm-styles");e?.remove()}else document.head.insertAdjacentHTML("beforeend",'')}}onCloseModal(e){e.target===e.currentTarget&&eg.jb.close()}onOpenModalEvent(){this.toggleBodyScroll(!1),this.addKeyboardEvents(),this.open=!0,setTimeout(async()=>{let e=ta.isMobileAnimation()?{y:["50vh","0vh"]}:{scale:[.98,1]};await Promise.all([animate_es_animate(this.overlayEl,{opacity:[0,1]},{delay:.1,duration:.2}).finished,animate_es_animate(this.containerEl,e,{delay:.1,duration:.2}).finished]),this.active=!0},0)}async onCloseModalEvent(){this.toggleBodyScroll(!0),this.removeKeyboardEvents();let e=ta.isMobileAnimation()?{y:["0vh","50vh"]}:{scale:[1,.98]};await Promise.all([animate_es_animate(this.overlayEl,{opacity:[1,0]},{duration:.2}).finished,animate_es_animate(this.containerEl,e,{duration:.2}).finished]),this.containerEl.removeAttribute("style"),this.active=!1,this.open=!1}addKeyboardEvents(){this.abortController=new AbortController,window.addEventListener("keydown",e=>{var t;"Escape"===e.key?eg.jb.close():"Tab"===e.key&&(null!=(t=e.target)&&t.tagName.includes("wcm-")||this.containerEl.focus())},this.abortController),this.containerEl.focus()}removeKeyboardEvents(){var e;null==(e=this.abortController)||e.abort(),this.abortController=void 0}render(){let e={"wcm-overlay":!0,"wcm-active":this.active};return J`
${this.open?J`
`:null}
`}};rn.styles=[eD.globalCss,rl],Re([state_t()],rn.prototype,"open",2),Re([state_t()],rn.prototype,"active",2),rn=Re([custom_element_e("wcm-modal")],rn);let rs=i`div{display:flex;margin-top:15px}slot{display:inline-block;margin:0 5px}wcm-button{margin:0 5px}`;var rc=Object.defineProperty,rd=Object.getOwnPropertyDescriptor,le=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?rd(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rc(t,l,s),s};let rm=class extends lit_element_s{constructor(){super(...arguments),this.isMobile=!1,this.isDesktop=!1,this.isWeb=!1,this.isRetry=!1}onMobile(){eg.zv.isMobile()?eg.AV.replace("MobileConnecting"):eg.AV.replace("MobileQrcodeConnecting")}onDesktop(){eg.AV.replace("DesktopConnecting")}onWeb(){eg.AV.replace("WebConnecting")}render(){return J`
${this.isRetry?J``:null} ${this.isMobile?J`Mobile`:null} ${this.isDesktop?J`Desktop`:null} ${this.isWeb?J`Web`:null}
`}};rm.styles=[eD.globalCss,rs],le([property_n({type:Boolean})],rm.prototype,"isMobile",2),le([property_n({type:Boolean})],rm.prototype,"isDesktop",2),le([property_n({type:Boolean})],rm.prototype,"isWeb",2),le([property_n({type:Boolean})],rm.prototype,"isRetry",2),rm=le([custom_element_e("wcm-platform-selection")],rm);let rh=i`button{display:flex;flex-direction:column;padding:5px 10px;border-radius:var(--wcm-button-hover-highlight-border-radius);height:100%;justify-content:flex-start}.wcm-icons{width:60px;height:60px;display:flex;flex-wrap:wrap;padding:7px;border-radius:var(--wcm-wallet-icon-border-radius);justify-content:space-between;align-items:center;margin-bottom:5px;background-color:var(--wcm-color-bg-2);box-shadow:inset 0 0 0 1px var(--wcm-color-overlay)}button:active{background-color:var(--wcm-color-overlay)}@media(hover:hover){button:hover{background-color:var(--wcm-color-overlay)}}.wcm-icons img{width:21px;height:21px;object-fit:cover;object-position:center;border-radius:calc(var(--wcm-wallet-icon-border-radius)/ 2);border:1px solid var(--wcm-color-overlay)}.wcm-icons svg{width:21px;height:21px}.wcm-icons img:nth-child(1),.wcm-icons img:nth-child(2),.wcm-icons svg:nth-child(1),.wcm-icons svg:nth-child(2){margin-bottom:4px}wcm-text{width:100%;text-align:center}#wallet-placeholder-fill{fill:var(--wcm-color-bg-3)}#wallet-placeholder-dash{stroke:var(--wcm-color-overlay)}`;var rp=Object.defineProperty,ru=Object.getOwnPropertyDescriptor;let rg=class extends lit_element_s{onClick(){eg.AV.push("WalletExplorer")}render(){let{recomendedWallets:e}=eg.ExplorerCtrl.state,t=t0.manualWallets(),l=[...e,...t].reverse().slice(0,4);return J``}};rg.styles=[eD.globalCss,rh],rg=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?ru(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rp(t,l,s),s})([custom_element_e("wcm-view-all-wallets-button")],rg);let rw=i`.wcm-qr-container{width:100%;display:flex;justify-content:center;align-items:center;aspect-ratio:1/1}`;var rv=Object.defineProperty,rf=Object.getOwnPropertyDescriptor,de=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?rf(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rv(t,l,s),s};let rb=class extends lit_element_s{constructor(){super(),this.walletId="",this.imageId="",this.uri="",setTimeout(()=>{let{walletConnectUri:e}=eg.OptionsCtrl.state;this.uri=e},0)}get overlayEl(){return ta.getShadowRootElement(this,".wcm-qr-container")}render(){return J`
${this.uri?J``:J``}
`}};rb.styles=[eD.globalCss,rw],de([property_n()],rb.prototype,"walletId",2),de([property_n()],rb.prototype,"imageId",2),de([state_t()],rb.prototype,"uri",2),rb=de([custom_element_e("wcm-walletconnect-qr")],rb);var ry=Object.defineProperty,r_=Object.getOwnPropertyDescriptor;let rx=class extends lit_element_s{viewTemplate(){return eg.zv.isAndroid()?J``:eg.zv.isMobile()?J``:J``}render(){return J`${this.viewTemplate()}`}};rx.styles=[eD.globalCss],rx=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?r_(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&ry(t,l,s),s})([custom_element_e("wcm-connect-wallet-view")],rx);let r$=i`wcm-info-footer{flex-direction:column;align-items:center;display:flex;width:100%;padding:5px 0}wcm-text{text-align:center}`;var rC=Object.defineProperty,rA=Object.getOwnPropertyDescriptor,Ke=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?rA(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rC(t,l,s),s};let rE=class extends lit_element_s{constructor(){super(),this.isError=!1,this.openDesktopApp()}onFormatAndRedirect(e){let{desktop:t,name:l}=eg.zv.getWalletRouterData(),o=t?.native;if(o){let t=eg.zv.formatNativeUrl(o,e,l);eg.zv.openHref(t,"_self")}}openDesktopApp(){let{walletConnectUri:e}=eg.OptionsCtrl.state,t=eg.zv.getWalletRouterData();ta.setRecentWallet(t),e&&this.onFormatAndRedirect(e)}render(){let{name:e,id:t,image_id:l}=eg.zv.getWalletRouterData(),{isMobile:o,isWeb:n}=ta.getCachedRouterWalletPlatforms();return J`${`Connection can continue loading if ${e} is not installed on your device`}Retry`}};rE.styles=[eD.globalCss,r$],Ke([state_t()],rE.prototype,"isError",2),rE=Ke([custom_element_e("wcm-desktop-connecting-view")],rE);let rO=i`wcm-info-footer{flex-direction:column;align-items:center;display:flex;width:100%;padding:5px 0}wcm-text{text-align:center}wcm-button{margin-top:15px}`;var rk=Object.defineProperty,rT=Object.getOwnPropertyDescriptor;let rI=class extends lit_element_s{onInstall(e){e&&eg.zv.openHref(e,"_blank")}render(){let{name:e,id:t,image_id:l,homepage:o}=eg.zv.getWalletRouterData();return J`${`Download ${e} to continue. If multiple browser extensions are installed, disable non ${e} ones and try again`}Download`}};rI.styles=[eD.globalCss,rO],rI=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?rT(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rk(t,l,s),s})([custom_element_e("wcm-install-wallet-view")],rI);let rS=i`wcm-wallet-image{border-radius:var(--wcm-wallet-icon-large-border-radius);width:96px;height:96px;margin-bottom:20px}wcm-info-footer{display:flex;width:100%}.wcm-app-store{justify-content:space-between}.wcm-app-store wcm-wallet-image{margin-right:10px;margin-bottom:0;width:28px;height:28px;border-radius:var(--wcm-wallet-icon-small-border-radius)}.wcm-app-store div{display:flex;align-items:center}.wcm-app-store wcm-button{margin-right:-10px}.wcm-note{flex-direction:column;align-items:center;padding:5px 0}.wcm-note wcm-text{text-align:center}wcm-platform-selection{margin-top:-15px}.wcm-note wcm-text{margin-top:15px}.wcm-note wcm-text span{color:var(--wcm-accent-color)}`;var rR=Object.defineProperty,rP=Object.getOwnPropertyDescriptor,Ye=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?rP(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rR(t,l,s),s};let rM=class extends lit_element_s{constructor(){super(),this.isError=!1,this.openMobileApp()}onFormatAndRedirect(e,t=!1){let{mobile:l,name:o}=eg.zv.getWalletRouterData(),n=l?.native,s=l?.universal;if(n&&!t){let t=eg.zv.formatNativeUrl(n,e,o);eg.zv.openHref(t,"_self")}else if(s){let t=eg.zv.formatUniversalUrl(s,e,o);eg.zv.openHref(t,"_self")}}openMobileApp(e=!1){let{walletConnectUri:t}=eg.OptionsCtrl.state,l=eg.zv.getWalletRouterData();ta.setRecentWallet(l),t&&this.onFormatAndRedirect(t,e)}onGoToAppStore(e){e&&eg.zv.openHref(e,"_blank")}render(){let{name:e,id:t,image_id:l,app:o,mobile:n}=eg.zv.getWalletRouterData(),{isWeb:s}=ta.getCachedRouterWalletPlatforms(),c=o?.ios,d=n?.universal;return J`Retry${d?J`Still doesn't work? Try this alternate link`:null}
${`Get ${e}`}
App Store
`}};rM.styles=[eD.globalCss,rS],Ye([state_t()],rM.prototype,"isError",2),rM=Ye([custom_element_e("wcm-mobile-connecting-view")],rM);let rL=i`wcm-info-footer{flex-direction:column;align-items:center;display:flex;width:100%;padding:5px 0}wcm-text{text-align:center}`;var rW=Object.defineProperty,rN=Object.getOwnPropertyDescriptor;let rj=class extends lit_element_s{render(){let{name:e,id:t,image_id:l}=eg.zv.getWalletRouterData(),{isDesktop:o,isWeb:n}=ta.getCachedRouterWalletPlatforms();return J`${`Scan this QR Code with your phone's camera or inside ${e} app`}`}};rj.styles=[eD.globalCss,rL],rj=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?rN(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rW(t,l,s),s})([custom_element_e("wcm-mobile-qr-connecting-view")],rj);var rD=Object.defineProperty,rz=Object.getOwnPropertyDescriptor;let rU=class extends lit_element_s{render(){return J``}};rU.styles=[eD.globalCss],rU=((e,t,l,o)=>{for(var n,s=o>1?void 0:o?rz(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rD(t,l,s),s})([custom_element_e("wcm-qrcode-view")],rU);let rH=i`wcm-modal-content{height:clamp(200px,60vh,600px);display:block;overflow:scroll;scrollbar-width:none;position:relative;margin-top:1px}.wcm-grid{display:grid;grid-template-columns:repeat(4,80px);justify-content:space-between;margin:-15px -10px;padding-top:20px}wcm-modal-content::after,wcm-modal-content::before{content:'';position:fixed;pointer-events:none;z-index:1;width:100%;height:20px;opacity:1}wcm-modal-content::before{box-shadow:0 -1px 0 0 var(--wcm-color-bg-1);background:linear-gradient(var(--wcm-color-bg-1),rgba(255,255,255,0))}wcm-modal-content::after{box-shadow:0 1px 0 0 var(--wcm-color-bg-1);background:linear-gradient(rgba(255,255,255,0),var(--wcm-color-bg-1));top:calc(100% - 20px)}wcm-modal-content::-webkit-scrollbar{display:none}.wcm-placeholder-block{display:flex;justify-content:center;align-items:center;height:100px;overflow:hidden}.wcm-empty,.wcm-loading{display:flex}.wcm-loading .wcm-placeholder-block{height:100%}.wcm-end-reached .wcm-placeholder-block{height:0;opacity:0}.wcm-empty .wcm-placeholder-block{opacity:1;height:100%}wcm-wallet-button{margin:calc((100% - 60px)/ 3) 0}`;var rB=Object.defineProperty,rV=Object.getOwnPropertyDescriptor,ie=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?rV(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rB(t,l,s),s};let rZ=class extends lit_element_s{constructor(){super(...arguments),this.loading=!eg.ExplorerCtrl.state.wallets.listings.length,this.firstFetch=!eg.ExplorerCtrl.state.wallets.listings.length,this.search="",this.endReached=!1,this.intersectionObserver=void 0,this.searchDebounce=ta.debounce(e=>{e.length>=1?(this.firstFetch=!0,this.endReached=!1,this.search=e,eg.ExplorerCtrl.resetSearch(),this.fetchWallets()):this.search&&(this.search="",this.endReached=this.isLastPage(),eg.ExplorerCtrl.resetSearch())})}firstUpdated(){this.createPaginationObserver()}disconnectedCallback(){var e;null==(e=this.intersectionObserver)||e.disconnect()}get placeholderEl(){return ta.getShadowRootElement(this,".wcm-placeholder-block")}createPaginationObserver(){this.intersectionObserver=new IntersectionObserver(([e])=>{e.isIntersecting&&!(this.search&&this.firstFetch)&&this.fetchWallets()}),this.intersectionObserver.observe(this.placeholderEl)}isLastPage(){let{wallets:e,search:t}=eg.ExplorerCtrl.state,{listings:l,total:o}=this.search?t:e;return o<=40||l.length>=o}async fetchWallets(){var e;let{wallets:t,search:l}=eg.ExplorerCtrl.state,{listings:o,total:n,page:s}=this.search?l:t;if(!this.endReached&&(this.firstFetch||n>40&&o.lengthta.getWalletIcon(e));await Promise.all([...o.map(async e=>ta.preloadImage(e)),eg.zv.wait(300)]),this.endReached=this.isLastPage()}catch(e){console.error(e),eg.ToastCtrl.openToast(ta.getErrorMessage(e),"error")}finally{this.loading=!1,this.firstFetch=!1}}onConnect(e){eg.zv.isAndroid()?ta.handleMobileLinking(e):ta.goToConnectingView(e)}onSearchChange(e){let{value:t}=e.target;this.searchDebounce(t)}render(){let{wallets:e,search:t}=eg.ExplorerCtrl.state,{listings:l}=this.search?t:e,o=this.loading&&!l.length,n=this.search.length>=3,s=t1.manualWalletsTemplate(),c=t1.recomendedWalletsTemplate(!0);n&&(s=s.filter(({values:e})=>ta.caseSafeIncludes(e[0],this.search)),c=c.filter(({values:e})=>ta.caseSafeIncludes(e[0],this.search)));let d=!this.loading&&!l.length&&!c.length,m={"wcm-loading":o,"wcm-end-reached":this.endReached||!this.loading,"wcm-empty":d};return J`
${o?null:s} ${o?null:c} ${o?null:l.map(e=>J`${e?J``:null}`)}
${d?J`No results found`:null} ${!d&&this.loading?J``:null}
`}};rZ.styles=[eD.globalCss,rH],ie([state_t()],rZ.prototype,"loading",2),ie([state_t()],rZ.prototype,"firstFetch",2),ie([state_t()],rZ.prototype,"search",2),ie([state_t()],rZ.prototype,"endReached",2),rZ=ie([custom_element_e("wcm-wallet-explorer-view")],rZ);let rF=i`wcm-info-footer{flex-direction:column;align-items:center;display:flex;width:100%;padding:5px 0}wcm-text{text-align:center}`;var rq=Object.defineProperty,rK=Object.getOwnPropertyDescriptor,Ge=(e,t,l,o)=>{for(var n,s=o>1?void 0:o?rK(t,l):t,c=e.length-1;c>=0;c--)(n=e[c])&&(s=(o?n(t,l,s):n(s))||s);return o&&s&&rq(t,l,s),s};let rG=class extends lit_element_s{constructor(){super(),this.isError=!1,this.openWebWallet()}onFormatAndRedirect(e){let{desktop:t,name:l}=eg.zv.getWalletRouterData(),o=t?.universal;if(o){let t=eg.zv.formatUniversalUrl(o,e,l);eg.zv.openHref(t,"_blank")}}openWebWallet(){let{walletConnectUri:e}=eg.OptionsCtrl.state,t=eg.zv.getWalletRouterData();ta.setRecentWallet(t),e&&this.onFormatAndRedirect(e)}render(){let{name:e,id:t,image_id:l}=eg.zv.getWalletRouterData(),{isMobile:o,isDesktop:n}=ta.getCachedRouterWalletPlatforms(),s=eg.zv.isMobile();return J`${`${e} web app has opened in a new tab. Go there, accept the connection, and come back`}Retry`}};rG.styles=[eD.globalCss,rF],Ge([state_t()],rG.prototype,"isError",2),rG=Ge([custom_element_e("wcm-web-connecting-view")],rG)}}]); \ No newline at end of file diff --git a/_next/static/chunks/864-0aa61a7cd36fb457.js b/_next/static/chunks/864-0aa61a7cd36fb457.js new file mode 100644 index 0000000..ce4ddd1 --- /dev/null +++ b/_next/static/chunks/864-0aa61a7cd36fb457.js @@ -0,0 +1,25 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[864],{2335:function(){"trimStart"in String.prototype||(String.prototype.trimStart=String.prototype.trimLeft),"trimEnd"in String.prototype||(String.prototype.trimEnd=String.prototype.trimRight),"description"in Symbol.prototype||Object.defineProperty(Symbol.prototype,"description",{configurable:!0,get:function(){var e=/\((.*)\)/.exec(this.toString());return e?e[1]:void 0}}),Array.prototype.flat||(Array.prototype.flat=function(e,t){return t=this.concat.apply([],this),e>1&&t.some(Array.isArray)?t.flat(e-1):t},Array.prototype.flatMap=function(e,t){return this.map(e,t).flat()}),Promise.prototype.finally||(Promise.prototype.finally=function(e){if("function"!=typeof e)return this.then(e,e);var t=this.constructor||Promise;return this.then(function(r){return t.resolve(e()).then(function(){return r})},function(r){return t.resolve(e()).then(function(){throw r})})}),Object.fromEntries||(Object.fromEntries=function(e){return Array.from(e).reduce(function(e,t){return e[t[0]]=t[1],e},{})}),Array.prototype.at||(Array.prototype.at=function(e){var t=Math.trunc(e)||0;if(t<0&&(t+=this.length),!(t<0||t>=this.length))return this[t]})},69207:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"addBasePath",{enumerable:!0,get:function(){return addBasePath}});let n=r(26182),a=r(70474);function addBasePath(e,t){return(0,a.normalizePathTrailingSlash)((0,n.addPathPrefix)(e,"/test-wagmi-safe-privy"))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},81160:function(e,t){"use strict";function appBootstrap(e){var t,r;t=self.__next_s,r=()=>{e()},t&&t.length?t.reduce((e,t)=>{let[r,n]=t;return e.then(()=>new Promise((e,t)=>{let a=document.createElement("script");if(n)for(let e in n)"children"!==e&&a.setAttribute(e,n[e]);r?(a.src=r,a.onload=()=>e(),a.onerror=t):n&&(a.innerHTML=n.children,setTimeout(e)),document.head.appendChild(a)}))},Promise.resolve()).catch(e=>{console.error(e)}).then(()=>{r()}):r()}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"appBootstrap",{enumerable:!0,get:function(){return appBootstrap}}),window.next={version:"13.5.4",appDir:!0},("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},22655:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"callServer",{enumerable:!0,get:function(){return callServer}});let n=r(76054);async function callServer(e,t){let r=(0,n.getServerActionDispatcher)();if(!r)throw Error("Invariant: missing action dispatcher.");return new Promise((n,a)=>{r({actionId:e,actionArgs:t,resolve:n,reject:a})})}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},62596:function(e,t,r){"use strict";let n,a;Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"hydrate",{enumerable:!0,get:function(){return hydrate}});let o=r(21024),u=r(68533);r(2335);let l=o._(r(34040)),i=u._(r(2265)),s=r(6671),p=r(43305);r(11792);let _=o._(r(71747)),b=r(22655),v=r(38777),E=window.console.error;window.console.error=function(){for(var e=arguments.length,t=Array(e),r=0;r{if((0,v.isNextRouterError)(e.error)){e.preventDefault();return}});let j=document,getCacheKey=()=>{let{pathname:e,search:t}=location;return e+t},C=new TextEncoder,w=!1,A=!1,F=null;function nextServerDataCallback(e){if(0===e[0])n=[];else if(1===e[0]){if(!n)throw Error("Unexpected server data: missing bootstrap script.");a?a.enqueue(C.encode(e[1])):n.push(e[1])}else 2===e[0]&&(F=e[1])}let DOMContentLoaded=function(){a&&!A&&(a.close(),A=!0,n=void 0),w=!0};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",DOMContentLoaded,!1):DOMContentLoaded();let D=self.__next_f=self.__next_f||[];D.forEach(nextServerDataCallback),D.push=nextServerDataCallback;let U=new Map;function ServerRoot(e){let{cacheKey:t}=e;i.default.useEffect(()=>{U.delete(t)});let r=function(e){let t=U.get(e);if(t)return t;let r=new ReadableStream({start(e){n&&(n.forEach(t=>{e.enqueue(C.encode(t))}),w&&!A&&(e.close(),A=!0,n=void 0)),a=e}}),o=(0,s.createFromReadableStream)(r,{callServer:b.callServer});return U.set(e,o),o}(t),o=(0,i.use)(r);return o}let B=i.default.StrictMode;function Root(e){let{children:t}=e;return t}function RSCComponent(e){return i.default.createElement(ServerRoot,{...e,cacheKey:getCacheKey()})}function hydrate(){let e=i.default.createElement(B,null,i.default.createElement(p.HeadManagerContext.Provider,{value:{appDir:!0}},i.default.createElement(Root,null,i.default.createElement(RSCComponent,null)))),t={onRecoverableError:_.default},r="__next_error__"===document.documentElement.id;r?l.default.createRoot(j,t).render(e):i.default.startTransition(()=>l.default.hydrateRoot(j,e,{...t,experimental_formState:F}))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},23123:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});let n=r(81160);(0,n.appBootstrap)(()=>{r(76054),r(81443),r(95708);let{hydrate:e}=r(62596);e()}),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},95708:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});let addChunkSuffix=e=>t=>e(t)+"",n=r.u,a={};r.u=addChunkSuffix(e=>encodeURI(a[e]||n(e)));let o=r.k;r.k=addChunkSuffix(o);let u=r.miniCssF;r.miniCssF=addChunkSuffix(u),self.__next_require__=r,self.__next_chunk_load__=e=>{if(!e)return Promise.resolve();let[t,n]=e.split(":");return a[t]=n,r.e(t)},("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},9214:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"AppRouterAnnouncer",{enumerable:!0,get:function(){return AppRouterAnnouncer}});let n=r(2265),a=r(54887),o="next-route-announcer";function AppRouterAnnouncer(e){let{tree:t}=e,[r,u]=(0,n.useState)(null);(0,n.useEffect)(()=>{let e=function(){var e;let t=document.getElementsByName(o)[0];if(null==t?void 0:null==(e=t.shadowRoot)?void 0:e.childNodes[0])return t.shadowRoot.childNodes[0];{let e=document.createElement(o);e.style.cssText="position:absolute";let t=document.createElement("div");t.ariaLive="assertive",t.id="__next-route-announcer__",t.role="alert",t.style.cssText="position:absolute;border:0;height:1px;margin:-1px;padding:0;width:1px;clip:rect(0 0 0 0);overflow:hidden;white-space:nowrap;word-wrap:normal";let r=e.attachShadow({mode:"open"});return r.appendChild(t),document.body.appendChild(e),t}}();return u(e),()=>{let e=document.getElementsByTagName(o)[0];(null==e?void 0:e.isConnected)&&document.body.removeChild(e)}},[]);let[l,i]=(0,n.useState)(""),s=(0,n.useRef)();return(0,n.useEffect)(()=>{let e="";if(document.title)e=document.title;else{let t=document.querySelector("h1");t&&(e=t.innerText||t.textContent||"")}void 0!==s.current&&s.current!==e&&i(e),s.current=e},[t]),r?(0,a.createPortal)(l,r):null}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},59980:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{RSC:function(){return r},ACTION:function(){return n},NEXT_ROUTER_STATE_TREE:function(){return a},NEXT_ROUTER_PREFETCH:function(){return o},NEXT_URL:function(){return u},RSC_CONTENT_TYPE_HEADER:function(){return l},RSC_VARY_HEADER:function(){return i},FLIGHT_PARAMETERS:function(){return s},NEXT_RSC_UNION_QUERY:function(){return p}});let r="RSC",n="Next-Action",a="Next-Router-State-Tree",o="Next-Router-Prefetch",u="Next-Url",l="text/x-component",i=r+", "+a+", "+o+", "+u,s=[[r],[a],[o]],p="_rsc";("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},76054:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{getServerActionDispatcher:function(){return getServerActionDispatcher},urlToUrlWithoutFlightMarker:function(){return urlToUrlWithoutFlightMarker},default:function(){return AppRouter}});let n=r(68533),a=n._(r(2265)),o=r(11792),u=r(23626),l=r(72271),i=r(67649),s=r(83682),p=r(74423),_=r(41729),b=r(78770),v=r(66175),E=r(69207),j=r(9214),C=r(37851),w=r(25483),A=r(42460),F=r(59980),D=r(14286),U=r(44561),B=new Map,$=null;function getServerActionDispatcher(){return $}let z={refresh:()=>{}};function urlToUrlWithoutFlightMarker(e){let t=new URL(e,location.origin);if(t.searchParams.delete(F.NEXT_RSC_UNION_QUERY),t.pathname.endsWith(".txt")){let{pathname:e}=t,r=e.endsWith("/index.txt")?10:4;t.pathname=e.slice(0,-r)}return t}function isExternalURL(e){return e.origin!==window.location.origin}function HistoryUpdater(e){let{tree:t,pushRef:r,canonicalUrl:n,sync:o}=e;return(0,a.useInsertionEffect)(()=>{let e={__NA:!0,tree:t};r.pendingPush&&(0,i.createHrefFromUrl)(new URL(window.location.href))!==n?(r.pendingPush=!1,window.history.pushState(e,"",n)):window.history.replaceState(e,"",n),o()},[t,r,n,o]),null}let createEmptyCacheNode=()=>({status:o.CacheStates.LAZY_INITIALIZED,data:null,subTreeData:null,parallelRoutes:new Map});function Router(e){let{buildId:t,initialHead:r,initialTree:n,initialCanonicalUrl:_,children:F,assetPrefix:K}=e,q=(0,a.useMemo)(()=>(0,b.createInitialRouterState)({buildId:t,children:F,initialCanonicalUrl:_,initialTree:n,initialParallelRoutes:B,isServer:!1,location:window.location,initialHead:r}),[t,F,_,n,r]),[{tree:Q,cache:ee,prefetchCache:et,pushRef:er,focusAndScrollRef:en,canonicalUrl:ea,nextUrl:eo},eu,el]=(0,p.useReducerWithReduxDevtools)(u.reducer,q);(0,a.useEffect)(()=>{B=null},[]);let{searchParams:ei,pathname:ec}=(0,a.useMemo)(()=>{let e=new URL(ea,window.location.href);return{searchParams:e.searchParams,pathname:(0,U.hasBasePath)(e.pathname)?(0,D.removeBasePath)(e.pathname):e.pathname}},[ea]),es=(0,a.useCallback)((e,t,r)=>{(0,a.startTransition)(()=>{eu({type:l.ACTION_SERVER_PATCH,flightData:t,previousTree:e,overrideCanonicalUrl:r,cache:createEmptyCacheNode(),mutable:{globalMutable:z}})})},[eu]),ef=(0,a.useCallback)((e,t,r,n)=>{let a=new URL((0,E.addBasePath)(e),location.href);return z.pendingNavigatePath=(0,i.createHrefFromUrl)(a),eu({type:l.ACTION_NAVIGATE,url:a,isExternalUrl:isExternalURL(a),locationSearch:location.search,forceOptimisticNavigation:r,shouldScroll:null==n||n,navigateType:t,cache:createEmptyCacheNode(),mutable:{globalMutable:z}})},[eu]);!function(e){let t=(0,a.useCallback)(t=>{(0,a.startTransition)(()=>{e({...t,type:l.ACTION_SERVER_ACTION,mutable:{globalMutable:z},cache:createEmptyCacheNode()})})},[e]);$=t}(eu);let ed=(0,a.useMemo)(()=>{let e={back:()=>window.history.back(),forward:()=>window.history.forward(),prefetch:(e,t)=>{if((0,v.isBot)(window.navigator.userAgent))return;let r=new URL((0,E.addBasePath)(e),location.href);isExternalURL(r)||(0,a.startTransition)(()=>{var e;eu({type:l.ACTION_PREFETCH,url:r,kind:null!=(e=null==t?void 0:t.kind)?e:l.PrefetchKind.FULL})})},replace:(e,t)=>{void 0===t&&(t={}),(0,a.startTransition)(()=>{var r;ef(e,"replace",!!t.forceOptimisticNavigation,null==(r=t.scroll)||r)})},push:(e,t)=>{void 0===t&&(t={}),(0,a.startTransition)(()=>{var r;ef(e,"push",!!t.forceOptimisticNavigation,null==(r=t.scroll)||r)})},refresh:()=>{(0,a.startTransition)(()=>{eu({type:l.ACTION_REFRESH,cache:createEmptyCacheNode(),mutable:{globalMutable:z},origin:window.location.origin})})},fastRefresh:()=>{throw Error("fastRefresh can only be used in development mode. Please use refresh instead.")}};return e},[eu,ef]);if((0,a.useEffect)(()=>{window.next&&(window.next.router=ed)},[ed]),(0,a.useEffect)(()=>{z.refresh=ed.refresh},[ed.refresh]),(0,a.useEffect)(()=>{function handlePageShow(e){var t;e.persisted&&(null==(t=window.history.state)?void 0:t.tree)&&eu({type:l.ACTION_RESTORE,url:new URL(window.location.href),tree:window.history.state.tree})}return window.addEventListener("pageshow",handlePageShow),()=>{window.removeEventListener("pageshow",handlePageShow)}},[eu]),er.mpaNavigation){if(z.pendingMpaPath!==ea){let e=window.location;er.pendingPush?e.assign(ea):e.replace(ea),z.pendingMpaPath=ea}(0,a.use)((0,A.createInfinitePromise)())}let ep=(0,a.useCallback)(e=>{let{state:t}=e;if(t){if(!t.__NA){window.location.reload();return}(0,a.startTransition)(()=>{eu({type:l.ACTION_RESTORE,url:new URL(window.location.href),tree:t.tree})})}},[eu]);(0,a.useEffect)(()=>(window.addEventListener("popstate",ep),()=>{window.removeEventListener("popstate",ep)}),[ep]);let eh=(0,a.useMemo)(()=>(0,w.findHeadInCache)(ee,Q[1]),[ee,Q]),ey=a.default.createElement(C.RedirectBoundary,null,eh,ee.subTreeData,a.default.createElement(j.AppRouterAnnouncer,{tree:Q}));return a.default.createElement(a.default.Fragment,null,a.default.createElement(HistoryUpdater,{tree:Q,pushRef:er,canonicalUrl:ea,sync:el}),a.default.createElement(s.PathnameContext.Provider,{value:ec},a.default.createElement(s.SearchParamsContext.Provider,{value:ei},a.default.createElement(o.GlobalLayoutRouterContext.Provider,{value:{buildId:t,changeByServerResponse:es,tree:Q,focusAndScrollRef:en,nextUrl:eo}},a.default.createElement(o.AppRouterContext.Provider,{value:ed},a.default.createElement(o.LayoutRouterContext.Provider,{value:{childNodes:ee.parallelRoutes,tree:Q,url:ea}},ey))))))}function AppRouter(e){let{globalErrorComponent:t,...r}=e;return a.default.createElement(_.ErrorBoundary,{errorComponent:t},a.default.createElement(Router,r))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},78989:function(e,t,r){"use strict";function clientHookInServerComponentError(e){}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"clientHookInServerComponentError",{enumerable:!0,get:function(){return clientHookInServerComponentError}}),r(21024),r(2265),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},41729:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ErrorBoundaryHandler:function(){return ErrorBoundaryHandler},GlobalError:function(){return GlobalError},default:function(){return l},ErrorBoundary:function(){return ErrorBoundary}});let n=r(21024),a=n._(r(2265)),o=r(20290),u={error:{fontFamily:'system-ui,"Segoe UI",Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"',height:"100vh",textAlign:"center",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},text:{fontSize:"14px",fontWeight:400,lineHeight:"28px",margin:"0 8px"}};let ErrorBoundaryHandler=class ErrorBoundaryHandler extends a.default.Component{static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return e.pathname!==t.previousPathname&&t.error?{error:null,previousPathname:e.pathname}:{error:t.error,previousPathname:e.pathname}}render(){return this.state.error?a.default.createElement(a.default.Fragment,null,this.props.errorStyles,a.default.createElement(this.props.errorComponent,{error:this.state.error,reset:this.reset})):this.props.children}constructor(e){super(e),this.reset=()=>{this.setState({error:null})},this.state={error:null,previousPathname:this.props.pathname}}};function GlobalError(e){let{error:t}=e,r=null==t?void 0:t.digest;return a.default.createElement("html",{id:"__next_error__"},a.default.createElement("head",null),a.default.createElement("body",null,a.default.createElement("div",{style:u.error},a.default.createElement("div",null,a.default.createElement("h2",{style:u.text},"Application error: a "+(r?"server":"client")+"-side exception has occurred (see the "+(r?"server logs":"browser console")+" for more information)."),r?a.default.createElement("p",{style:u.text},"Digest: "+r):null))))}let l=GlobalError;function ErrorBoundary(e){let{errorComponent:t,errorStyles:r,children:n}=e,u=(0,o.usePathname)();return t?a.default.createElement(ErrorBoundaryHandler,{pathname:u,errorComponent:t,errorStyles:r},n):a.default.createElement(a.default.Fragment,null,n)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},82076:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{DYNAMIC_ERROR_CODE:function(){return r},DynamicServerError:function(){return DynamicServerError}});let r="DYNAMIC_SERVER_USAGE";let DynamicServerError=class DynamicServerError extends Error{constructor(e){super("Dynamic server usage: "+e),this.digest=r}};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},42460:function(e,t){"use strict";let r;function createInfinitePromise(){return r||(r=new Promise(()=>{})),r}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createInfinitePromise",{enumerable:!0,get:function(){return createInfinitePromise}}),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},38777:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isNextRouterError",{enumerable:!0,get:function(){return isNextRouterError}});let n=r(49161),a=r(28320);function isNextRouterError(e){return e&&e.digest&&((0,a.isRedirectError)(e)||(0,n.isNotFoundError)(e))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},81443:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return OuterLayoutRouter}});let n=r(21024),a=r(68533),o=a._(r(2265)),u=n._(r(54887)),l=r(11792),i=r(9863),s=r(42460),p=r(41729),_=r(12858),b=r(53843),v=r(37851),E=r(36384),j=r(45461),C=r(93672),w=r(54790),A=["bottom","height","left","right","top","width","x","y"];function topOfElementInViewport(e,t){let r=e.getBoundingClientRect();return r.top>=0&&r.top<=t}let InnerScrollAndFocusHandler=class InnerScrollAndFocusHandler extends o.default.Component{componentDidMount(){this.handlePotentialScroll()}componentDidUpdate(){this.props.focusAndScrollRef.apply&&this.handlePotentialScroll()}render(){return this.props.children}constructor(...e){super(...e),this.handlePotentialScroll=()=>{let{focusAndScrollRef:e,segmentPath:t}=this.props;if(e.apply){var r;if(0!==e.segmentPaths.length&&!e.segmentPaths.some(e=>t.every((t,r)=>(0,_.matchSegment)(t,e[r]))))return;let n=null,a=e.hashFragment;if(a&&(n="top"===a?document.body:null!=(r=document.getElementById(a))?r:document.getElementsByName(a)[0]),n||(n=u.default.findDOMNode(this)),!(n instanceof Element))return;for(;!(n instanceof HTMLElement)||function(e){if(["sticky","fixed"].includes(getComputedStyle(e).position))return!0;let t=e.getBoundingClientRect();return A.every(e=>0===t[e])}(n);){if(null===n.nextElementSibling)return;n=n.nextElementSibling}e.apply=!1,e.hashFragment=null,e.segmentPaths=[],(0,b.handleSmoothScroll)(()=>{if(a){n.scrollIntoView();return}let e=document.documentElement,t=e.clientHeight;!topOfElementInViewport(n,t)&&(e.scrollTop=0,topOfElementInViewport(n,t)||n.scrollIntoView())},{dontForceLayout:!0,onlyHashChange:e.onlyHashChange}),e.onlyHashChange=!1,n.focus()}}}};function ScrollAndFocusHandler(e){let{segmentPath:t,children:r}=e,n=(0,o.useContext)(l.GlobalLayoutRouterContext);if(!n)throw Error("invariant global layout router not mounted");return o.default.createElement(InnerScrollAndFocusHandler,{segmentPath:t,focusAndScrollRef:n.focusAndScrollRef},r)}function InnerLayoutRouter(e){let{parallelRouterKey:t,url:r,childNodes:n,childProp:a,segmentPath:u,tree:p,cacheKey:b}=e,v=(0,o.useContext)(l.GlobalLayoutRouterContext);if(!v)throw Error("invariant global layout router not mounted");let{buildId:E,changeByServerResponse:j,tree:C}=v,A=n.get(b);if(a&&null!==a.current&&(A?A.status===l.CacheStates.LAZY_INITIALIZED&&(A.status=l.CacheStates.READY,A.subTreeData=a.current):(A={status:l.CacheStates.READY,data:null,subTreeData:a.current,parallelRoutes:new Map},n.set(b,A))),!A||A.status===l.CacheStates.LAZY_INITIALIZED){let e=function walkAddRefetch(e,t){if(e){let[r,n]=e,a=2===e.length;if((0,_.matchSegment)(t[0],r)&&t[1].hasOwnProperty(n)){if(a){let e=walkAddRefetch(void 0,t[1][n]);return[t[0],{...t[1],[n]:[e[0],e[1],e[2],"refetch"]}]}return[t[0],{...t[1],[n]:walkAddRefetch(e.slice(2),t[1][n])}]}}return t}(["",...u],C);A={status:l.CacheStates.DATA_FETCH,data:(0,w.createRecordFromThenable)((0,i.fetchServerResponse)(new URL(r,location.origin),e,v.nextUrl,E)),subTreeData:null,head:A&&A.status===l.CacheStates.LAZY_INITIALIZED?A.head:void 0,parallelRoutes:A&&A.status===l.CacheStates.LAZY_INITIALIZED?A.parallelRoutes:new Map},n.set(b,A)}if(!A)throw Error("Child node should always exist");if(A.subTreeData&&A.data)throw Error("Child node should not have both subTreeData and data");if(A.data){let[e,t]=(0,o.use)(A.data);A.data=null,setTimeout(()=>{(0,o.startTransition)(()=>{j(C,e,t)})}),(0,o.use)((0,s.createInfinitePromise)())}A.subTreeData||(0,o.use)((0,s.createInfinitePromise)());let F=o.default.createElement(l.LayoutRouterContext.Provider,{value:{tree:p[1][t],childNodes:A.parallelRoutes,url:r}},A.subTreeData);return F}function LoadingBoundary(e){let{children:t,loading:r,loadingStyles:n,hasLoading:a}=e;return a?o.default.createElement(o.Suspense,{fallback:o.default.createElement(o.default.Fragment,null,n,r)},t):o.default.createElement(o.default.Fragment,null,t)}function OuterLayoutRouter(e){let{parallelRouterKey:t,segmentPath:r,childProp:n,error:a,errorStyles:u,templateStyles:i,loading:s,loadingStyles:b,hasLoading:w,template:A,notFound:F,notFoundStyles:D,styles:U}=e,B=(0,o.useContext)(l.LayoutRouterContext);if(!B)throw Error("invariant expected layout router to be mounted");let{childNodes:$,tree:z,url:K}=B,q=$.get(t);q||(q=new Map,$.set(t,q));let Q=z[1][t][0],ee=n.segment,et=(0,j.getSegmentValue)(Q),er=[Q];return o.default.createElement(o.default.Fragment,null,U,er.map(e=>{let U=(0,_.matchSegment)(e,ee),B=(0,j.getSegmentValue)(e),$=(0,C.createRouterCacheKey)(e);return o.default.createElement(l.TemplateContext.Provider,{key:(0,C.createRouterCacheKey)(e,!0),value:o.default.createElement(ScrollAndFocusHandler,{segmentPath:r},o.default.createElement(p.ErrorBoundary,{errorComponent:a,errorStyles:u},o.default.createElement(LoadingBoundary,{hasLoading:w,loading:s,loadingStyles:b},o.default.createElement(E.NotFoundBoundary,{notFound:F,notFoundStyles:D},o.default.createElement(v.RedirectBoundary,null,o.default.createElement(InnerLayoutRouter,{parallelRouterKey:t,url:K,tree:z,childNodes:q,childProp:U?n:null,segmentPath:r,cacheKey:$,isActive:et===B}))))))},i,A)}))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},12858:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{matchSegment:function(){return matchSegment},canSegmentBeOverridden:function(){return canSegmentBeOverridden}});let n=r(15682),matchSegment=(e,t)=>"string"==typeof e?"string"==typeof t&&e===t:"string"!=typeof t&&e[0]===t[0]&&e[1]===t[1],canSegmentBeOverridden=(e,t)=>{var r;return!Array.isArray(e)&&!!Array.isArray(t)&&(null==(r=(0,n.getSegmentParam)(e))?void 0:r.param)===t[0]};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},20290:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ReadonlyURLSearchParams:function(){return ReadonlyURLSearchParams},useSearchParams:function(){return useSearchParams},usePathname:function(){return usePathname},ServerInsertedHTMLContext:function(){return i.ServerInsertedHTMLContext},useServerInsertedHTML:function(){return i.useServerInsertedHTML},useRouter:function(){return useRouter},useParams:function(){return useParams},useSelectedLayoutSegments:function(){return useSelectedLayoutSegments},useSelectedLayoutSegment:function(){return useSelectedLayoutSegment},redirect:function(){return s.redirect},permanentRedirect:function(){return s.permanentRedirect},RedirectType:function(){return s.RedirectType},notFound:function(){return p.notFound}});let n=r(2265),a=r(11792),o=r(83682),u=r(78989),l=r(45461),i=r(26619),s=r(28320),p=r(49161),_=Symbol("internal for urlsearchparams readonly");function readonlyURLSearchParamsError(){return Error("ReadonlyURLSearchParams cannot be modified")}let ReadonlyURLSearchParams=class ReadonlyURLSearchParams{[Symbol.iterator](){return this[_][Symbol.iterator]()}append(){throw readonlyURLSearchParamsError()}delete(){throw readonlyURLSearchParamsError()}set(){throw readonlyURLSearchParamsError()}sort(){throw readonlyURLSearchParamsError()}constructor(e){this[_]=e,this.entries=e.entries.bind(e),this.forEach=e.forEach.bind(e),this.get=e.get.bind(e),this.getAll=e.getAll.bind(e),this.has=e.has.bind(e),this.keys=e.keys.bind(e),this.values=e.values.bind(e),this.toString=e.toString.bind(e),this.size=e.size}};function useSearchParams(){(0,u.clientHookInServerComponentError)("useSearchParams");let e=(0,n.useContext)(o.SearchParamsContext),t=(0,n.useMemo)(()=>e?new ReadonlyURLSearchParams(e):null,[e]);return t}function usePathname(){return(0,u.clientHookInServerComponentError)("usePathname"),(0,n.useContext)(o.PathnameContext)}function useRouter(){(0,u.clientHookInServerComponentError)("useRouter");let e=(0,n.useContext)(a.AppRouterContext);if(null===e)throw Error("invariant expected app router to be mounted");return e}function useParams(){(0,u.clientHookInServerComponentError)("useParams");let e=(0,n.useContext)(a.GlobalLayoutRouterContext),t=(0,n.useContext)(o.PathParamsContext);return e?function getSelectedParams(e,t){void 0===t&&(t={});let r=e[1];for(let e of Object.values(r)){let r=e[0],n=Array.isArray(r),a=n?r[1]:r;if(!a||a.startsWith("__PAGE__"))continue;let o=n&&("c"===r[2]||"oc"===r[2]);o?t[r[0]]=r[1].split("/"):n&&(t[r[0]]=r[1]),t=getSelectedParams(e,t)}return t}(e.tree):t}function useSelectedLayoutSegments(e){void 0===e&&(e="children"),(0,u.clientHookInServerComponentError)("useSelectedLayoutSegments");let{tree:t}=(0,n.useContext)(a.LayoutRouterContext);return function getSelectedLayoutSegmentPath(e,t,r,n){let a;if(void 0===r&&(r=!0),void 0===n&&(n=[]),r)a=e[1][t];else{var o;let t=e[1];a=null!=(o=t.children)?o:Object.values(t)[0]}if(!a)return n;let u=a[0],i=(0,l.getSegmentValue)(u);return!i||i.startsWith("__PAGE__")?n:(n.push(i),getSelectedLayoutSegmentPath(a,t,!1,n))}(t,e)}function useSelectedLayoutSegment(e){void 0===e&&(e="children"),(0,u.clientHookInServerComponentError)("useSelectedLayoutSegment");let t=useSelectedLayoutSegments(e);return 0===t.length?null:t[0]}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},36384:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"NotFoundBoundary",{enumerable:!0,get:function(){return NotFoundBoundary}});let n=r(21024),a=n._(r(2265)),o=r(20290);let NotFoundErrorBoundary=class NotFoundErrorBoundary extends a.default.Component{static getDerivedStateFromError(e){if((null==e?void 0:e.digest)==="NEXT_NOT_FOUND")return{notFoundTriggered:!0};throw e}static getDerivedStateFromProps(e,t){return e.pathname!==t.previousPathname&&t.notFoundTriggered?{notFoundTriggered:!1,previousPathname:e.pathname}:{notFoundTriggered:t.notFoundTriggered,previousPathname:e.pathname}}render(){return this.state.notFoundTriggered?a.default.createElement(a.default.Fragment,null,a.default.createElement("meta",{name:"robots",content:"noindex"}),!1,this.props.notFoundStyles,this.props.notFound):this.props.children}constructor(e){super(e),this.state={notFoundTriggered:!!e.asNotFound,previousPathname:e.pathname}}};function NotFoundBoundary(e){let{notFound:t,notFoundStyles:r,asNotFound:n,children:u}=e,l=(0,o.usePathname)();return t?a.default.createElement(NotFoundErrorBoundary,{pathname:l,notFound:t,notFoundStyles:r,asNotFound:n},u):a.default.createElement(a.default.Fragment,null,u)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},49161:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{notFound:function(){return notFound},isNotFoundError:function(){return isNotFoundError}});let r="NEXT_NOT_FOUND";function notFound(){let e=Error(r);throw e.digest=r,e}function isNotFoundError(e){return(null==e?void 0:e.digest)===r}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},5678:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"PromiseQueue",{enumerable:!0,get:function(){return PromiseQueue}});let n=r(24677),a=r(6249);var o=a._("_maxConcurrency"),u=a._("_runningCount"),l=a._("_queue"),i=a._("_processNext");let PromiseQueue=class PromiseQueue{enqueue(e){let t,r;let a=new Promise((e,n)=>{t=e,r=n}),task=async()=>{try{n._(this,u)[u]++;let r=await e();t(r)}catch(e){r(e)}finally{n._(this,u)[u]--,n._(this,i)[i]()}};return n._(this,l)[l].push({promiseFn:a,task}),n._(this,i)[i](),a}bump(e){let t=n._(this,l)[l].findIndex(t=>t.promiseFn===e);if(t>-1){let e=n._(this,l)[l].splice(t,1)[0];n._(this,l)[l].unshift(e),n._(this,i)[i](!0)}}constructor(e=5){Object.defineProperty(this,i,{value:processNext}),Object.defineProperty(this,o,{writable:!0,value:void 0}),Object.defineProperty(this,u,{writable:!0,value:void 0}),Object.defineProperty(this,l,{writable:!0,value:void 0}),n._(this,o)[o]=e,n._(this,u)[u]=0,n._(this,l)[l]=[]}};function processNext(e){if(void 0===e&&(e=!1),(n._(this,u)[u]0){var t;null==(t=n._(this,l)[l].shift())||t.task()}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},37851:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{RedirectErrorBoundary:function(){return RedirectErrorBoundary},RedirectBoundary:function(){return RedirectBoundary}});let n=r(68533),a=n._(r(2265)),o=r(20290),u=r(28320);function HandleRedirect(e){let{redirect:t,reset:r,redirectType:n}=e,l=(0,o.useRouter)();return(0,a.useEffect)(()=>{a.default.startTransition(()=>{n===u.RedirectType.push?l.push(t,{}):l.replace(t,{}),r()})},[t,n,r,l]),null}let RedirectErrorBoundary=class RedirectErrorBoundary extends a.default.Component{static getDerivedStateFromError(e){if((0,u.isRedirectError)(e)){let t=(0,u.getURLFromRedirectError)(e),r=(0,u.getRedirectTypeFromError)(e);return{redirect:t,redirectType:r}}throw e}render(){let{redirect:e,redirectType:t}=this.state;return null!==e&&null!==t?a.default.createElement(HandleRedirect,{redirect:e,redirectType:t,reset:()=>this.setState({redirect:null})}):this.props.children}constructor(e){super(e),this.state={redirect:null,redirectType:null}}};function RedirectBoundary(e){let{children:t}=e,r=(0,o.useRouter)();return a.default.createElement(RedirectErrorBoundary,{router:r},t)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},28320:function(e,t,r){"use strict";var n,a;Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{RedirectType:function(){return n},getRedirectError:function(){return getRedirectError},redirect:function(){return redirect},permanentRedirect:function(){return permanentRedirect},isRedirectError:function(){return isRedirectError},getURLFromRedirectError:function(){return getURLFromRedirectError},getRedirectTypeFromError:function(){return getRedirectTypeFromError}});let o=r(77501),u="NEXT_REDIRECT";function getRedirectError(e,t,r){void 0===r&&(r=!1);let n=Error(u);n.digest=u+";"+t+";"+e+";"+r;let a=o.requestAsyncStorage.getStore();return a&&(n.mutableCookies=a.mutableCookies),n}function redirect(e,t){throw void 0===t&&(t="replace"),getRedirectError(e,t,!1)}function permanentRedirect(e,t){throw void 0===t&&(t="replace"),getRedirectError(e,t,!0)}function isRedirectError(e){if("string"!=typeof(null==e?void 0:e.digest))return!1;let[t,r,n,a]=e.digest.split(";",4);return t===u&&("replace"===r||"push"===r)&&"string"==typeof n&&("true"===a||"false"===a)}function getURLFromRedirectError(e){return isRedirectError(e)?e.digest.split(";",3)[2]:null}function getRedirectTypeFromError(e){if(!isRedirectError(e))throw Error("Not a redirect error");return e.digest.split(";",3)[1]}(a=n||(n={})).push="push",a.replace="replace",("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},18639:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return RenderFromTemplateContext}});let n=r(68533),a=n._(r(2265)),o=r(11792);function RenderFromTemplateContext(){let e=(0,a.useContext)(o.TemplateContext);return a.default.createElement(a.default.Fragment,null,e)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},77501:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"requestAsyncStorage",{enumerable:!0,get:function(){return a}});let n=r(31846),a=(0,n.createAsyncLocalStorage)();("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},47558:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"applyFlightData",{enumerable:!0,get:function(){return applyFlightData}});let n=r(11792),a=r(10980),o=r(1916);function applyFlightData(e,t,r,u){void 0===u&&(u=!1);let[l,i,s]=r.slice(-3);return null!==i&&(3===r.length?(t.status=n.CacheStates.READY,t.subTreeData=i,(0,a.fillLazyItemsTillLeafWithHead)(t,e,l,s,u)):(t.status=n.CacheStates.READY,t.subTreeData=e.subTreeData,t.parallelRoutes=new Map(e.parallelRoutes),(0,o.fillCacheWithNewSubTreeData)(t,e,r,u)),!0)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},41739:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"applyRouterStatePatchToTree",{enumerable:!0,get:function(){return function applyRouterStatePatchToTree(e,t,r){let a;let[o,u,,,l]=t;if(1===e.length){let e=applyPatch(t,r);return e}let[i,s]=e;if(!(0,n.matchSegment)(i,o))return null;let p=2===e.length;if(p)a=applyPatch(u[s],r);else if(null===(a=applyRouterStatePatchToTree(e.slice(2),u[s],r)))return null;let _=[e[0],{...u,[s]:a}];return l&&(_[4]=!0),_}}});let n=r(12858);function applyPatch(e,t){let[r,a]=e,[o,u]=t;if("__DEFAULT__"===o&&"__DEFAULT__"!==r)return e;if((0,n.matchSegment)(r,o)){let t={};for(let e in a){let r=void 0!==u[e];r?t[e]=applyPatch(a[e],u[e]):t[e]=a[e]}for(let e in u)t[e]||(t[e]=u[e]);let n=[r,t];return e[2]&&(n[2]=e[2]),e[3]&&(n[3]=e[3]),e[4]&&(n[4]=e[4]),n}return t}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},15240:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{extractPathFromFlightRouterState:function(){return extractPathFromFlightRouterState},computeChangedPath:function(){return computeChangedPath}});let n=r(84507),a=r(21235),o=r(12858),removeLeadingSlash=e=>"/"===e[0]?e.slice(1):e,segmentToPathname=e=>"string"==typeof e?e:e[1];function normalizeSegments(e){return e.reduce((e,t)=>""===(t=removeLeadingSlash(t))||(0,a.isGroupSegment)(t)?e:e+"/"+t,"")||"/"}function extractPathFromFlightRouterState(e){var t;let r=Array.isArray(e[0])?e[0][1]:e[0];if("__DEFAULT__"===r||n.INTERCEPTION_ROUTE_MARKERS.some(e=>r.startsWith(e)))return;if(r.startsWith("__PAGE__"))return"";let a=[r],o=null!=(t=e[1])?t:{},u=o.children?extractPathFromFlightRouterState(o.children):void 0;if(void 0!==u)a.push(u);else for(let[e,t]of Object.entries(o)){if("children"===e)continue;let r=extractPathFromFlightRouterState(t);void 0!==r&&a.push(r)}return normalizeSegments(a)}function computeChangedPath(e,t){let r=function computeChangedPathImpl(e,t){let[r,a]=e,[u,l]=t,i=segmentToPathname(r),s=segmentToPathname(u);if(n.INTERCEPTION_ROUTE_MARKERS.some(e=>i.startsWith(e)||s.startsWith(e)))return"";if(!(0,o.matchSegment)(r,u)){var p;return null!=(p=extractPathFromFlightRouterState(t))?p:""}for(let e in a)if(l[e]){let t=computeChangedPathImpl(a[e],l[e]);if(null!==t)return segmentToPathname(u)+"/"+t}return null}(e,t);return null==r||"/"===r?r:normalizeSegments(r.split("/"))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},67649:function(e,t){"use strict";function createHrefFromUrl(e,t){return void 0===t&&(t=!0),e.pathname+e.search+(t?e.hash:"")}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createHrefFromUrl",{enumerable:!0,get:function(){return createHrefFromUrl}}),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},78770:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createInitialRouterState",{enumerable:!0,get:function(){return createInitialRouterState}});let n=r(11792),a=r(67649),o=r(10980),u=r(15240);function createInitialRouterState(e){var t;let{buildId:r,initialTree:l,children:i,initialCanonicalUrl:s,initialParallelRoutes:p,isServer:_,location:b,initialHead:v}=e,E={status:n.CacheStates.READY,data:null,subTreeData:i,parallelRoutes:_?new Map:p};return(null===p||0===p.size)&&(0,o.fillLazyItemsTillLeafWithHead)(E,void 0,l,v),{buildId:r,tree:l,cache:E,prefetchCache:new Map,pushRef:{pendingPush:!1,mpaNavigation:!1},focusAndScrollRef:{apply:!1,onlyHashChange:!1,hashFragment:null,segmentPaths:[]},canonicalUrl:b?(0,a.createHrefFromUrl)(b):s,nextUrl:null!=(t=(0,u.extractPathFromFlightRouterState)(l)||(null==b?void 0:b.pathname))?t:null}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},28746:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createOptimisticTree",{enumerable:!0,get:function(){return function createOptimisticTree(e,t,r){let a;let[o,u,l,i,s]=t||[null,{}],p=e[0],_=1===e.length,b=null!==o&&(0,n.matchSegment)(o,p),v=Object.keys(u).length>1,E=!t||!b||v,j={};if(null!==o&&b&&(j=u),!_&&!v){let t=createOptimisticTree(e.slice(1),j?j.children:null,r||E);a=t}let C=[p,{...j,...a?{children:a}:{}}];return l&&(C[2]=l),!r&&E?C[3]="refetch":b&&i&&(C[3]=i),b&&s&&(C[4]=s),C}}});let n=r(12858);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},54790:function(e,t){"use strict";function createRecordFromThenable(e){return e.status="pending",e.then(t=>{"pending"===e.status&&(e.status="fulfilled",e.value=t)},t=>{"pending"===e.status&&(e.status="rejected",e.reason=t)}),e}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createRecordFromThenable",{enumerable:!0,get:function(){return createRecordFromThenable}}),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},93672:function(e,t){"use strict";function createRouterCacheKey(e,t){return void 0===t&&(t=!1),Array.isArray(e)?(e[0]+"|"+e[1]+"|"+e[2]).toLowerCase():t&&e.startsWith("__PAGE__")?"__PAGE__":e}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createRouterCacheKey",{enumerable:!0,get:function(){return createRouterCacheKey}}),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},9863:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"fetchServerResponse",{enumerable:!0,get:function(){return fetchServerResponse}});let n=r(59980),a=r(76054),o=r(22655),u=r(72271),l=r(655),{createFromFetch:i}=r(6671);function doMpaNavigation(e){return[(0,a.urlToUrlWithoutFlightMarker)(e).toString(),void 0]}async function fetchServerResponse(e,t,r,s,p){let _={[n.RSC]:"1",[n.NEXT_ROUTER_STATE_TREE]:encodeURIComponent(JSON.stringify(t))};p===u.PrefetchKind.AUTO&&(_[n.NEXT_ROUTER_PREFETCH]="1"),r&&(_[n.NEXT_URL]=r);let b=(0,l.hexHash)([_[n.NEXT_ROUTER_PREFETCH]||"0",_[n.NEXT_ROUTER_STATE_TREE],_[n.NEXT_URL]].join(","));try{let t=new URL(e);t.pathname.endsWith("/")?t.pathname+="index.txt":t.pathname+=".txt",t.searchParams.set(n.NEXT_RSC_UNION_QUERY,b);let r=await fetch(t,{credentials:"same-origin",headers:_}),u=(0,a.urlToUrlWithoutFlightMarker)(r.url),l=r.redirected?u:void 0,p=r.headers.get("content-type")||"",v=p===n.RSC_CONTENT_TYPE_HEADER;if(v||(v=p.startsWith("text/plain")),!v||!r.ok)return e.hash&&(u.hash=e.hash),doMpaNavigation(u.toString());let[E,j]=await i(Promise.resolve(r),{callServer:o.callServer});if(s!==E)return doMpaNavigation(r.url);return[j,l]}catch(t){return console.error("Failed to fetch RSC payload. Falling back to browser navigation.",t),[e.toString(),void 0]}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},68747:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"fillCacheWithDataProperty",{enumerable:!0,get:function(){return function fillCacheWithDataProperty(e,t,r,o,u){void 0===u&&(u=!1);let l=r.length<=2,[i,s]=r,p=(0,a.createRouterCacheKey)(s),_=t.parallelRoutes.get(i);if(!_||u&&t.parallelRoutes.size>1)return{bailOptimistic:!0};let b=e.parallelRoutes.get(i);b&&b!==_||(b=new Map(_),e.parallelRoutes.set(i,b));let v=_.get(p),E=b.get(p);if(l){E&&E.data&&E!==v||b.set(p,{status:n.CacheStates.DATA_FETCH,data:o(),subTreeData:null,parallelRoutes:new Map});return}if(!E||!v){E||b.set(p,{status:n.CacheStates.DATA_FETCH,data:o(),subTreeData:null,parallelRoutes:new Map});return}return E===v&&(E={status:E.status,data:E.data,subTreeData:E.subTreeData,parallelRoutes:new Map(E.parallelRoutes)},b.set(p,E)),fillCacheWithDataProperty(E,v,r.slice(2),o)}}});let n=r(11792),a=r(93672);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},1916:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"fillCacheWithNewSubTreeData",{enumerable:!0,get:function(){return function fillCacheWithNewSubTreeData(e,t,r,l){let i=r.length<=5,[s,p]=r,_=(0,u.createRouterCacheKey)(p),b=t.parallelRoutes.get(s);if(!b)return;let v=e.parallelRoutes.get(s);v&&v!==b||(v=new Map(b),e.parallelRoutes.set(s,v));let E=b.get(_),j=v.get(_);if(i){j&&j.data&&j!==E||(j={status:n.CacheStates.READY,data:null,subTreeData:r[3],parallelRoutes:E?new Map(E.parallelRoutes):new Map},E&&(0,a.invalidateCacheByRouterState)(j,E,r[2]),(0,o.fillLazyItemsTillLeafWithHead)(j,E,r[2],r[4],l),v.set(_,j));return}j&&E&&(j===E&&(j={status:j.status,data:j.data,subTreeData:j.subTreeData,parallelRoutes:new Map(j.parallelRoutes)},v.set(_,j)),fillCacheWithNewSubTreeData(j,E,r.slice(2),l))}}});let n=r(11792),a=r(16594),o=r(10980),u=r(93672);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},10980:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"fillLazyItemsTillLeafWithHead",{enumerable:!0,get:function(){return function fillLazyItemsTillLeafWithHead(e,t,r,o,u){let l=0===Object.keys(r[1]).length;if(l){e.head=o;return}for(let l in r[1]){let i=r[1][l],s=i[0],p=(0,a.createRouterCacheKey)(s);if(t){let r=t.parallelRoutes.get(l);if(r){let t=new Map(r),a=t.get(p),s=u&&a?{status:a.status,data:a.data,subTreeData:a.subTreeData,parallelRoutes:new Map(a.parallelRoutes)}:{status:n.CacheStates.LAZY_INITIALIZED,data:null,subTreeData:null,parallelRoutes:new Map(null==a?void 0:a.parallelRoutes)};t.set(p,s),fillLazyItemsTillLeafWithHead(s,a,i,o,u),e.parallelRoutes.set(l,t);continue}}let _={status:n.CacheStates.LAZY_INITIALIZED,data:null,subTreeData:null,parallelRoutes:new Map},b=e.parallelRoutes.get(l);b?b.set(p,_):e.parallelRoutes.set(l,new Map([[p,_]])),fillLazyItemsTillLeafWithHead(_,void 0,i,o,u)}}}});let n=r(11792),a=r(93672);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},16959:function(e,t){"use strict";var r,n;function getPrefetchEntryCacheStatus(e){let{kind:t,prefetchTime:r,lastUsedTime:n}=e;return Date.now()<(null!=n?n:r)+3e4?n?"reusable":"fresh":"auto"===t&&Date.now()["children",e]).flat(),v=(0,s.fillCacheWithDataProperty)(i,e.cache,b,()=>(_||(_=(0,o.createRecordFromThenable)((0,a.fetchServerResponse)(r,u,e.nextUrl,e.buildId))),_),!0);if(!(null==v?void 0:v.bailOptimistic))return $.previousTree=e.tree,$.patchedTree=u,$.pendingPush=et,$.hashFragment=Q,$.shouldScroll=K,$.scrollableSegments=[],$.cache=i,$.canonicalUrl=ee,e.prefetchCache.set((0,l.createHrefFromUrl)(r,!1),{data:_?(0,o.createRecordFromThenable)(Promise.resolve(_)):null,kind:E.PrefetchKind.TEMPORARY,prefetchTime:Date.now(),treeAtTimeOfPrefetch:e.tree,lastUsedTime:Date.now()}),(0,j.handleMutable)(e,$)}if(!en){let t=(0,o.createRecordFromThenable)((0,a.fetchServerResponse)(r,e.tree,e.nextUrl,e.buildId,void 0)),n={data:(0,o.createRecordFromThenable)(Promise.resolve(t)),kind:E.PrefetchKind.TEMPORARY,prefetchTime:Date.now(),treeAtTimeOfPrefetch:e.tree,lastUsedTime:null};e.prefetchCache.set((0,l.createHrefFromUrl)(r,!1),n),en=n}let ea=(0,w.getPrefetchEntryCacheStatus)(en),{treeAtTimeOfPrefetch:eo,data:eu}=en;F.prefetchQueue.bump(eu);let[el,ei]=(0,u.readRecordValue)(eu);if(en.lastUsedTime||(en.lastUsedTime=Date.now()),"string"==typeof el)return handleExternalUrl(e,$,el,et);let ec=e.tree,es=e.cache,ef=[];for(let t of el){let u=t.slice(0,-4),l=t.slice(-3)[0],p=["",...u],E=(0,_.applyRouterStatePatchToTree)(p,ec,l);if(null===E&&(E=(0,_.applyRouterStatePatchToTree)(p,eo,l)),null!==E){if((0,v.isNavigatingToNewRootLayout)(ec,E))return handleExternalUrl(e,$,ee,et);let _=(0,C.applyFlightData)(es,B,t,"auto"===en.kind&&ea===w.PrefetchCacheEntryStatus.reusable);_||ea!==w.PrefetchCacheEntryStatus.stale||(_=function(e,t,r,a,o){let u=!1;e.status=n.CacheStates.READY,e.subTreeData=t.subTreeData,e.parallelRoutes=new Map(t.parallelRoutes);let l=generateSegmentsFromPatch(a).map(e=>[...r,...e]);for(let r of l){let n=(0,s.fillCacheWithDataProperty)(e,t,r,o);(null==n?void 0:n.bailOptimistic)||(u=!0)}return u}(B,es,u,l,()=>(0,o.createRecordFromThenable)((0,a.fetchServerResponse)(r,ec,e.nextUrl,e.buildId))));let j=(0,b.shouldHardNavigate)(p,ec);for(let e of(j?(B.status=n.CacheStates.READY,B.subTreeData=es.subTreeData,(0,i.invalidateCacheBelowFlightSegmentPath)(B,es,u),$.cache=B):_&&($.cache=B),es=B,ec=E,generateSegmentsFromPatch(l))){let t=[...u,...e];"__DEFAULT__"!==t[t.length-1]&&ef.push(t)}}}return $.previousTree=e.tree,$.patchedTree=ec,$.canonicalUrl=ei?(0,l.createHrefFromUrl)(ei):ee,$.pendingPush=et,$.scrollableSegments=ef,$.hashFragment=Q,$.shouldScroll=K,(0,j.handleMutable)(e,$)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},82191:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{prefetchQueue:function(){return p},prefetchReducer:function(){return prefetchReducer}});let n=r(67649),a=r(9863),o=r(72271),u=r(54790),l=r(72512),i=r(59980),s=r(5678),p=new s.PromiseQueue(5);function prefetchReducer(e,t){(0,l.prunePrefetchCache)(e.prefetchCache);let{url:r}=t;r.searchParams.delete(i.NEXT_RSC_UNION_QUERY);let s=(0,n.createHrefFromUrl)(r,!1),_=e.prefetchCache.get(s);if(_&&(_.kind===o.PrefetchKind.TEMPORARY&&e.prefetchCache.set(s,{..._,kind:t.kind}),!(_.kind===o.PrefetchKind.AUTO&&t.kind===o.PrefetchKind.FULL)))return e;let b=(0,u.createRecordFromThenable)(p.enqueue(()=>(0,a.fetchServerResponse)(r,e.tree,e.nextUrl,e.buildId,t.kind)));return e.prefetchCache.set(s,{treeAtTimeOfPrefetch:e.tree,data:b,kind:t.kind,prefetchTime:Date.now(),lastUsedTime:null}),e}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},72512:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"prunePrefetchCache",{enumerable:!0,get:function(){return prunePrefetchCache}});let n=r(16959);function prunePrefetchCache(e){for(let[t,r]of e)(0,n.getPrefetchEntryCacheStatus)(r)===n.PrefetchCacheEntryStatus.expired&&e.delete(t)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},27063:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"refreshReducer",{enumerable:!0,get:function(){return refreshReducer}});let n=r(9863),a=r(54790),o=r(55327),u=r(67649),l=r(41739),i=r(22542),s=r(15971),p=r(56586),_=r(11792),b=r(10980);function refreshReducer(e,t){let{cache:r,mutable:v,origin:E}=t,j=e.canonicalUrl,C=e.tree,w=JSON.stringify(v.previousTree)===JSON.stringify(C);if(w)return(0,p.handleMutable)(e,v);r.data||(r.data=(0,a.createRecordFromThenable)((0,n.fetchServerResponse)(new URL(j,E),[C[0],C[1],C[2],"refetch"],e.nextUrl,e.buildId)));let[A,F]=(0,o.readRecordValue)(r.data);if("string"==typeof A)return(0,s.handleExternalUrl)(e,v,A,e.pushRef.pendingPush);for(let t of(r.data=null,A)){if(3!==t.length)return console.log("REFRESH FAILED"),e;let[n]=t,a=(0,l.applyRouterStatePatchToTree)([""],C,n);if(null===a)throw Error("SEGMENT MISMATCH");if((0,i.isNavigatingToNewRootLayout)(C,a))return(0,s.handleExternalUrl)(e,v,j,e.pushRef.pendingPush);let o=F?(0,u.createHrefFromUrl)(F):void 0;F&&(v.canonicalUrl=o);let[p,E]=t.slice(-2);null!==p&&(r.status=_.CacheStates.READY,r.subTreeData=p,(0,b.fillLazyItemsTillLeafWithHead)(r,void 0,n,E),v.cache=r,v.prefetchCache=new Map),v.previousTree=C,v.patchedTree=a,v.canonicalUrl=j,C=a}return(0,p.handleMutable)(e,v)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},65686:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"restoreReducer",{enumerable:!0,get:function(){return restoreReducer}});let n=r(67649);function restoreReducer(e,t){let{url:r,tree:a}=t,o=(0,n.createHrefFromUrl)(r);return{buildId:e.buildId,canonicalUrl:o,pushRef:e.pushRef,focusAndScrollRef:e.focusAndScrollRef,cache:e.cache,prefetchCache:e.prefetchCache,tree:a,nextUrl:r.pathname}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},71465:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"serverActionReducer",{enumerable:!0,get:function(){return serverActionReducer}});let n=r(22655),a=r(59980),o=r(54790),u=r(55327),l=r(69207),i=r(67649),s=r(15971),p=r(41739),_=r(22542),b=r(11792),v=r(56586),E=r(10980),{createFromFetch:j,encodeReply:C}=r(6671);async function fetchServerAction(e,t){let r,{actionId:o,actionArgs:u}=t,i=await C(u),s=await fetch("",{method:"POST",headers:{Accept:a.RSC_CONTENT_TYPE_HEADER,[a.ACTION]:o,[a.NEXT_ROUTER_STATE_TREE]:encodeURIComponent(JSON.stringify(e.tree)),...e.nextUrl?{[a.NEXT_URL]:e.nextUrl}:{}},body:i}),p=s.headers.get("x-action-redirect");try{let e=JSON.parse(s.headers.get("x-action-revalidated")||"[[],0,0]");r={paths:e[0]||[],tag:!!e[1],cookie:e[2]}}catch(e){r={paths:[],tag:!1,cookie:!1}}let _=p?new URL((0,l.addBasePath)(p),new URL(e.canonicalUrl,window.location.href)):void 0;if(s.headers.get("content-type")===a.RSC_CONTENT_TYPE_HEADER){let e=await j(Promise.resolve(s),{callServer:n.callServer});if(p){let[,t]=null!=e?e:[];return{actionFlightData:t,redirectLocation:_,revalidatedParts:r}}let[t,[,a]]=null!=e?e:[];return{actionResult:t,actionFlightData:a,redirectLocation:_,revalidatedParts:r}}return{redirectLocation:_,revalidatedParts:r}}function serverActionReducer(e,t){let{mutable:r,cache:n,resolve:a,reject:l}=t,j=e.canonicalUrl,C=e.tree,w=JSON.stringify(r.previousTree)===JSON.stringify(C);if(w)return(0,v.handleMutable)(e,r);if(r.inFlightServerAction){if("fulfilled"!==r.inFlightServerAction.status&&r.globalMutable.pendingNavigatePath&&r.globalMutable.pendingNavigatePath!==j)return r.inFlightServerAction.then(()=>{r.actionResultResolved||(r.inFlightServerAction=null,r.globalMutable.pendingNavigatePath=void 0,r.globalMutable.refresh(),r.actionResultResolved=!0)},()=>{}),e}else r.inFlightServerAction=(0,o.createRecordFromThenable)(fetchServerAction(e,t));try{let{actionResult:t,actionFlightData:o,redirectLocation:l}=(0,u.readRecordValue)(r.inFlightServerAction);if(l&&(e.pushRef.pendingPush=!0,r.pendingPush=!0),r.previousTree=e.tree,!o){if(r.actionResultResolved||(a(t),r.actionResultResolved=!0),l)return(0,s.handleExternalUrl)(e,r,l.href,e.pushRef.pendingPush);return e}if("string"==typeof o)return(0,s.handleExternalUrl)(e,r,o,e.pushRef.pendingPush);for(let t of(r.inFlightServerAction=null,o)){if(3!==t.length)return console.log("SERVER ACTION APPLY FAILED"),e;let[a]=t,o=(0,p.applyRouterStatePatchToTree)([""],C,a);if(null===o)throw Error("SEGMENT MISMATCH");if((0,_.isNavigatingToNewRootLayout)(C,o))return(0,s.handleExternalUrl)(e,r,j,e.pushRef.pendingPush);let[u,l]=t.slice(-2);null!==u&&(n.status=b.CacheStates.READY,n.subTreeData=u,(0,E.fillLazyItemsTillLeafWithHead)(n,void 0,a,l),r.cache=n,r.prefetchCache=new Map),r.previousTree=C,r.patchedTree=o,r.canonicalUrl=j,C=o}if(l){let e=(0,i.createHrefFromUrl)(l,!1);r.canonicalUrl=e}return r.actionResultResolved||(a(t),r.actionResultResolved=!0),(0,v.handleMutable)(e,r)}catch(t){if("rejected"===t.status)return r.actionResultResolved||(l(t.reason),r.actionResultResolved=!0),e;throw t}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},26079:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"serverPatchReducer",{enumerable:!0,get:function(){return serverPatchReducer}});let n=r(67649),a=r(41739),o=r(22542),u=r(15971),l=r(47558),i=r(56586);function serverPatchReducer(e,t){let{flightData:r,previousTree:s,overrideCanonicalUrl:p,cache:_,mutable:b}=t,v=JSON.stringify(s)===JSON.stringify(e.tree);if(!v)return console.log("TREE MISMATCH"),e;if(b.previousTree)return(0,i.handleMutable)(e,b);if("string"==typeof r)return(0,u.handleExternalUrl)(e,b,r,e.pushRef.pendingPush);let E=e.tree,j=e.cache;for(let t of r){let r=t.slice(0,-4),[i]=t.slice(-3,-2),s=(0,a.applyRouterStatePatchToTree)(["",...r],E,i);if(null===s)throw Error("SEGMENT MISMATCH");if((0,o.isNavigatingToNewRootLayout)(E,s))return(0,u.handleExternalUrl)(e,b,e.canonicalUrl,e.pushRef.pendingPush);let v=p?(0,n.createHrefFromUrl)(p):void 0;v&&(b.canonicalUrl=v),(0,l.applyFlightData)(j,_,t),b.previousTree=E,b.patchedTree=s,b.cache=_,j=_,E=s}return(0,i.handleMutable)(e,b)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},72271:function(e,t){"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{PrefetchKind:function(){return r},ACTION_REFRESH:function(){return a},ACTION_NAVIGATE:function(){return o},ACTION_RESTORE:function(){return u},ACTION_SERVER_PATCH:function(){return l},ACTION_PREFETCH:function(){return i},ACTION_FAST_REFRESH:function(){return s},ACTION_SERVER_ACTION:function(){return p}});let a="refresh",o="navigate",u="restore",l="server-patch",i="prefetch",s="fast-refresh",p="server-action";(n=r||(r={})).AUTO="auto",n.FULL="full",n.TEMPORARY="temporary",("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},23626:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"reducer",{enumerable:!0,get:function(){return reducer}});let n=r(72271),a=r(15971),o=r(26079),u=r(65686),l=r(27063),i=r(82191),s=r(95170),p=r(71465),reducer=function(e,t){switch(t.type){case n.ACTION_NAVIGATE:return(0,a.navigateReducer)(e,t);case n.ACTION_SERVER_PATCH:return(0,o.serverPatchReducer)(e,t);case n.ACTION_RESTORE:return(0,u.restoreReducer)(e,t);case n.ACTION_REFRESH:return(0,l.refreshReducer)(e,t);case n.ACTION_FAST_REFRESH:return(0,s.fastRefreshReducer)(e,t);case n.ACTION_PREFETCH:return(0,i.prefetchReducer)(e,t);case n.ACTION_SERVER_ACTION:return(0,p.serverActionReducer)(e,t);default:throw Error("Unknown action")}};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},44427:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"shouldHardNavigate",{enumerable:!0,get:function(){return function shouldHardNavigate(e,t){let[r,a]=t,[o,u]=e;if(!(0,n.matchSegment)(o,r))return!!Array.isArray(o);let l=e.length<=2;return!l&&shouldHardNavigate(e.slice(2),a[u])}}});let n=r(12858);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},63046:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createSearchParamsBailoutProxy",{enumerable:!0,get:function(){return createSearchParamsBailoutProxy}});let n=r(75350);function createSearchParamsBailoutProxy(){return new Proxy({},{get(e,t){"string"==typeof t&&(0,n.staticGenerationBailout)("searchParams."+t)}})}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},41788:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"staticGenerationAsyncStorage",{enumerable:!0,get:function(){return a}});let n=r(31846),a=(0,n.createAsyncLocalStorage)();("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},75350:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"staticGenerationBailout",{enumerable:!0,get:function(){return staticGenerationBailout}});let n=r(82076),a=r(41788);let StaticGenBailoutError=class StaticGenBailoutError extends Error{constructor(...e){super(...e),this.code="NEXT_STATIC_GEN_BAILOUT"}};function formatErrorMessage(e,t){let{dynamic:r,link:n}=t||{};return"Page"+(r?' with `dynamic = "'+r+'"`':"")+" couldn't be rendered statically because it used `"+e+"`."+(n?" See more info here: "+n:"")}let staticGenerationBailout=(e,t)=>{let r=a.staticGenerationAsyncStorage.getStore();if(null==r?void 0:r.forceStatic)return!0;if(null==r?void 0:r.dynamicShouldError){var o;throw new StaticGenBailoutError(formatErrorMessage(e,{...t,dynamic:null!=(o=null==t?void 0:t.dynamic)?o:"error"}))}if(!r||(r.revalidate=0,(null==t?void 0:t.dynamic)||(r.staticPrefetchBailout=!0)),null==r?void 0:r.isStaticGeneration){let a=new n.DynamicServerError(formatErrorMessage(e,{...t,link:"https://nextjs.org/docs/messages/dynamic-server-error"}));throw r.dynamicUsageDescription=e,r.dynamicUsageStack=a.stack,a}return!1};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},65146:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return StaticGenerationSearchParamsBailoutProvider}});let n=r(21024),a=n._(r(2265)),o=r(63046);function StaticGenerationSearchParamsBailoutProvider(e){let{Component:t,propsForComponent:r,isStaticGeneration:n}=e;if(n){let e=(0,o.createSearchParamsBailoutProxy)();return a.default.createElement(t,{searchParams:e,...r})}return a.default.createElement(t,r)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},74423:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useReducerWithReduxDevtools",{enumerable:!0,get:function(){return useReducerWithReduxDevtools}});let n=r(2265);function normalizeRouterState(e){if(e instanceof Map){let t={};for(let[r,n]of e.entries()){if("function"==typeof n){t[r]="fn()";continue}if("object"==typeof n&&null!==n){if(n.$$typeof){t[r]=n.$$typeof.toString();continue}if(n._bundlerConfig){t[r]="FlightData";continue}}t[r]=normalizeRouterState(n)}return t}if("object"==typeof e&&null!==e){let t={};for(let r in e){let n=e[r];if("function"==typeof n){t[r]="fn()";continue}if("object"==typeof n&&null!==n){if(n.$$typeof){t[r]=n.$$typeof.toString();continue}if(n.hasOwnProperty("_bundlerConfig")){t[r]="FlightData";continue}}t[r]=normalizeRouterState(n)}return t}return Array.isArray(e)?e.map(normalizeRouterState):e}let useReducerWithReduxDevtools=function(e,t){let r=(0,n.useRef)(),a=(0,n.useRef)();(0,n.useEffect)(()=>{if(!r.current&&!1!==a.current){if(void 0===a.current&&void 0===window.__REDUX_DEVTOOLS_EXTENSION__){a.current=!1;return}return r.current=window.__REDUX_DEVTOOLS_EXTENSION__.connect({instanceId:8e3,name:"next-router"}),r.current&&r.current.init(normalizeRouterState(t)),()=>{r.current=void 0}}},[t]);let[o,u]=(0,n.useReducer)((t,n)=>{let a=e(t,n);return r.current&&r.current.send(n,normalizeRouterState(a)),a},t),l=(0,n.useCallback)(()=>{r.current&&r.current.send({type:"RENDER_SYNC"},normalizeRouterState(o))},[o]);return[o,u,l]};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},44561:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"hasBasePath",{enumerable:!0,get:function(){return hasBasePath}});let n=r(15648);function hasBasePath(e){return(0,n.pathHasPrefix)(e,"/test-wagmi-safe-privy")}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},70474:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"normalizePathTrailingSlash",{enumerable:!0,get:function(){return normalizePathTrailingSlash}});let n=r(993),a=r(89792),normalizePathTrailingSlash=e=>{if(!e.startsWith("/"))return e;let{pathname:t,query:r,hash:o}=(0,a.parsePath)(e);return""+(0,n.removeTrailingSlash)(t)+r+o};("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},71747:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return onRecoverableError}});let n=r(54922);function onRecoverableError(e){let t="function"==typeof reportError?reportError:e=>{window.console.error(e)};e.digest!==n.NEXT_DYNAMIC_NO_SSR_CODE&&t(e)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},14286:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"removeBasePath",{enumerable:!0,get:function(){return removeBasePath}}),r(44561);let n="/test-wagmi-safe-privy";function removeBasePath(e){return 0===n.length||(e=e.slice(n.length)).startsWith("/")||(e="/"+e),e}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},11792:function(e,t,r){"use strict";var n,a;Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{CacheStates:function(){return n},AppRouterContext:function(){return l},LayoutRouterContext:function(){return i},GlobalLayoutRouterContext:function(){return s},TemplateContext:function(){return p}});let o=r(21024),u=o._(r(2265));(a=n||(n={})).LAZY_INITIALIZED="LAZYINITIALIZED",a.DATA_FETCH="DATAFETCH",a.READY="READY";let l=u.default.createContext(null),i=u.default.createContext(null),s=u.default.createContext(null),p=u.default.createContext(null)},655:function(e,t){"use strict";function djb2Hash(e){let t=5381;for(let r=0;r!t||(0,a.isGroupSegment)(t)||"@"===t[0]||("page"===t||"route"===t)&&r===n.length-1?e:e+"/"+t,""))}function normalizeRscPath(e,t){return t?e.replace(/\.rsc($|\?)/,"$1"):e}},53843:function(e,t){"use strict";function handleSmoothScroll(e,t){if(void 0===t&&(t={}),t.onlyHashChange){e();return}let r=document.documentElement,n=r.style.scrollBehavior;r.style.scrollBehavior="auto",t.dontForceLayout||r.getClientRects(),e(),r.style.scrollBehavior=n}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"handleSmoothScroll",{enumerable:!0,get:function(){return handleSmoothScroll}})},66175:function(e,t){"use strict";function isBot(e){return/Googlebot|Mediapartners-Google|AdsBot-Google|googleweblight|Storebot-Google|Google-PageRenderer|Bingbot|BingPreview|Slurp|DuckDuckBot|baiduspider|yandex|sogou|LinkedInBot|bitlybot|tumblr|vkShare|quora link preview|facebookexternalhit|facebookcatalog|Twitterbot|applebot|redditbot|Slackbot|Discordbot|WhatsApp|SkypeUriPreview|ia_archiver/i.test(e)}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isBot",{enumerable:!0,get:function(){return isBot}})},89792:function(e,t){"use strict";function parsePath(e){let t=e.indexOf("#"),r=e.indexOf("?"),n=r>-1&&(t<0||r-1?{pathname:e.substring(0,n?r:t),query:n?e.substring(r,t>-1?t:void 0):"",hash:t>-1?e.slice(t):""}:{pathname:e,query:"",hash:""}}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"parsePath",{enumerable:!0,get:function(){return parsePath}})},15648:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"pathHasPrefix",{enumerable:!0,get:function(){return pathHasPrefix}});let n=r(89792);function pathHasPrefix(e,t){if("string"!=typeof e)return!1;let{pathname:r}=(0,n.parsePath)(e);return r===t||r.startsWith(t+"/")}},993:function(e,t){"use strict";function removeTrailingSlash(e){return e.replace(/\/$/,"")||"/"}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"removeTrailingSlash",{enumerable:!0,get:function(){return removeTrailingSlash}})},21235:function(e,t){"use strict";function isGroupSegment(e){return"("===e[0]&&e.endsWith(")")}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isGroupSegment",{enumerable:!0,get:function(){return isGroupSegment}})},26619:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ServerInsertedHTMLContext:function(){return o},useServerInsertedHTML:function(){return useServerInsertedHTML}});let n=r(68533),a=n._(r(2265)),o=a.default.createContext(null);function useServerInsertedHTML(e){let t=(0,a.useContext)(o);t&&t(e)}},31846:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createAsyncLocalStorage",{enumerable:!0,get:function(){return createAsyncLocalStorage}});let r=Error("Invariant: AsyncLocalStorage accessed in runtime where it is not available");let FakeAsyncLocalStorage=class FakeAsyncLocalStorage{disable(){throw r}getStore(){}run(){throw r}exit(){throw r}enterWith(){throw r}};let n=globalThis.AsyncLocalStorage;function createAsyncLocalStorage(){return n?new n:new FakeAsyncLocalStorage}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},34040:function(e,t,r){"use strict";var n=r(54887);t.createRoot=n.createRoot,t.hydrateRoot=n.hydrateRoot},54887:function(e,t,r){"use strict";!function checkDCE(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE)}catch(e){console.error(e)}}(),e.exports=r(84417)},97950:function(e,t,r){"use strict";/** + * @license React + * react-server-dom-webpack-client.browser.production.min.js + * + * Copyright (c) Meta Platforms, Inc. and affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var n=r(54887),a=r(2265),o={stream:!0},u=new Map;function x(e){var t=globalThis.__next_require__(e);return"function"!=typeof t.then||"fulfilled"===t.status?null:(t.then(function(e){t.status="fulfilled",t.value=e},function(e){t.status="rejected",t.reason=e}),t)}function y(){}var l=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.Dispatcher,i=Symbol.for("react.element"),s=Symbol.for("react.lazy"),p=Symbol.for("react.default_value"),_=Symbol.iterator,b=Array.isArray,v=new WeakMap,E=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ContextRegistry;function L(e,t,r,n){this.status=e,this.value=t,this.reason=r,this._response=n}function da(e){switch(e.status){case"resolved_model":M(e);break;case"resolved_module":N(e)}switch(e.status){case"fulfilled":return e.value;case"pending":case"blocked":throw e;default:throw e.reason}}function O(e,t){for(var r=0;ri?(p=i,i=3,a++):(p=0,i=3);continue;case 2:44===(v=n[a++])?i=4:_=_<<4|(96n.length&&(v=-1)}var E=n.byteOffset+a;if(-1>>1,a=e[n];if(0>>1;ng(l,r))ig(s,l)?(e[n]=s,e[i]=r,n=i):(e[n]=l,e[u]=r,n=u);else if(ig(s,r))e[n]=s,e[i]=r,n=i;else break}}return t}function g(e,t){var r=e.sortIndex-t.sortIndex;return 0!==r?r:e.id-t.id}if(t.unstable_now=void 0,"object"==typeof performance&&"function"==typeof performance.now){var r,n=performance;t.unstable_now=function(){return n.now()}}else{var a=Date,o=a.now();t.unstable_now=function(){return a.now()-o}}var u=[],l=[],i=1,s=null,p=3,_=!1,b=!1,v=!1,E="function"==typeof setTimeout?setTimeout:null,j="function"==typeof clearTimeout?clearTimeout:null,C="undefined"!=typeof setImmediate?setImmediate:null;function G(e){for(var t=h(l);null!==t;){if(null===t.callback)k(l);else if(t.startTime<=e)k(l),t.sortIndex=t.expirationTime,f(u,t);else break;t=h(l)}}function H(e){if(v=!1,G(e),!b){if(null!==h(u))b=!0,I();else{var t=h(l);null!==t&&J(H,t.startTime-e)}}}"undefined"!=typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var w=!1,A=-1,F=5,D=-1;function O(){return!(t.unstable_now()-De&&O());){var o=s.callback;if("function"==typeof o){s.callback=null,p=s.priorityLevel;var i=o(s.expirationTime<=e);if(e=t.unstable_now(),"function"==typeof i){s.callback=i,G(e),n=!0;break t}s===h(u)&&k(u),G(e)}else k(u);s=h(u)}if(null!==s)n=!0;else{var E=h(l);null!==E&&J(H,E.startTime-e),n=!1}}break e}finally{s=null,p=a,_=!1}n=void 0}}finally{n?r():w=!1}}}if("function"==typeof C)r=function(){C(P)};else if("undefined"!=typeof MessageChannel){var U=new MessageChannel,B=U.port2;U.port1.onmessage=P,r=function(){B.postMessage(null)}}else r=function(){E(P,0)};function I(){w||(w=!0,r())}function J(e,r){A=E(function(){e(t.unstable_now())},r)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){b||_||(b=!0,I())},t.unstable_forceFrameRate=function(e){0>e||125a?(e.sortIndex=n,f(l,e),null===h(u)&&e===h(l)&&(v?(j(A),A=-1):v=!0,J(H,n-a))):(e.sortIndex=o,f(u,e),b||_||(b=!0,I())),e},t.unstable_shouldYield=O,t.unstable_wrapCallback=function(e){var t=p;return function(){var r=p;p=t;try{return e.apply(this,arguments)}finally{p=r}}}},8261:function(e,t,r){"use strict";e.exports=r(21756)},15682:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getSegmentParam",{enumerable:!0,get:function(){return getSegmentParam}});let n=r(84507);function getSegmentParam(e){let t=n.INTERCEPTION_ROUTE_MARKERS.find(t=>e.startsWith(t));return(t&&(e=e.slice(t.length)),e.startsWith("[[...")&&e.endsWith("]]"))?{type:"optional-catchall",param:e.slice(5,-2)}:e.startsWith("[...")&&e.endsWith("]")?{type:"catchall",param:e.slice(4,-1)}:e.startsWith("[")&&e.endsWith("]")?{type:"dynamic",param:e.slice(1,-1)}:null}},84507:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{INTERCEPTION_ROUTE_MARKERS:function(){return a},isInterceptionRouteAppPath:function(){return isInterceptionRouteAppPath},extractInterceptionRouteInformation:function(){return extractInterceptionRouteInformation}});let n=r(50291),a=["(..)(..)","(.)","(..)","(...)"];function isInterceptionRouteAppPath(e){return void 0!==e.split("/").find(e=>a.find(t=>e.startsWith(t)))}function extractInterceptionRouteInformation(e){let t,r,o;for(let n of e.split("/"))if(r=a.find(e=>n.startsWith(e))){[t,o]=e.split(r,2);break}if(!t||!r||!o)throw Error(`Invalid interception route: ${e}. Must be in the format //(..|...|..)(..)/`);switch(t=(0,n.normalizeAppPath)(t),r){case"(.)":o="/"===t?`/${o}`:t+"/"+o;break;case"(..)":if("/"===t)throw Error(`Invalid interception route: ${e}. Cannot use (..) marker at the root level, use (.) instead.`);o=t.split("/").slice(0,-1).concat(o).join("/");break;case"(...)":o="/"+o;break;case"(..)(..)":let u=t.split("/");if(u.length<=2)throw Error(`Invalid interception route: ${e}. Cannot use (..)(..) marker at the root level or one level up.`);o=u.slice(0,-2).concat(o).join("/");break;default:throw Error("Invariant: unexpected marker")}return{interceptingRoute:t,interceptedRoute:o}}},24677:function(e,t,r){"use strict";function _class_private_field_loose_base(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw TypeError("attempted to use private field on non-instance");return e}r.r(t),r.d(t,{_:function(){return _class_private_field_loose_base},_class_private_field_loose_base:function(){return _class_private_field_loose_base}})},6249:function(e,t,r){"use strict";r.r(t),r.d(t,{_:function(){return _class_private_field_loose_key},_class_private_field_loose_key:function(){return _class_private_field_loose_key}});var n=0;function _class_private_field_loose_key(e){return"__private_"+n+++"_"+e}},21024:function(e,t,r){"use strict";function _interop_require_default(e){return e&&e.__esModule?e:{default:e}}r.r(t),r.d(t,{_:function(){return _interop_require_default},_interop_require_default:function(){return _interop_require_default}})},68533:function(e,t,r){"use strict";function _getRequireWildcardCache(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(_getRequireWildcardCache=function(e){return e?r:t})(e)}function _interop_require_wildcard(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var r=_getRequireWildcardCache(t);if(r&&r.has(e))return r.get(e);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&Object.prototype.hasOwnProperty.call(e,o)){var u=a?Object.getOwnPropertyDescriptor(e,o):null;u&&(u.get||u.set)?Object.defineProperty(n,o,u):n[o]=e[o]}return n.default=e,r&&r.set(e,n),n}r.r(t),r.d(t,{_:function(){return _interop_require_wildcard},_interop_require_wildcard:function(){return _interop_require_wildcard}})}}]); \ No newline at end of file diff --git a/_next/static/chunks/905-d2b9c45a6b50b0e1.js b/_next/static/chunks/905-d2b9c45a6b50b0e1.js new file mode 100644 index 0000000..a6d0866 --- /dev/null +++ b/_next/static/chunks/905-d2b9c45a6b50b0e1.js @@ -0,0 +1,218 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[905],{36098:function(c,l,et){"use strict";var eo=et(25566);Object.defineProperty(l,"__esModule",{value:!0}),l.CoinbaseWalletSDK=void 0;let es=et(95691),ec=et(89406),el=et(3384),ed=et(81217),eh=et(50312),ef=et(84607),ep=et(7278),eg=et(91029),em=et(59656),eb=eo.env.LINK_API_URL||"https://www.walletlink.org",ey=eo.env.SDK_VERSION||et(6871).i8||"unknown";let CoinbaseWalletSDK=class CoinbaseWalletSDK{constructor(c){var l,et,eo;this._appName="",this._appLogoUrl=null,this._relay=null,this._relayEventManager=null;let es=c.linkAPIUrl||eb;if(void 0===c.overrideIsMetaMask?this._overrideIsMetaMask=!1:this._overrideIsMetaMask=c.overrideIsMetaMask,this._overrideIsCoinbaseWallet=null===(l=c.overrideIsCoinbaseWallet)||void 0===l||l,this._overrideIsCoinbaseBrowser=null!==(et=c.overrideIsCoinbaseBrowser)&&void 0!==et&&et,c.diagnosticLogger&&c.eventListener)throw Error("Can't have both eventListener and diagnosticLogger options, use only diagnosticLogger");c.eventListener?this._diagnosticLogger={log:c.eventListener.onEvent}:this._diagnosticLogger=c.diagnosticLogger,this._reloadOnDisconnect=null===(eo=c.reloadOnDisconnect)||void 0===eo||eo;let el=new URL(es),e_=`${el.protocol}//${el.host}`;if(this._storage=new ec.ScopedLocalStorage(`-walletlink:${e_}`),this._storage.setItem("version",CoinbaseWalletSDK.VERSION),this.walletExtension||this.coinbaseBrowser)return;this._relayEventManager=new eg.WalletSDKRelayEventManager;let ew=(0,em.isMobileWeb)(),eE=c.uiConstructor||(c=>ew?new ed.MobileRelayUI(c):new eh.WalletLinkRelayUI(c)),eS={linkAPIUrl:es,version:ey,darkMode:!!c.darkMode,uiConstructor:eE,storage:this._storage,relayEventManager:this._relayEventManager,diagnosticLogger:this._diagnosticLogger,reloadOnDisconnect:this._reloadOnDisconnect,enableMobileWalletLink:c.enableMobileWalletLink};if(this._relay=ew?new ef.MobileRelay(eS):new ep.WalletLinkRelay(eS),this.setAppInfo(c.appName,c.appLogoUrl),c.headlessMode)return;this._relay.attachUI()}makeWeb3Provider(c="",l=1){let et=this.walletExtension;if(et)return this.isCipherProvider(et)||et.setProviderInfo(c,l),!1===this._reloadOnDisconnect&&"function"==typeof et.disableReloadOnDisconnect&&et.disableReloadOnDisconnect(),et;let eo=this.coinbaseBrowser;if(eo)return eo;let es=this._relay;if(!es||!this._relayEventManager||!this._storage)throw Error("Relay not initialized, should never happen");return c||es.setConnectDisabled(!0),new el.CoinbaseWalletProvider({relayProvider:()=>Promise.resolve(es),relayEventManager:this._relayEventManager,storage:this._storage,jsonRpcUrl:c,chainId:l,qrUrl:this.getQrUrl(),diagnosticLogger:this._diagnosticLogger,overrideIsMetaMask:this._overrideIsMetaMask,overrideIsCoinbaseWallet:this._overrideIsCoinbaseWallet,overrideIsCoinbaseBrowser:this._overrideIsCoinbaseBrowser})}setAppInfo(c,l){var et;this._appName=c||"DApp",this._appLogoUrl=l||(0,em.getFavicon)();let eo=this.walletExtension;eo?this.isCipherProvider(eo)||eo.setAppInfo(this._appName,this._appLogoUrl):null===(et=this._relay)||void 0===et||et.setAppInfo(this._appName,this._appLogoUrl)}setUseLocationMethod(c){this._relay instanceof ef.MobileRelay&&this._relay.setUseLocationMethod(c)}disconnect(){var c;let l=this.walletExtension;l?l.close():null===(c=this._relay)||void 0===c||c.resetAndReload()}getQrUrl(){var c,l;return null!==(l=null===(c=this._relay)||void 0===c?void 0:c.getQRCodeUrl())&&void 0!==l?l:null}getCoinbaseWalletLogo(c,l=240){return(0,es.walletLogo)(c,l)}get walletExtension(){var c;return null!==(c=window.coinbaseWalletExtension)&&void 0!==c?c:window.walletLinkExtension}get coinbaseBrowser(){var c,l;try{let et=null!==(c=window.ethereum)&&void 0!==c?c:null===(l=window.top)||void 0===l?void 0:l.ethereum;if(!et)return;if("isCoinbaseBrowser"in et&&et.isCoinbaseBrowser)return et;return}catch(c){return}}isCipherProvider(c){return"boolean"==typeof c.isCipher&&c.isCipher}};l.CoinbaseWalletSDK=CoinbaseWalletSDK,CoinbaseWalletSDK.VERSION=ey},95691:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.walletLogo=void 0,l.walletLogo=(c,l)=>{let et;switch(c){case"standard":default:return et=l,`data:image/svg+xml,%3Csvg width='${l}' height='${et}' viewBox='0 0 1024 1024' fill='none' xmlns='http://www.w3.org/2000/svg'%3E %3Crect width='1024' height='1024' fill='%230052FF'/%3E %3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M152 512C152 710.823 313.177 872 512 872C710.823 872 872 710.823 872 512C872 313.177 710.823 152 512 152C313.177 152 152 313.177 152 512ZM420 396C406.745 396 396 406.745 396 420V604C396 617.255 406.745 628 420 628H604C617.255 628 628 617.255 628 604V420C628 406.745 617.255 396 604 396H420Z' fill='white'/%3E %3C/svg%3E `;case"circle":return et=l,`data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='${l}' height='${et}' viewBox='0 0 999.81 999.81'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052fe;%7D.cls-2%7Bfill:%23fefefe;%7D.cls-3%7Bfill:%230152fe;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M655-115.9h56c.83,1.59,2.36.88,3.56,1a478,478,0,0,1,75.06,10.42C891.4-81.76,978.33-32.58,1049.19,44q116.7,126,131.94,297.61c.38,4.14-.34,8.53,1.78,12.45v59c-1.58.84-.91,2.35-1,3.56a482.05,482.05,0,0,1-10.38,74.05c-24,106.72-76.64,196.76-158.83,268.93s-178.18,112.82-287.2,122.6c-4.83.43-9.86-.25-14.51,1.77H654c-1-1.68-2.69-.91-4.06-1a496.89,496.89,0,0,1-105.9-18.59c-93.54-27.42-172.78-77.59-236.91-150.94Q199.34,590.1,184.87,426.58c-.47-5.19.25-10.56-1.77-15.59V355c1.68-1,.91-2.7,1-4.06a498.12,498.12,0,0,1,18.58-105.9c26-88.75,72.64-164.9,140.6-227.57q126-116.27,297.21-131.61C645.32-114.57,650.35-113.88,655-115.9Zm377.92,500c0-192.44-156.31-349.49-347.56-350.15-194.13-.68-350.94,155.13-352.29,347.42-1.37,194.55,155.51,352.1,348.56,352.47C876.15,734.23,1032.93,577.84,1032.93,384.11Z' transform='translate(-183.1 115.9)'/%3E%3Cpath class='cls-2' d='M1032.93,384.11c0,193.73-156.78,350.12-351.29,349.74-193-.37-349.93-157.92-348.56-352.47C334.43,189.09,491.24,33.28,685.37,34,876.62,34.62,1032.94,191.67,1032.93,384.11ZM683,496.81q43.74,0,87.48,0c15.55,0,25.32-9.72,25.33-25.21q0-87.48,0-175c0-15.83-9.68-25.46-25.59-25.46H595.77c-15.88,0-25.57,9.64-25.58,25.46q0,87.23,0,174.45c0,16.18,9.59,25.7,25.84,25.71Z' transform='translate(-183.1 115.9)'/%3E%3Cpath class='cls-3' d='M683,496.81H596c-16.25,0-25.84-9.53-25.84-25.71q0-87.23,0-174.45c0-15.82,9.7-25.46,25.58-25.46H770.22c15.91,0,25.59,9.63,25.59,25.46q0,87.47,0,175c0,15.49-9.78,25.2-25.33,25.21Q726.74,496.84,683,496.81Z' transform='translate(-183.1 115.9)'/%3E%3C/svg%3E`;case"text":return et=(.1*l).toFixed(2),`data:image/svg+xml,%3Csvg width='${l}' height='${et}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 528.15 53.64'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052ff;%7D%3C/style%3E%3C/defs%3E%3Ctitle%3ECoinbase_Wordmark_SubBrands_ALL%3C/title%3E%3Cpath class='cls-1' d='M164.45,15a15,15,0,0,0-11.74,5.4V0h-8.64V52.92h8.5V48a15,15,0,0,0,11.88,5.62c10.37,0,18.21-8.21,18.21-19.3S174.67,15,164.45,15Zm-1.3,30.67c-6.19,0-10.73-4.83-10.73-11.31S157,23,163.22,23s10.66,4.82,10.66,11.37S169.34,45.65,163.15,45.65Zm83.31-14.91-6.34-.93c-3-.43-5.18-1.44-5.18-3.82,0-2.59,2.8-3.89,6.62-3.89,4.18,0,6.84,1.8,7.42,4.76h8.35c-.94-7.49-6.7-11.88-15.55-11.88-9.15,0-15.2,4.68-15.2,11.3,0,6.34,4,10,12,11.16l6.33.94c3.1.43,4.83,1.65,4.83,4,0,2.95-3,4.17-7.2,4.17-5.12,0-8-2.09-8.43-5.25h-8.49c.79,7.27,6.48,12.38,16.84,12.38,9.44,0,15.7-4.32,15.7-11.74C258.12,35.28,253.58,31.82,246.46,30.74Zm-27.65-2.3c0-8.06-4.9-13.46-15.27-13.46-9.79,0-15.26,5-16.34,12.6h8.57c.43-3,2.73-5.4,7.63-5.4,4.39,0,6.55,1.94,6.55,4.32,0,3.09-4,3.88-8.85,4.39-6.63.72-14.84,3-14.84,11.66,0,6.7,5,11,12.89,11,6.19,0,10.08-2.59,12-6.7.28,3.67,3,6.05,6.84,6.05h5v-7.7h-4.25Zm-8.5,9.36c0,5-4.32,8.64-9.57,8.64-3.24,0-6-1.37-6-4.25,0-3.67,4.39-4.68,8.42-5.11s6-1.22,7.13-2.88ZM281.09,15c-11.09,0-19.23,8.35-19.23,19.36,0,11.6,8.72,19.3,19.37,19.3,9,0,16.06-5.33,17.86-12.89h-9c-1.3,3.31-4.47,5.19-8.71,5.19-5.55,0-9.72-3.46-10.66-9.51H299.3V33.12C299.3,22.46,291.53,15,281.09,15Zm-9.87,15.26c1.37-5.18,5.26-7.7,9.72-7.7,4.9,0,8.64,2.8,9.51,7.7ZM19.3,23a9.84,9.84,0,0,1,9.5,7h9.14c-1.65-8.93-9-15-18.57-15A19,19,0,0,0,0,34.34c0,11.09,8.28,19.3,19.37,19.3,9.36,0,16.85-6,18.5-15H28.8a9.75,9.75,0,0,1-9.43,7.06c-6.27,0-10.66-4.83-10.66-11.31S13,23,19.3,23Zm41.11-8A19,19,0,0,0,41,34.34c0,11.09,8.28,19.3,19.37,19.3A19,19,0,0,0,79.92,34.27C79.92,23.33,71.64,15,60.41,15Zm.07,30.67c-6.19,0-10.73-4.83-10.73-11.31S54.22,23,60.41,23s10.8,4.89,10.8,11.37S66.67,45.65,60.48,45.65ZM123.41,15c-5.62,0-9.29,2.3-11.45,5.54V15.7h-8.57V52.92H112V32.69C112,27,115.63,23,121,23c5,0,8.06,3.53,8.06,8.64V52.92h8.64V31C137.66,21.6,132.84,15,123.41,15ZM92,.36a5.36,5.36,0,0,0-5.55,5.47,5.55,5.55,0,0,0,11.09,0A5.35,5.35,0,0,0,92,.36Zm-9.72,23h5.4V52.92h8.64V15.7h-14Zm298.17-7.7L366.2,52.92H372L375.29,44H392l3.33,8.88h6L386.87,15.7ZM377,39.23l6.45-17.56h.1l6.56,17.56ZM362.66,15.7l-7.88,29h-.11l-8.14-29H341l-8,28.93h-.1l-8-28.87H319L329.82,53h5.45l8.19-29.24h.11L352,53h5.66L368.1,15.7Zm135.25,0v4.86h12.32V52.92h5.6V20.56h12.32V15.7ZM467.82,52.92h25.54V48.06H473.43v-12h18.35V31.35H473.43V20.56h19.93V15.7H467.82ZM443,15.7h-5.6V52.92h24.32V48.06H443Zm-30.45,0h-5.61V52.92h24.32V48.06H412.52Z'/%3E%3C/svg%3E`;case"textWithLogo":return et=(.25*l).toFixed(2),`data:image/svg+xml,%3Csvg width='${l}' height='${et}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 308.44 77.61'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%230052ff;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M142.94,20.2l-7.88,29H135l-8.15-29h-5.55l-8,28.93h-.11l-8-28.87H99.27l10.84,37.27h5.44l8.2-29.24h.1l8.41,29.24h5.66L148.39,20.2Zm17.82,0L146.48,57.42h5.82l3.28-8.88h16.65l3.34,8.88h6L167.16,20.2Zm-3.44,23.52,6.45-17.55h.11l6.56,17.55ZM278.2,20.2v4.86h12.32V57.42h5.6V25.06h12.32V20.2ZM248.11,57.42h25.54V52.55H253.71V40.61h18.35V35.85H253.71V25.06h19.94V20.2H248.11ZM223.26,20.2h-5.61V57.42H242V52.55H223.26Zm-30.46,0h-5.6V57.42h24.32V52.55H192.8Zm-154,38A19.41,19.41,0,1,1,57.92,35.57H77.47a38.81,38.81,0,1,0,0,6.47H57.92A19.39,19.39,0,0,1,38.81,58.21Z'/%3E%3C/svg%3E`;case"textLight":return et=(.1*l).toFixed(2),`data:image/svg+xml,%3Csvg width='${l}' height='${et}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 528.15 53.64'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%23fefefe;%7D%3C/style%3E%3C/defs%3E%3Ctitle%3ECoinbase_Wordmark_SubBrands_ALL%3C/title%3E%3Cpath class='cls-1' d='M164.45,15a15,15,0,0,0-11.74,5.4V0h-8.64V52.92h8.5V48a15,15,0,0,0,11.88,5.62c10.37,0,18.21-8.21,18.21-19.3S174.67,15,164.45,15Zm-1.3,30.67c-6.19,0-10.73-4.83-10.73-11.31S157,23,163.22,23s10.66,4.82,10.66,11.37S169.34,45.65,163.15,45.65Zm83.31-14.91-6.34-.93c-3-.43-5.18-1.44-5.18-3.82,0-2.59,2.8-3.89,6.62-3.89,4.18,0,6.84,1.8,7.42,4.76h8.35c-.94-7.49-6.7-11.88-15.55-11.88-9.15,0-15.2,4.68-15.2,11.3,0,6.34,4,10,12,11.16l6.33.94c3.1.43,4.83,1.65,4.83,4,0,2.95-3,4.17-7.2,4.17-5.12,0-8-2.09-8.43-5.25h-8.49c.79,7.27,6.48,12.38,16.84,12.38,9.44,0,15.7-4.32,15.7-11.74C258.12,35.28,253.58,31.82,246.46,30.74Zm-27.65-2.3c0-8.06-4.9-13.46-15.27-13.46-9.79,0-15.26,5-16.34,12.6h8.57c.43-3,2.73-5.4,7.63-5.4,4.39,0,6.55,1.94,6.55,4.32,0,3.09-4,3.88-8.85,4.39-6.63.72-14.84,3-14.84,11.66,0,6.7,5,11,12.89,11,6.19,0,10.08-2.59,12-6.7.28,3.67,3,6.05,6.84,6.05h5v-7.7h-4.25Zm-8.5,9.36c0,5-4.32,8.64-9.57,8.64-3.24,0-6-1.37-6-4.25,0-3.67,4.39-4.68,8.42-5.11s6-1.22,7.13-2.88ZM281.09,15c-11.09,0-19.23,8.35-19.23,19.36,0,11.6,8.72,19.3,19.37,19.3,9,0,16.06-5.33,17.86-12.89h-9c-1.3,3.31-4.47,5.19-8.71,5.19-5.55,0-9.72-3.46-10.66-9.51H299.3V33.12C299.3,22.46,291.53,15,281.09,15Zm-9.87,15.26c1.37-5.18,5.26-7.7,9.72-7.7,4.9,0,8.64,2.8,9.51,7.7ZM19.3,23a9.84,9.84,0,0,1,9.5,7h9.14c-1.65-8.93-9-15-18.57-15A19,19,0,0,0,0,34.34c0,11.09,8.28,19.3,19.37,19.3,9.36,0,16.85-6,18.5-15H28.8a9.75,9.75,0,0,1-9.43,7.06c-6.27,0-10.66-4.83-10.66-11.31S13,23,19.3,23Zm41.11-8A19,19,0,0,0,41,34.34c0,11.09,8.28,19.3,19.37,19.3A19,19,0,0,0,79.92,34.27C79.92,23.33,71.64,15,60.41,15Zm.07,30.67c-6.19,0-10.73-4.83-10.73-11.31S54.22,23,60.41,23s10.8,4.89,10.8,11.37S66.67,45.65,60.48,45.65ZM123.41,15c-5.62,0-9.29,2.3-11.45,5.54V15.7h-8.57V52.92H112V32.69C112,27,115.63,23,121,23c5,0,8.06,3.53,8.06,8.64V52.92h8.64V31C137.66,21.6,132.84,15,123.41,15ZM92,.36a5.36,5.36,0,0,0-5.55,5.47,5.55,5.55,0,0,0,11.09,0A5.35,5.35,0,0,0,92,.36Zm-9.72,23h5.4V52.92h8.64V15.7h-14Zm298.17-7.7L366.2,52.92H372L375.29,44H392l3.33,8.88h6L386.87,15.7ZM377,39.23l6.45-17.56h.1l6.56,17.56ZM362.66,15.7l-7.88,29h-.11l-8.14-29H341l-8,28.93h-.1l-8-28.87H319L329.82,53h5.45l8.19-29.24h.11L352,53h5.66L368.1,15.7Zm135.25,0v4.86h12.32V52.92h5.6V20.56h12.32V15.7ZM467.82,52.92h25.54V48.06H473.43v-12h18.35V31.35H473.43V20.56h19.93V15.7H467.82ZM443,15.7h-5.6V52.92h24.32V48.06H443Zm-30.45,0h-5.61V52.92h24.32V48.06H412.52Z'/%3E%3C/svg%3E`;case"textWithLogoLight":return et=(.25*l).toFixed(2),`data:image/svg+xml,%3Csvg width='${l}' height='${et}' xmlns='http://www.w3.org/2000/svg' viewBox='0 0 308.44 77.61'%3E%3Cdefs%3E%3Cstyle%3E.cls-1%7Bfill:%23fefefe;%7D%3C/style%3E%3C/defs%3E%3Cpath class='cls-1' d='M142.94,20.2l-7.88,29H135l-8.15-29h-5.55l-8,28.93h-.11l-8-28.87H99.27l10.84,37.27h5.44l8.2-29.24h.1l8.41,29.24h5.66L148.39,20.2Zm17.82,0L146.48,57.42h5.82l3.28-8.88h16.65l3.34,8.88h6L167.16,20.2Zm-3.44,23.52,6.45-17.55h.11l6.56,17.55ZM278.2,20.2v4.86h12.32V57.42h5.6V25.06h12.32V20.2ZM248.11,57.42h25.54V52.55H253.71V40.61h18.35V35.85H253.71V25.06h19.94V20.2H248.11ZM223.26,20.2h-5.61V57.42H242V52.55H223.26Zm-30.46,0h-5.6V57.42h24.32V52.55H192.8Zm-154,38A19.41,19.41,0,1,1,57.92,35.57H77.47a38.81,38.81,0,1,0,0,6.47H57.92A19.39,19.39,0,0,1,38.81,58.21Z'/%3E%3C/svg%3E`}}},83762:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=".-cbwsdk-css-reset .-cbwsdk-connect-content{height:430px;width:700px;border-radius:12px;padding:30px}.-cbwsdk-css-reset .-cbwsdk-connect-content.light{background:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content.dark{background:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-content-header{display:flex;align-items:center;justify-content:space-between;margin:0 0 30px}.-cbwsdk-css-reset .-cbwsdk-connect-content-heading{font-style:normal;font-weight:500;font-size:28px;line-height:36px;margin:0}.-cbwsdk-css-reset .-cbwsdk-connect-content-heading.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-content-heading.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content-layout{display:flex;flex-direction:row}.-cbwsdk-css-reset .-cbwsdk-connect-content-column-left{margin-right:30px;display:flex;flex-direction:column;justify-content:space-between}.-cbwsdk-css-reset .-cbwsdk-connect-content-column-right{flex:25%;margin-right:34px}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-wrapper{width:220px;height:220px;border-radius:12px;display:flex;justify-content:center;align-items:center;background:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting{position:absolute;top:0;bottom:0;left:0;right:0;display:flex;flex-direction:column;align-items:center;justify-content:center}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.light{background-color:rgba(255,255,255,.95)}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.light>p{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.dark{background-color:rgba(10,11,13,.9)}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting.dark>p{color:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-content-qr-connecting>p{font-size:12px;font-weight:bold;margin-top:16px}.-cbwsdk-css-reset .-cbwsdk-connect-content-update-app{border-radius:8px;font-size:14px;line-height:20px;padding:12px;width:339px}.-cbwsdk-css-reset .-cbwsdk-connect-content-update-app.light{background:#eef0f3;color:#5b636e}.-cbwsdk-css-reset .-cbwsdk-connect-content-update-app.dark{background:#1e2025;color:#8a919e}.-cbwsdk-css-reset .-cbwsdk-cancel-button{-webkit-appearance:none;border:none;background:none;cursor:pointer;padding:0;margin:0}.-cbwsdk-css-reset .-cbwsdk-cancel-button-x{position:relative;display:block;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-wallet-steps{padding:0 0 0 16px;margin:0;width:100%;list-style:decimal}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item{list-style-type:decimal;display:list-item;font-style:normal;font-weight:400;font-size:16px;line-height:24px;margin-top:20px}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-item-wrapper{display:flex;align-items:center}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-pad-left{margin-left:6px}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon{display:flex;border-radius:50%;height:24px;width:24px}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon svg{margin:auto;display:block}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon.light{background:#0052ff}.-cbwsdk-css-reset .-cbwsdk-wallet-steps-icon.dark{background:#588af5}.-cbwsdk-css-reset .-cbwsdk-connect-item{align-items:center;display:flex;flex-direction:row;padding:16px 24px;gap:12px;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-connect-item.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-connect-item.light.selected{background:#f5f8ff;color:#0052ff}.-cbwsdk-css-reset .-cbwsdk-connect-item.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-connect-item.dark.selected{background:#001033;color:#588af5}.-cbwsdk-css-reset .-cbwsdk-connect-item.selected{border-radius:100px;font-weight:600}.-cbwsdk-css-reset .-cbwsdk-connect-item-copy-wrapper{margin:0 4px 0 8px}.-cbwsdk-css-reset .-cbwsdk-connect-item-title{margin:0 0 0;font-size:16px;line-height:24px;font-weight:500}.-cbwsdk-css-reset .-cbwsdk-connect-item-description{font-weight:400;font-size:14px;line-height:20px;margin:0}"},9307:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.CoinbaseAppSteps=l.CoinbaseWalletSteps=l.ConnectItem=l.ConnectContent=void 0;let es=eo(et(50348)),ec=et(88049),el=et(87060),ed=et(59656),eh=et(94579),ef=et(35889),ep=eo(et(52375)),eg=eo(et(13445)),em=et(62052),eb=eo(et(4048)),ey=eo(et(183)),e_=et(48197),ew=et(50927),eE=et(89626),eS=eo(et(83762)),ex={"coinbase-wallet-app":{title:"Coinbase Wallet app",description:"Connect with your self-custody wallet",icon:eg.default,steps:CoinbaseWalletSteps},"coinbase-app":{title:"Coinbase app",description:"Connect with your Coinbase account",icon:ep.default,steps:CoinbaseAppSteps}},makeQrCodeImage=c=>"coinbase-app"===c?eb.default:ey.default,makeIconColor=c=>"light"===c?"#FFFFFF":"#0A0B0D";function ConnectItem({title:c,description:l,icon:et,selected:eo,theme:el,onClick:ed}){return(0,ec.h)("div",{onClick:ed,class:(0,es.default)("-cbwsdk-connect-item",el,{selected:eo})},(0,ec.h)("div",null,(0,ec.h)("img",{src:et,alt:c})),(0,ec.h)("div",{class:"-cbwsdk-connect-item-copy-wrapper"},(0,ec.h)("h3",{class:"-cbwsdk-connect-item-title"},c),(0,ec.h)("p",{class:"-cbwsdk-connect-item-description"},l)))}function CoinbaseWalletSteps({theme:c}){return(0,ec.h)("ol",{class:"-cbwsdk-wallet-steps"},(0,ec.h)("li",{class:(0,es.default)("-cbwsdk-wallet-steps-item",c)},(0,ec.h)("div",{class:"-cbwsdk-wallet-steps-item-wrapper"},"Open Coinbase Wallet app")),(0,ec.h)("li",{class:(0,es.default)("-cbwsdk-wallet-steps-item",c)},(0,ec.h)("div",{class:"-cbwsdk-wallet-steps-item-wrapper"},(0,ec.h)("span",null,"Tap ",(0,ec.h)("strong",null,"Scan")," "),(0,ec.h)("span",{class:(0,es.default)("-cbwsdk-wallet-steps-pad-left","-cbwsdk-wallet-steps-icon",c)},(0,ec.h)(em.QRCodeIcon,{fill:makeIconColor(c)})))))}function CoinbaseAppSteps({theme:c}){return(0,ec.h)("ol",{class:"-cbwsdk-wallet-steps"},(0,ec.h)("li",{class:(0,es.default)("-cbwsdk-wallet-steps-item",c)},(0,ec.h)("div",{class:"-cbwsdk-wallet-steps-item-wrapper"},"Open Coinbase app")),(0,ec.h)("li",{class:(0,es.default)("-cbwsdk-wallet-steps-item",c)},(0,ec.h)("div",{class:"-cbwsdk-wallet-steps-item-wrapper"},(0,ec.h)("span",null,"Tap ",(0,ec.h)("strong",null,"More")),(0,ec.h)("span",{class:(0,es.default)("-cbwsdk-wallet-steps-pad-left","-cbwsdk-wallet-steps-icon",c)},(0,ec.h)(e_.StatusDotIcon,{fill:makeIconColor(c)})),(0,ec.h)("span",{class:"-cbwsdk-wallet-steps-pad-left"},"then ",(0,ec.h)("strong",null,"Scan")),(0,ec.h)("span",{class:(0,es.default)("-cbwsdk-wallet-steps-pad-left","-cbwsdk-wallet-steps-icon",c)},(0,ec.h)(em.QRCodeIcon,{fill:makeIconColor(c)})))))}l.ConnectContent=function(c){let{theme:l}=c,[et,eo]=(0,el.useState)("coinbase-wallet-app"),ep=(0,el.useCallback)(c=>{eo(c)},[]),eg=(0,ed.createQrUrl)(c.sessionId,c.sessionSecret,c.linkAPIUrl,c.isParentConnection,c.version,c.chainId),em=ex[et];if(!et)return null;let eb=em.steps,ey="coinbase-app"===et;return(0,ec.h)("div",{"data-testid":"connect-content",class:(0,es.default)("-cbwsdk-connect-content",l)},(0,ec.h)("style",null,eS.default),(0,ec.h)("div",{class:"-cbwsdk-connect-content-header"},(0,ec.h)("h2",{class:(0,es.default)("-cbwsdk-connect-content-heading",l)},"Scan to connect with one of our mobile apps"),c.onCancel&&(0,ec.h)("button",{type:"button",class:"-cbwsdk-cancel-button",onClick:c.onCancel},(0,ec.h)(ef.CloseIcon,{fill:"light"===l?"#0A0B0D":"#FFFFFF"}))),(0,ec.h)("div",{class:"-cbwsdk-connect-content-layout"},(0,ec.h)("div",{class:"-cbwsdk-connect-content-column-left"},(0,ec.h)("div",null,Object.entries(ex).map(([c,eo])=>(0,ec.h)(ConnectItem,{key:c,title:eo.title,description:eo.description,icon:eo.icon,selected:et===c,onClick:()=>ep(c),theme:l}))),ey&&(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-connect-content-update-app",l)},"Don’t see a ",(0,ec.h)("strong",null,"Scan")," option? Update your Coinbase app to the latest version and try again.")),(0,ec.h)("div",{class:"-cbwsdk-connect-content-column-right"},(0,ec.h)("div",{class:"-cbwsdk-connect-content-qr-wrapper"},(0,ec.h)(ew.QRCode,{content:eg,width:200,height:200,fgColor:"#000",bgColor:"transparent",image:{svg:makeQrCodeImage(et),width:25,height:25}}),(0,ec.h)("input",{type:"hidden",name:"cbw-cbwsdk-version",value:eh.LIB_VERSION}),(0,ec.h)("input",{type:"hidden",value:eg})),(0,ec.h)(eb,{theme:l}),!c.isConnected&&(0,ec.h)("div",{"data-testid":"connecting-spinner",class:(0,es.default)("-cbwsdk-connect-content-qr-connecting",l)},(0,ec.h)(eE.Spinner,{size:36,color:"dark"===l?"#FFF":"#000"}),(0,ec.h)("p",null,"Connecting...")))))},l.ConnectItem=ConnectItem,l.CoinbaseWalletSteps=CoinbaseWalletSteps,l.CoinbaseAppSteps=CoinbaseAppSteps},84289:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=".-cbwsdk-css-reset .-cbwsdk-connect-dialog{z-index:2147483647;position:fixed;top:0;left:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop{z-index:2147483647;position:fixed;top:0;left:0;right:0;bottom:0;transition:opacity .25s}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop.light{background-color:rgba(0,0,0,.5)}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop.dark{background-color:rgba(50,53,61,.4)}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-backdrop-hidden{opacity:0}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-box{display:flex;position:relative;flex-direction:column;transform:scale(1);transition:opacity .25s,transform .25s}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-box-hidden{opacity:0;transform:scale(0.85)}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-container{display:block}.-cbwsdk-css-reset .-cbwsdk-connect-dialog-container-hidden{display:none}"},54041:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.ConnectDialog=void 0;let es=eo(et(50348)),ec=et(88049),el=et(87060),ed=et(9307),eh=et(11773),ef=eo(et(84289));l.ConnectDialog=c=>{let{isOpen:l,darkMode:et}=c,[eo,ep]=(0,el.useState)(!l),[eg,em]=(0,el.useState)(!l);(0,el.useEffect)(()=>{let c=[window.setTimeout(()=>{em(!l)},10)];return l?ep(!1):c.push(window.setTimeout(()=>{ep(!0)},360)),()=>{c.forEach(window.clearTimeout)}},[c.isOpen]);let eb=et?"dark":"light";return(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-connect-dialog-container",eo&&"-cbwsdk-connect-dialog-container-hidden")},(0,ec.h)("style",null,ef.default),(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-connect-dialog-backdrop",eb,eg&&"-cbwsdk-connect-dialog-backdrop-hidden")}),(0,ec.h)("div",{class:"-cbwsdk-connect-dialog"},(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-connect-dialog-box",eg&&"-cbwsdk-connect-dialog-box-hidden")},c.connectDisabled?null:(0,ec.h)(ed.ConnectContent,{theme:eb,version:c.version,sessionId:c.sessionId,sessionSecret:c.sessionSecret,linkAPIUrl:c.linkAPIUrl,isConnected:c.isConnected,isParentConnection:c.isParentConnection,chainId:c.chainId,onCancel:c.onCancel}),(0,ec.h)(eh.TryExtensionContent,{theme:eb}))))}},49598:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.LinkFlow=void 0;let eo=et(88049),es=et(33664),ec=et(54041);l.LinkFlow=class{constructor(c){this.extensionUI$=new es.BehaviorSubject({}),this.subscriptions=new es.Subscription,this.isConnected=!1,this.chainId=1,this.isOpen=!1,this.onCancel=null,this.root=null,this.connectDisabled=!1,this.darkMode=c.darkMode,this.version=c.version,this.sessionId=c.sessionId,this.sessionSecret=c.sessionSecret,this.linkAPIUrl=c.linkAPIUrl,this.isParentConnection=c.isParentConnection,this.connected$=c.connected$,this.chainId$=c.chainId$}attach(c){this.root=document.createElement("div"),this.root.className="-cbwsdk-link-flow-root",c.appendChild(this.root),this.render(),this.subscriptions.add(this.connected$.subscribe(c=>{this.isConnected!==c&&(this.isConnected=c,this.render())})),this.subscriptions.add(this.chainId$.subscribe(c=>{this.chainId!==c&&(this.chainId=c,this.render())}))}detach(){var c;this.root&&(this.subscriptions.unsubscribe(),(0,eo.render)(null,this.root),null===(c=this.root.parentElement)||void 0===c||c.removeChild(this.root))}setConnectDisabled(c){this.connectDisabled=c}open(c){this.isOpen=!0,this.onCancel=c.onCancel,this.render()}close(){this.isOpen=!1,this.onCancel=null,this.render()}render(){if(!this.root)return;let c=this.extensionUI$.subscribe(()=>{this.root&&(0,eo.render)((0,eo.h)(ec.ConnectDialog,{darkMode:this.darkMode,version:this.version,sessionId:this.sessionId,sessionSecret:this.sessionSecret,linkAPIUrl:this.linkAPIUrl,isOpen:this.isOpen,isConnected:this.isConnected,isParentConnection:this.isParentConnection,chainId:this.chainId,onCancel:this.onCancel,connectDisabled:this.connectDisabled}),this.root)});this.subscriptions.add(c)}}},50927:function(c,l,et){"use strict";var eo=et(67133).Buffer,es=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.QRCode=void 0;let ec=et(88049),el=et(87060),ed=es(et(49204));l.QRCode=c=>{let[l,et]=(0,el.useState)("");return(0,el.useEffect)(()=>{var l,es;let ec=new ed.default({content:c.content,background:c.bgColor||"#ffffff",color:c.fgColor||"#000000",container:"svg",ecl:"M",width:null!==(l=c.width)&&void 0!==l?l:256,height:null!==(es=c.height)&&void 0!==es?es:256,padding:0,image:c.image}),el=eo.from(ec.svg(),"utf8").toString("base64");et(`data:image/svg+xml;base64,${el}`)}),l?(0,ec.h)("img",{src:l,alt:"QR Code"}):null}},64923:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=".-cbwsdk-css-reset .-cbwsdk-redirect-dialog-backdrop{position:fixed;top:0;left:0;right:0;bottom:0;transition:opacity .25s;background-color:rgba(10,11,13,.5)}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-backdrop-hidden{opacity:0}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box{display:block;position:fixed;top:50%;left:50%;transform:translate(-50%, -50%);padding:20px;border-radius:8px;background-color:#fff;color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box p{display:block;font-weight:400;font-size:14px;line-height:20px;padding-bottom:12px;color:#5b636e}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box button{appearance:none;border:none;background:none;color:#0052ff;padding:0;text-decoration:none;display:block;font-weight:600;font-size:16px;line-height:24px}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.dark{background-color:#0a0b0d;color:#fff}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.dark button{color:#0052ff}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.light{background-color:#fff;color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-redirect-dialog-box.light button{color:#0052ff}"},97430:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.RedirectDialog=void 0;let es=eo(et(50348)),ec=et(88049),el=et(97302),ed=et(41811),eh=eo(et(64923));l.RedirectDialog=class{constructor(){this.root=null}attach(){let c=document.documentElement;this.root=document.createElement("div"),this.root.className="-cbwsdk-css-reset",c.appendChild(this.root),(0,el.injectCssReset)()}present(c){this.render(c)}clear(){this.render(null)}render(c){this.root&&((0,ec.render)(null,this.root),c&&(0,ec.render)((0,ec.h)(RedirectDialogContent,Object.assign({},c,{onDismiss:()=>{this.clear()}})),this.root))}};let RedirectDialogContent=({title:c,buttonText:l,darkMode:et,onButtonClick:eo,onDismiss:el})=>(0,ec.h)(ed.SnackbarContainer,{darkMode:et},(0,ec.h)("div",{class:"-cbwsdk-redirect-dialog"},(0,ec.h)("style",null,eh.default),(0,ec.h)("div",{class:"-cbwsdk-redirect-dialog-backdrop",onClick:el}),(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-redirect-dialog-box",et?"dark":"light")},(0,ec.h)("p",null,c),(0,ec.h)("button",{onClick:eo},l))))},48895:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=".-cbwsdk-css-reset .-gear-container{margin-left:16px !important;margin-right:9px !important;display:flex;align-items:center;justify-content:center;width:24px;height:24px;transition:opacity .25s}.-cbwsdk-css-reset .-gear-container *{user-select:none}.-cbwsdk-css-reset .-gear-container svg{opacity:0;position:absolute}.-cbwsdk-css-reset .-gear-icon{height:12px;width:12px;z-index:10000}.-cbwsdk-css-reset .-cbwsdk-snackbar{align-items:flex-end;display:flex;flex-direction:column;position:fixed;right:0;top:0;z-index:2147483647}.-cbwsdk-css-reset .-cbwsdk-snackbar *{user-select:none}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance{display:flex;flex-direction:column;margin:8px 16px 0 16px;overflow:visible;text-align:left;transform:translateX(0);transition:opacity .25s,transform .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header:hover .-gear-container svg{opacity:1}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header{display:flex;align-items:center;background:#fff;overflow:hidden;border:1px solid #e7ebee;box-sizing:border-box;border-radius:8px;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header-cblogo{margin:8px 8px 8px 8px}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header *{cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-header-message{color:#000;font-size:13px;line-height:1.5;user-select:none}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu{background:#fff;transition:opacity .25s ease-in-out,transform .25s linear,visibility 0s;visibility:hidden;border:1px solid #e7ebee;box-sizing:border-box;border-radius:8px;opacity:0;flex-direction:column;padding-left:8px;padding-right:8px}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:last-child{margin-bottom:8px !important}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:hover{background:#f5f7f8;border-radius:6px;transition:background .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:hover span{color:#050f19;transition:color .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item:hover svg path{fill:#000;transition:fill .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item{visibility:inherit;height:35px;margin-top:8px;margin-bottom:0;display:flex;flex-direction:row;align-items:center;padding:8px;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item *{visibility:inherit;cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover{background:rgba(223,95,103,.2);transition:background .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover *{cursor:pointer}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover svg path{fill:#df5f67;transition:fill .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-is-red:hover span{color:#df5f67;transition:color .25s}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-menu-item-info{color:#aaa;font-size:13px;margin:0 8px 0 32px;position:absolute}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-hidden{opacity:0;text-align:left;transform:translateX(25%);transition:opacity .5s linear}.-cbwsdk-css-reset .-cbwsdk-snackbar-instance-expanded .-cbwsdk-snackbar-instance-menu{opacity:1;display:flex;transform:translateY(8px);visibility:visible}"},91715:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.SnackbarInstance=l.SnackbarContainer=l.Snackbar=void 0;let es=eo(et(50348)),ec=et(88049),el=et(87060),ed=eo(et(48895));l.Snackbar=class{constructor(c){this.items=new Map,this.nextItemKey=0,this.root=null,this.darkMode=c.darkMode}attach(c){this.root=document.createElement("div"),this.root.className="-cbwsdk-snackbar-root",c.appendChild(this.root),this.render()}presentItem(c){let l=this.nextItemKey++;return this.items.set(l,c),this.render(),()=>{this.items.delete(l),this.render()}}clear(){this.items.clear(),this.render()}render(){this.root&&(0,ec.render)((0,ec.h)("div",null,(0,ec.h)(l.SnackbarContainer,{darkMode:this.darkMode},Array.from(this.items.entries()).map(([c,et])=>(0,ec.h)(l.SnackbarInstance,Object.assign({},et,{key:c}))))),this.root)}},l.SnackbarContainer=c=>(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-snackbar-container")},(0,ec.h)("style",null,ed.default),(0,ec.h)("div",{class:"-cbwsdk-snackbar"},c.children)),l.SnackbarInstance=({autoExpand:c,message:l,menuItems:et,appSrc:eo})=>{let[ed,eh]=(0,el.useState)(!0),[ef,ep]=(0,el.useState)(null!=c&&c);return(0,el.useEffect)(()=>{let c=[window.setTimeout(()=>{eh(!1)},1),window.setTimeout(()=>{ep(!0)},1e4)];return()=>{c.forEach(window.clearTimeout)}}),(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-snackbar-instance",ed&&"-cbwsdk-snackbar-instance-hidden",ef&&"-cbwsdk-snackbar-instance-expanded")},(0,ec.h)("div",{class:"-cbwsdk-snackbar-instance-header",onClick:()=>{ep(!ef)}},(0,ec.h)("img",{src:"coinbase-app"===eo?"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzAiIGhlaWdodD0iMzAiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTE0LjY3NCAxOC44NThjLTIuMDQ1IDAtMy42NDgtMS43MjItMy42NDgtMy44NDVzMS42NTktMy44NDUgMy42NDgtMy44NDVjMS44MjQgMCAzLjMxNyAxLjM3NyAzLjU5MyAzLjIxNGgzLjcwM2MtLjMzMS0zLjk2LTMuNDgyLTcuMDU5LTcuMjk2LTcuMDU5LTQuMDM0IDAtNy4zNSAzLjQ0My03LjM1IDcuNjkgMCA0LjI0NiAzLjI2IDcuNjkgNy4zNSA3LjY5IDMuODcgMCA2Ljk2NS0zLjEgNy4yOTYtNy4wNTloLTMuNzAzYy0uMjc2IDEuODM2LTEuNzY5IDMuMjE0LTMuNTkzIDMuMjE0WiIgZmlsbD0iI2ZmZiIvPjxwYXRoIGQ9Ik0wIDEwLjY3OGMwLTMuNzExIDAtNS41OTYuNzQyLTcuMDIzQTYuNTMyIDYuNTMyIDAgMCAxIDMuNjU1Ljc0MkM1LjA4MiAwIDYuOTY3IDAgMTAuNjc4IDBoNy45MzhjMy43MTEgMCA1LjU5NiAwIDcuMDIzLjc0MmE2LjUzMSA2LjUzMSAwIDAgMSAyLjkxMyAyLjkxM2MuNzQyIDEuNDI3Ljc0MiAzLjMxMi43NDIgNy4wMjN2Ny45MzhjMCAzLjcxMSAwIDUuNTk2LS43NDIgNy4wMjNhNi41MzEgNi41MzEgMCAwIDEtMi45MTMgMi45MTNjLTEuNDI3Ljc0Mi0zLjMxMi43NDItNy4wMjMuNzQyaC03LjkzOGMtMy43MTEgMC01LjU5NiAwLTcuMDIzLS43NDJhNi41MzEgNi41MzEgMCAwIDEtMi45MTMtMi45MTNDMCAyNC4yMTIgMCAyMi4zODQgMCAxOC42MTZ2LTcuOTM4WiIgZmlsbD0iIzAwNTJGRiIvPjxwYXRoIGQ9Ik0xNC42ODQgMTkuNzczYy0yLjcyNyAwLTQuODY0LTIuMjk1LTQuODY0LTUuMTI2IDAtMi44MzEgMi4yMS01LjEyNyA0Ljg2NC01LjEyNyAyLjQzMiAwIDQuNDIyIDEuODM3IDQuNzkgNC4yODVoNC45MzhjLS40NDItNS4yOC00LjY0My05LjQxMS05LjcyOC05LjQxMS01LjM4IDAtOS44MDIgNC41OS05LjgwMiAxMC4yNTMgMCA1LjY2MiA0LjM0OCAxMC4yNTMgOS44MDIgMTAuMjUzIDUuMTU5IDAgOS4yODYtNC4xMzIgOS43MjgtOS40MTFoLTQuOTM4Yy0uMzY4IDIuNDQ4LTIuMzU4IDQuMjg0LTQuNzkgNC4yODRaIiBmaWxsPSIjZmZmIi8+PC9zdmc+":"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzIiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEuNDkyIDEwLjQxOWE4LjkzIDguOTMgMCAwMTguOTMtOC45M2gxMS4xNjNhOC45MyA4LjkzIDAgMDE4LjkzIDguOTN2MTEuMTYzYTguOTMgOC45MyAwIDAxLTguOTMgOC45M0gxMC40MjJhOC45MyA4LjkzIDAgMDEtOC45My04LjkzVjEwLjQxOXoiIGZpbGw9IiMxNjUyRjAiLz48cGF0aCBmaWxsLXJ1bGU9ImV2ZW5vZGQiIGNsaXAtcnVsZT0iZXZlbm9kZCIgZD0iTTEwLjQxOSAwSDIxLjU4QzI3LjMzNSAwIDMyIDQuNjY1IDMyIDEwLjQxOVYyMS41OEMzMiAyNy4zMzUgMjcuMzM1IDMyIDIxLjU4MSAzMkgxMC40MkM0LjY2NSAzMiAwIDI3LjMzNSAwIDIxLjU4MVYxMC40MkMwIDQuNjY1IDQuNjY1IDAgMTAuNDE5IDB6bTAgMS40ODhhOC45MyA4LjkzIDAgMDAtOC45MyA4LjkzdjExLjE2M2E4LjkzIDguOTMgMCAwMDguOTMgOC45M0gyMS41OGE4LjkzIDguOTMgMCAwMDguOTMtOC45M1YxMC40MmE4LjkzIDguOTMgMCAwMC04LjkzLTguOTNIMTAuNDJ6IiBmaWxsPSIjZmZmIi8+PHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0xNS45OTggMjYuMDQ5Yy01LjU0OSAwLTEwLjA0Ny00LjQ5OC0xMC4wNDctMTAuMDQ3IDAtNS41NDggNC40OTgtMTAuMDQ2IDEwLjA0Ny0xMC4wNDYgNS41NDggMCAxMC4wNDYgNC40OTggMTAuMDQ2IDEwLjA0NiAwIDUuNTQ5LTQuNDk4IDEwLjA0Ny0xMC4wNDYgMTAuMDQ3eiIgZmlsbD0iI2ZmZiIvPjxwYXRoIGQ9Ik0xMi43NjIgMTQuMjU0YzAtLjgyMi42NjctMS40ODkgMS40ODktMS40ODloMy40OTdjLjgyMiAwIDEuNDg4LjY2NiAxLjQ4OCAxLjQ4OXYzLjQ5N2MwIC44MjItLjY2NiAxLjQ4OC0xLjQ4OCAxLjQ4OGgtMy40OTdhMS40ODggMS40ODggMCAwMS0xLjQ4OS0xLjQ4OHYtMy40OTh6IiBmaWxsPSIjMTY1MkYwIi8+PC9zdmc+",class:"-cbwsdk-snackbar-instance-header-cblogo"}),(0,ec.h)("div",{class:"-cbwsdk-snackbar-instance-header-message"},l),(0,ec.h)("div",{class:"-gear-container"},!ef&&(0,ec.h)("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,ec.h)("circle",{cx:"12",cy:"12",r:"12",fill:"#F5F7F8"})),(0,ec.h)("img",{src:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTIiIGhlaWdodD0iMTIiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEyIDYuNzV2LTEuNWwtMS43Mi0uNTdjLS4wOC0uMjctLjE5LS41Mi0uMzItLjc3bC44MS0xLjYyLTEuMDYtMS4wNi0xLjYyLjgxYy0uMjQtLjEzLS41LS4yNC0uNzctLjMyTDYuNzUgMGgtMS41bC0uNTcgMS43MmMtLjI3LjA4LS41My4xOS0uNzcuMzJsLTEuNjItLjgxLTEuMDYgMS4wNi44MSAxLjYyYy0uMTMuMjQtLjI0LjUtLjMyLjc3TDAgNS4yNXYxLjVsMS43Mi41N2MuMDguMjcuMTkuNTMuMzIuNzdsLS44MSAxLjYyIDEuMDYgMS4wNiAxLjYyLS44MWMuMjQuMTMuNS4yMy43Ny4zMkw1LjI1IDEyaDEuNWwuNTctMS43MmMuMjctLjA4LjUyLS4xOS43Ny0uMzJsMS42Mi44MSAxLjA2LTEuMDYtLjgxLTEuNjJjLjEzLS4yNC4yMy0uNS4zMi0uNzdMMTIgNi43NXpNNiA4LjVhMi41IDIuNSAwIDAxMC01IDIuNSAyLjUgMCAwMTAgNXoiIGZpbGw9IiMwNTBGMTkiLz48L3N2Zz4=",class:"-gear-icon",title:"Expand"}))),et&&et.length>0&&(0,ec.h)("div",{class:"-cbwsdk-snackbar-instance-menu"},et.map((c,l)=>(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-snackbar-instance-menu-item",c.isRed&&"-cbwsdk-snackbar-instance-menu-item-is-red"),onClick:c.onClick,key:l},(0,ec.h)("svg",{width:c.svgWidth,height:c.svgHeight,viewBox:"0 0 10 11",fill:"none",xmlns:"http://www.w3.org/2000/svg"},(0,ec.h)("path",{"fill-rule":c.defaultFillRule,"clip-rule":c.defaultClipRule,d:c.path,fill:"#AAAAAA"})),(0,ec.h)("span",{class:(0,es.default)("-cbwsdk-snackbar-instance-menu-item-info",c.isRed&&"-cbwsdk-snackbar-instance-menu-item-info-is-red")},c.info)))))}},41811:function(c,l,et){"use strict";var eo=this&&this.__createBinding||(Object.create?function(c,l,et,eo){void 0===eo&&(eo=et),Object.defineProperty(c,eo,{enumerable:!0,get:function(){return l[et]}})}:function(c,l,et,eo){void 0===eo&&(eo=et),c[eo]=l[et]}),es=this&&this.__exportStar||function(c,l){for(var et in c)"default"===et||Object.prototype.hasOwnProperty.call(l,et)||eo(l,c,et)};Object.defineProperty(l,"__esModule",{value:!0}),es(et(91715),l)},88443:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=".-cbwsdk-css-reset .-cbwsdk-spinner{display:inline-block}.-cbwsdk-css-reset .-cbwsdk-spinner svg{display:inline-block;animation:2s linear infinite -cbwsdk-spinner-svg}.-cbwsdk-css-reset .-cbwsdk-spinner svg circle{animation:1.9s ease-in-out infinite both -cbwsdk-spinner-circle;display:block;fill:rgba(0,0,0,0);stroke-dasharray:283;stroke-dashoffset:280;stroke-linecap:round;stroke-width:10px;transform-origin:50% 50%}@keyframes -cbwsdk-spinner-svg{0%{transform:rotateZ(0deg)}100%{transform:rotateZ(360deg)}}@keyframes -cbwsdk-spinner-circle{0%,25%{stroke-dashoffset:280;transform:rotate(0)}50%,75%{stroke-dashoffset:75;transform:rotate(45deg)}100%{stroke-dashoffset:280;transform:rotate(360deg)}}"},89626:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.Spinner=void 0;let es=et(88049),ec=eo(et(88443));l.Spinner=c=>{var l;let et=null!==(l=c.size)&&void 0!==l?l:64,eo=c.color||"#000";return(0,es.h)("div",{class:"-cbwsdk-spinner"},(0,es.h)("style",null,ec.default),(0,es.h)("svg",{viewBox:"0 0 100 100",xmlns:"http://www.w3.org/2000/svg",style:{width:et,height:et}},(0,es.h)("circle",{style:{cx:50,cy:50,r:45,stroke:eo}})))}},38479:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=".-cbwsdk-css-reset .-cbwsdk-try-extension{display:flex;margin-top:12px;height:202px;width:700px;border-radius:12px;padding:30px}.-cbwsdk-css-reset .-cbwsdk-try-extension.light{background:#fff}.-cbwsdk-css-reset .-cbwsdk-try-extension.dark{background:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-try-extension-column-half{flex:50%}.-cbwsdk-css-reset .-cbwsdk-try-extension-heading{font-style:normal;font-weight:500;font-size:25px;line-height:32px;margin:0;max-width:204px}.-cbwsdk-css-reset .-cbwsdk-try-extension-heading.light{color:#0a0b0d}.-cbwsdk-css-reset .-cbwsdk-try-extension-heading.dark{color:#fff}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta{appearance:none;border:none;background:none;color:#0052ff;cursor:pointer;padding:0;text-decoration:none;display:block;font-weight:600;font-size:16px;line-height:24px}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta.light{color:#0052ff}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta.dark{color:#588af5}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta-wrapper{display:flex;align-items:center;margin-top:12px}.-cbwsdk-css-reset .-cbwsdk-try-extension-cta-icon{display:block;margin-left:4px;height:14px}.-cbwsdk-css-reset .-cbwsdk-try-extension-list{display:flex;flex-direction:column;justify-content:center;align-items:center;margin:0;padding:0;list-style:none;height:100%}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item{display:flex;align-items:center;flex-flow:nowrap;margin-top:24px}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item:first-of-type{margin-top:0}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon-wrapper{display:block}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon{display:flex;height:32px;width:32px;border-radius:50%}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon svg{margin:auto;display:block}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon.light{background:#eef0f3}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-icon.dark{background:#1e2025}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-copy{display:block;font-weight:400;font-size:14px;line-height:20px;padding-left:12px}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-copy.light{color:#5b636e}.-cbwsdk-css-reset .-cbwsdk-try-extension-list-item-copy.dark{color:#8a919e}"},11773:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.TryExtensionContent=void 0;let es=eo(et(50348)),ec=et(88049),el=et(87060),ed=et(66978),eh=et(91475),ef=et(46344),ep=eo(et(38479));l.TryExtensionContent=function({theme:c}){let[l,et]=(0,el.useState)(!1),eo=(0,el.useCallback)(()=>{window.open("https://api.wallet.coinbase.com/rpc/v2/desktop/chrome","_blank")},[]),eg=(0,el.useCallback)(()=>{l?window.location.reload():(eo(),et(!0))},[eo,l]);return(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-try-extension",c)},(0,ec.h)("style",null,ep.default),(0,ec.h)("div",{class:"-cbwsdk-try-extension-column-half"},(0,ec.h)("h3",{class:(0,es.default)("-cbwsdk-try-extension-heading",c)},"Or try the Coinbase Wallet browser extension"),(0,ec.h)("div",{class:"-cbwsdk-try-extension-cta-wrapper"},(0,ec.h)("button",{class:(0,es.default)("-cbwsdk-try-extension-cta",c),onClick:eg},l?"Refresh":"Install"),(0,ec.h)("div",null,!l&&(0,ec.h)(ed.ArrowLeftIcon,{class:"-cbwsdk-try-extension-cta-icon",fill:"light"===c?"#0052FF":"#588AF5"})))),(0,ec.h)("div",{class:"-cbwsdk-try-extension-column-half"},(0,ec.h)("ul",{class:"-cbwsdk-try-extension-list"},(0,ec.h)("li",{class:"-cbwsdk-try-extension-list-item"},(0,ec.h)("div",{class:"-cbwsdk-try-extension-list-item-icon-wrapper"},(0,ec.h)("span",{class:(0,es.default)("-cbwsdk-try-extension-list-item-icon",c)},(0,ec.h)(eh.LaptopIcon,{fill:"light"===c?"#0A0B0D":"#FFFFFF"}))),(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-try-extension-list-item-copy",c)},"Connect with dapps with just one click on your desktop browser")),(0,ec.h)("li",{class:"-cbwsdk-try-extension-list-item"},(0,ec.h)("div",{class:"-cbwsdk-try-extension-list-item-icon-wrapper"},(0,ec.h)("span",{class:(0,es.default)("-cbwsdk-try-extension-list-item-icon",c)},(0,ec.h)(ef.SafeIcon,{fill:"light"===c?"#0A0B0D":"#FFFFFF"}))),(0,ec.h)("div",{class:(0,es.default)("-cbwsdk-try-extension-list-item-copy",c)},"Add an additional layer of security by using a supported Ledger hardware wallet")))))}},66978:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.ArrowLeftIcon=void 0;let eo=et(88049);l.ArrowLeftIcon=function(c){return(0,eo.h)("svg",Object.assign({width:"16",height:"16",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg"},c),(0,eo.h)("path",{d:"M8.60675 0.155884L7.37816 1.28209L12.7723 7.16662H0V8.83328H12.6548L6.82149 14.6666L8 15.8451L15.8201 8.02501L8.60675 0.155884Z"}))}},35889:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.CloseIcon=void 0;let eo=et(88049);l.CloseIcon=function(c){return(0,eo.h)("svg",Object.assign({width:"40",height:"40",viewBox:"0 0 40 40",fill:"none",xmlns:"http://www.w3.org/2000/svg"},c),(0,eo.h)("path",{d:"M13.7677 13L12.3535 14.4142L18.3535 20.4142L12.3535 26.4142L13.7677 27.8284L19.7677 21.8284L25.7677 27.8284L27.1819 26.4142L21.1819 20.4142L27.1819 14.4142L25.7677 13L19.7677 19L13.7677 13Z"}))}},91475:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.LaptopIcon=void 0;let eo=et(88049);l.LaptopIcon=function(c){return(0,eo.h)("svg",Object.assign({width:"14",height:"14",viewBox:"0 0 14 14",xmlns:"http://www.w3.org/2000/svg"},c),(0,eo.h)("path",{d:"M1.8001 2.2002H12.2001V9.40019H1.8001V2.2002ZM3.4001 3.8002V7.80019H10.6001V3.8002H3.4001Z"}),(0,eo.h)("path",{d:"M13.4001 10.2002H0.600098C0.600098 11.0838 1.31644 11.8002 2.2001 11.8002H11.8001C12.6838 11.8002 13.4001 11.0838 13.4001 10.2002Z"}))}},62052:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.QRCodeIcon=void 0;let eo=et(88049);l.QRCodeIcon=function(c){return(0,eo.h)("svg",Object.assign({width:"10",height:"10",viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg"},c),(0,eo.h)("path",{d:"M8.2271 1.77124L7.0271 1.77124V2.97124H8.2271V1.77124Z"}),(0,eo.h)("path",{d:"M5.44922 0.199219L5.44922 4.54922L9.79922 4.54922V0.199219L5.44922 0.199219ZM8.89922 3.64922L6.34922 3.64922L6.34922 1.09922L8.89922 1.09922V3.64922Z"}),(0,eo.h)("path",{d:"M2.97124 1.77124L1.77124 1.77124L1.77124 2.97124H2.97124V1.77124Z"}),(0,eo.h)("path",{d:"M0.199219 4.54922L4.54922 4.54922L4.54922 0.199219L0.199219 0.199219L0.199219 4.54922ZM1.09922 1.09922L3.64922 1.09922L3.64922 3.64922L1.09922 3.64922L1.09922 1.09922Z"}),(0,eo.h)("path",{d:"M2.97124 7.0271H1.77124L1.77124 8.2271H2.97124V7.0271Z"}),(0,eo.h)("path",{d:"M0.199219 9.79922H4.54922L4.54922 5.44922L0.199219 5.44922L0.199219 9.79922ZM1.09922 6.34922L3.64922 6.34922L3.64922 8.89922H1.09922L1.09922 6.34922Z"}),(0,eo.h)("path",{d:"M8.89922 7.39912H7.99922V5.40112H5.44922L5.44922 9.79912H6.34922L6.34922 6.30112H7.09922V8.29912H9.79922V5.40112H8.89922V7.39912Z"}),(0,eo.h)("path",{d:"M7.99912 8.89917H7.09912V9.79917H7.99912V8.89917Z"}),(0,eo.h)("path",{d:"M9.79917 8.89917H8.89917V9.79917H9.79917V8.89917Z"}))}},4048:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let et=` + + + + + +`;l.default=et},183:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default=` + + + + + + +`},46344:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.SafeIcon=void 0;let eo=et(88049);l.SafeIcon=function(c){return(0,eo.h)("svg",Object.assign({width:"14",height:"14",viewBox:"0 0 14 14",xmlns:"http://www.w3.org/2000/svg"},c),(0,eo.h)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M0.600098 0.600098V11.8001H13.4001V0.600098H0.600098ZM7.0001 9.2001C5.3441 9.2001 4.0001 7.8561 4.0001 6.2001C4.0001 4.5441 5.3441 3.2001 7.0001 3.2001C8.6561 3.2001 10.0001 4.5441 10.0001 6.2001C10.0001 7.8561 8.6561 9.2001 7.0001 9.2001ZM0.600098 12.6001H3.8001V13.4001H0.600098V12.6001ZM10.2001 12.6001H13.4001V13.4001H10.2001V12.6001ZM8.8001 6.2001C8.8001 7.19421 7.99421 8.0001 7.0001 8.0001C6.00598 8.0001 5.2001 7.19421 5.2001 6.2001C5.2001 5.20598 6.00598 4.4001 7.0001 4.4001C7.99421 4.4001 8.8001 5.20598 8.8001 6.2001Z"}))}},48197:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.StatusDotIcon=void 0;let eo=et(88049);l.StatusDotIcon=function(c){return(0,eo.h)("svg",Object.assign({width:"10",height:"10",viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg"},c),(0,eo.h)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.29995 4.99995C2.29995 5.57985 1.82985 6.04995 1.24995 6.04995C0.670052 6.04995 0.199951 5.57985 0.199951 4.99995C0.199951 4.42005 0.670052 3.94995 1.24995 3.94995C1.82985 3.94995 2.29995 4.42005 2.29995 4.99995ZM4.99995 6.04995C5.57985 6.04995 6.04995 5.57985 6.04995 4.99995C6.04995 4.42005 5.57985 3.94995 4.99995 3.94995C4.42005 3.94995 3.94995 4.42005 3.94995 4.99995C3.94995 5.57985 4.42005 6.04995 4.99995 6.04995ZM8.74995 6.04995C9.32985 6.04995 9.79995 5.57985 9.79995 4.99995C9.79995 4.42005 9.32985 3.94995 8.74995 3.94995C8.17005 3.94995 7.69995 4.42005 7.69995 4.99995C7.69995 5.57985 8.17005 6.04995 8.74995 6.04995Z"}))}},52375:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjgiIGhlaWdodD0iMjgiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGNpcmNsZSBjeD0iMTQiIGN5PSIxNCIgcj0iMTQiIGZpbGw9IiMwMDUyRkYiLz48cGF0aCBkPSJNMTQuMDM3IDE4LjkyNmMtMi43NSAwLTQuOTA3LTIuMjA1LTQuOTA3LTQuOTI2IDAtMi43MiAyLjIzLTQuOTI2IDQuOTA3LTQuOTI2YTQuODY2IDQuODY2IDAgMCAxIDQuODMzIDQuMTE4aDQuOTgyYy0uNDQ2LTUuMDczLTQuNjg0LTkuMDQ0LTkuODE1LTkuMDQ0QzguNjEgNC4xNDggNC4xNDkgOC41NiA0LjE0OSAxNHM0LjM4NyA5Ljg1MiA5Ljg5IDkuODUyYzUuMjA0IDAgOS4zNjgtMy45NyA5LjgxNC05LjA0M0gxOC44N2E0Ljg2NiA0Ljg2NiAwIDAgMS00LjgzMyA0LjExN1oiIGZpbGw9IiNmZmYiLz48L3N2Zz4="},13445:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjgiIGhlaWdodD0iMjgiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGNpcmNsZSBjeD0iMTQiIGN5PSIxNCIgcj0iMTQiIGZpbGw9IiMwMDUyRkYiLz48cGF0aCBkPSJNMjMuODUyIDE0QTkuODM0IDkuODM0IDAgMCAxIDE0IDIzLjg1MiA5LjgzNCA5LjgzNCAwIDAgMSA0LjE0OCAxNCA5LjgzNCA5LjgzNCAwIDAgMSAxNCA0LjE0OCA5LjgzNCA5LjgzNCAwIDAgMSAyMy44NTIgMTRaIiBmaWxsPSIjZmZmIi8+PHBhdGggZD0iTTExLjE4NSAxMi41MDRjMC0uNDU2IDAtLjcxLjA5OC0uODYyLjA5OC0uMTUyLjE5Ni0uMzA0LjM0My0uMzU1LjE5Ni0uMTAyLjM5Mi0uMTAyLjg4MS0uMTAyaDIuOTg2Yy40OSAwIC42ODYgMCAuODgyLjEwMi4xNDYuMTAxLjI5My4yMDMuMzQyLjM1NS4wOTguMjAzLjA5OC40MDYuMDk4Ljg2MnYyLjk5MmMwIC40NTcgMCAuNzEtLjA5OC44NjMtLjA5OC4xNTItLjE5NS4zMDQtLjM0Mi4zNTUtLjE5Ni4xMDEtLjM5Mi4xMDEtLjg4Mi4xMDFoLTIuOTg2Yy0uNDkgMC0uNjg1IDAtLjg4LS4xMDEtLjE0OC0uMTAyLS4yOTUtLjIwMy0uMzQ0LS4zNTUtLjA5OC0uMjAzLS4wOTgtLjQwNi0uMDk4LS44NjN2LTIuOTkyWiIgZmlsbD0iIzAwNTJGRiIvPjwvc3ZnPg=="},54775:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.ClientMessagePublishEvent=l.ClientMessageSetSessionConfig=l.ClientMessageGetSessionConfig=l.ClientMessageIsLinked=l.ClientMessageHostSession=void 0,l.ClientMessageHostSession=function(c){return Object.assign({type:"HostSession"},c)},l.ClientMessageIsLinked=function(c){return Object.assign({type:"IsLinked"},c)},l.ClientMessageGetSessionConfig=function(c){return Object.assign({type:"GetSessionConfig"},c)},l.ClientMessageSetSessionConfig=function(c){return Object.assign({type:"SetSessionConfig"},c)},l.ClientMessagePublishEvent=function(c){return Object.assign({type:"PublishEvent"},c)}},81371:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.EVENTS=void 0,l.EVENTS={STARTED_CONNECTING:"walletlink_sdk.started.connecting",CONNECTED_STATE_CHANGE:"walletlink_sdk.connected",DISCONNECTED:"walletlink_sdk.disconnected",METADATA_DESTROYED:"walletlink_sdk_metadata_destroyed",LINKED:"walletlink_sdk.linked",FAILURE:"walletlink_sdk.generic_failure",SESSION_CONFIG_RECEIVED:"walletlink_sdk.session_config_event_received",ETH_ACCOUNTS_STATE:"walletlink_sdk.eth_accounts_state",SESSION_STATE_CHANGE:"walletlink_sdk.session_state_change",UNLINKED_ERROR_STATE:"walletlink_sdk.unlinked_error_state",SKIPPED_CLEARING_SESSION:"walletlink_sdk.skipped_clearing_session",GENERAL_ERROR:"walletlink_sdk.general_error",WEB3_REQUEST:"walletlink_sdk.web3.request",WEB3_REQUEST_PUBLISHED:"walletlink_sdk.web3.request_published",WEB3_RESPONSE:"walletlink_sdk.web3.response",UNKNOWN_ADDRESS_ENCOUNTERED:"walletlink_sdk.unknown_address_encountered"}},11849:function(c,l,et){"use strict";var eo,es;Object.defineProperty(l,"__esModule",{value:!0}),l.RxWebSocket=l.ConnectionState=void 0;let ec=et(33664),el=et(39254);(es=eo=l.ConnectionState||(l.ConnectionState={}))[es.DISCONNECTED=0]="DISCONNECTED",es[es.CONNECTING=1]="CONNECTING",es[es.CONNECTED=2]="CONNECTED",l.RxWebSocket=class{constructor(c,l=WebSocket){this.WebSocketClass=l,this.webSocket=null,this.connectionStateSubject=new ec.BehaviorSubject(eo.DISCONNECTED),this.incomingDataSubject=new ec.Subject,this.pendingData=[],this.url=c.replace(/^http/,"ws")}connect(){return this.webSocket?(0,ec.throwError)(Error("webSocket object is not null")):new ec.Observable(c=>{let l;try{this.webSocket=l=new this.WebSocketClass(this.url)}catch(l){c.error(l);return}this.connectionStateSubject.next(eo.CONNECTING),l.onclose=l=>{this.clearWebSocket(),c.error(Error(`websocket error ${l.code}: ${l.reason}`)),this.connectionStateSubject.next(eo.DISCONNECTED)},l.onopen=l=>{if(c.next(),c.complete(),this.connectionStateSubject.next(eo.CONNECTED),this.pendingData.length>0){let c=[...this.pendingData];c.forEach(c=>this.sendData(c)),this.pendingData=[]}},l.onmessage=c=>{this.incomingDataSubject.next(c.data)}}).pipe((0,el.take)(1))}disconnect(){let{webSocket:c}=this;if(c){this.clearWebSocket(),this.connectionStateSubject.next(eo.DISCONNECTED);try{c.close()}catch(c){}}}get connectionState$(){return this.connectionStateSubject.asObservable()}get incomingData$(){return this.incomingDataSubject.asObservable()}get incomingJSONData$(){return this.incomingData$.pipe((0,el.flatMap)(c=>{let l;try{l=JSON.parse(c)}catch(c){return(0,ec.empty)()}return(0,ec.of)(l)}))}sendData(c){let{webSocket:l}=this;if(!l){this.pendingData.push(c),this.connect().subscribe();return}l.send(c)}clearWebSocket(){let{webSocket:c}=this;c&&(this.webSocket=null,c.onclose=null,c.onerror=null,c.onmessage=null,c.onopen=null)}}},80448:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.isServerMessageFail=void 0,l.isServerMessageFail=function(c){return c&&"Fail"===c.type&&"number"==typeof c.id&&"string"==typeof c.sessionId&&"string"==typeof c.error}},74924:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.WalletLinkConnection=void 0;let eo=et(33664),es=et(39254),ec=et(14677),el=et(73156),ed=et(54775),eh=et(81371),ef=et(11849),ep=et(80448);l.WalletLinkConnection=class{constructor(c,l,et,ed,ep=WebSocket){this.sessionId=c,this.sessionKey=l,this.linkAPIUrl=et,this.diagnostic=ed,this.subscriptions=new eo.Subscription,this.destroyed=!1,this.lastHeartbeatResponse=0,this.nextReqId=(0,el.IntNumber)(1),this.connectedSubject=new eo.BehaviorSubject(!1),this.linkedSubject=new eo.BehaviorSubject(!1),this.sessionConfigSubject=new eo.ReplaySubject(1),this.unseenEventsSubject=new eo.Subject;let eg=new ef.RxWebSocket(et+"/rpc",ep);this.ws=eg,this.subscriptions.add(eg.connectionState$.pipe((0,es.tap)(l=>{var et;return null===(et=this.diagnostic)||void 0===et?void 0:et.log(eh.EVENTS.CONNECTED_STATE_CHANGE,{state:l,sessionIdHash:ec.Session.hash(c)})}),(0,es.skip)(1),(0,es.filter)(c=>c===ef.ConnectionState.DISCONNECTED&&!this.destroyed),(0,es.delay)(5e3),(0,es.filter)(c=>!this.destroyed),(0,es.flatMap)(c=>eg.connect()),(0,es.retry)()).subscribe()),this.subscriptions.add(eg.connectionState$.pipe((0,es.skip)(2),(0,es.switchMap)(c=>(0,eo.iif)(()=>c===ef.ConnectionState.CONNECTED,this.authenticate().pipe((0,es.tap)(c=>this.sendIsLinked()),(0,es.tap)(c=>this.sendGetSessionConfig()),(0,es.map)(c=>!0)),(0,eo.of)(!1))),(0,es.distinctUntilChanged)(),(0,es.catchError)(c=>(0,eo.of)(!1))).subscribe(c=>this.connectedSubject.next(c))),this.subscriptions.add(eg.connectionState$.pipe((0,es.skip)(1),(0,es.switchMap)(c=>(0,eo.iif)(()=>c===ef.ConnectionState.CONNECTED,(0,eo.timer)(0,1e4)))).subscribe(c=>0===c?this.updateLastHeartbeat():this.heartbeat())),this.subscriptions.add(eg.incomingData$.pipe((0,es.filter)(c=>"h"===c)).subscribe(c=>this.updateLastHeartbeat())),this.subscriptions.add(eg.incomingJSONData$.pipe((0,es.filter)(c=>["IsLinkedOK","Linked"].includes(c.type))).subscribe(l=>{var et;null===(et=this.diagnostic)||void 0===et||et.log(eh.EVENTS.LINKED,{sessionIdHash:ec.Session.hash(c),linked:l.linked,type:l.type,onlineGuests:l.onlineGuests}),this.linkedSubject.next(l.linked||l.onlineGuests>0)})),this.subscriptions.add(eg.incomingJSONData$.pipe((0,es.filter)(c=>["GetSessionConfigOK","SessionConfigUpdated"].includes(c.type))).subscribe(l=>{var et;null===(et=this.diagnostic)||void 0===et||et.log(eh.EVENTS.SESSION_CONFIG_RECEIVED,{sessionIdHash:ec.Session.hash(c),metadata_keys:l&&l.metadata?Object.keys(l.metadata):void 0}),this.sessionConfigSubject.next({webhookId:l.webhookId,webhookUrl:l.webhookUrl,metadata:l.metadata})})),this.subscriptions.add(this.unseenEventsSubject.subscribe(c=>{let l=`${this.sessionId}:${this.sessionKey}`,et=`Basic ${btoa(l)}`;fetch(`${this.linkAPIUrl}/events/${c.eventId}/seen`,{method:"POST",headers:{Authorization:et}}).catch(c=>console.error("Unabled to mark event as failed:",c))}))}connect(){var c;if(this.destroyed)throw Error("instance is destroyed");null===(c=this.diagnostic)||void 0===c||c.log(eh.EVENTS.STARTED_CONNECTING,{sessionIdHash:ec.Session.hash(this.sessionId)}),this.ws.connect().subscribe()}destroy(){var c;this.subscriptions.unsubscribe(),this.ws.disconnect(),null===(c=this.diagnostic)||void 0===c||c.log(eh.EVENTS.DISCONNECTED,{sessionIdHash:ec.Session.hash(this.sessionId)}),this.destroyed=!0}get isDestroyed(){return this.destroyed}get connected$(){return this.connectedSubject.asObservable()}get onceConnected$(){return this.connected$.pipe((0,es.filter)(c=>c),(0,es.take)(1),(0,es.map)(()=>void 0))}get linked$(){return this.linkedSubject.asObservable()}get onceLinked$(){return this.linked$.pipe((0,es.filter)(c=>c),(0,es.take)(1),(0,es.map)(()=>void 0))}get sessionConfig$(){return this.sessionConfigSubject.asObservable()}get incomingEvent$(){return(0,eo.merge)(this.ws.incomingJSONData$,this.unseenEventsSubject).pipe((0,es.filter)(c=>"Event"===c.type&&"string"==typeof c.sessionId&&"string"==typeof c.eventId&&"string"==typeof c.event&&"string"==typeof c.data),(0,es.map)(c=>c))}async checkUnseenEvents(){var c;let l=`${this.sessionId}:${this.sessionKey}`,et=`Basic ${btoa(l)}`,eo=await fetch(`${this.linkAPIUrl}/events?unseen=true`,{headers:{Authorization:et}});if(eo.ok){let{events:l,error:et}=await eo.json();if(et)throw Error(`Check unseen events failed: ${et}`);let es=null!==(c=null==l?void 0:l.filter(c=>"Web3Response"===c.event).map(c=>({type:"Event",sessionId:this.sessionId,eventId:c.id,event:c.event,data:c.data})))&&void 0!==c?c:[];es.forEach(c=>this.unseenEventsSubject.next(c))}else throw Error(`Check unseen events failed: ${eo.status}`)}setSessionMetadata(c,l){let et=(0,ed.ClientMessageSetSessionConfig)({id:(0,el.IntNumber)(this.nextReqId++),sessionId:this.sessionId,metadata:{[c]:l}});return this.onceConnected$.pipe((0,es.flatMap)(c=>this.makeRequest(et)),(0,es.map)(c=>{if((0,ep.isServerMessageFail)(c))throw Error(c.error||"failed to set session metadata")}))}publishEvent(c,l,et=!1){let eo=(0,ed.ClientMessagePublishEvent)({id:(0,el.IntNumber)(this.nextReqId++),sessionId:this.sessionId,event:c,data:l,callWebhook:et});return this.onceLinked$.pipe((0,es.flatMap)(c=>this.makeRequest(eo)),(0,es.map)(c=>{if((0,ep.isServerMessageFail)(c))throw Error(c.error||"failed to publish event");return c.eventId}))}sendData(c){this.ws.sendData(JSON.stringify(c))}updateLastHeartbeat(){this.lastHeartbeatResponse=Date.now()}heartbeat(){if(Date.now()-this.lastHeartbeatResponse>2e4){this.ws.disconnect();return}try{this.ws.sendData("h")}catch(c){}}makeRequest(c,l=6e4){let et=c.id;try{this.sendData(c)}catch(c){return(0,eo.throwError)(c)}return this.ws.incomingJSONData$.pipe((0,es.timeoutWith)(l,(0,eo.throwError)(Error(`request ${et} timed out`))),(0,es.filter)(c=>c.id===et),(0,es.take)(1))}authenticate(){let c=(0,ed.ClientMessageHostSession)({id:(0,el.IntNumber)(this.nextReqId++),sessionId:this.sessionId,sessionKey:this.sessionKey});return this.makeRequest(c).pipe((0,es.map)(c=>{if((0,ep.isServerMessageFail)(c))throw Error(c.error||"failed to authentcate")}))}sendIsLinked(){let c=(0,ed.ClientMessageIsLinked)({id:(0,el.IntNumber)(this.nextReqId++),sessionId:this.sessionId});this.sendData(c)}sendGetSessionConfig(){let c=(0,ed.ClientMessageGetSessionConfig)({id:(0,el.IntNumber)(this.nextReqId++),sessionId:this.sessionId});this.sendData(c)}}},77507:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.getErrorCode=l.serializeError=l.standardErrors=l.standardErrorMessage=l.standardErrorCodes=void 0;let eo=et(46281),es=et(6787),ec=et(94579);l.standardErrorCodes=Object.freeze(Object.assign(Object.assign({},eo.errorCodes),{provider:Object.freeze(Object.assign(Object.assign({},eo.errorCodes.provider),{unsupportedChain:4902}))})),l.standardErrorMessage=function(c){return void 0!==c?(0,eo.getMessageFromCode)(c):"Unknown error"},l.standardErrors=Object.freeze(Object.assign(Object.assign({},eo.ethErrors),{provider:Object.freeze(Object.assign(Object.assign({},eo.ethErrors.provider),{unsupportedChain:(c="")=>eo.ethErrors.provider.custom({code:l.standardErrorCodes.provider.unsupportedChain,message:`Unrecognized chain ID ${c}. Try adding the chain using wallet_addEthereumChain first.`})}))})),l.serializeError=function(c,et){let el=(0,eo.serializeError)("string"==typeof c?{message:c,code:l.standardErrorCodes.rpc.internal}:(0,es.isErrorResponse)(c)?Object.assign(Object.assign({},c),{message:c.errorMessage,code:c.errorCode,data:{method:c.method,result:c.result}}):c,{shouldIncludeStack:!0}),ed=new URL("https://docs.cloud.coinbase.com/wallet-sdk/docs/errors");ed.searchParams.set("version",ec.LIB_VERSION),ed.searchParams.set("code",el.code.toString());let eh=function(c,l){let et=null==c?void 0:c.method;return et?et:void 0!==l?"string"==typeof l?l:Array.isArray(l)?l.length>0?l[0].method:void 0:l.method:void 0}(el.data,et);return eh&&ed.searchParams.set("method",eh),ed.searchParams.set("message",el.message),Object.assign(Object.assign({},el),{docUrl:ed.href})},l.getErrorCode=function(c){var l;return"number"==typeof c?c:"object"==typeof c&&null!==c&&("number"==typeof c.code||"number"==typeof c.errorCode)?null!==(l=c.code)&&void 0!==l?l:c.errorCode:void 0}},64775:function(c,l,et){"use strict";let eo=et(36098),es=et(3384);et(36098),et(3384),l.ZP=eo.CoinbaseWalletSDK,"undefined"!=typeof window&&(window.CoinbaseWalletSDK=eo.CoinbaseWalletSDK,window.CoinbaseWalletProvider=es.CoinbaseWalletProvider,window.WalletLink=eo.CoinbaseWalletSDK,window.WalletLinkProvider=es.CoinbaseWalletProvider)},89406:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.ScopedLocalStorage=void 0,l.ScopedLocalStorage=class{constructor(c){this.scope=c}setItem(c,l){localStorage.setItem(this.scopedKey(c),l)}getItem(c){return localStorage.getItem(this.scopedKey(c))}removeItem(c){localStorage.removeItem(this.scopedKey(c))}clear(){let c=this.scopedKey(""),l=[];for(let et=0;etlocalStorage.removeItem(c))}scopedKey(c){return`${this.scope}:${c}`}}},38954:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.default='@namespace svg "http://www.w3.org/2000/svg";.-cbwsdk-css-reset,.-cbwsdk-css-reset *{animation:none;animation-delay:0;animation-direction:normal;animation-duration:0;animation-fill-mode:none;animation-iteration-count:1;animation-name:none;animation-play-state:running;animation-timing-function:ease;backface-visibility:visible;background:0;background-attachment:scroll;background-clip:border-box;background-color:rgba(0,0,0,0);background-image:none;background-origin:padding-box;background-position:0 0;background-position-x:0;background-position-y:0;background-repeat:repeat;background-size:auto auto;border:0;border-style:none;border-width:medium;border-color:inherit;border-bottom:0;border-bottom-color:inherit;border-bottom-left-radius:0;border-bottom-right-radius:0;border-bottom-style:none;border-bottom-width:medium;border-collapse:separate;border-image:none;border-left:0;border-left-color:inherit;border-left-style:none;border-left-width:medium;border-radius:0;border-right:0;border-right-color:inherit;border-right-style:none;border-right-width:medium;border-spacing:0;border-top:0;border-top-color:inherit;border-top-left-radius:0;border-top-right-radius:0;border-top-style:none;border-top-width:medium;box-shadow:none;box-sizing:border-box;caption-side:top;clear:none;clip:auto;color:inherit;columns:auto;column-count:auto;column-fill:balance;column-gap:normal;column-rule:medium none currentColor;column-rule-color:currentColor;column-rule-style:none;column-rule-width:none;column-span:1;column-width:auto;counter-increment:none;counter-reset:none;direction:ltr;empty-cells:show;float:none;font:normal;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;height:auto;hyphens:none;letter-spacing:normal;line-height:normal;list-style:none;list-style-image:none;list-style-position:outside;list-style-type:disc;margin:0;margin-bottom:0;margin-left:0;margin-right:0;margin-top:0;opacity:1;orphans:0;outline:0;outline-color:invert;outline-style:none;outline-width:medium;overflow:visible;overflow-x:visible;overflow-y:visible;padding:0;padding-bottom:0;padding-left:0;padding-right:0;padding-top:0;page-break-after:auto;page-break-before:auto;page-break-inside:auto;perspective:none;perspective-origin:50% 50%;pointer-events:auto;position:static;quotes:"\\201C" "\\201D" "\\2018" "\\2019";tab-size:8;table-layout:auto;text-align:inherit;text-align-last:auto;text-decoration:none;text-decoration-color:inherit;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-shadow:none;text-transform:none;transform:none;transform-style:flat;transition:none;transition-delay:0s;transition-duration:0s;transition-property:none;transition-timing-function:ease;unicode-bidi:normal;vertical-align:baseline;visibility:visible;white-space:normal;widows:0;word-spacing:normal;z-index:auto}.-cbwsdk-css-reset strong{font-weight:bold}.-cbwsdk-css-reset *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;line-height:1}.-cbwsdk-css-reset [class*=container]{margin:0;padding:0}.-cbwsdk-css-reset style{display:none}'},97302:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.injectCssReset=void 0;let es=eo(et(38954));l.injectCssReset=function(){let c=document.createElement("style");c.type="text/css",c.appendChild(document.createTextNode(es.default)),document.documentElement.appendChild(c)}},3384:function(c,l,et){"use strict";var eo=et(67133).Buffer,es=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.CoinbaseWalletProvider=void 0;let ec=es(et(12941)),el=es(et(56662)),ed=et(81371),eh=et(77507),ef=et(84607),ep=et(14677),eg=et(66452),em=et(90263),eb=et(6787),ey=et(59656),e_=es(et(31880)),ew=et(61532),eE=et(65505),eS=et(60125),ex="DefaultChainId",ek="DefaultJsonRpcUrl";let CoinbaseWalletProvider=class CoinbaseWalletProvider extends ec.default{constructor(c){var l,et;super(),this._filterPolyfill=new ew.FilterPolyfill(this),this._subscriptionManager=new eS.SubscriptionManager(this),this._relay=null,this._addresses=[],this.hasMadeFirstChainChangedEmission=!1,this.setProviderInfo=this.setProviderInfo.bind(this),this.updateProviderInfo=this.updateProviderInfo.bind(this),this.getChainId=this.getChainId.bind(this),this.setAppInfo=this.setAppInfo.bind(this),this.enable=this.enable.bind(this),this.close=this.close.bind(this),this.send=this.send.bind(this),this.sendAsync=this.sendAsync.bind(this),this.request=this.request.bind(this),this._setAddresses=this._setAddresses.bind(this),this.scanQRCode=this.scanQRCode.bind(this),this.genericRequest=this.genericRequest.bind(this),this._chainIdFromOpts=c.chainId,this._jsonRpcUrlFromOpts=c.jsonRpcUrl,this._overrideIsMetaMask=c.overrideIsMetaMask,this._relayProvider=c.relayProvider,this._storage=c.storage,this._relayEventManager=c.relayEventManager,this.diagnostic=c.diagnosticLogger,this.reloadOnDisconnect=!0,this.isCoinbaseWallet=null===(l=c.overrideIsCoinbaseWallet)||void 0===l||l,this.isCoinbaseBrowser=null!==(et=c.overrideIsCoinbaseBrowser)&&void 0!==et&&et,this.qrUrl=c.qrUrl,this.supportsAddressSwitching=c.supportsAddressSwitching,this.isLedger=c.isLedger;let eo=this.getChainId(),es=(0,ey.prepend0x)(eo.toString(16));this.emit("connect",{chainIdStr:es});let ec=this._storage.getItem(eg.LOCAL_STORAGE_ADDRESSES_KEY);if(ec){let c=ec.split(" ");""!==c[0]&&(this._addresses=c.map(c=>(0,ey.ensureAddressString)(c)),this.emit("accountsChanged",c))}this._subscriptionManager.events.on("notification",c=>{this.emit("message",{type:c.method,data:c.params})}),this._addresses.length>0&&this.initializeRelay(),window.addEventListener("message",c=>{var l;if(c.origin===location.origin&&c.source===window&&"walletLinkMessage"===c.data.type){if("defaultChainChanged"===c.data.data.action||"dappChainSwitched"===c.data.data.action){let et=c.data.data.chainId,eo=null!==(l=c.data.data.jsonRpcUrl)&&void 0!==l?l:this.jsonRpcUrl;this.updateProviderInfo(eo,Number(et))}"addressChanged"===c.data.data.action&&this._setAddresses([c.data.data.address])}})}get selectedAddress(){return this._addresses[0]||void 0}get networkVersion(){return this.getChainId().toString(10)}get chainId(){return(0,ey.prepend0x)(this.getChainId().toString(16))}get isWalletLink(){return!0}get isMetaMask(){return this._overrideIsMetaMask}get host(){return this.jsonRpcUrl}get connected(){return!0}isConnected(){return!0}get jsonRpcUrl(){var c;return null!==(c=this._storage.getItem(ek))&&void 0!==c?c:this._jsonRpcUrlFromOpts}set jsonRpcUrl(c){this._storage.setItem(ek,c)}disableReloadOnDisconnect(){this.reloadOnDisconnect=!1}setProviderInfo(c,l){this.isLedger||this.isCoinbaseBrowser||(this._chainIdFromOpts=l,this._jsonRpcUrlFromOpts=c),this.updateProviderInfo(this.jsonRpcUrl,this.getChainId())}updateProviderInfo(c,l){this.jsonRpcUrl=c;let et=this.getChainId();this._storage.setItem(ex,l.toString(10));let eo=(0,ey.ensureIntNumber)(l)!==et;(eo||!this.hasMadeFirstChainChangedEmission)&&(this.emit("chainChanged",this.getChainId()),this.hasMadeFirstChainChangedEmission=!0)}async watchAsset(c,l,et,eo,es,ec){let el=await this.initializeRelay(),ed=await el.watchAsset(c,l,et,eo,es,null==ec?void 0:ec.toString()).promise;return!!ed.result}async addEthereumChain(c,l,et,eo,es,ec){var el,ed;if((0,ey.ensureIntNumber)(c)===this.getChainId())return!1;let eh=await this.initializeRelay(),ef=eh.inlineAddEthereumChain(c.toString());this._isAuthorized()||ef||await eh.requestEthereumAccounts().promise;let ep=await eh.addEthereumChain(c.toString(),l,es,et,eo,ec).promise;return(null===(el=ep.result)||void 0===el?void 0:el.isApproved)===!0&&this.updateProviderInfo(l[0],c),(null===(ed=ep.result)||void 0===ed?void 0:ed.isApproved)===!0}async switchEthereumChain(c){let l=await this.initializeRelay(),et=await l.switchEthereumChain(c.toString(10),this.selectedAddress||void 0).promise;if((0,eb.isErrorResponse)(et)&&et.errorCode){if(et.errorCode===eh.standardErrorCodes.provider.unsupportedChain)throw eh.standardErrors.provider.unsupportedChain(c);throw eh.standardErrors.provider.custom({message:et.errorMessage,code:et.errorCode})}let eo=et.result;eo.isApproved&&eo.rpcUrl.length>0&&this.updateProviderInfo(eo.rpcUrl,c)}setAppInfo(c,l){this.initializeRelay().then(et=>et.setAppInfo(c,l))}async enable(){var c;return(null===(c=this.diagnostic)||void 0===c||c.log(ed.EVENTS.ETH_ACCOUNTS_STATE,{method:"provider::enable",addresses_length:this._addresses.length,sessionIdHash:this._relay?ep.Session.hash(this._relay.session.id):void 0}),this._addresses.length>0)?[...this._addresses]:await this.send(eE.JSONRPCMethod.eth_requestAccounts)}async close(){let c=await this.initializeRelay();c.resetAndReload()}send(c,l){try{let et=this._send(c,l);if(et instanceof Promise)return et.catch(l=>{throw(0,eh.serializeError)(l,c)})}catch(l){throw(0,eh.serializeError)(l,c)}}_send(c,l){if("string"==typeof c){let et=Array.isArray(l)?l:void 0!==l?[l]:[];return this._sendRequestAsync({jsonrpc:"2.0",id:0,method:c,params:et}).then(c=>c.result)}return"function"==typeof l?this._sendAsync(c,l):Array.isArray(c)?c.map(c=>this._sendRequest(c)):this._sendRequest(c)}async sendAsync(c,l){try{return this._sendAsync(c,l).catch(l=>{throw(0,eh.serializeError)(l,c)})}catch(l){return Promise.reject((0,eh.serializeError)(l,c))}}async _sendAsync(c,l){if("function"!=typeof l)throw Error("callback is required");if(Array.isArray(c)){this._sendMultipleRequestsAsync(c).then(c=>l(null,c)).catch(c=>l(c,null));return}return this._sendRequestAsync(c).then(c=>l(null,c)).catch(c=>l(c,null))}async request(c){try{return this._request(c).catch(l=>{throw(0,eh.serializeError)(l,c.method)})}catch(l){return Promise.reject((0,eh.serializeError)(l,c.method))}}async _request(c){if(!c||"object"!=typeof c||Array.isArray(c))throw eh.standardErrors.rpc.invalidRequest({message:"Expected a single, non-array, object argument.",data:c});let{method:l,params:et}=c;if("string"!=typeof l||0===l.length)throw eh.standardErrors.rpc.invalidRequest({message:"'args.method' must be a non-empty string.",data:c});if(void 0!==et&&!Array.isArray(et)&&("object"!=typeof et||null===et))throw eh.standardErrors.rpc.invalidRequest({message:"'args.params' must be an object or array if provided.",data:c});let eo=void 0===et?[]:et,es=this._relayEventManager.makeRequestId(),ec=await this._sendRequestAsync({method:l,params:eo,jsonrpc:"2.0",id:es});return ec.result}async scanQRCode(c){var l;let et=await this.initializeRelay(),eo=await et.scanQRCode((0,ey.ensureRegExpString)(c)).promise;if("string"!=typeof eo.result)throw(0,eh.serializeError)(null!==(l=eo.errorMessage)&&void 0!==l?l:"result was not a string",em.Web3Method.scanQRCode);return eo.result}async genericRequest(c,l){var et;let eo=await this.initializeRelay(),es=await eo.genericRequest(c,l).promise;if("string"!=typeof es.result)throw(0,eh.serializeError)(null!==(et=es.errorMessage)&&void 0!==et?et:"result was not a string",em.Web3Method.generic);return es.result}async connectAndSignIn(c){var l;let et;null===(l=this.diagnostic)||void 0===l||l.log(ed.EVENTS.ETH_ACCOUNTS_STATE,{method:"provider::connectAndSignIn",sessionIdHash:this._relay?ep.Session.hash(this._relay.session.id):void 0});try{let l=await this.initializeRelay();if(!(l instanceof ef.MobileRelay))throw Error("connectAndSignIn is only supported on mobile");et=await l.connectAndSignIn(c).promise}catch(c){if("string"==typeof c.message&&c.message.match(/(denied|rejected)/i))throw eh.standardErrors.provider.userRejectedRequest("User denied account authorization");throw c}if(!et.result)throw Error("accounts received is empty");let{accounts:eo}=et.result;return this._setAddresses(eo),this.isLedger||this.isCoinbaseBrowser||await this.switchEthereumChain(this.getChainId()),et.result}async selectProvider(c){var l;let et=await this.initializeRelay(),eo=await et.selectProvider(c).promise;if("string"!=typeof eo.result)throw(0,eh.serializeError)(null!==(l=eo.errorMessage)&&void 0!==l?l:"result was not a string",em.Web3Method.selectProvider);return eo.result}supportsSubscriptions(){return!1}subscribe(){throw Error("Subscriptions are not supported")}unsubscribe(){throw Error("Subscriptions are not supported")}disconnect(){return!0}_sendRequest(c){let l={jsonrpc:"2.0",id:c.id},{method:et}=c;if(l.result=this._handleSynchronousMethods(c),void 0===l.result)throw Error(`Coinbase Wallet does not support calling ${et} synchronously without a callback. Please provide a callback parameter to call ${et} asynchronously.`);return l}_setAddresses(c,l){if(!Array.isArray(c))throw Error("addresses is not an array");let et=c.map(c=>(0,ey.ensureAddressString)(c));JSON.stringify(et)!==JSON.stringify(this._addresses)&&(!(this._addresses.length>0)||!1!==this.supportsAddressSwitching||l)&&(this._addresses=et,this.emit("accountsChanged",this._addresses),this._storage.setItem(eg.LOCAL_STORAGE_ADDRESSES_KEY,et.join(" ")))}_sendRequestAsync(c){return new Promise((l,et)=>{try{let eo=this._handleSynchronousMethods(c);if(void 0!==eo)return l({jsonrpc:"2.0",id:c.id,result:eo});let es=this._handleAsynchronousFilterMethods(c);if(void 0!==es){es.then(et=>l(Object.assign(Object.assign({},et),{id:c.id}))).catch(c=>et(c));return}let ec=this._handleSubscriptionMethods(c);if(void 0!==ec){ec.then(et=>l({jsonrpc:"2.0",id:c.id,result:et.result})).catch(c=>et(c));return}}catch(c){return et(c)}this._handleAsynchronousMethods(c).then(et=>et&&l(Object.assign(Object.assign({},et),{id:c.id}))).catch(c=>et(c))})}_sendMultipleRequestsAsync(c){return Promise.all(c.map(c=>this._sendRequestAsync(c)))}_handleSynchronousMethods(c){let{method:l}=c,et=c.params||[];switch(l){case eE.JSONRPCMethod.eth_accounts:return this._eth_accounts();case eE.JSONRPCMethod.eth_coinbase:return this._eth_coinbase();case eE.JSONRPCMethod.eth_uninstallFilter:return this._eth_uninstallFilter(et);case eE.JSONRPCMethod.net_version:return this._net_version();case eE.JSONRPCMethod.eth_chainId:return this._eth_chainId();default:return}}async _handleAsynchronousMethods(c){let{method:l}=c,et=c.params||[];switch(l){case eE.JSONRPCMethod.eth_requestAccounts:return this._eth_requestAccounts();case eE.JSONRPCMethod.eth_sign:return this._eth_sign(et);case eE.JSONRPCMethod.eth_ecRecover:return this._eth_ecRecover(et);case eE.JSONRPCMethod.personal_sign:return this._personal_sign(et);case eE.JSONRPCMethod.personal_ecRecover:return this._personal_ecRecover(et);case eE.JSONRPCMethod.eth_signTransaction:return this._eth_signTransaction(et);case eE.JSONRPCMethod.eth_sendRawTransaction:return this._eth_sendRawTransaction(et);case eE.JSONRPCMethod.eth_sendTransaction:return this._eth_sendTransaction(et);case eE.JSONRPCMethod.eth_signTypedData_v1:return this._eth_signTypedData_v1(et);case eE.JSONRPCMethod.eth_signTypedData_v2:return this._throwUnsupportedMethodError();case eE.JSONRPCMethod.eth_signTypedData_v3:return this._eth_signTypedData_v3(et);case eE.JSONRPCMethod.eth_signTypedData_v4:case eE.JSONRPCMethod.eth_signTypedData:return this._eth_signTypedData_v4(et);case eE.JSONRPCMethod.cbWallet_arbitrary:return this._cbwallet_arbitrary(et);case eE.JSONRPCMethod.wallet_addEthereumChain:return this._wallet_addEthereumChain(et);case eE.JSONRPCMethod.wallet_switchEthereumChain:return this._wallet_switchEthereumChain(et);case eE.JSONRPCMethod.wallet_watchAsset:return this._wallet_watchAsset(et)}let eo=await this.initializeRelay();return eo.makeEthereumJSONRPCRequest(c,this.jsonRpcUrl)}_handleAsynchronousFilterMethods(c){let{method:l}=c,et=c.params||[];switch(l){case eE.JSONRPCMethod.eth_newFilter:return this._eth_newFilter(et);case eE.JSONRPCMethod.eth_newBlockFilter:return this._eth_newBlockFilter();case eE.JSONRPCMethod.eth_newPendingTransactionFilter:return this._eth_newPendingTransactionFilter();case eE.JSONRPCMethod.eth_getFilterChanges:return this._eth_getFilterChanges(et);case eE.JSONRPCMethod.eth_getFilterLogs:return this._eth_getFilterLogs(et)}}_handleSubscriptionMethods(c){switch(c.method){case eE.JSONRPCMethod.eth_subscribe:case eE.JSONRPCMethod.eth_unsubscribe:return this._subscriptionManager.handleRequest(c)}}_isKnownAddress(c){try{let l=(0,ey.ensureAddressString)(c),et=this._addresses.map(c=>(0,ey.ensureAddressString)(c));return et.includes(l)}catch(c){}return!1}_ensureKnownAddress(c){var l;if(!this._isKnownAddress(c))throw null===(l=this.diagnostic)||void 0===l||l.log(ed.EVENTS.UNKNOWN_ADDRESS_ENCOUNTERED),Error("Unknown Ethereum address")}_prepareTransactionParams(c){let l=c.from?(0,ey.ensureAddressString)(c.from):this.selectedAddress;if(!l)throw Error("Ethereum address is unavailable");this._ensureKnownAddress(l);let et=c.to?(0,ey.ensureAddressString)(c.to):null,es=null!=c.value?(0,ey.ensureBN)(c.value):new el.default(0),ec=c.data?(0,ey.ensureBuffer)(c.data):eo.alloc(0),ed=null!=c.nonce?(0,ey.ensureIntNumber)(c.nonce):null,eh=null!=c.gasPrice?(0,ey.ensureBN)(c.gasPrice):null,ef=null!=c.maxFeePerGas?(0,ey.ensureBN)(c.maxFeePerGas):null,ep=null!=c.maxPriorityFeePerGas?(0,ey.ensureBN)(c.maxPriorityFeePerGas):null,eg=null!=c.gas?(0,ey.ensureBN)(c.gas):null,em=this.getChainId();return{fromAddress:l,toAddress:et,weiValue:es,data:ec,nonce:ed,gasPriceInWei:eh,maxFeePerGas:ef,maxPriorityFeePerGas:ep,gasLimit:eg,chainId:em}}_isAuthorized(){return this._addresses.length>0}_requireAuthorization(){if(!this._isAuthorized())throw eh.standardErrors.provider.unauthorized({})}_throwUnsupportedMethodError(){throw eh.standardErrors.provider.unsupportedMethod({})}async _signEthereumMessage(c,l,et,eo){this._ensureKnownAddress(l);try{let es=await this.initializeRelay(),ec=await es.signEthereumMessage(c,l,et,eo).promise;return{jsonrpc:"2.0",id:0,result:ec.result}}catch(c){if("string"==typeof c.message&&c.message.match(/(denied|rejected)/i))throw eh.standardErrors.provider.userRejectedRequest("User denied message signature");throw c}}async _ethereumAddressFromSignedMessage(c,l,et){let eo=await this.initializeRelay(),es=await eo.ethereumAddressFromSignedMessage(c,l,et).promise;return{jsonrpc:"2.0",id:0,result:es.result}}_eth_accounts(){return[...this._addresses]}_eth_coinbase(){return this.selectedAddress||null}_net_version(){return this.getChainId().toString(10)}_eth_chainId(){return(0,ey.hexStringFromIntNumber)(this.getChainId())}getChainId(){let c=this._storage.getItem(ex);if(!c)return(0,ey.ensureIntNumber)(this._chainIdFromOpts);let l=parseInt(c,10);return(0,ey.ensureIntNumber)(l)}async _eth_requestAccounts(){var c;let l;if(null===(c=this.diagnostic)||void 0===c||c.log(ed.EVENTS.ETH_ACCOUNTS_STATE,{method:"provider::_eth_requestAccounts",addresses_length:this._addresses.length,sessionIdHash:this._relay?ep.Session.hash(this._relay.session.id):void 0}),this._addresses.length>0)return Promise.resolve({jsonrpc:"2.0",id:0,result:this._addresses});try{let c=await this.initializeRelay();l=await c.requestEthereumAccounts().promise}catch(c){if("string"==typeof c.message&&c.message.match(/(denied|rejected)/i))throw eh.standardErrors.provider.userRejectedRequest("User denied account authorization");throw c}if(!l.result)throw Error("accounts received is empty");return this._setAddresses(l.result),this.isLedger||this.isCoinbaseBrowser||await this.switchEthereumChain(this.getChainId()),{jsonrpc:"2.0",id:0,result:this._addresses}}_eth_sign(c){this._requireAuthorization();let l=(0,ey.ensureAddressString)(c[0]),et=(0,ey.ensureBuffer)(c[1]);return this._signEthereumMessage(et,l,!1)}_eth_ecRecover(c){let l=(0,ey.ensureBuffer)(c[0]),et=(0,ey.ensureBuffer)(c[1]);return this._ethereumAddressFromSignedMessage(l,et,!1)}_personal_sign(c){this._requireAuthorization();let l=(0,ey.ensureBuffer)(c[0]),et=(0,ey.ensureAddressString)(c[1]);return this._signEthereumMessage(l,et,!0)}_personal_ecRecover(c){let l=(0,ey.ensureBuffer)(c[0]),et=(0,ey.ensureBuffer)(c[1]);return this._ethereumAddressFromSignedMessage(l,et,!0)}async _eth_signTransaction(c){this._requireAuthorization();let l=this._prepareTransactionParams(c[0]||{});try{let c=await this.initializeRelay(),et=await c.signEthereumTransaction(l).promise;return{jsonrpc:"2.0",id:0,result:et.result}}catch(c){if("string"==typeof c.message&&c.message.match(/(denied|rejected)/i))throw eh.standardErrors.provider.userRejectedRequest("User denied transaction signature");throw c}}async _eth_sendRawTransaction(c){let l=(0,ey.ensureBuffer)(c[0]),et=await this.initializeRelay(),eo=await et.submitEthereumTransaction(l,this.getChainId()).promise;return{jsonrpc:"2.0",id:0,result:eo.result}}async _eth_sendTransaction(c){this._requireAuthorization();let l=this._prepareTransactionParams(c[0]||{});try{let c=await this.initializeRelay(),et=await c.signAndSubmitEthereumTransaction(l).promise;return{jsonrpc:"2.0",id:0,result:et.result}}catch(c){if("string"==typeof c.message&&c.message.match(/(denied|rejected)/i))throw eh.standardErrors.provider.userRejectedRequest("User denied transaction signature");throw c}}async _eth_signTypedData_v1(c){this._requireAuthorization();let l=(0,ey.ensureParsedJSONObject)(c[0]),et=(0,ey.ensureAddressString)(c[1]);this._ensureKnownAddress(et);let eo=e_.default.hashForSignTypedDataLegacy({data:l}),es=JSON.stringify(l,null,2);return this._signEthereumMessage(eo,et,!1,es)}async _eth_signTypedData_v3(c){this._requireAuthorization();let l=(0,ey.ensureAddressString)(c[0]),et=(0,ey.ensureParsedJSONObject)(c[1]);this._ensureKnownAddress(l);let eo=e_.default.hashForSignTypedData_v3({data:et}),es=JSON.stringify(et,null,2);return this._signEthereumMessage(eo,l,!1,es)}async _eth_signTypedData_v4(c){this._requireAuthorization();let l=(0,ey.ensureAddressString)(c[0]),et=(0,ey.ensureParsedJSONObject)(c[1]);this._ensureKnownAddress(l);let eo=e_.default.hashForSignTypedData_v4({data:et}),es=JSON.stringify(et,null,2);return this._signEthereumMessage(eo,l,!1,es)}async _cbwallet_arbitrary(c){let l=c[0],et=c[1];if("string"!=typeof et)throw Error("parameter must be a string");if("object"!=typeof l||null===l)throw Error("parameter must be an object");let eo=await this.genericRequest(l,et);return{jsonrpc:"2.0",id:0,result:eo}}async _wallet_addEthereumChain(c){var l,et,eo,es;let ec=c[0];if((null===(l=ec.rpcUrls)||void 0===l?void 0:l.length)===0)return{jsonrpc:"2.0",id:0,error:{code:2,message:"please pass in at least 1 rpcUrl"}};if(!ec.chainName||""===ec.chainName.trim())throw eh.standardErrors.rpc.invalidParams("chainName is a required field");if(!ec.nativeCurrency)throw eh.standardErrors.rpc.invalidParams("nativeCurrency is a required field");let el=parseInt(ec.chainId,16),ed=await this.addEthereumChain(el,null!==(et=ec.rpcUrls)&&void 0!==et?et:[],null!==(eo=ec.blockExplorerUrls)&&void 0!==eo?eo:[],ec.chainName,null!==(es=ec.iconUrls)&&void 0!==es?es:[],ec.nativeCurrency);return ed?{jsonrpc:"2.0",id:0,result:null}:{jsonrpc:"2.0",id:0,error:{code:2,message:"unable to add ethereum chain"}}}async _wallet_switchEthereumChain(c){let l=c[0];return await this.switchEthereumChain(parseInt(l.chainId,16)),{jsonrpc:"2.0",id:0,result:null}}async _wallet_watchAsset(c){let l=Array.isArray(c)?c[0]:c;if(!l.type)throw eh.standardErrors.rpc.invalidParams("Type is required");if((null==l?void 0:l.type)!=="ERC20")throw eh.standardErrors.rpc.invalidParams(`Asset of type '${l.type}' is not supported`);if(!(null==l?void 0:l.options))throw eh.standardErrors.rpc.invalidParams("Options are required");if(!(null==l?void 0:l.options.address))throw eh.standardErrors.rpc.invalidParams("Address is required");let et=this.getChainId(),{address:eo,symbol:es,image:ec,decimals:el}=l.options,ed=await this.watchAsset(l.type,eo,es,el,ec,et);return{jsonrpc:"2.0",id:0,result:ed}}_eth_uninstallFilter(c){let l=(0,ey.ensureHexString)(c[0]);return this._filterPolyfill.uninstallFilter(l)}async _eth_newFilter(c){let l=c[0],et=await this._filterPolyfill.newFilter(l);return{jsonrpc:"2.0",id:0,result:et}}async _eth_newBlockFilter(){let c=await this._filterPolyfill.newBlockFilter();return{jsonrpc:"2.0",id:0,result:c}}async _eth_newPendingTransactionFilter(){let c=await this._filterPolyfill.newPendingTransactionFilter();return{jsonrpc:"2.0",id:0,result:c}}_eth_getFilterChanges(c){let l=(0,ey.ensureHexString)(c[0]);return this._filterPolyfill.getFilterChanges(l)}_eth_getFilterLogs(c){let l=(0,ey.ensureHexString)(c[0]);return this._filterPolyfill.getFilterLogs(l)}initializeRelay(){return this._relay?Promise.resolve(this._relay):this._relayProvider().then(c=>(c.setAccountsCallback((c,l)=>this._setAddresses(c,l)),c.setChainCallback((c,l)=>{this.updateProviderInfo(l,parseInt(c,10))}),c.setDappDefaultChainCallback(this._chainIdFromOpts),this._relay=c,c))}};l.CoinbaseWalletProvider=CoinbaseWalletProvider},61532:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.filterFromParam=l.FilterPolyfill=void 0;let eo=et(73156),es=et(59656),ec={jsonrpc:"2.0",id:0};function filterFromParam(c){return{fromBlock:intBlockHeightFromHexBlockHeight(c.fromBlock),toBlock:intBlockHeightFromHexBlockHeight(c.toBlock),addresses:void 0===c.address?null:Array.isArray(c.address)?c.address:[c.address],topics:c.topics||[]}}function paramFromFilter(c){let l={fromBlock:hexBlockHeightFromIntBlockHeight(c.fromBlock),toBlock:hexBlockHeightFromIntBlockHeight(c.toBlock),topics:c.topics};return null!==c.addresses&&(l.address=c.addresses),l}function intBlockHeightFromHexBlockHeight(c){if(void 0===c||"latest"===c||"pending"===c)return"latest";if("earliest"===c)return(0,eo.IntNumber)(0);if((0,es.isHexString)(c))return(0,es.intNumberFromHexString)(c);throw Error(`Invalid block option: ${String(c)}`)}function hexBlockHeightFromIntBlockHeight(c){return"latest"===c?c:(0,es.hexStringFromIntNumber)(c)}function filterNotFoundError(){return Object.assign(Object.assign({},ec),{error:{code:-32e3,message:"filter not found"}})}function emptyResult(){return Object.assign(Object.assign({},ec),{result:[]})}l.FilterPolyfill=class{constructor(c){this.logFilters=new Map,this.blockFilters=new Set,this.pendingTransactionFilters=new Set,this.cursors=new Map,this.timeouts=new Map,this.nextFilterId=(0,eo.IntNumber)(1),this.provider=c}async newFilter(c){let l=filterFromParam(c),et=this.makeFilterId(),eo=await this.setInitialCursorPosition(et,l.fromBlock);return console.log(`Installing new log filter(${et}):`,l,"initial cursor position:",eo),this.logFilters.set(et,l),this.setFilterTimeout(et),(0,es.hexStringFromIntNumber)(et)}async newBlockFilter(){let c=this.makeFilterId(),l=await this.setInitialCursorPosition(c,"latest");return console.log(`Installing new block filter (${c}) with initial cursor position:`,l),this.blockFilters.add(c),this.setFilterTimeout(c),(0,es.hexStringFromIntNumber)(c)}async newPendingTransactionFilter(){let c=this.makeFilterId(),l=await this.setInitialCursorPosition(c,"latest");return console.log(`Installing new block filter (${c}) with initial cursor position:`,l),this.pendingTransactionFilters.add(c),this.setFilterTimeout(c),(0,es.hexStringFromIntNumber)(c)}uninstallFilter(c){let l=(0,es.intNumberFromHexString)(c);return console.log(`Uninstalling filter (${l})`),this.deleteFilter(l),!0}getFilterChanges(c){let l=(0,es.intNumberFromHexString)(c);return(this.timeouts.has(l)&&this.setFilterTimeout(l),this.logFilters.has(l))?this.getLogFilterChanges(l):this.blockFilters.has(l)?this.getBlockFilterChanges(l):this.pendingTransactionFilters.has(l)?this.getPendingTransactionFilterChanges(l):Promise.resolve(filterNotFoundError())}async getFilterLogs(c){let l=(0,es.intNumberFromHexString)(c),et=this.logFilters.get(l);return et?this.sendAsyncPromise(Object.assign(Object.assign({},ec),{method:"eth_getLogs",params:[paramFromFilter(et)]})):filterNotFoundError()}makeFilterId(){return(0,eo.IntNumber)(++this.nextFilterId)}sendAsyncPromise(c){return new Promise((l,et)=>{this.provider.sendAsync(c,(c,eo)=>c?et(c):Array.isArray(eo)||null==eo?et(Error(`unexpected response received: ${JSON.stringify(eo)}`)):void l(eo))})}deleteFilter(c){console.log(`Deleting filter (${c})`),this.logFilters.delete(c),this.blockFilters.delete(c),this.pendingTransactionFilters.delete(c),this.cursors.delete(c),this.timeouts.delete(c)}async getLogFilterChanges(c){let l=this.logFilters.get(c),et=this.cursors.get(c);if(!et||!l)return filterNotFoundError();let el=await this.getCurrentBlockHeight(),ed="latest"===l.toBlock?el:l.toBlock;if(et>el||et>l.toBlock)return emptyResult();console.log(`Fetching logs from ${et} to ${ed} for filter ${c}`);let eh=await this.sendAsyncPromise(Object.assign(Object.assign({},ec),{method:"eth_getLogs",params:[paramFromFilter(Object.assign(Object.assign({},l),{fromBlock:et,toBlock:ed}))]}));if(Array.isArray(eh.result)){let l=eh.result.map(c=>(0,es.intNumberFromHexString)(c.blockNumber||"0x0")),ec=Math.max(...l);if(ec&&ec>et){let l=(0,eo.IntNumber)(ec+1);console.log(`Moving cursor position for filter (${c}) from ${et} to ${l}`),this.cursors.set(c,l)}}return eh}async getBlockFilterChanges(c){let l=this.cursors.get(c);if(!l)return filterNotFoundError();let et=await this.getCurrentBlockHeight();if(l>et)return emptyResult();console.log(`Fetching blocks from ${l} to ${et} for filter (${c})`);let el=(await Promise.all((0,es.range)(l,et+1).map(c=>this.getBlockHashByNumber((0,eo.IntNumber)(c))))).filter(c=>!!c),ed=(0,eo.IntNumber)(l+el.length);return console.log(`Moving cursor position for filter (${c}) from ${l} to ${ed}`),this.cursors.set(c,ed),Object.assign(Object.assign({},ec),{result:el})}async getPendingTransactionFilterChanges(c){return Promise.resolve(emptyResult())}async setInitialCursorPosition(c,l){let et=await this.getCurrentBlockHeight(),eo="number"==typeof l&&l>et?l:et;return this.cursors.set(c,eo),eo}setFilterTimeout(c){let l=this.timeouts.get(c);l&&window.clearTimeout(l);let et=window.setTimeout(()=>{console.log(`Filter (${c}) timed out`),this.deleteFilter(c)},3e5);this.timeouts.set(c,et)}async getCurrentBlockHeight(){let{result:c}=await this.sendAsyncPromise(Object.assign(Object.assign({},ec),{method:"eth_blockNumber",params:[]}));return(0,es.intNumberFromHexString)((0,es.ensureHexString)(c))}async getBlockHashByNumber(c){let l=await this.sendAsyncPromise(Object.assign(Object.assign({},ec),{method:"eth_getBlockByNumber",params:[(0,es.hexStringFromIntNumber)(c),!1]}));return l.result&&"string"==typeof l.result.hash?(0,es.ensureHexString)(l.result.hash):null}},l.filterFromParam=filterFromParam},65505:function(c,l){"use strict";var et;Object.defineProperty(l,"__esModule",{value:!0}),l.JSONRPCMethod=void 0,(et=l.JSONRPCMethod||(l.JSONRPCMethod={})).eth_accounts="eth_accounts",et.eth_coinbase="eth_coinbase",et.net_version="net_version",et.eth_chainId="eth_chainId",et.eth_uninstallFilter="eth_uninstallFilter",et.eth_requestAccounts="eth_requestAccounts",et.eth_sign="eth_sign",et.eth_ecRecover="eth_ecRecover",et.personal_sign="personal_sign",et.personal_ecRecover="personal_ecRecover",et.eth_signTransaction="eth_signTransaction",et.eth_sendRawTransaction="eth_sendRawTransaction",et.eth_sendTransaction="eth_sendTransaction",et.eth_signTypedData_v1="eth_signTypedData_v1",et.eth_signTypedData_v2="eth_signTypedData_v2",et.eth_signTypedData_v3="eth_signTypedData_v3",et.eth_signTypedData_v4="eth_signTypedData_v4",et.eth_signTypedData="eth_signTypedData",et.cbWallet_arbitrary="walletlink_arbitrary",et.wallet_addEthereumChain="wallet_addEthereumChain",et.wallet_switchEthereumChain="wallet_switchEthereumChain",et.wallet_watchAsset="wallet_watchAsset",et.eth_subscribe="eth_subscribe",et.eth_unsubscribe="eth_unsubscribe",et.eth_newFilter="eth_newFilter",et.eth_newBlockFilter="eth_newBlockFilter",et.eth_newPendingTransactionFilter="eth_newPendingTransactionFilter",et.eth_getFilterChanges="eth_getFilterChanges",et.eth_getFilterLogs="eth_getFilterLogs"},81217:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.MobileRelayUI=void 0;let eo=et(97430);l.MobileRelayUI=class{constructor(c){this.attached=!1,this.darkMode=!1,this.openedWindow=null,this.useLocationMethod=!1,this.redirectDialog=new eo.RedirectDialog,this.darkMode=c.darkMode}attach(){if(this.attached)throw Error("Coinbase Wallet SDK UI is already attached");this.redirectDialog.attach(),this.attached=!0}closeOpenedWindow(){var c;null===(c=this.openedWindow)||void 0===c||c.close(),this.openedWindow=null}setUseLocationMethod(c){this.useLocationMethod=c}redirectToCoinbaseWallet(c){let l=new URL("https://go.cb-w.com/walletlink");if(l.searchParams.append("redirect_url",window.location.href),c&&l.searchParams.append("wl_url",c),this.useLocationMethod){window.location.href=l.href;return}this.openedWindow=window.open(l.href,"cbw-opener"),this.openedWindow&&setTimeout(()=>this.closeOpenedWindow(),5e3)}openCoinbaseWalletDeeplink(c){this.redirectDialog.present({title:"Redirecting to Coinbase Wallet...",buttonText:"Open",darkMode:this.darkMode,onButtonClick:()=>{this.redirectToCoinbaseWallet(c)}}),setTimeout(()=>{this.redirectToCoinbaseWallet(c)},99)}showConnecting(c){return()=>{this.closeOpenedWindow(),this.redirectDialog.clear()}}hideRequestEthereumAccounts(){this.closeOpenedWindow(),this.redirectDialog.clear()}requestEthereumAccounts(c){}addEthereumChain(c){}watchAsset(c){}selectProvider(c){}switchEthereumChain(c){}signEthereumMessage(c){}signEthereumTransaction(c){}submitEthereumTransaction(c){}ethereumAddressFromSignedMessage(c){}reloadUI(){}setStandalone(c){}setAppSrc(c){}setConnectDisabled(c){}inlineAccountsResponse(){return!1}inlineAddEthereumChain(c){return!1}inlineWatchAsset(){return!1}inlineSwitchEthereumChain(){return!1}isStandalone(){return!1}}},60125:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.SubscriptionManager=void 0;let eo=et(2704),es=et(55117),noop=()=>{};l.SubscriptionManager=class{constructor(c){let l=new eo.PollingBlockTracker({provider:c,pollingInterval:15e3,setSkipCacheFlag:!0}),{events:et,middleware:ec}=es({blockTracker:l,provider:c});this.events=et,this.subscriptionMiddleware=ec}async handleRequest(c){let l={};return await this.subscriptionMiddleware(c,l,noop,noop),l}destroy(){this.subscriptionMiddleware.destroy()}}},50312:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.WalletLinkRelayUI=void 0;let eo=et(49598),es=et(91715),ec=et(97302);l.WalletLinkRelayUI=class{constructor(c){this.standalone=null,this.attached=!1,this.appSrc=null,this.snackbar=new es.Snackbar({darkMode:c.darkMode}),this.linkFlow=new eo.LinkFlow({darkMode:c.darkMode,version:c.version,sessionId:c.session.id,sessionSecret:c.session.secret,linkAPIUrl:c.linkAPIUrl,connected$:c.connected$,chainId$:c.chainId$,isParentConnection:!1})}attach(){if(this.attached)throw Error("Coinbase Wallet SDK UI is already attached");let c=document.documentElement,l=document.createElement("div");l.className="-cbwsdk-css-reset",c.appendChild(l),this.linkFlow.attach(l),this.snackbar.attach(l),this.attached=!0,(0,ec.injectCssReset)()}setConnectDisabled(c){this.linkFlow.setConnectDisabled(c)}addEthereumChain(c){}watchAsset(c){}switchEthereumChain(c){}requestEthereumAccounts(c){this.linkFlow.open({onCancel:c.onCancel})}hideRequestEthereumAccounts(){this.linkFlow.close()}signEthereumMessage(c){}signEthereumTransaction(c){}submitEthereumTransaction(c){}ethereumAddressFromSignedMessage(c){}showConnecting(c){let l;return l=c.isUnlinkedErrorState?{autoExpand:!0,message:"Connection lost",appSrc:this.appSrc,menuItems:[{isRed:!1,info:"Reset connection",svgWidth:"10",svgHeight:"11",path:"M5.00008 0.96875C6.73133 0.96875 8.23758 1.94375 9.00008 3.375L10.0001 2.375V5.5H9.53133H7.96883H6.87508L7.80633 4.56875C7.41258 3.3875 6.31258 2.53125 5.00008 2.53125C3.76258 2.53125 2.70633 3.2875 2.25633 4.36875L0.812576 3.76875C1.50008 2.125 3.11258 0.96875 5.00008 0.96875ZM2.19375 6.43125C2.5875 7.6125 3.6875 8.46875 5 8.46875C6.2375 8.46875 7.29375 7.7125 7.74375 6.63125L9.1875 7.23125C8.5 8.875 6.8875 10.0312 5 10.0312C3.26875 10.0312 1.7625 9.05625 1 7.625L0 8.625V5.5H0.46875H2.03125H3.125L2.19375 6.43125Z",defaultFillRule:"evenodd",defaultClipRule:"evenodd",onClick:c.onResetConnection}]}:{message:"Confirm on phone",appSrc:this.appSrc,menuItems:[{isRed:!0,info:"Cancel transaction",svgWidth:"11",svgHeight:"11",path:"M10.3711 1.52346L9.21775 0.370117L5.37109 4.21022L1.52444 0.370117L0.371094 1.52346L4.2112 5.37012L0.371094 9.21677L1.52444 10.3701L5.37109 6.53001L9.21775 10.3701L10.3711 9.21677L6.53099 5.37012L10.3711 1.52346Z",defaultFillRule:"inherit",defaultClipRule:"inherit",onClick:c.onCancel},{isRed:!1,info:"Reset connection",svgWidth:"10",svgHeight:"11",path:"M5.00008 0.96875C6.73133 0.96875 8.23758 1.94375 9.00008 3.375L10.0001 2.375V5.5H9.53133H7.96883H6.87508L7.80633 4.56875C7.41258 3.3875 6.31258 2.53125 5.00008 2.53125C3.76258 2.53125 2.70633 3.2875 2.25633 4.36875L0.812576 3.76875C1.50008 2.125 3.11258 0.96875 5.00008 0.96875ZM2.19375 6.43125C2.5875 7.6125 3.6875 8.46875 5 8.46875C6.2375 8.46875 7.29375 7.7125 7.74375 6.63125L9.1875 7.23125C8.5 8.875 6.8875 10.0312 5 10.0312C3.26875 10.0312 1.7625 9.05625 1 7.625L0 8.625V5.5H0.46875H2.03125H3.125L2.19375 6.43125Z",defaultFillRule:"evenodd",defaultClipRule:"evenodd",onClick:c.onResetConnection}]},this.snackbar.presentItem(l)}setAppSrc(c){this.appSrc=c}reloadUI(){document.location.reload()}inlineAccountsResponse(){return!1}inlineAddEthereumChain(c){return!1}inlineWatchAsset(){return!1}inlineSwitchEthereumChain(){return!1}setStandalone(c){this.standalone=c}isStandalone(){var c;return null!==(c=this.standalone)&&void 0!==c&&c}}},84607:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.MobileRelay=void 0;let eo=et(81217),es=et(59656),ec=et(7278),el=et(90263);let MobileRelay=class MobileRelay extends ec.WalletLinkRelay{constructor(c){var l;super(c),this._enableMobileWalletLink=null!==(l=c.enableMobileWalletLink)&&void 0!==l&&l}requestEthereumAccounts(){return this._enableMobileWalletLink?super.requestEthereumAccounts():{promise:new Promise(()=>{let c=(0,es.getLocation)();c.href=`https://www.coinbase.com/connect-dapp?uri=${encodeURIComponent(c.href)}`}),cancel:()=>{}}}publishWeb3RequestEvent(c,l){if(super.publishWeb3RequestEvent(c,l),!(this._enableMobileWalletLink&&this.ui instanceof eo.MobileRelayUI))return;let et=!1;switch(l.method){case el.Web3Method.requestEthereumAccounts:case el.Web3Method.connectAndSignIn:et=!0,this.ui.openCoinbaseWalletDeeplink(this.getQRCodeUrl());break;case el.Web3Method.switchEthereumChain:return;default:et=!0,this.ui.openCoinbaseWalletDeeplink()}et&&window.addEventListener("blur",()=>{window.addEventListener("focus",()=>{this.connection.onceConnected$.subscribe(()=>{setTimeout(()=>{this.connection.checkUnseenEvents().catch(c=>console.error("Unable to check for unseen events",c))},250)})},{once:!0})},{once:!0})}handleWeb3ResponseMessage(c){super.handleWeb3ResponseMessage(c),this._enableMobileWalletLink&&this.ui instanceof eo.MobileRelayUI&&this.ui.closeOpenedWindow()}connectAndSignIn(c){if(!this._enableMobileWalletLink)throw Error("connectAndSignIn is supported only when enableMobileWalletLink is on");return this.sendRequest({method:el.Web3Method.connectAndSignIn,params:{appName:this.appName,appLogoUrl:this.appLogoUrl,domain:window.location.hostname,aud:window.location.href,version:"1",type:"eip4361",nonce:c.nonce,iat:new Date().toISOString(),chainId:`eip155:${this.dappDefaultChain}`,statement:c.statement,resources:c.resources}})}setUseLocationMethod(c){this.ui instanceof eo.MobileRelayUI&&this.ui.setUseLocationMethod(c)}};l.MobileRelay=MobileRelay},51514:function(c,l){"use strict";var et;Object.defineProperty(l,"__esModule",{value:!0}),l.RelayMessageType=void 0,(et=l.RelayMessageType||(l.RelayMessageType={})).SESSION_ID_REQUEST="SESSION_ID_REQUEST",et.SESSION_ID_RESPONSE="SESSION_ID_RESPONSE",et.LINKED="LINKED",et.UNLINKED="UNLINKED",et.WEB3_REQUEST="WEB3_REQUEST",et.WEB3_REQUEST_CANCELED="WEB3_REQUEST_CANCELED",et.WEB3_RESPONSE="WEB3_RESPONSE"},14677:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.Session=void 0;let eo=et(71114),es=et(59656),ec="session:id",el="session:secret",ed="session:linked";let Session=class Session{constructor(c,l,et,ec){this._storage=c,this._id=l||(0,es.randomBytesHex)(16),this._secret=et||(0,es.randomBytesHex)(32),this._key=new eo.sha256().update(`${this._id}, ${this._secret} WalletLink`).digest("hex"),this._linked=!!ec}static load(c){let l=c.getItem(ec),et=c.getItem(ed),eo=c.getItem(el);return l&&eo?new Session(c,l,eo,"1"===et):null}static hash(c){return new eo.sha256().update(c).digest("hex")}get id(){return this._id}get secret(){return this._secret}get key(){return this._key}get linked(){return this._linked}set linked(c){this._linked=c,this.persistLinked()}save(){return this._storage.setItem(ec,this._id),this._storage.setItem(el,this._secret),this.persistLinked(),this}persistLinked(){this._storage.setItem(ed,this._linked?"1":"0")}};l.Session=Session},7278:function(c,l,et){"use strict";var eo=this&&this.__createBinding||(Object.create?function(c,l,et,eo){void 0===eo&&(eo=et),Object.defineProperty(c,eo,{enumerable:!0,get:function(){return l[et]}})}:function(c,l,et,eo){void 0===eo&&(eo=et),c[eo]=l[et]}),es=this&&this.__setModuleDefault||(Object.create?function(c,l){Object.defineProperty(c,"default",{enumerable:!0,value:l})}:function(c,l){c.default=l}),ec=this&&this.__decorate||function(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el},el=this&&this.__importStar||function(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)"default"!==et&&Object.prototype.hasOwnProperty.call(c,et)&&eo(l,c,et);return es(l,c),l},ed=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.WalletLinkRelay=void 0;let eh=ed(et(18714)),ef=et(33664),ep=et(39254),eg=et(81371),em=et(74924),eb=et(77507),ey=et(73156),e_=et(59656),ew=el(et(82758)),eE=et(14677),eS=et(66452),ex=et(90263),ek=et(43517),eC=et(63578),eA=et(6787),eI=et(91609);let WalletLinkRelay=class WalletLinkRelay extends eS.WalletSDKRelayAbstract{constructor(c){var l;super(),this.accountsCallback=null,this.chainCallback=null,this.dappDefaultChainSubject=new ef.BehaviorSubject(1),this.dappDefaultChain=1,this.appName="",this.appLogoUrl=null,this.subscriptions=new ef.Subscription,this.linkAPIUrl=c.linkAPIUrl,this.storage=c.storage,this.options=c;let{session:et,ui:eo,connection:es}=this.subscribe();if(this._session=et,this.connection=es,this.relayEventManager=c.relayEventManager,c.diagnosticLogger&&c.eventListener)throw Error("Can't have both eventListener and diagnosticLogger options, use only diagnosticLogger");c.eventListener?this.diagnostic={log:c.eventListener.onEvent}:this.diagnostic=c.diagnosticLogger,this._reloadOnDisconnect=null===(l=c.reloadOnDisconnect)||void 0===l||l,this.ui=eo}subscribe(){this.subscriptions.add(this.dappDefaultChainSubject.subscribe(c=>{this.dappDefaultChain!==c&&(this.dappDefaultChain=c)}));let c=eE.Session.load(this.storage)||new eE.Session(this.storage).save(),l=new em.WalletLinkConnection(c.id,c.key,this.linkAPIUrl,this.diagnostic);this.subscriptions.add(l.sessionConfig$.subscribe({next:c=>{this.onSessionConfigChanged(c)},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"error while invoking session config callback"})}})),this.subscriptions.add(l.incomingEvent$.pipe((0,ep.filter)(c=>"Web3Response"===c.event)).subscribe({next:this.handleIncomingEvent})),this.subscriptions.add(l.linked$.pipe((0,ep.skip)(1),(0,ep.tap)(c=>{var l;this.isLinked=c;let et=this.storage.getItem(eS.LOCAL_STORAGE_ADDRESSES_KEY);if(c&&(this.session.linked=c),this.isUnlinkedErrorState=!1,et){let eo=et.split(" "),es="true"===this.storage.getItem("IsStandaloneSigning");if(""!==eo[0]&&!c&&this.session.linked&&!es){this.isUnlinkedErrorState=!0;let c=this.getSessionIdHash();null===(l=this.diagnostic)||void 0===l||l.log(eg.EVENTS.UNLINKED_ERROR_STATE,{sessionIdHash:c})}}})).subscribe()),this.subscriptions.add(l.sessionConfig$.pipe((0,ep.filter)(c=>!!c.metadata&&"1"===c.metadata.__destroyed)).subscribe(()=>{var c;let et=l.isDestroyed;return null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.METADATA_DESTROYED,{alreadyDestroyed:et,sessionIdHash:this.getSessionIdHash()}),this.resetAndReload()})),this.subscriptions.add(l.sessionConfig$.pipe((0,ep.filter)(c=>c.metadata&&void 0!==c.metadata.WalletUsername)).pipe((0,ep.mergeMap)(l=>ew.decrypt(l.metadata.WalletUsername,c.secret))).subscribe({next:c=>{this.storage.setItem(eS.WALLET_USER_NAME_KEY,c)},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"username"})}})),this.subscriptions.add(l.sessionConfig$.pipe((0,ep.filter)(c=>c.metadata&&void 0!==c.metadata.AppVersion)).pipe((0,ep.mergeMap)(l=>ew.decrypt(l.metadata.AppVersion,c.secret))).subscribe({next:c=>{this.storage.setItem(eS.APP_VERSION_KEY,c)},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"appversion"})}})),this.subscriptions.add(l.sessionConfig$.pipe((0,ep.filter)(c=>c.metadata&&void 0!==c.metadata.ChainId&&void 0!==c.metadata.JsonRpcUrl)).pipe((0,ep.mergeMap)(l=>(0,ef.zip)(ew.decrypt(l.metadata.ChainId,c.secret),ew.decrypt(l.metadata.JsonRpcUrl,c.secret)))).pipe((0,ep.distinctUntilChanged)()).subscribe({next:([c,l])=>{this.chainCallback&&this.chainCallback(c,l)},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"chainId|jsonRpcUrl"})}})),this.subscriptions.add(l.sessionConfig$.pipe((0,ep.filter)(c=>c.metadata&&void 0!==c.metadata.EthereumAddress)).pipe((0,ep.mergeMap)(l=>ew.decrypt(l.metadata.EthereumAddress,c.secret))).subscribe({next:c=>{this.accountsCallback&&this.accountsCallback([c]),WalletLinkRelay.accountRequestCallbackIds.size>0&&(Array.from(WalletLinkRelay.accountRequestCallbackIds.values()).forEach(l=>{let et=(0,eI.Web3ResponseMessage)({id:l,response:(0,eA.RequestEthereumAccountsResponse)([c])});this.invokeCallback(Object.assign(Object.assign({},et),{id:l}))}),WalletLinkRelay.accountRequestCallbackIds.clear())},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"selectedAddress"})}})),this.subscriptions.add(l.sessionConfig$.pipe((0,ep.filter)(c=>c.metadata&&void 0!==c.metadata.AppSrc)).pipe((0,ep.mergeMap)(l=>ew.decrypt(l.metadata.AppSrc,c.secret))).subscribe({next:c=>{this.ui.setAppSrc(c)},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"appSrc"})}}));let et=this.options.uiConstructor({linkAPIUrl:this.options.linkAPIUrl,version:this.options.version,darkMode:this.options.darkMode,session:c,connected$:l.connected$,chainId$:this.dappDefaultChainSubject});return l.connect(),{session:c,ui:et,connection:l}}attachUI(){this.ui.attach()}resetAndReload(){this.connection.setSessionMetadata("__destroyed","1").pipe((0,ep.timeout)(1e3),(0,ep.catchError)(c=>(0,ef.of)(null))).subscribe(c=>{var l,et,eo;let es=this.ui.isStandalone();try{this.subscriptions.unsubscribe()}catch(c){null===(l=this.diagnostic)||void 0===l||l.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error unsubscribing"})}null===(et=this.diagnostic)||void 0===et||et.log(eg.EVENTS.SESSION_STATE_CHANGE,{method:"relay::resetAndReload",sessionMetadataChange:"__destroyed, 1",sessionIdHash:this.getSessionIdHash()}),this.connection.destroy();let ec=eE.Session.load(this.storage);if((null==ec?void 0:ec.id)===this._session.id?this.storage.clear():ec&&(null===(eo=this.diagnostic)||void 0===eo||eo.log(eg.EVENTS.SKIPPED_CLEARING_SESSION,{sessionIdHash:this.getSessionIdHash(),storedSessionIdHash:eE.Session.hash(ec.id)})),this._reloadOnDisconnect){this.ui.reloadUI();return}this.accountsCallback&&this.accountsCallback([],!0),this.subscriptions=new ef.Subscription;let{session:el,ui:ed,connection:eh}=this.subscribe();this._session=el,this.connection=eh,this.ui=ed,es&&this.ui.setStandalone&&this.ui.setStandalone(!0),this.attachUI()},c=>{var l;null===(l=this.diagnostic)||void 0===l||l.log(eg.EVENTS.FAILURE,{method:"relay::resetAndReload",message:`failed to reset and reload with ${c}`,sessionIdHash:this.getSessionIdHash()})})}setAppInfo(c,l){this.appName=c,this.appLogoUrl=l}getStorageItem(c){return this.storage.getItem(c)}get session(){return this._session}setStorageItem(c,l){this.storage.setItem(c,l)}signEthereumMessage(c,l,et,eo){return this.sendRequest({method:ex.Web3Method.signEthereumMessage,params:{message:(0,e_.hexStringFromBuffer)(c,!0),address:l,addPrefix:et,typedDataJson:eo||null}})}ethereumAddressFromSignedMessage(c,l,et){return this.sendRequest({method:ex.Web3Method.ethereumAddressFromSignedMessage,params:{message:(0,e_.hexStringFromBuffer)(c,!0),signature:(0,e_.hexStringFromBuffer)(l,!0),addPrefix:et}})}signEthereumTransaction(c){return this.sendRequest({method:ex.Web3Method.signEthereumTransaction,params:{fromAddress:c.fromAddress,toAddress:c.toAddress,weiValue:(0,e_.bigIntStringFromBN)(c.weiValue),data:(0,e_.hexStringFromBuffer)(c.data,!0),nonce:c.nonce,gasPriceInWei:c.gasPriceInWei?(0,e_.bigIntStringFromBN)(c.gasPriceInWei):null,maxFeePerGas:c.gasPriceInWei?(0,e_.bigIntStringFromBN)(c.gasPriceInWei):null,maxPriorityFeePerGas:c.gasPriceInWei?(0,e_.bigIntStringFromBN)(c.gasPriceInWei):null,gasLimit:c.gasLimit?(0,e_.bigIntStringFromBN)(c.gasLimit):null,chainId:c.chainId,shouldSubmit:!1}})}signAndSubmitEthereumTransaction(c){return this.sendRequest({method:ex.Web3Method.signEthereumTransaction,params:{fromAddress:c.fromAddress,toAddress:c.toAddress,weiValue:(0,e_.bigIntStringFromBN)(c.weiValue),data:(0,e_.hexStringFromBuffer)(c.data,!0),nonce:c.nonce,gasPriceInWei:c.gasPriceInWei?(0,e_.bigIntStringFromBN)(c.gasPriceInWei):null,maxFeePerGas:c.maxFeePerGas?(0,e_.bigIntStringFromBN)(c.maxFeePerGas):null,maxPriorityFeePerGas:c.maxPriorityFeePerGas?(0,e_.bigIntStringFromBN)(c.maxPriorityFeePerGas):null,gasLimit:c.gasLimit?(0,e_.bigIntStringFromBN)(c.gasLimit):null,chainId:c.chainId,shouldSubmit:!0}})}submitEthereumTransaction(c,l){return this.sendRequest({method:ex.Web3Method.submitEthereumTransaction,params:{signedTransaction:(0,e_.hexStringFromBuffer)(c,!0),chainId:l}})}scanQRCode(c){return this.sendRequest({method:ex.Web3Method.scanQRCode,params:{regExp:c}})}getQRCodeUrl(){return(0,e_.createQrUrl)(this._session.id,this._session.secret,this.linkAPIUrl,!1,this.options.version,this.dappDefaultChain)}genericRequest(c,l){return this.sendRequest({method:ex.Web3Method.generic,params:{action:l,data:c}})}sendGenericMessage(c){return this.sendRequest(c)}sendRequest(c){let l=null,et=(0,e_.randomBytesHex)(8),cancel=eo=>{this.publishWeb3RequestCanceledEvent(et),this.handleErrorResponse(et,c.method,eo),null==l||l()},eo=new Promise((eo,es)=>{this.ui.isStandalone()||(l=this.ui.showConnecting({isUnlinkedErrorState:this.isUnlinkedErrorState,onCancel:cancel,onResetConnection:this.resetAndReload})),this.relayEventManager.callbacks.set(et,c=>{if(null==l||l(),c.errorMessage)return es(Error(c.errorMessage));eo(c)}),this.ui.isStandalone()?this.sendRequestStandalone(et,c):this.publishWeb3RequestEvent(et,c)});return{promise:eo,cancel}}setConnectDisabled(c){this.ui.setConnectDisabled(c)}setAccountsCallback(c){this.accountsCallback=c}setChainCallback(c){this.chainCallback=c}setDappDefaultChainCallback(c){this.dappDefaultChainSubject.next(c)}publishWeb3RequestEvent(c,l){var et;let eo=(0,eC.Web3RequestMessage)({id:c,request:l}),es=eE.Session.load(this.storage);null===(et=this.diagnostic)||void 0===et||et.log(eg.EVENTS.WEB3_REQUEST,{eventId:eo.id,method:`relay::${eo.request.method}`,sessionIdHash:this.getSessionIdHash(),storedSessionIdHash:es?eE.Session.hash(es.id):"",isSessionMismatched:((null==es?void 0:es.id)!==this._session.id).toString()}),this.subscriptions.add(this.publishEvent("Web3Request",eo,!0).subscribe({next:c=>{var l;null===(l=this.diagnostic)||void 0===l||l.log(eg.EVENTS.WEB3_REQUEST_PUBLISHED,{eventId:eo.id,method:`relay::${eo.request.method}`,sessionIdHash:this.getSessionIdHash(),storedSessionIdHash:es?eE.Session.hash(es.id):"",isSessionMismatched:((null==es?void 0:es.id)!==this._session.id).toString()})},error:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eo.id,response:{method:eo.request.method,errorMessage:c.message}}))}}))}publishWeb3RequestCanceledEvent(c){let l=(0,ek.Web3RequestCanceledMessage)(c);this.subscriptions.add(this.publishEvent("Web3RequestCanceled",l,!1).subscribe())}publishEvent(c,l,et){let eo=this.session.secret;return new ef.Observable(c=>{ew.encrypt(JSON.stringify(Object.assign(Object.assign({},l),{origin:location.origin,relaySource:window.coinbaseWalletExtension?"injected_sdk":"sdk"})),eo).then(l=>{c.next(l),c.complete()})}).pipe((0,ep.mergeMap)(l=>this.connection.publishEvent(c,l,et)))}handleIncomingEvent(c){try{this.subscriptions.add((0,ef.from)(ew.decrypt(c.data,this.session.secret)).pipe((0,ep.map)(c=>JSON.parse(c))).subscribe({next:c=>{let l=(0,eI.isWeb3ResponseMessage)(c)?c:null;l&&this.handleWeb3ResponseMessage(l)},error:()=>{var c;null===(c=this.diagnostic)||void 0===c||c.log(eg.EVENTS.GENERAL_ERROR,{message:"Had error decrypting",value:"incomingEvent"})}}))}catch(c){return}}handleWeb3ResponseMessage(c){var l;let{response:et}=c;if(null===(l=this.diagnostic)||void 0===l||l.log(eg.EVENTS.WEB3_RESPONSE,{eventId:c.id,method:`relay::${et.method}`,sessionIdHash:this.getSessionIdHash()}),(0,eA.isRequestEthereumAccountsResponse)(et)){WalletLinkRelay.accountRequestCallbackIds.forEach(l=>this.invokeCallback(Object.assign(Object.assign({},c),{id:l}))),WalletLinkRelay.accountRequestCallbackIds.clear();return}this.invokeCallback(c)}handleErrorResponse(c,l,et,eo){var es;let ec=null!==(es=null==et?void 0:et.message)&&void 0!==es?es:(0,eb.standardErrorMessage)(eo);this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:c,response:{method:l,errorMessage:ec,errorCode:eo}}))}invokeCallback(c){let l=this.relayEventManager.callbacks.get(c.id);l&&(l(c.response),this.relayEventManager.callbacks.delete(c.id))}requestEthereumAccounts(){let c={method:ex.Web3Method.requestEthereumAccounts,params:{appName:this.appName,appLogoUrl:this.appLogoUrl||null}},l=(0,e_.randomBytesHex)(8),cancel=et=>{this.publishWeb3RequestCanceledEvent(l),this.handleErrorResponse(l,c.method,et)},et=new Promise((et,eo)=>{if(this.relayEventManager.callbacks.set(l,c=>{if(this.ui.hideRequestEthereumAccounts(),c.errorMessage)return eo(Error(c.errorMessage));et(c)}),this.ui.inlineAccountsResponse())this.ui.requestEthereumAccounts({onCancel:cancel,onAccounts:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:l,response:(0,eA.RequestEthereumAccountsResponse)(c)}))}});else{let c=eb.standardErrors.provider.userRejectedRequest("User denied account authorization");this.ui.requestEthereumAccounts({onCancel:()=>cancel(c)})}WalletLinkRelay.accountRequestCallbackIds.add(l),this.ui.inlineAccountsResponse()||this.ui.isStandalone()||this.publishWeb3RequestEvent(l,c)});return{promise:et,cancel}}selectProvider(c){let l={method:ex.Web3Method.selectProvider,params:{providerOptions:c}},et=(0,e_.randomBytesHex)(8),eo=new Promise((l,eo)=>{this.relayEventManager.callbacks.set(et,c=>{if(c.errorMessage)return eo(Error(c.errorMessage));l(c)}),this.ui.selectProvider&&this.ui.selectProvider({onApprove:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:et,response:(0,eA.SelectProviderResponse)(c)}))},onCancel:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:et,response:(0,eA.SelectProviderResponse)(ey.ProviderType.Unselected)}))},providerOptions:c})});return{cancel:c=>{this.publishWeb3RequestCanceledEvent(et),this.handleErrorResponse(et,l.method,c)},promise:eo}}watchAsset(c,l,et,eo,es,ec){let el={method:ex.Web3Method.watchAsset,params:{type:c,options:{address:l,symbol:et,decimals:eo,image:es},chainId:ec}},ed=null,eh=(0,e_.randomBytesHex)(8),cancel=c=>{this.publishWeb3RequestCanceledEvent(eh),this.handleErrorResponse(eh,el.method,c),null==ed||ed()};this.ui.inlineWatchAsset()||(ed=this.ui.showConnecting({isUnlinkedErrorState:this.isUnlinkedErrorState,onCancel:cancel,onResetConnection:this.resetAndReload}));let ef=new Promise((ef,ep)=>{this.relayEventManager.callbacks.set(eh,c=>{if(null==ed||ed(),c.errorMessage)return ep(Error(c.errorMessage));ef(c)}),this.ui.inlineWatchAsset()&&this.ui.watchAsset({onApprove:()=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eh,response:(0,eA.WatchAssetReponse)(!0)}))},onCancel:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eh,response:(0,eA.WatchAssetReponse)(!1)}))},type:c,address:l,symbol:et,decimals:eo,image:es,chainId:ec}),this.ui.inlineWatchAsset()||this.ui.isStandalone()||this.publishWeb3RequestEvent(eh,el)});return{cancel,promise:ef}}addEthereumChain(c,l,et,eo,es,ec){let el={method:ex.Web3Method.addEthereumChain,params:{chainId:c,rpcUrls:l,blockExplorerUrls:eo,chainName:es,iconUrls:et,nativeCurrency:ec}},ed=null,eh=(0,e_.randomBytesHex)(8),cancel=c=>{this.publishWeb3RequestCanceledEvent(eh),this.handleErrorResponse(eh,el.method,c),null==ed||ed()};this.ui.inlineAddEthereumChain(c)||(ed=this.ui.showConnecting({isUnlinkedErrorState:this.isUnlinkedErrorState,onCancel:cancel,onResetConnection:this.resetAndReload}));let ef=new Promise((l,et)=>{this.relayEventManager.callbacks.set(eh,c=>{if(null==ed||ed(),c.errorMessage)return et(Error(c.errorMessage));l(c)}),this.ui.inlineAddEthereumChain(c)&&this.ui.addEthereumChain({onCancel:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eh,response:(0,eA.AddEthereumChainResponse)({isApproved:!1,rpcUrl:""})}))},onApprove:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eh,response:(0,eA.AddEthereumChainResponse)({isApproved:!0,rpcUrl:c})}))},chainId:el.params.chainId,rpcUrls:el.params.rpcUrls,blockExplorerUrls:el.params.blockExplorerUrls,chainName:el.params.chainName,iconUrls:el.params.iconUrls,nativeCurrency:el.params.nativeCurrency}),this.ui.inlineAddEthereumChain(c)||this.ui.isStandalone()||this.publishWeb3RequestEvent(eh,el)});return{promise:ef,cancel}}switchEthereumChain(c,l){let et={method:ex.Web3Method.switchEthereumChain,params:Object.assign({chainId:c},{address:l})},eo=(0,e_.randomBytesHex)(8),es=new Promise((l,es)=>{this.relayEventManager.callbacks.set(eo,c=>(0,eA.isErrorResponse)(c)&&c.errorCode?es(eb.standardErrors.provider.custom({code:c.errorCode,message:"Unrecognized chain ID. Try adding the chain using addEthereumChain first."})):c.errorMessage?es(Error(c.errorMessage)):void l(c)),this.ui.switchEthereumChain({onCancel:l=>{var et;if(l){let es=null!==(et=(0,eb.getErrorCode)(l))&&void 0!==et?et:eb.standardErrorCodes.provider.unsupportedChain;this.handleErrorResponse(eo,ex.Web3Method.switchEthereumChain,l instanceof Error?l:eb.standardErrors.provider.unsupportedChain(c),es)}else this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eo,response:(0,eA.SwitchEthereumChainResponse)({isApproved:!1,rpcUrl:""})}))},onApprove:c=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:eo,response:(0,eA.SwitchEthereumChainResponse)({isApproved:!0,rpcUrl:c})}))},chainId:et.params.chainId,address:et.params.address}),this.ui.inlineSwitchEthereumChain()||this.ui.isStandalone()||this.publishWeb3RequestEvent(eo,et)});return{promise:es,cancel:c=>{this.publishWeb3RequestCanceledEvent(eo),this.handleErrorResponse(eo,et.method,c)}}}inlineAddEthereumChain(c){return this.ui.inlineAddEthereumChain(c)}getSessionIdHash(){return eE.Session.hash(this._session.id)}sendRequestStandalone(c,l){let _cancel=et=>{this.handleErrorResponse(c,l.method,et)},onSuccess=l=>{this.handleWeb3ResponseMessage((0,eI.Web3ResponseMessage)({id:c,response:l}))};switch(l.method){case ex.Web3Method.signEthereumMessage:this.ui.signEthereumMessage({request:l,onSuccess,onCancel:_cancel});break;case ex.Web3Method.signEthereumTransaction:this.ui.signEthereumTransaction({request:l,onSuccess,onCancel:_cancel});break;case ex.Web3Method.submitEthereumTransaction:this.ui.submitEthereumTransaction({request:l,onSuccess,onCancel:_cancel});break;case ex.Web3Method.ethereumAddressFromSignedMessage:this.ui.ethereumAddressFromSignedMessage({request:l,onSuccess});break;default:_cancel()}}onSessionConfigChanged(c){}};WalletLinkRelay.accountRequestCallbackIds=new Set,ec([eh.default],WalletLinkRelay.prototype,"resetAndReload",null),ec([eh.default],WalletLinkRelay.prototype,"handleIncomingEvent",null),l.WalletLinkRelay=WalletLinkRelay},66452:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.WalletSDKRelayAbstract=l.APP_VERSION_KEY=l.LOCAL_STORAGE_ADDRESSES_KEY=l.WALLET_USER_NAME_KEY=void 0;let eo=et(77507);l.WALLET_USER_NAME_KEY="walletUsername",l.LOCAL_STORAGE_ADDRESSES_KEY="Addresses",l.APP_VERSION_KEY="AppVersion",l.WalletSDKRelayAbstract=class{async makeEthereumJSONRPCRequest(c,l){if(!l)throw Error("Error: No jsonRpcUrl provided");return window.fetch(l,{method:"POST",body:JSON.stringify(c),mode:"cors",headers:{"Content-Type":"application/json"}}).then(c=>c.json()).then(l=>{if(!l)throw eo.standardErrors.rpc.parse({});let{error:et}=l;if(et)throw(0,eo.serializeError)(et,c.method);return l})}}},91029:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.WalletSDKRelayEventManager=void 0;let eo=et(59656);l.WalletSDKRelayEventManager=class{constructor(){this._nextRequestId=0,this.callbacks=new Map}makeRequestId(){this._nextRequestId=(this._nextRequestId+1)%2147483647;let c=this._nextRequestId,l=(0,eo.prepend0x)(c.toString(16)),et=this.callbacks.get(l);return et&&this.callbacks.delete(l),c}}},90263:function(c,l){"use strict";var et;Object.defineProperty(l,"__esModule",{value:!0}),l.Web3Method=void 0,(et=l.Web3Method||(l.Web3Method={})).requestEthereumAccounts="requestEthereumAccounts",et.signEthereumMessage="signEthereumMessage",et.signEthereumTransaction="signEthereumTransaction",et.submitEthereumTransaction="submitEthereumTransaction",et.ethereumAddressFromSignedMessage="ethereumAddressFromSignedMessage",et.scanQRCode="scanQRCode",et.generic="generic",et.childRequestEthereumAccounts="childRequestEthereumAccounts",et.addEthereumChain="addEthereumChain",et.switchEthereumChain="switchEthereumChain",et.makeEthereumJSONRPCRequest="makeEthereumJSONRPCRequest",et.watchAsset="watchAsset",et.selectProvider="selectProvider",et.connectAndSignIn="connectAndSignIn"},43517:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.Web3RequestCanceledMessage=void 0;let eo=et(51514);l.Web3RequestCanceledMessage=function(c){return{type:eo.RelayMessageType.WEB3_REQUEST_CANCELED,id:c}}},63578:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.Web3RequestMessage=void 0;let eo=et(51514);l.Web3RequestMessage=function(c){return Object.assign({type:eo.RelayMessageType.WEB3_REQUEST},c)}},6787:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.EthereumAddressFromSignedMessageResponse=l.SubmitEthereumTransactionResponse=l.SignEthereumTransactionResponse=l.SignEthereumMessageResponse=l.isRequestEthereumAccountsResponse=l.SelectProviderResponse=l.WatchAssetReponse=l.RequestEthereumAccountsResponse=l.SwitchEthereumChainResponse=l.AddEthereumChainResponse=l.isErrorResponse=void 0;let eo=et(90263);l.isErrorResponse=function(c){return(null==c?void 0:c.method)!==void 0&&(null==c?void 0:c.errorMessage)!==void 0},l.AddEthereumChainResponse=function(c){return{method:eo.Web3Method.addEthereumChain,result:c}},l.SwitchEthereumChainResponse=function(c){return{method:eo.Web3Method.switchEthereumChain,result:c}},l.RequestEthereumAccountsResponse=function(c){return{method:eo.Web3Method.requestEthereumAccounts,result:c}},l.WatchAssetReponse=function(c){return{method:eo.Web3Method.watchAsset,result:c}},l.SelectProviderResponse=function(c){return{method:eo.Web3Method.selectProvider,result:c}},l.isRequestEthereumAccountsResponse=function(c){return c&&c.method===eo.Web3Method.requestEthereumAccounts},l.SignEthereumMessageResponse=function(c){return{method:eo.Web3Method.signEthereumMessage,result:c}},l.SignEthereumTransactionResponse=function(c){return{method:eo.Web3Method.signEthereumTransaction,result:c}},l.SubmitEthereumTransactionResponse=function(c){return{method:eo.Web3Method.submitEthereumTransaction,result:c}},l.EthereumAddressFromSignedMessageResponse=function(c){return{method:eo.Web3Method.ethereumAddressFromSignedMessage,result:c}}},91609:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.isWeb3ResponseMessage=l.Web3ResponseMessage=void 0;let eo=et(51514);l.Web3ResponseMessage=function(c){return Object.assign({type:eo.RelayMessageType.WEB3_RESPONSE},c)},l.isWeb3ResponseMessage=function(c){return c&&c.type===eo.RelayMessageType.WEB3_RESPONSE}},82758:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.decrypt=l.encrypt=void 0;let eo=et(59656);async function encrypt(c,l){if(64!==l.length)throw Error("secret must be 256 bits");let et=crypto.getRandomValues(new Uint8Array(12)),es=await crypto.subtle.importKey("raw",(0,eo.hexStringToUint8Array)(l),{name:"aes-gcm"},!1,["encrypt","decrypt"]),ec=new TextEncoder,el=await window.crypto.subtle.encrypt({name:"AES-GCM",iv:et},es,ec.encode(c)),ed=el.slice(el.byteLength-16),eh=el.slice(0,el.byteLength-16),ef=new Uint8Array(ed),ep=new Uint8Array(eh),eg=new Uint8Array([...et,...ef,...ep]);return(0,eo.uint8ArrayToHex)(eg)}l.encrypt=encrypt,l.decrypt=function(c,l){if(64!==l.length)throw Error("secret must be 256 bits");return new Promise((et,es)=>{!async function(){let ec=await crypto.subtle.importKey("raw",(0,eo.hexStringToUint8Array)(l),{name:"aes-gcm"},!1,["encrypt","decrypt"]),el=(0,eo.hexStringToUint8Array)(c),ed=el.slice(0,12),eh=el.slice(12,28),ef=el.slice(28),ep=new Uint8Array([...ef,...eh]),eg={name:"AES-GCM",iv:new Uint8Array(ed)};try{let c=await window.crypto.subtle.decrypt(eg,ec,ep),l=new TextDecoder;et(l.decode(c))}catch(c){es(c)}}()})}},73156:function(c,l){"use strict";var et;function OpaqueType(){return c=>c}Object.defineProperty(l,"__esModule",{value:!0}),l.ProviderType=l.RegExpString=l.IntNumber=l.BigIntString=l.AddressString=l.HexString=l.OpaqueType=void 0,l.OpaqueType=OpaqueType,l.HexString=OpaqueType(),l.AddressString=OpaqueType(),l.BigIntString=OpaqueType(),l.IntNumber=function(c){return Math.floor(c)},l.RegExpString=OpaqueType(),(et=l.ProviderType||(l.ProviderType={})).CoinbaseWallet="CoinbaseWallet",et.MetaMask="MetaMask",et.Unselected=""},59656:function(c,l,et){"use strict";var eo=et(67133).Buffer,es=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.isMobileWeb=l.getLocation=l.isInIFrame=l.createQrUrl=l.getFavicon=l.range=l.isBigNumber=l.ensureParsedJSONObject=l.ensureBN=l.ensureRegExpString=l.ensureIntNumber=l.ensureBuffer=l.ensureAddressString=l.ensureEvenLengthHexString=l.ensureHexString=l.isHexString=l.prepend0x=l.strip0x=l.has0xPrefix=l.hexStringFromIntNumber=l.intNumberFromHexString=l.bigIntStringFromBN=l.hexStringFromBuffer=l.hexStringToUint8Array=l.uint8ArrayToHex=l.randomBytesHex=void 0;let ec=es(et(56662)),el=et(76548),ed=et(77507),eh=et(73156),ef=/^[0-9]*$/,ep=/^[a-f0-9]*$/;function uint8ArrayToHex(c){return[...c].map(c=>c.toString(16).padStart(2,"0")).join("")}function has0xPrefix(c){return c.startsWith("0x")||c.startsWith("0X")}function strip0x(c){return has0xPrefix(c)?c.slice(2):c}function prepend0x(c){return has0xPrefix(c)?"0x"+c.slice(2):"0x"+c}function isHexString(c){if("string"!=typeof c)return!1;let l=strip0x(c).toLowerCase();return ep.test(l)}function ensureHexString(c,l=!1){if("string"==typeof c){let et=strip0x(c).toLowerCase();if(ep.test(et))return(0,eh.HexString)(l?"0x"+et:et)}throw ed.standardErrors.rpc.invalidParams(`"${String(c)}" is not a hexadecimal string`)}function ensureEvenLengthHexString(c,l=!1){let et=ensureHexString(c,!1);return et.length%2==1&&(et=(0,eh.HexString)("0"+et)),l?(0,eh.HexString)("0x"+et):et}function ensureIntNumber(c){if("number"==typeof c&&Number.isInteger(c))return(0,eh.IntNumber)(c);if("string"==typeof c){if(ef.test(c))return(0,eh.IntNumber)(Number(c));if(isHexString(c))return(0,eh.IntNumber)(new ec.default(ensureEvenLengthHexString(c,!1),16).toNumber())}throw ed.standardErrors.rpc.invalidParams(`Not an integer: ${String(c)}`)}function isBigNumber(c){if(null==c||"function"!=typeof c.constructor)return!1;let{constructor:l}=c;return"function"==typeof l.config&&"number"==typeof l.EUCLID}function isInIFrame(){try{return null!==window.frameElement}catch(c){return!1}}l.randomBytesHex=function(c){return uint8ArrayToHex(crypto.getRandomValues(new Uint8Array(c)))},l.uint8ArrayToHex=uint8ArrayToHex,l.hexStringToUint8Array=function(c){return new Uint8Array(c.match(/.{1,2}/g).map(c=>parseInt(c,16)))},l.hexStringFromBuffer=function(c,l=!1){let et=c.toString("hex");return(0,eh.HexString)(l?"0x"+et:et)},l.bigIntStringFromBN=function(c){return(0,eh.BigIntString)(c.toString(10))},l.intNumberFromHexString=function(c){return(0,eh.IntNumber)(new ec.default(ensureEvenLengthHexString(c,!1),16).toNumber())},l.hexStringFromIntNumber=function(c){return(0,eh.HexString)("0x"+new ec.default(c).toString(16))},l.has0xPrefix=has0xPrefix,l.strip0x=strip0x,l.prepend0x=prepend0x,l.isHexString=isHexString,l.ensureHexString=ensureHexString,l.ensureEvenLengthHexString=ensureEvenLengthHexString,l.ensureAddressString=function(c){if("string"==typeof c){let l=strip0x(c).toLowerCase();if(isHexString(l)&&40===l.length)return(0,eh.AddressString)(prepend0x(l))}throw ed.standardErrors.rpc.invalidParams(`Invalid Ethereum address: ${String(c)}`)},l.ensureBuffer=function(c){if(eo.isBuffer(c))return c;if("string"==typeof c){if(!isHexString(c))return eo.from(c,"utf8");{let l=ensureEvenLengthHexString(c,!1);return eo.from(l,"hex")}}throw ed.standardErrors.rpc.invalidParams(`Not binary data: ${String(c)}`)},l.ensureIntNumber=ensureIntNumber,l.ensureRegExpString=function(c){if(c instanceof RegExp)return(0,eh.RegExpString)(c.toString());throw ed.standardErrors.rpc.invalidParams(`Not a RegExp: ${String(c)}`)},l.ensureBN=function(c){if(null!==c&&(ec.default.isBN(c)||isBigNumber(c)))return new ec.default(c.toString(10),10);if("number"==typeof c)return new ec.default(ensureIntNumber(c));if("string"==typeof c){if(ef.test(c))return new ec.default(c,10);if(isHexString(c))return new ec.default(ensureEvenLengthHexString(c,!1),16)}throw ed.standardErrors.rpc.invalidParams(`Not an integer: ${String(c)}`)},l.ensureParsedJSONObject=function(c){if("string"==typeof c)return JSON.parse(c);if("object"==typeof c)return c;throw ed.standardErrors.rpc.invalidParams(`Not a JSON string or an object: ${String(c)}`)},l.isBigNumber=isBigNumber,l.range=function(c,l){return Array.from({length:l-c},(l,et)=>c+et)},l.getFavicon=function(){let c=document.querySelector('link[sizes="192x192"]')||document.querySelector('link[sizes="180x180"]')||document.querySelector('link[rel="icon"]')||document.querySelector('link[rel="shortcut icon"]'),{protocol:l,host:et}=document.location,eo=c?c.getAttribute("href"):null;return!eo||eo.startsWith("javascript:")?null:eo.startsWith("http://")||eo.startsWith("https://")||eo.startsWith("data:")?eo:eo.startsWith("//")?l+eo:`${l}//${et}${eo}`},l.createQrUrl=function(c,l,et,eo,es,ec){let ed=(0,el.stringify)({[eo?"parent-id":"id"]:c,secret:l,server:et,v:es,chainId:ec}),eh=`${et}/#/link?${ed}`;return eh},l.isInIFrame=isInIFrame,l.getLocation=function(){try{if(isInIFrame()&&window.top)return window.top.location;return window.location}catch(c){return window.location}},l.isMobileWeb=function(){var c;return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(null===(c=null==window?void 0:window.navigator)||void 0===c?void 0:c.userAgent)}},5865:function(c,l,et){var eo=et(67133).Buffer;let es=et(59942),ec=et(56662);function elementaryName(c){if(c.startsWith("int["))return"int256"+c.slice(3);if("int"===c)return"int256";if(c.startsWith("uint["))return"uint256"+c.slice(4);if("uint"===c)return"uint256";if(c.startsWith("fixed["))return"fixed128x128"+c.slice(5);if("fixed"===c)return"fixed128x128";if(c.startsWith("ufixed["))return"ufixed128x128"+c.slice(6);else if("ufixed"===c)return"ufixed128x128";return c}function parseTypeN(c){return parseInt(/^\D+(\d+)$/.exec(c)[1],10)}function parseTypeNxM(c){var l=/^\D+(\d+)x(\d+)$/.exec(c);return[parseInt(l[1],10),parseInt(l[2],10)]}function parseTypeArray(c){var l=c.match(/(.*)\[(.*?)\]$/);return l?""===l[2]?"dynamic":parseInt(l[2],10):null}function parseNumber(c){var l=typeof c;if("string"===l)return es.isHexString(c)?new ec(es.stripHexPrefix(c),16):new ec(c,10);if("number"===l)return new ec(c);if(c.toArray)return c;throw Error("Argument is not a number")}function encodeSingle(c,l){if("address"===c)return encodeSingle("uint160",parseNumber(l));if("bool"===c)return encodeSingle("uint8",l?1:0);if("string"===c)return encodeSingle("bytes",new eo(l,"utf8"));if((ef=c).lastIndexOf("]")===ef.length-1){if(void 0===l.length)throw Error("Not an array?");if("dynamic"!==(et=parseTypeArray(c))&&0!==et&&l.length>et)throw Error("Elements exceed array size: "+et);for(eh in ed=[],c=c.slice(0,c.lastIndexOf("[")),"string"==typeof l&&(l=JSON.parse(l)),l)ed.push(encodeSingle(c,l[eh]));if("dynamic"===et){var et,el,ed,eh,ef,ep=encodeSingle("uint256",l.length);ed.unshift(ep)}return eo.concat(ed)}if("bytes"===c)return l=new eo(l),ed=eo.concat([encodeSingle("uint256",l.length),l]),l.length%32!=0&&(ed=eo.concat([ed,es.zeros(32-l.length%32)])),ed;if(c.startsWith("bytes")){if((et=parseTypeN(c))<1||et>32)throw Error("Invalid bytes width: "+et);return es.setLengthRight(l,32)}else if(c.startsWith("uint")){if((et=parseTypeN(c))%8||et<8||et>256)throw Error("Invalid uint width: "+et);if((el=parseNumber(l)).bitLength()>et)throw Error("Supplied uint exceeds width: "+et+" vs "+el.bitLength());if(el<0)throw Error("Supplied uint is negative");return el.toArrayLike(eo,"be",32)}else if(c.startsWith("int")){if((et=parseTypeN(c))%8||et<8||et>256)throw Error("Invalid int width: "+et);if((el=parseNumber(l)).bitLength()>et)throw Error("Supplied int exceeds width: "+et+" vs "+el.bitLength());return el.toTwos(256).toArrayLike(eo,"be",32)}else if(c.startsWith("ufixed")){if(et=parseTypeNxM(c),(el=parseNumber(l))<0)throw Error("Supplied ufixed is negative");return encodeSingle("uint256",el.mul(new ec(2).pow(new ec(et[1]))))}else if(c.startsWith("fixed"))return et=parseTypeNxM(c),encodeSingle("int256",parseNumber(l).mul(new ec(2).pow(new ec(et[1]))));throw Error("Unsupported or invalid type: "+c)}function solidityPack(c,l){if(c.length!==l.length)throw Error("Number of types are not matching the values");for(var et,ec,el=[],ed=0;ed32)throw Error("Invalid bytes width: "+et);el.push(es.setLengthRight(ef,et))}else if(eh.startsWith("uint")){if((et=parseTypeN(eh))%8||et<8||et>256)throw Error("Invalid uint width: "+et);if((ec=parseNumber(ef)).bitLength()>et)throw Error("Supplied uint exceeds width: "+et+" vs "+ec.bitLength());el.push(ec.toArrayLike(eo,"be",et/8))}else if(eh.startsWith("int")){if((et=parseTypeN(eh))%8||et<8||et>256)throw Error("Invalid int width: "+et);if((ec=parseNumber(ef)).bitLength()>et)throw Error("Supplied int exceeds width: "+et+" vs "+ec.bitLength());el.push(ec.toTwos(et).toArrayLike(eo,"be",et/8))}else throw Error("Unsupported or invalid type: "+eh)}return eo.concat(el)}c.exports={rawEncode:function(c,l){var et=[],es=[],ec=32*c.length;for(var el in c){var ed=elementaryName(c[el]),eh=encodeSingle(ed,l[el]);"string"===ed||"bytes"===ed||"dynamic"===parseTypeArray(ed)?(et.push(encodeSingle("uint256",ec)),es.push(eh),ec+=eh.length):et.push(eh)}return eo.concat(et.concat(es))},solidityPack,soliditySHA3:function(c,l){return es.keccak(solidityPack(c,l))}}},31880:function(c,l,et){var eo=et(67133).Buffer;let es=et(59942),ec=et(5865),el={type:"object",properties:{types:{type:"object",additionalProperties:{type:"array",items:{type:"object",properties:{name:{type:"string"},type:{type:"string"}},required:["name","type"]}}},primaryType:{type:"string"},domain:{type:"object"},message:{type:"object"}},required:["types","primaryType","domain","message"]},ed={encodeData(c,l,et,el=!0){let ed=["bytes32"],eh=[this.hashType(c,et)];if(el){let encodeField=(c,l,ed)=>{if(void 0!==et[l])return["bytes32",null==ed?"0x0000000000000000000000000000000000000000000000000000000000000000":es.keccak(this.encodeData(l,ed,et,el))];if(void 0===ed)throw Error(`missing value for field ${c} of type ${l}`);if("bytes"===l)return["bytes32",es.keccak(ed)];if("string"===l)return"string"==typeof ed&&(ed=eo.from(ed,"utf8")),["bytes32",es.keccak(ed)];if(l.lastIndexOf("]")===l.length-1){let et=l.slice(0,l.lastIndexOf("[")),eo=ed.map(l=>encodeField(c,et,l));return["bytes32",es.keccak(ec.rawEncode(eo.map(([c])=>c),eo.map(([,c])=>c)))]}return[l,ed]};for(let eo of et[c]){let[c,et]=encodeField(eo.name,eo.type,l[eo.name]);ed.push(c),eh.push(et)}}else for(let ec of et[c]){let c=l[ec.name];if(void 0!==c){if("bytes"===ec.type)ed.push("bytes32"),c=es.keccak(c),eh.push(c);else if("string"===ec.type)ed.push("bytes32"),"string"==typeof c&&(c=eo.from(c,"utf8")),c=es.keccak(c),eh.push(c);else if(void 0!==et[ec.type])ed.push("bytes32"),c=es.keccak(this.encodeData(ec.type,c,et,el)),eh.push(c);else if(ec.type.lastIndexOf("]")===ec.type.length-1)throw Error("Arrays currently unimplemented in encodeData");else ed.push(ec.type),eh.push(c)}}return ec.rawEncode(ed,eh)},encodeType(c,l){let et="",eo=this.findTypeDependencies(c,l).filter(l=>l!==c);for(let es of eo=[c].concat(eo.sort())){let c=l[es];if(!c)throw Error("No type definition specified: "+es);et+=es+"("+l[es].map(({name:c,type:l})=>l+" "+c).join(",")+")"}return et},findTypeDependencies(c,l,et=[]){if(c=c.match(/^\w*/)[0],et.includes(c)||void 0===l[c])return et;for(let eo of(et.push(c),l[c]))for(let c of this.findTypeDependencies(eo.type,l,et))et.includes(c)||et.push(c);return et},hashStruct(c,l,et,eo=!0){return es.keccak(this.encodeData(c,l,et,eo))},hashType(c,l){return es.keccak(this.encodeType(c,l))},sanitizeData(c){let l={};for(let et in el.properties)c[et]&&(l[et]=c[et]);return l.types&&(l.types=Object.assign({EIP712Domain:[]},l.types)),l},hash(c,l=!0){let et=this.sanitizeData(c),ec=[eo.from("1901","hex")];return ec.push(this.hashStruct("EIP712Domain",et.domain,et.types,l)),"EIP712Domain"!==et.primaryType&&ec.push(this.hashStruct(et.primaryType,et.message,et.types,l)),es.keccak(eo.concat(ec))}};c.exports={TYPED_MESSAGE_SCHEMA:el,TypedDataUtils:ed,hashForSignTypedDataLegacy:function(c){return function(c){let l=Error("Expect argument to be non-empty array");if("object"!=typeof c||!c.length)throw l;let et=c.map(function(c){return"bytes"===c.type?es.toBuffer(c.value):c.value}),eo=c.map(function(c){return c.type}),el=c.map(function(c){if(!c.name)throw l;return c.type+" "+c.name});return ec.soliditySHA3(["bytes32","bytes32"],[ec.soliditySHA3(Array(c.length).fill("string"),el),ec.soliditySHA3(eo,et)])}(c.data)},hashForSignTypedData_v3:function(c){return ed.hash(c.data,!1)},hashForSignTypedData_v4:function(c){return ed.hash(c.data)}}},59942:function(c,l,et){var eo=et(67133).Buffer;let es=et(26961),ec=et(56662);function zeros(c){return eo.allocUnsafe(c).fill(0)}function setLength(c,l,et){let eo=zeros(l);return(c=toBuffer(c),et)?c.length65536?(es[0]=240|(1835008&ec)>>>18,es[1]=128|(258048&ec)>>>12,es[2]=128|(4032&ec)>>>6,es[3]=128|63&ec):ec>2048?(es[0]=224|(61440&ec)>>>12,es[1]=128|(4032&ec)>>>6,es[2]=128|63&ec):ec>128?(es[0]=192|(1984&ec)>>>6,es[1]=128|63&ec):es[0]=ec,this.parsedData.push(es)}this.parsedData=Array.prototype.concat.apply([],this.parsedData),this.parsedData.length!=this.data.length&&(this.parsedData.unshift(191),this.parsedData.unshift(187),this.parsedData.unshift(239))}function QRCodeModel(c,l){this.typeNumber=c,this.errorCorrectLevel=l,this.modules=null,this.moduleCount=0,this.dataCache=null,this.dataList=[]}QR8bitByte.prototype={getLength:function(c){return this.parsedData.length},write:function(c){for(var l=0,et=this.parsedData.length;l=7&&this.setupTypeNumber(c),null==this.dataCache&&(this.dataCache=QRCodeModel.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,l)},setupPositionProbePattern:function(c,l){for(var et=-1;et<=7;et++)if(!(c+et<=-1)&&!(this.moduleCount<=c+et))for(var eo=-1;eo<=7;eo++)l+eo<=-1||this.moduleCount<=l+eo||(0<=et&&et<=6&&(0==eo||6==eo)||0<=eo&&eo<=6&&(0==et||6==et)||2<=et&&et<=4&&2<=eo&&eo<=4?this.modules[c+et][l+eo]=!0:this.modules[c+et][l+eo]=!1)},getBestMaskPattern:function(){for(var c=0,l=0,et=0;et<8;et++){this.makeImpl(!0,et);var eo=es.getLostPoint(this);(0==et||c>eo)&&(c=eo,l=et)}return l},createMovieClip:function(c,l,et){var eo=c.createEmptyMovieClip(l,et);this.make();for(var es=0;es>et&1)==1;this.modules[Math.floor(et/3)][et%3+this.moduleCount-8-3]=eo}for(var et=0;et<18;et++){var eo=!c&&(l>>et&1)==1;this.modules[et%3+this.moduleCount-8-3][Math.floor(et/3)]=eo}},setupTypeInfo:function(c,l){for(var et=this.errorCorrectLevel<<3|l,eo=es.getBCHTypeInfo(et),ec=0;ec<15;ec++){var el=!c&&(eo>>ec&1)==1;ec<6?this.modules[ec][8]=el:ec<8?this.modules[ec+1][8]=el:this.modules[this.moduleCount-15+ec][8]=el}for(var ec=0;ec<15;ec++){var el=!c&&(eo>>ec&1)==1;ec<8?this.modules[8][this.moduleCount-ec-1]=el:ec<9?this.modules[8][15-ec-1+1]=el:this.modules[8][15-ec-1]=el}this.modules[this.moduleCount-8][8]=!c},mapData:function(c,l){for(var et=-1,eo=this.moduleCount-1,ec=7,el=0,ed=this.moduleCount-1;ed>0;ed-=2)for(6==ed&&ed--;;){for(var eh=0;eh<2;eh++)if(null==this.modules[eo][ed-eh]){var ef=!1;el>>ec&1)==1),es.getMask(l,eo,ed-eh)&&(ef=!ef),this.modules[eo][ed-eh]=ef,-1==--ec&&(el++,ec=7)}if((eo+=et)<0||this.moduleCount<=eo){eo-=et,et=-et;break}}}},QRCodeModel.PAD0=236,QRCodeModel.PAD1=17,QRCodeModel.createData=function(c,l,et){for(var eo=QRRSBlock.getRSBlocks(c,l),ec=new QRBitBuffer,el=0;el8*eh)throw Error("code length overflow. ("+ec.getLengthInBits()+">"+8*eh+")");for(ec.getLengthInBits()+4<=8*eh&&ec.put(0,4);ec.getLengthInBits()%8!=0;)ec.putBit(!1);for(;!(ec.getLengthInBits()>=8*eh)&&(ec.put(QRCodeModel.PAD0,8),!(ec.getLengthInBits()>=8*eh));)ec.put(QRCodeModel.PAD1,8);return QRCodeModel.createBytes(ec,eo)},QRCodeModel.createBytes=function(c,l){for(var et=0,eo=0,ec=0,el=Array(l.length),ed=Array(l.length),eh=0;eh=0?eb.get(ey):0}}for(var e_=0,eg=0;eg=0;)l^=es.G15<=0;)l^=es.G18<>>=1;return l},getPatternPosition:function(c){return es.PATTERN_POSITION_TABLE[c-1]},getMask:function(c,l,et){switch(c){case eo.PATTERN000:return(l+et)%2==0;case eo.PATTERN001:return l%2==0;case eo.PATTERN010:return et%3==0;case eo.PATTERN011:return(l+et)%3==0;case eo.PATTERN100:return(Math.floor(l/2)+Math.floor(et/3))%2==0;case eo.PATTERN101:return l*et%2+l*et%3==0;case eo.PATTERN110:return(l*et%2+l*et%3)%2==0;case eo.PATTERN111:return(l*et%3+(l+et)%2)%2==0;default:throw Error("bad maskPattern:"+c)}},getErrorCorrectPolynomial:function(c){for(var l=new QRPolynomial([1],0),et=0;et5&&(et+=3+ec-5)}for(var eo=0;eo=256;)c-=255;return ec.EXP_TABLE[c]},EXP_TABLE:Array(256),LOG_TABLE:Array(256)},el=0;el<8;el++)ec.EXP_TABLE[el]=1<>>7-c%8&1)==1},put:function(c,l){for(var et=0;et>>l-et-1&1)==1)},getLengthInBits:function(){return this.length},putBit:function(c){var l=Math.floor(this.length/8);this.buffer.length<=l&&this.buffer.push(0),c&&(this.buffer[l]|=128>>>this.length%8),this.length++}};var ed=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]];function QRCode(c){if(this.options={padding:4,width:256,height:256,typeNumber:4,color:"#000000",background:"#ffffff",ecl:"M",image:{svg:"",width:0,height:0}},"string"==typeof c&&(c={content:c}),c)for(var l in c)this.options[l]=c[l];if("string"!=typeof this.options.content)throw Error("Expected 'content' as string!");if(0===this.options.content.length)throw Error("Expected 'content' to be non-empty!");if(!(this.options.padding>=0))throw Error("Expected 'padding' value to be non-negative!");if(!(this.options.width>0)||!(this.options.height>0))throw Error("Expected 'width' or 'height' value to be higher than zero!");var eo=this.options.content,es=function(c,l){for(var et,eo=(et=encodeURI(c).toString().replace(/\%[0-9a-fA-F]{2}/g,"a")).length+(et.length!=c?3:0),es=1,ec=0,el=0,eh=ed.length;el<=eh;el++){var ef=ed[el];if(!ef)throw Error("Content too long: expected "+ec+" but got "+eo);switch(l){case"L":ec=ef[0];break;case"M":ec=ef[1];break;case"Q":ec=ef[2];break;case"H":ec=ef[3];break;default:throw Error("Unknwon error correction level: "+l)}if(eo<=ec)break;es++}if(es>ed.length)throw Error("Content too long");return es}(eo,this.options.ecl),ec=function(c){switch(c){case"L":return et.L;case"M":return et.M;case"Q":return et.Q;case"H":return et.H;default:throw Error("Unknwon error correction level: "+c)}}(this.options.ecl);this.qrcode=new QRCodeModel(es,ec),this.qrcode.addData(eo),this.qrcode.make()}QRCode.prototype.svg=function(c){var l=this.options||{},et=this.qrcode.modules;void 0===c&&(c={container:l.container||"svg"});for(var eo=void 0===l.pretty||!!l.pretty,es=eo?" ":"",ec=eo?"\r\n":"",el=l.width,ed=l.height,eh=et.length,ef=el/(eh+2*l.padding),ep=ed/(eh+2*l.padding),eg=void 0!==l.join&&!!l.join,em=void 0!==l.swap&&!!l.swap,eb=void 0===l.xmlDeclaration||!!l.xmlDeclaration,ey=void 0!==l.predefined&&!!l.predefined,e_=ey?es+''+ec:"",ew=es+''+ec,eE="",eS="",ex=0;ex'+ec:eE+=es+''+ec}eg&&(eE=es+'');let eO="";if(void 0!==this.options.image&&this.options.image.svg){let c=el*this.options.image.width/100,l=ed*this.options.image.height/100;eO+=``+(this.options.image.svg+ec)+""}var eT="";switch(c.container){case"svg":eb&&(eT+=''+ec),eT+=''+ec+(e_+ew+eE)+eO+"";break;case"svg-viewbox":eb&&(eT+=''+ec),eT+=''+ec+(e_+ew+eE)+eO+"";break;case"g":eT+=''+ec+(e_+ew+eE)+eO+"";break;default:eT+=(e_+ew+eE+eO).replace(/^\s+/,"")}return eT},c.exports=QRCode},94579:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.LIB_VERSION=void 0,l.LIB_VERSION="3.8.0-beta.3"},56335:function(c,l,et){"use strict";et.d(l,{Z:function(){return createCache}});var eo=function(){function StyleSheet(c){var l=this;this._insertTag=function(c){var et;et=0===l.tags.length?l.insertionPoint?l.insertionPoint.nextSibling:l.prepend?l.container.firstChild:l.before:l.tags[l.tags.length-1].nextSibling,l.container.insertBefore(c,et),l.tags.push(c)},this.isSpeedy=void 0===c.speedy||c.speedy,this.tags=[],this.ctr=0,this.nonce=c.nonce,this.key=c.key,this.container=c.container,this.prepend=c.prepend,this.insertionPoint=c.insertionPoint,this.before=null}var c=StyleSheet.prototype;return c.hydrate=function(c){c.forEach(this._insertTag)},c.insert=function(c){if(this.ctr%(this.isSpeedy?65e3:1)==0){var l;this._insertTag(((l=document.createElement("style")).setAttribute("data-emotion",this.key),void 0!==this.nonce&&l.setAttribute("nonce",this.nonce),l.appendChild(document.createTextNode("")),l.setAttribute("data-s",""),l))}var et=this.tags[this.tags.length-1];if(this.isSpeedy){var eo=function(c){if(c.sheet)return c.sheet;for(var l=0;l0?eb[ex]+" "+ek:Utility_replace(ek,/&\f/g,eb[ex])).trim())&&(ef[eS++]=eC);return node(c,l,et,0===ec?eE:eh,ef,ep,eg)}function declaration(c,l,et,eo){return node(c,l,et,eS,Utility_substr(c,0,eo),Utility_substr(c,eo+1,-1),eo)}var identifierWithPointTracking=function(c,l,et){for(var eo=0,es=0;eo=es,es=peek(),38===eo&&12===es&&(l[et]=1),!token(es);)next();return Utility_substr(em,c,ep)},toRules=function(c,l){var et=-1,eo=44;do switch(token(eo)){case 0:38===eo&&12===peek()&&(l[et]=1),c[et]+=identifierWithPointTracking(ep-1,l,et);break;case 2:c[et]+=delimit(eo);break;case 4:if(44===eo){c[++et]=58===peek()?"&\f":"",l[et]=c[et].length;break}default:c[et]+=ec(eo)}while(eo=next());return c},getRules=function(c,l){var et;return et=toRules(alloc(c),l),em="",et},ek=new WeakMap,compat=function(c){if("rule"===c.type&&c.parent&&!(c.length<1)){for(var l=c.value,et=c.parent,eo=c.column===et.column&&c.line===et.line;"rule"!==et.type;)if(!(et=et.parent))return;if((1!==c.props.length||58===l.charCodeAt(0)||ek.get(et))&&!eo){ek.set(c,!0);for(var es=[],ec=getRules(l,es),el=et.props,ed=0,eh=0;ed-1&&!c.return)switch(c.type){case eS:c.return=function emotion_cache_browser_esm_prefix(c,l){switch(45^Utility_charat(c,0)?(((l<<2^Utility_charat(c,0))<<2^Utility_charat(c,1))<<2^Utility_charat(c,2))<<2^Utility_charat(c,3):0){case 5103:return e_+"print-"+c+c;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return e_+c+c;case 5349:case 4246:case 4810:case 6968:case 2756:return e_+c+ey+c+eb+c+c;case 6828:case 4268:return e_+c+eb+c+c;case 6165:return e_+c+eb+"flex-"+c+c;case 5187:return e_+c+Utility_replace(c,/(\w+).+(:[^]+)/,e_+"box-$1$2"+eb+"flex-$1$2")+c;case 5443:return e_+c+eb+"flex-item-"+Utility_replace(c,/flex-|-self/,"")+c;case 4675:return e_+c+eb+"flex-line-pack"+Utility_replace(c,/align-content|flex-|-self/,"")+c;case 5548:return e_+c+eb+Utility_replace(c,"shrink","negative")+c;case 5292:return e_+c+eb+Utility_replace(c,"basis","preferred-size")+c;case 6060:return e_+"box-"+Utility_replace(c,"-grow","")+e_+c+eb+Utility_replace(c,"grow","positive")+c;case 4554:return e_+Utility_replace(c,/([^-])(transform)/g,"$1"+e_+"$2")+c;case 6187:return Utility_replace(Utility_replace(Utility_replace(c,/(zoom-|grab)/,e_+"$1"),/(image-set)/,e_+"$1"),c,"")+c;case 5495:case 3959:return Utility_replace(c,/(image-set\([^]*)/,e_+"$1$`$1");case 4968:return Utility_replace(Utility_replace(c,/(.+:)(flex-)?(.*)/,e_+"box-pack:$3"+eb+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+e_+c+c;case 4095:case 3583:case 4068:case 2532:return Utility_replace(c,/(.+)-inline(.+)/,e_+"$1$2")+c;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Utility_strlen(c)-1-l>6)switch(Utility_charat(c,l+1)){case 109:if(45!==Utility_charat(c,l+4))break;case 102:return Utility_replace(c,/(.+:)(.+)-([^]+)/,"$1"+e_+"$2-$3$1"+ey+(108==Utility_charat(c,l+3)?"$3":"$2-$3"))+c;case 115:return~indexof(c,"stretch")?emotion_cache_browser_esm_prefix(Utility_replace(c,"stretch","fill-available"),l)+c:c}break;case 4949:if(115!==Utility_charat(c,l+1))break;case 6444:switch(Utility_charat(c,Utility_strlen(c)-3-(~indexof(c,"!important")&&10))){case 107:return Utility_replace(c,":",":"+e_)+c;case 101:return Utility_replace(c,/(.+:)([^;!]+)(;|!.+)?/,"$1"+e_+(45===Utility_charat(c,14)?"inline-":"")+"box$3$1"+e_+"$2$3$1"+eb+"$2box$3")+c}break;case 5936:switch(Utility_charat(c,l+11)){case 114:return e_+c+eb+Utility_replace(c,/[svh]\w+-[tblr]{2}/,"tb")+c;case 108:return e_+c+eb+Utility_replace(c,/[svh]\w+-[tblr]{2}/,"tb-rl")+c;case 45:return e_+c+eb+Utility_replace(c,/[svh]\w+-[tblr]{2}/,"lr")+c}return e_+c+eb+c+c}return c}(c.value,c.length);break;case ex:return Serializer_serialize([Tokenizer_copy(c,{value:Utility_replace(c.value,"@","@"+e_)})],eo);case eE:if(c.length)return c.props.map(function(l){var et;switch(et=l,(et=/(::plac\w+|:read-\w+)/.exec(et))?et[0]:et){case":read-only":case":read-write":return Serializer_serialize([Tokenizer_copy(c,{props:[Utility_replace(l,/:(read-\w+)/,":"+ey+"$1")]})],eo);case"::placeholder":return Serializer_serialize([Tokenizer_copy(c,{props:[Utility_replace(l,/:(plac\w+)/,":"+e_+"input-$1")]}),Tokenizer_copy(c,{props:[Utility_replace(l,/:(plac\w+)/,":"+ey+"$1")]}),Tokenizer_copy(c,{props:[Utility_replace(l,/:(plac\w+)/,eb+"input-$1")]})],eo)}return""}).join("")}}],createCache=function(c){var l,et,es,el,ef,eb=c.key;if("css"===eb){var ey=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(ey,function(c){-1!==c.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(c),c.setAttribute("data-s",""))})}var e_=c.stylisPlugins||eC,eE={},eS=[];el=c.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+eb+' "]'),function(c){for(var l=c.getAttribute("data-emotion").split(" "),et=1;et2||token(eg)>3?"":" "}(eA);break;case 92:eB+=function(c,l){for(var et;--l&&next()&&!(eg<48)&&!(eg>102)&&(!(eg>57)||!(eg<65))&&(!(eg>70)||!(eg<97)););return et=ep+(l<6&&32==peek()&&32==next()),Utility_substr(em,c,et)}(ep-1,7);continue;case 47:switch(peek()){case 42:case 47:Utility_append(node(e_=function(c,l){for(;next();)if(c+eg===57)break;else if(c+eg===84&&47===peek())break;return"/*"+Utility_substr(em,l,ep-1)+"*"+ec(47===c?c:next())}(next(),ep),l,et,ew,ec(eg),Utility_substr(e_,2,-2),0),ey);break;default:eB+="/"}break;case 123*eI:eb[eE++]=Utility_strlen(eB)*eR;case 125*eI:case 59:case 0:switch(eO){case 0:case 125:eP=0;case 59+eS:-1==eR&&(eB=Utility_replace(eB,/\f/g,"")),eC>0&&Utility_strlen(eB)-ex&&Utility_append(eC>32?declaration(eB+";",eo,et,ex-1):declaration(Utility_replace(eB," ","")+";",eo,et,ex-2),ey);break;case 59:eB+=";";default:if(Utility_append(e$=ruleset(eB,l,et,eE,eS,es,eb,eT,eN=[],eM=[],ex),el),123===eO){if(0===eS)parse(eB,l,e$,e$,eN,el,ex,eb,eM);else switch(99===ek&&110===Utility_charat(eB,3)?100:ek){case 100:case 108:case 109:case 115:parse(c,e$,e$,eo&&Utility_append(ruleset(c,e$,e$,0,0,es,eb,eT,es,eN=[],ex),eM),es,eM,ex,eb,eo?eN:eM);break;default:parse(eB,e$,e$,e$,[""],eM,0,eb,eM)}}}eE=eS=eC=0,eI=eR=1,eT=eB="",ex=ef;break;case 58:ex=1+Utility_strlen(eB),eC=eA;default:if(eI<1){if(123==eO)--eI;else if(125==eO&&0==eI++&&125==(eg=ep>0?Utility_charat(em,--ep):0,eh--,10===eg&&(eh=1,ed--),eg))continue}switch(eB+=ec(eO),eO*eI){case 38:eR=eS>0?1:(eB+="\f",-1);break;case 44:eb[eE++]=(Utility_strlen(eB)-1)*eR,eR=1;break;case 64:45===peek()&&(eB+=delimit(next())),ek=peek(),eS=ex=Utility_strlen(eT=eB+=function(c){for(;!token(peek());)next();return Utility_substr(em,c,ep)}(ep)),eO++;break;case 45:45===eA&&2==Utility_strlen(eB)&&(eI=0)}}return el}("",null,null,null,[""],l=alloc(l=c),0,[0],l),em="",et),ex)},ek={key:eb,sheet:new eo({key:eb,container:el,nonce:c.nonce,speedy:c.speedy,prepend:c.prepend,insertionPoint:c.insertionPoint}),nonce:c.nonce,inserted:eE,registered:{},insert:function(c,l,et,eo){ef=et,stylis(c?c+"{"+l.styles+"}":l.styles),eo&&(ek.inserted[l.name]=!0)}};return ek.sheet.hydrate(eS),ek}},67008:function(c,l,et){"use strict";et.d(l,{Z:function(){return ec}});var eo=et(44935),es=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,ec=(0,eo.Z)(function(c){return es.test(c)||111===c.charCodeAt(0)&&110===c.charCodeAt(1)&&91>c.charCodeAt(2)})},44935:function(c,l,et){"use strict";function memoize(c){var l=Object.create(null);return function(et){return void 0===l[et]&&(l[et]=c(et)),l[et]}}et.d(l,{Z:function(){return memoize}})},65673:function(c,l,et){"use strict";et.d(l,{C:function(){return eh},T:function(){return ef},a:function(){return ThemeProvider},i:function(){return el},w:function(){return withEmotionCache}});var eo=et(2265),es=et(56335),ec=et(13428),weakMemoize=function(c){var l=new WeakMap;return function(et){if(l.has(et))return l.get(et);var eo=c(et);return l.set(et,eo),eo}};et(53597),et(7599);var el=!0,ed=eo.createContext("undefined"!=typeof HTMLElement?(0,es.Z)({key:"css"}):null),eh=ed.Provider,withEmotionCache=function(c){return(0,eo.forwardRef)(function(l,et){return c(l,(0,eo.useContext)(ed),et)})};el||(withEmotionCache=function(c){return function(l){var et=(0,eo.useContext)(ed);return null===et?(et=(0,es.Z)({key:"css"}),eo.createElement(ed.Provider,{value:et},c(l,et))):c(l,et)}});var ef=eo.createContext({}),ep=weakMemoize(function(c){return weakMemoize(function(l){return"function"==typeof l?l(c):(0,ec.Z)({},c,l)})}),ThemeProvider=function(c){var l=eo.useContext(ef);return c.theme!==l&&(l=ep(l)(c.theme)),eo.createElement(ef.Provider,{value:l},c.children)}},99538:function(c,l,et){"use strict";et.d(l,{F4:function(){return keyframes},xB:function(){return eh}});var eo=et(65673),es=et(2265),ec=et(94645),el=et(7599),ed=et(53597);et(56335),et(55487);var eh=(0,eo.w)(function(c,l){var et=c.styles,eh=(0,ed.O)([et],void 0,es.useContext(eo.T));if(!eo.i){for(var ef,ep=eh.name,eg=eh.styles,em=eh.next;void 0!==em;)ep+=" "+em.name,eg+=em.styles,em=em.next;var eb=!0===l.compat,ey=l.insert("",{name:ep,styles:eg},l.sheet,eb);return eb?null:es.createElement("style",((ef={})["data-emotion"]=l.key+"-global "+ep,ef.dangerouslySetInnerHTML={__html:ey},ef.nonce=l.sheet.nonce,ef))}var e_=es.useRef();return(0,el.j)(function(){var c=l.key+"-global",et=new l.sheet.constructor({key:c,nonce:l.sheet.nonce,container:l.sheet.container,speedy:l.sheet.isSpeedy}),eo=!1,es=document.querySelector('style[data-emotion="'+c+" "+eh.name+'"]');return l.sheet.tags.length&&(et.before=l.sheet.tags[0]),null!==es&&(eo=!0,es.setAttribute("data-emotion",c),et.hydrate([es])),e_.current=[et,eo],function(){et.flush()}},[l]),(0,el.j)(function(){var c=e_.current,et=c[0];if(c[1]){c[1]=!1;return}if(void 0!==eh.next&&(0,ec.My)(l,eh.next,!0),et.tags.length){var eo=et.tags[et.tags.length-1].nextElementSibling;et.before=eo,et.flush()}l.insert("",eh,et,!1)},[l,eh.name]),null});function css(){for(var c=arguments.length,l=Array(c),et=0;et=4;++eo,es-=4)l=(65535&(l=255&c.charCodeAt(eo)|(255&c.charCodeAt(++eo))<<8|(255&c.charCodeAt(++eo))<<16|(255&c.charCodeAt(++eo))<<24))*1540483477+((l>>>16)*59797<<16),l^=l>>>24,et=(65535&l)*1540483477+((l>>>16)*59797<<16)^(65535&et)*1540483477+((et>>>16)*59797<<16);switch(es){case 3:et^=(255&c.charCodeAt(eo+2))<<16;case 2:et^=(255&c.charCodeAt(eo+1))<<8;case 1:et^=255&c.charCodeAt(eo),et=(65535&et)*1540483477+((et>>>16)*59797<<16)}return et^=et>>>13,(((et=(65535&et)*1540483477+((et>>>16)*59797<<16))^et>>>15)>>>0).toString(36)}(el)+ep,styles:el,next:eo}}},7599:function(c,l,et){"use strict";et.d(l,{L:function(){return el},j:function(){return ed}});var eo,es=et(2265),ec=!!(eo||(eo=et.t(es,2))).useInsertionEffect&&(eo||(eo=et.t(es,2))).useInsertionEffect,el=ec||function(c){return c()},ed=ec||es.useLayoutEffect},94645:function(c,l,et){"use strict";function getRegisteredStyles(c,l,et){var eo="";return et.split(" ").forEach(function(et){void 0!==c[et]?l.push(c[et]+";"):eo+=et+" "}),eo}et.d(l,{My:function(){return insertStyles},fp:function(){return getRegisteredStyles},hC:function(){return registerStyles}});var registerStyles=function(c,l,et){var eo=c.key+"-"+l.name;!1===et&&void 0===c.registered[eo]&&(c.registered[eo]=l.styles)},insertStyles=function(c,l,et){registerStyles(c,l,et);var eo=c.key+"-"+l.name;if(void 0===c.inserted[l.name]){var es=l;do c.insert(l===es?"."+eo:"",es,c.sheet,!0),es=es.next;while(void 0!==es)}}},14941:function(c,l,et){"use strict";et.d(l,{E:function(){return Signer},b:function(){return VoidSigner}});var eo=et(17213),es=et(36288),__awaiter=function(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})};let ec=new es.Yd("abstract-signer/5.7.0"),el=["accessList","ccipReadEnabled","chainId","customData","data","from","gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","nonce","to","type","value"],ed=[es.Yd.errors.INSUFFICIENT_FUNDS,es.Yd.errors.NONCE_EXPIRED,es.Yd.errors.REPLACEMENT_UNDERPRICED];let Signer=class Signer{constructor(){ec.checkAbstract(new.target,Signer),(0,eo.zG)(this,"_isSigner",!0)}getBalance(c){return __awaiter(this,void 0,void 0,function*(){return this._checkProvider("getBalance"),yield this.provider.getBalance(this.getAddress(),c)})}getTransactionCount(c){return __awaiter(this,void 0,void 0,function*(){return this._checkProvider("getTransactionCount"),yield this.provider.getTransactionCount(this.getAddress(),c)})}estimateGas(c){return __awaiter(this,void 0,void 0,function*(){this._checkProvider("estimateGas");let l=yield(0,eo.mE)(this.checkTransaction(c));return yield this.provider.estimateGas(l)})}call(c,l){return __awaiter(this,void 0,void 0,function*(){this._checkProvider("call");let et=yield(0,eo.mE)(this.checkTransaction(c));return yield this.provider.call(et,l)})}sendTransaction(c){return __awaiter(this,void 0,void 0,function*(){this._checkProvider("sendTransaction");let l=yield this.populateTransaction(c),et=yield this.signTransaction(l);return yield this.provider.sendTransaction(et)})}getChainId(){return __awaiter(this,void 0,void 0,function*(){this._checkProvider("getChainId");let c=yield this.provider.getNetwork();return c.chainId})}getGasPrice(){return __awaiter(this,void 0,void 0,function*(){return this._checkProvider("getGasPrice"),yield this.provider.getGasPrice()})}getFeeData(){return __awaiter(this,void 0,void 0,function*(){return this._checkProvider("getFeeData"),yield this.provider.getFeeData()})}resolveName(c){return __awaiter(this,void 0,void 0,function*(){return this._checkProvider("resolveName"),yield this.provider.resolveName(c)})}checkTransaction(c){for(let l in c)-1===el.indexOf(l)&&ec.throwArgumentError("invalid transaction key: "+l,"transaction",c);let l=(0,eo.DC)(c);return null==l.from?l.from=this.getAddress():l.from=Promise.all([Promise.resolve(l.from),this.getAddress()]).then(l=>(l[0].toLowerCase()!==l[1].toLowerCase()&&ec.throwArgumentError("from address mismatch","transaction",c),l[0])),l}populateTransaction(c){return __awaiter(this,void 0,void 0,function*(){let l=yield(0,eo.mE)(this.checkTransaction(c));null!=l.to&&(l.to=Promise.resolve(l.to).then(c=>__awaiter(this,void 0,void 0,function*(){if(null==c)return null;let l=yield this.resolveName(c);return null==l&&ec.throwArgumentError("provided ENS name resolves to null","tx.to",c),l})),l.to.catch(c=>{}));let et=null!=l.maxFeePerGas||null!=l.maxPriorityFeePerGas;if(null!=l.gasPrice&&(2===l.type||et)?ec.throwArgumentError("eip-1559 transaction do not support gasPrice","transaction",c):(0===l.type||1===l.type)&&et&&ec.throwArgumentError("pre-eip-1559 transaction do not support maxFeePerGas/maxPriorityFeePerGas","transaction",c),(2===l.type||null==l.type)&&null!=l.maxFeePerGas&&null!=l.maxPriorityFeePerGas)l.type=2;else if(0===l.type||1===l.type)null==l.gasPrice&&(l.gasPrice=this.getGasPrice());else{let c=yield this.getFeeData();if(null==l.type){if(null!=c.maxFeePerGas&&null!=c.maxPriorityFeePerGas){if(l.type=2,null!=l.gasPrice){let c=l.gasPrice;delete l.gasPrice,l.maxFeePerGas=c,l.maxPriorityFeePerGas=c}else null==l.maxFeePerGas&&(l.maxFeePerGas=c.maxFeePerGas),null==l.maxPriorityFeePerGas&&(l.maxPriorityFeePerGas=c.maxPriorityFeePerGas)}else null!=c.gasPrice?(et&&ec.throwError("network does not support EIP-1559",es.Yd.errors.UNSUPPORTED_OPERATION,{operation:"populateTransaction"}),null==l.gasPrice&&(l.gasPrice=c.gasPrice),l.type=0):ec.throwError("failed to get consistent fee data",es.Yd.errors.UNSUPPORTED_OPERATION,{operation:"signer.getFeeData"})}else 2===l.type&&(null==l.maxFeePerGas&&(l.maxFeePerGas=c.maxFeePerGas),null==l.maxPriorityFeePerGas&&(l.maxPriorityFeePerGas=c.maxPriorityFeePerGas))}return null==l.nonce&&(l.nonce=this.getTransactionCount("pending")),null==l.gasLimit&&(l.gasLimit=this.estimateGas(l).catch(c=>{if(ed.indexOf(c.code)>=0)throw c;return ec.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",es.Yd.errors.UNPREDICTABLE_GAS_LIMIT,{error:c,tx:l})})),null==l.chainId?l.chainId=this.getChainId():l.chainId=Promise.all([Promise.resolve(l.chainId),this.getChainId()]).then(l=>(0!==l[1]&&l[0]!==l[1]&&ec.throwArgumentError("chainId address mismatch","transaction",c),l[0])),yield(0,eo.mE)(l)})}_checkProvider(c){this.provider||ec.throwError("missing provider",es.Yd.errors.UNSUPPORTED_OPERATION,{operation:c||"_checkProvider"})}static isSigner(c){return!!(c&&c._isSigner)}};let VoidSigner=class VoidSigner extends Signer{constructor(c,l){super(),(0,eo.zG)(this,"address",c),(0,eo.zG)(this,"provider",l||null)}getAddress(){return Promise.resolve(this.address)}_fail(c,l){return Promise.resolve().then(()=>{ec.throwError(c,es.Yd.errors.UNSUPPORTED_OPERATION,{operation:l})})}signMessage(c){return this._fail("VoidSigner cannot sign messages","signMessage")}signTransaction(c){return this._fail("VoidSigner cannot sign transactions","signTransaction")}_signTypedData(c,l,et){return this._fail("VoidSigner cannot sign typed data","signTypedData")}connect(c){return new VoidSigner(this.address,c)}}},18994:function(c,l,et){"use strict";et.d(l,{Kn:function(){return getAddress},CR:function(){return getContractAddress}});var eo=et(57273),es=et(92598),ec=et(14184),el=et(7054),ed=et(36288);let eh=new ed.Yd("address/5.7.0");function getChecksumAddress(c){(0,eo.A7)(c,20)||eh.throwArgumentError("invalid address","address",c),c=c.toLowerCase();let l=c.substring(2).split(""),et=new Uint8Array(40);for(let c=0;c<40;c++)et[c]=l[c].charCodeAt(0);let es=(0,eo.lE)((0,ec.w)(et));for(let c=0;c<40;c+=2)es[c>>1]>>4>=8&&(l[c]=l[c].toUpperCase()),(15&es[c>>1])>=8&&(l[c+1]=l[c+1].toUpperCase());return"0x"+l.join("")}let ef={};for(let c=0;c<10;c++)ef[String(c)]=String(c);for(let c=0;c<26;c++)ef[String.fromCharCode(65+c)]=String(10+c);let ep=Math.floor(Math.log10?Math.log10(9007199254740991):Math.log(9007199254740991)/Math.LN10);function getAddress(c){let l=null;if("string"!=typeof c&&eh.throwArgumentError("invalid address","address",c),c.match(/^(0x)?[0-9a-fA-F]{40}$/))"0x"!==c.substring(0,2)&&(c="0x"+c),l=getChecksumAddress(c),c.match(/([A-F].*[a-f])|([a-f].*[A-F])/)&&l!==c&&eh.throwArgumentError("bad address checksum","address",c);else if(c.match(/^XE[0-9]{2}[0-9A-Za-z]{30,31}$/)){for(c.substring(2,4)!==function(c){let l=(c=(c=c.toUpperCase()).substring(4)+c.substring(0,2)+"00").split("").map(c=>ef[c]).join("");for(;l.length>=ep;){let c=l.substring(0,ep);l=parseInt(c,10)%97+l.substring(c.length)}let et=String(98-parseInt(l,10)%97);for(;et.length<2;)et="0"+et;return et}(c)&&eh.throwArgumentError("bad icap checksum","address",c),l=(0,es.g$)(c.substring(4));l.length<40;)l="0"+l;l=getChecksumAddress("0x"+l)}else eh.throwArgumentError("invalid address","address",c);return l}function getContractAddress(c){let l=null;try{l=getAddress(c.from)}catch(l){eh.throwArgumentError("missing from address","transaction",c)}let et=(0,eo.G1)((0,eo.lE)(es.O$.from(c.nonce).toHexString()));return getAddress((0,eo.p3)((0,ec.w)((0,el.c)([l,et])),12))}},68334:function(c,l,et){"use strict";et.d(l,{i:function(){return eo}});let eo="bignumber/5.7.0"},92598:function(c,l,et){"use strict";et.d(l,{O$:function(){return BigNumber},Zm:function(){return isBigNumberish},g$:function(){return _base36To16}});var eo=et(56662),es=et.n(eo),ec=et(57273),el=et(36288),ed=et(68334),eh=es().BN;let ef=new el.Yd(ed.i),ep={};function isBigNumberish(c){return null!=c&&(BigNumber.isBigNumber(c)||"number"==typeof c&&c%1==0||"string"==typeof c&&!!c.match(/^-?[0-9]+$/)||(0,ec.A7)(c)||"bigint"==typeof c||(0,ec._t)(c))}let eg=!1;let BigNumber=class BigNumber{constructor(c,l){c!==ep&&ef.throwError("cannot call constructor directly; use BigNumber.from",el.Yd.errors.UNSUPPORTED_OPERATION,{operation:"new (BigNumber)"}),this._hex=l,this._isBigNumber=!0,Object.freeze(this)}fromTwos(c){return toBigNumber(toBN(this).fromTwos(c))}toTwos(c){return toBigNumber(toBN(this).toTwos(c))}abs(){return"-"===this._hex[0]?BigNumber.from(this._hex.substring(1)):this}add(c){return toBigNumber(toBN(this).add(toBN(c)))}sub(c){return toBigNumber(toBN(this).sub(toBN(c)))}div(c){let l=BigNumber.from(c);return l.isZero()&&throwFault("division-by-zero","div"),toBigNumber(toBN(this).div(toBN(c)))}mul(c){return toBigNumber(toBN(this).mul(toBN(c)))}mod(c){let l=toBN(c);return l.isNeg()&&throwFault("division-by-zero","mod"),toBigNumber(toBN(this).umod(l))}pow(c){let l=toBN(c);return l.isNeg()&&throwFault("negative-power","pow"),toBigNumber(toBN(this).pow(l))}and(c){let l=toBN(c);return(this.isNegative()||l.isNeg())&&throwFault("unbound-bitwise-result","and"),toBigNumber(toBN(this).and(l))}or(c){let l=toBN(c);return(this.isNegative()||l.isNeg())&&throwFault("unbound-bitwise-result","or"),toBigNumber(toBN(this).or(l))}xor(c){let l=toBN(c);return(this.isNegative()||l.isNeg())&&throwFault("unbound-bitwise-result","xor"),toBigNumber(toBN(this).xor(l))}mask(c){return(this.isNegative()||c<0)&&throwFault("negative-width","mask"),toBigNumber(toBN(this).maskn(c))}shl(c){return(this.isNegative()||c<0)&&throwFault("negative-width","shl"),toBigNumber(toBN(this).shln(c))}shr(c){return(this.isNegative()||c<0)&&throwFault("negative-width","shr"),toBigNumber(toBN(this).shrn(c))}eq(c){return toBN(this).eq(toBN(c))}lt(c){return toBN(this).lt(toBN(c))}lte(c){return toBN(this).lte(toBN(c))}gt(c){return toBN(this).gt(toBN(c))}gte(c){return toBN(this).gte(toBN(c))}isNegative(){return"-"===this._hex[0]}isZero(){return toBN(this).isZero()}toNumber(){try{return toBN(this).toNumber()}catch(c){throwFault("overflow","toNumber",this.toString())}return null}toBigInt(){try{return BigInt(this.toString())}catch(c){}return ef.throwError("this platform does not support BigInt",el.Yd.errors.UNSUPPORTED_OPERATION,{value:this.toString()})}toString(){return arguments.length>0&&(10===arguments[0]?eg||(eg=!0,ef.warn("BigNumber.toString does not accept any parameters; base-10 is assumed")):16===arguments[0]?ef.throwError("BigNumber.toString does not accept any parameters; use bigNumber.toHexString()",el.Yd.errors.UNEXPECTED_ARGUMENT,{}):ef.throwError("BigNumber.toString does not accept parameters",el.Yd.errors.UNEXPECTED_ARGUMENT,{})),toBN(this).toString(10)}toHexString(){return this._hex}toJSON(c){return{type:"BigNumber",hex:this.toHexString()}}static from(c){if(c instanceof BigNumber)return c;if("string"==typeof c)return c.match(/^-?0x[0-9a-f]+$/i)?new BigNumber(ep,toHex(c)):c.match(/^-?[0-9]+$/)?new BigNumber(ep,toHex(new eh(c))):ef.throwArgumentError("invalid BigNumber string","value",c);if("number"==typeof c)return c%1&&throwFault("underflow","BigNumber.from",c),(c>=9007199254740991||c<=-9007199254740991)&&throwFault("overflow","BigNumber.from",c),BigNumber.from(String(c));if("bigint"==typeof c)return BigNumber.from(c.toString());if((0,ec._t)(c))return BigNumber.from((0,ec.Dv)(c));if(c){if(c.toHexString){let l=c.toHexString();if("string"==typeof l)return BigNumber.from(l)}else{let l=c._hex;if(null==l&&"BigNumber"===c.type&&(l=c.hex),"string"==typeof l&&((0,ec.A7)(l)||"-"===l[0]&&(0,ec.A7)(l.substring(1))))return BigNumber.from(l)}}return ef.throwArgumentError("invalid BigNumber value","value",c)}static isBigNumber(c){return!!(c&&c._isBigNumber)}};function toHex(c){if("string"!=typeof c)return toHex(c.toString(16));if("-"===c[0])return("-"===(c=c.substring(1))[0]&&ef.throwArgumentError("invalid hex","value",c),"0x00"===(c=toHex(c)))?c:"-"+c;if("0x"!==c.substring(0,2)&&(c="0x"+c),"0x"===c)return"0x00";for(c.length%2&&(c="0x0"+c.substring(2));c.length>4&&"0x00"===c.substring(0,4);)c="0x"+c.substring(4);return c}function toBigNumber(c){return BigNumber.from(toHex(c))}function toBN(c){let l=BigNumber.from(c).toHexString();return"-"===l[0]?new eh("-"+l.substring(3),16):new eh(l.substring(2),16)}function throwFault(c,l,et){let eo={fault:c,operation:l};return null!=et&&(eo.value=et),ef.throwError(c,el.Yd.errors.NUMERIC_FAULT,eo)}function _base36To16(c){return new eh(c,36).toString(16)}},57273:function(c,l,et){"use strict";et.d(l,{lE:function(){return arrayify},zo:function(){return concat},xs:function(){return hexConcat},E1:function(){return hexDataLength},p3:function(){return hexDataSlice},$P:function(){return hexValue},$m:function(){return hexZeroPad},Dv:function(){return hexlify},_t:function(){return isBytes},Zq:function(){return isBytesLike},A7:function(){return isHexString},N:function(){return splitSignature},G1:function(){return stripZeros}});var eo=et(36288);let es=new eo.Yd("bytes/5.7.0");function isHexable(c){return!!c.toHexString}function addSlice(c){return c.slice||(c.slice=function(){let l=Array.prototype.slice.call(arguments);return addSlice(new Uint8Array(Array.prototype.slice.apply(c,l)))}),c}function isBytesLike(c){return isHexString(c)&&!(c.length%2)||isBytes(c)}function isInteger(c){return"number"==typeof c&&c==c&&c%1==0}function isBytes(c){if(null==c)return!1;if(c.constructor===Uint8Array)return!0;if("string"==typeof c||!isInteger(c.length)||c.length<0)return!1;for(let l=0;l=256)return!1}return!0}function arrayify(c,l){if(l||(l={}),"number"==typeof c){es.checkSafeUint53(c,"invalid arrayify value");let l=[];for(;c;)l.unshift(255&c),c=parseInt(String(c/256));return 0===l.length&&l.push(0),addSlice(new Uint8Array(l))}if(l.allowMissingPrefix&&"string"==typeof c&&"0x"!==c.substring(0,2)&&(c="0x"+c),isHexable(c)&&(c=c.toHexString()),isHexString(c)){let et=c.substring(2);et.length%2&&("left"===l.hexPad?et="0"+et:"right"===l.hexPad?et+="0":es.throwArgumentError("hex data is odd-length","value",c));let eo=[];for(let c=0;carrayify(c)),et=l.reduce((c,l)=>c+l.length,0),eo=new Uint8Array(et);return l.reduce((c,l)=>(eo.set(l,c),c+l.length),0),addSlice(eo)}function stripZeros(c){let l=arrayify(c);if(0===l.length)return l;let et=0;for(;et>4]+ec[15&eo]}return l}return es.throwArgumentError("invalid hexlify value","value",c)}function hexDataLength(c){if("string"!=typeof c)c=hexlify(c);else if(!isHexString(c)||c.length%2)return null;return(c.length-2)/2}function hexDataSlice(c,l,et){return("string"!=typeof c?c=hexlify(c):(!isHexString(c)||c.length%2)&&es.throwArgumentError("invalid hexData","value",c),l=2+2*l,null!=et)?"0x"+c.substring(l,2+2*et):"0x"+c.substring(l)}function hexConcat(c){let l="0x";return c.forEach(c=>{l+=hexlify(c).substring(2)}),l}function hexValue(c){let l=function(c){"string"!=typeof c&&(c=hexlify(c)),isHexString(c)||es.throwArgumentError("invalid hex string","value",c),c=c.substring(2);let l=0;for(;l2*l+2&&es.throwArgumentError("value out of range","value",arguments[1]);c.length<2*l+2;)c="0x0"+c.substring(2);return c}function splitSignature(c){let l={r:"0x",s:"0x",_vs:"0x",recoveryParam:0,v:0,yParityAndS:"0x",compact:"0x"};if(isBytesLike(c)){let et=arrayify(c);64===et.length?(l.v=27+(et[32]>>7),et[32]&=127,l.r=hexlify(et.slice(0,32)),l.s=hexlify(et.slice(32,64))):65===et.length?(l.r=hexlify(et.slice(0,32)),l.s=hexlify(et.slice(32,64)),l.v=et[64]):es.throwArgumentError("invalid signature string","signature",c),l.v<27&&(0===l.v||1===l.v?l.v+=27:es.throwArgumentError("signature invalid v byte","signature",c)),l.recoveryParam=1-l.v%2,l.recoveryParam&&(et[32]|=128),l._vs=hexlify(et.slice(32,64))}else{if(l.r=c.r,l.s=c.s,l.v=c.v,l.recoveryParam=c.recoveryParam,l._vs=c._vs,null!=l._vs){let et=function(c,l){(c=arrayify(c)).length>l&&es.throwArgumentError("value out of range","value",arguments[0]);let et=new Uint8Array(l);return et.set(c,l-c.length),addSlice(et)}(arrayify(l._vs),32);l._vs=hexlify(et);let eo=et[0]>=128?1:0;null==l.recoveryParam?l.recoveryParam=eo:l.recoveryParam!==eo&&es.throwArgumentError("signature recoveryParam mismatch _vs","signature",c),et[0]&=127;let ec=hexlify(et);null==l.s?l.s=ec:l.s!==ec&&es.throwArgumentError("signature v mismatch _vs","signature",c)}if(null==l.recoveryParam)null==l.v?es.throwArgumentError("signature missing v and recoveryParam","signature",c):0===l.v||1===l.v?l.recoveryParam=l.v:l.recoveryParam=1-l.v%2;else if(null==l.v)l.v=27+l.recoveryParam;else{let et=0===l.v||1===l.v?l.v:1-l.v%2;l.recoveryParam!==et&&es.throwArgumentError("signature recoveryParam mismatch v","signature",c)}null!=l.r&&isHexString(l.r)?l.r=hexZeroPad(l.r,32):es.throwArgumentError("signature missing or invalid r","signature",c),null!=l.s&&isHexString(l.s)?l.s=hexZeroPad(l.s,32):es.throwArgumentError("signature missing or invalid s","signature",c);let et=arrayify(l.s);et[0]>=128&&es.throwArgumentError("signature s out of range","signature",c),l.recoveryParam&&(et[0]|=128);let eo=hexlify(et);l._vs&&(isHexString(l._vs)||es.throwArgumentError("signature invalid _vs","signature",c),l._vs=hexZeroPad(l._vs,32)),null==l._vs?l._vs=eo:l._vs!==eo&&es.throwArgumentError("signature _vs mismatch v and s","signature",c)}return l.yParityAndS=l._vs,l.compact=l.r+l.yParityAndS.substring(2),l}},14184:function(c,l,et){"use strict";et.d(l,{w:function(){return keccak256}});var eo=et(26398),es=et.n(eo),ec=et(57273);function keccak256(c){return"0x"+es().keccak_256((0,ec.lE)(c))}},36288:function(c,l,et){"use strict";var eo,es,ec,el;et.d(l,{jK:function(){return es},Yd:function(){return Logger}});let ed=!1,eh=!1,ef={debug:1,default:2,info:2,warning:3,error:4,off:5},ep=2,eg=null,em=function(){try{let c=[];if(["NFD","NFC","NFKD","NFKC"].forEach(l=>{try{if("test"!=="test".normalize(l))throw Error("bad normalize")}catch(et){c.push(l)}}),c.length)throw Error("missing "+c.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw Error("broken implementation")}catch(c){return c.message}return null}();(ec=eo||(eo={})).DEBUG="DEBUG",ec.INFO="INFO",ec.WARNING="WARNING",ec.ERROR="ERROR",ec.OFF="OFF",(el=es||(es={})).UNKNOWN_ERROR="UNKNOWN_ERROR",el.NOT_IMPLEMENTED="NOT_IMPLEMENTED",el.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",el.NETWORK_ERROR="NETWORK_ERROR",el.SERVER_ERROR="SERVER_ERROR",el.TIMEOUT="TIMEOUT",el.BUFFER_OVERRUN="BUFFER_OVERRUN",el.NUMERIC_FAULT="NUMERIC_FAULT",el.MISSING_NEW="MISSING_NEW",el.INVALID_ARGUMENT="INVALID_ARGUMENT",el.MISSING_ARGUMENT="MISSING_ARGUMENT",el.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",el.CALL_EXCEPTION="CALL_EXCEPTION",el.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",el.NONCE_EXPIRED="NONCE_EXPIRED",el.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",el.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",el.TRANSACTION_REPLACED="TRANSACTION_REPLACED",el.ACTION_REJECTED="ACTION_REJECTED";let eb="0123456789abcdef";let Logger=class Logger{constructor(c){Object.defineProperty(this,"version",{enumerable:!0,value:c,writable:!1})}_log(c,l){let et=c.toLowerCase();null==ef[et]&&this.throwArgumentError("invalid log level name","logLevel",c),ep>ef[et]||console.log.apply(console,l)}debug(...c){this._log(Logger.levels.DEBUG,c)}info(...c){this._log(Logger.levels.INFO,c)}warn(...c){this._log(Logger.levels.WARNING,c)}makeError(c,l,et){if(eh)return this.makeError("censored error",l,{});l||(l=Logger.errors.UNKNOWN_ERROR),et||(et={});let eo=[];Object.keys(et).forEach(c=>{let l=et[c];try{if(l instanceof Uint8Array){let et="";for(let c=0;c>4]+eb[15&l[c]];eo.push(c+"=Uint8Array(0x"+et+")")}else eo.push(c+"="+JSON.stringify(l))}catch(l){eo.push(c+"="+JSON.stringify(et[c].toString()))}}),eo.push(`code=${l}`),eo.push(`version=${this.version}`);let ec=c,el="";switch(l){case es.NUMERIC_FAULT:{el="NUMERIC_FAULT";let l=c;switch(l){case"overflow":case"underflow":case"division-by-zero":el+="-"+l;break;case"negative-power":case"negative-width":el+="-unsupported";break;case"unbound-bitwise-result":el+="-unbound-result"}break}case es.CALL_EXCEPTION:case es.INSUFFICIENT_FUNDS:case es.MISSING_NEW:case es.NONCE_EXPIRED:case es.REPLACEMENT_UNDERPRICED:case es.TRANSACTION_REPLACED:case es.UNPREDICTABLE_GAS_LIMIT:el=l}el&&(c+=" [ See: https://links.ethers.org/v5-errors-"+el+" ]"),eo.length&&(c+=" ("+eo.join(", ")+")");let ed=Error(c);return ed.reason=ec,ed.code=l,Object.keys(et).forEach(function(c){ed[c]=et[c]}),ed}throwError(c,l,et){throw this.makeError(c,l,et)}throwArgumentError(c,l,et){return this.throwError(c,Logger.errors.INVALID_ARGUMENT,{argument:l,value:et})}assert(c,l,et,eo){c||this.throwError(l,et,eo)}assertArgument(c,l,et,eo){c||this.throwArgumentError(l,et,eo)}checkNormalize(c){null==c&&(c="platform missing String.prototype.normalize"),em&&this.throwError("platform missing String.prototype.normalize",Logger.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:em})}checkSafeUint53(c,l){"number"==typeof c&&(null==l&&(l="value not safe"),(c<0||c>=9007199254740991)&&this.throwError(l,Logger.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:c}),c%1&&this.throwError(l,Logger.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:c}))}checkArgumentCount(c,l,et){et=et?": "+et:"",cl&&this.throwError("too many arguments"+et,Logger.errors.UNEXPECTED_ARGUMENT,{count:c,expectedCount:l})}checkNew(c,l){(c===Object||null==c)&&this.throwError("missing new",Logger.errors.MISSING_NEW,{name:l.name})}checkAbstract(c,l){c===l?this.throwError("cannot instantiate abstract class "+JSON.stringify(l.name)+" directly; use a sub-class",Logger.errors.UNSUPPORTED_OPERATION,{name:c.name,operation:"new"}):(c===Object||null==c)&&this.throwError("missing new",Logger.errors.MISSING_NEW,{name:l.name})}static globalLogger(){return eg||(eg=new Logger("logger/5.7.0")),eg}static setCensorship(c,l){if(!c&&l&&this.globalLogger().throwError("cannot permanently disable censorship",Logger.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),ed){if(!c)return;this.globalLogger().throwError("error censorship permanent",Logger.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}eh=!!c,ed=!!l}static setLogLevel(c){let l=ef[c.toLowerCase()];if(null==l){Logger.globalLogger().warn("invalid log level - "+c);return}ep=l}static from(c){return new Logger(c)}};Logger.errors=es,Logger.levels=eo},17213:function(c,l,et){"use strict";et.d(l,{dk:function(){return Description},uj:function(){return checkProperties},p$:function(){return deepCopy},zG:function(){return defineReadOnly},tu:function(){return getStatic},mE:function(){return resolveProperties},DC:function(){return shallowCopy}});var eo=et(36288);let es=new eo.Yd("properties/5.7.0");function defineReadOnly(c,l,et){Object.defineProperty(c,l,{enumerable:!0,value:et,writable:!1})}function getStatic(c,l){for(let et=0;et<32;et++){if(c[l])return c[l];if(!c.prototype||"object"!=typeof c.prototype)break;c=Object.getPrototypeOf(c.prototype).constructor}return null}function resolveProperties(c){var l,et,eo,es;return l=this,et=void 0,eo=void 0,es=function*(){let l=Object.keys(c).map(l=>{let et=c[l];return Promise.resolve(et).then(c=>({key:l,value:c}))}),et=yield Promise.all(l);return et.reduce((c,l)=>(c[l.key]=l.value,c),{})},new(eo||(eo=Promise))(function(c,ec){function fulfilled(c){try{step(es.next(c))}catch(c){ec(c)}}function rejected(c){try{step(es.throw(c))}catch(c){ec(c)}}function step(l){var et;l.done?c(l.value):((et=l.value)instanceof eo?et:new eo(function(c){c(et)})).then(fulfilled,rejected)}step((es=es.apply(l,et||[])).next())})}function checkProperties(c,l){c&&"object"==typeof c||es.throwArgumentError("invalid object","object",c),Object.keys(c).forEach(et=>{l[et]||es.throwArgumentError("invalid object key - "+et,"transaction:"+et,c)})}function shallowCopy(c){let l={};for(let et in c)l[et]=c[et];return l}let ec={bigint:!0,boolean:!0,function:!0,number:!0,string:!0};function deepCopy(c){return function(c){if(function _isFrozen(c){if(null==c||ec[typeof c])return!0;if(Array.isArray(c)||"object"==typeof c){if(!Object.isFrozen(c))return!1;let l=Object.keys(c);for(let et=0;etdeepCopy(c)));if("object"==typeof c){let l={};for(let et in c){let eo=c[et];void 0!==eo&&defineReadOnly(l,et,deepCopy(eo))}return l}return es.throwArgumentError(`Cannot deepCopy ${typeof c}`,"object",c)}(c)}let Description=class Description{constructor(c){for(let l in c)this[l]=deepCopy(c[l])}}},12312:function(c,l,et){"use strict";et.d(l,{i:function(){return eo}});let eo="providers/5.7.2"},32074:function(c,l,et){"use strict";let eo,es;et.d(l,{r:function(){return JsonRpcProvider}});var ec,el,ed,eh=et(14941),ef=et(92598),ep=et(57273),eg=et(18994),em=et(14184),eb=et(17213),ey=et(36288);let e_="hash/5.7.0";var ew=et(58337);function id(c){return(0,em.w)((0,ew.Y0)(c))}let eE=new ey.Yd(e_),eS=new Uint8Array(32);eS.fill(0);let ex=ef.O$.from(-1),ek=ef.O$.from(0),eC=ef.O$.from(1),eA=ef.O$.from("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"),eI=(0,ep.$m)(eC.toHexString(),32),eP=(0,ep.$m)(ek.toHexString(),32),eR={name:"string",version:"string",chainId:"uint256",verifyingContract:"address",salt:"bytes32"},eO=["name","version","chainId","verifyingContract","salt"];function checkString(c){return function(l){return"string"!=typeof l&&eE.throwArgumentError(`invalid domain value for ${JSON.stringify(c)}`,`domain.${c}`,l),l}}let eT={name:checkString("name"),version:checkString("version"),chainId:function(c){try{return ef.O$.from(c).toString()}catch(c){}return eE.throwArgumentError('invalid domain value for "chainId"',"domain.chainId",c)},verifyingContract:function(c){try{return(0,eg.Kn)(c).toLowerCase()}catch(c){}return eE.throwArgumentError('invalid domain value "verifyingContract"',"domain.verifyingContract",c)},salt:function(c){try{let l=(0,ep.lE)(c);if(32!==l.length)throw Error("bad length");return(0,ep.Dv)(l)}catch(c){}return eE.throwArgumentError('invalid domain value "salt"',"domain.salt",c)}};function getBaseEncoder(c){{let l=c.match(/^(u?)int(\d*)$/);if(l){let et=""===l[1],eo=parseInt(l[2]||"256");(eo%8!=0||eo>256||l[2]&&l[2]!==String(eo))&&eE.throwArgumentError("invalid numeric width","type",c);let es=eA.mask(et?eo-1:eo),ec=et?es.add(eC).mul(ex):ek;return function(l){let et=ef.O$.from(l);return(et.lt(ec)||et.gt(es))&&eE.throwArgumentError(`value out-of-bounds for ${c}`,"value",l),(0,ep.$m)(et.toTwos(256).toHexString(),32)}}}{let l=c.match(/^bytes(\d+)$/);if(l){let et=parseInt(l[1]);return(0===et||et>32||l[1]!==String(et))&&eE.throwArgumentError("invalid bytes width","type",c),function(l){let eo=(0,ep.lE)(l);return eo.length!==et&&eE.throwArgumentError(`invalid length for ${c}`,"value",l),function(c){let l=(0,ep.lE)(c),et=l.length%32;return et?(0,ep.xs)([l,eS.slice(et)]):(0,ep.Dv)(l)}(l)}}}switch(c){case"address":return function(c){return(0,ep.$m)((0,eg.Kn)(c),32)};case"bool":return function(c){return c?eI:eP};case"bytes":return function(c){return(0,em.w)(c)};case"string":return function(c){return id(c)}}return null}function encodeType(c,l){return`${c}(${l.map(({name:c,type:l})=>l+" "+c).join(",")})`}let TypedDataEncoder=class TypedDataEncoder{constructor(c){(0,eb.zG)(this,"types",Object.freeze((0,eb.p$)(c))),(0,eb.zG)(this,"_encoderCache",{}),(0,eb.zG)(this,"_types",{});let l={},et={},eo={};for(let es in Object.keys(c).forEach(c=>{l[c]={},et[c]=[],eo[c]={}}),c){let eo={};c[es].forEach(ec=>{eo[ec.name]&&eE.throwArgumentError(`duplicate variable name ${JSON.stringify(ec.name)} in ${JSON.stringify(es)}`,"types",c),eo[ec.name]=!0;let el=ec.type.match(/^([^\x5b]*)(\x5b|$)/)[1];el===es&&eE.throwArgumentError(`circular type reference to ${JSON.stringify(el)}`,"types",c);let ed=getBaseEncoder(el);ed||(et[el]||eE.throwArgumentError(`unknown type ${JSON.stringify(el)}`,"types",c),et[el].push(es),l[es][el]=!0)})}let es=Object.keys(et).filter(c=>0===et[c].length);for(let ec in 0===es.length?eE.throwArgumentError("missing primary type","types",c):es.length>1&&eE.throwArgumentError(`ambiguous primary types or unused types: ${es.map(c=>JSON.stringify(c)).join(", ")}`,"types",c),(0,eb.zG)(this,"primaryType",es[0]),!function checkCircular(es,ec){ec[es]&&eE.throwArgumentError(`circular type reference to ${JSON.stringify(es)}`,"types",c),ec[es]=!0,Object.keys(l[es]).forEach(c=>{et[c]&&(checkCircular(c,ec),Object.keys(ec).forEach(l=>{eo[l][c]=!0}))}),delete ec[es]}(this.primaryType,{}),eo){let l=Object.keys(eo[ec]);l.sort(),this._types[ec]=encodeType(ec,c[ec])+l.map(l=>encodeType(l,c[l])).join("")}}getEncoder(c){let l=this._encoderCache[c];return l||(l=this._encoderCache[c]=this._getEncoder(c)),l}_getEncoder(c){{let l=getBaseEncoder(c);if(l)return l}let l=c.match(/^(.*)(\x5b(\d*)\x5d)$/);if(l){let c=l[1],et=this.getEncoder(c),eo=parseInt(l[3]);return l=>{eo>=0&&l.length!==eo&&eE.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",l);let es=l.map(et);return this._types[c]&&(es=es.map(em.w)),(0,em.w)((0,ep.xs)(es))}}let et=this.types[c];if(et){let l=id(this._types[c]);return c=>{let eo=et.map(({name:l,type:et})=>{let eo=this.getEncoder(et)(c[l]);return this._types[et]?(0,em.w)(eo):eo});return eo.unshift(l),(0,ep.xs)(eo)}}return eE.throwArgumentError(`unknown type: ${c}`,"type",c)}encodeType(c){let l=this._types[c];return l||eE.throwArgumentError(`unknown type: ${JSON.stringify(c)}`,"name",c),l}encodeData(c,l){return this.getEncoder(c)(l)}hashStruct(c,l){return(0,em.w)(this.encodeData(c,l))}encode(c){return this.encodeData(this.primaryType,c)}hash(c){return this.hashStruct(this.primaryType,c)}_visit(c,l,et){{let eo=getBaseEncoder(c);if(eo)return et(c,l)}let eo=c.match(/^(.*)(\x5b(\d*)\x5d)$/);if(eo){let c=eo[1],es=parseInt(eo[3]);return es>=0&&l.length!==es&&eE.throwArgumentError("array length mismatch; expected length ${ arrayLength }","value",l),l.map(l=>this._visit(c,l,et))}let es=this.types[c];return es?es.reduce((c,{name:eo,type:es})=>(c[eo]=this._visit(es,l[eo],et),c),{}):eE.throwArgumentError(`unknown type: ${c}`,"type",c)}visit(c,l){return this._visit(this.primaryType,c,l)}static from(c){return new TypedDataEncoder(c)}static getPrimaryType(c){return TypedDataEncoder.from(c).primaryType}static hashStruct(c,l,et){return TypedDataEncoder.from(l).hashStruct(c,et)}static hashDomain(c){let l=[];for(let et in c){let eo=eR[et];eo||eE.throwArgumentError(`invalid typed-data domain key: ${JSON.stringify(et)}`,"domain",c),l.push({name:et,type:eo})}return l.sort((c,l)=>eO.indexOf(c.name)-eO.indexOf(l.name)),TypedDataEncoder.hashStruct("EIP712Domain",{EIP712Domain:l},c)}static encode(c,l,et){return(0,ep.xs)(["0x1901",TypedDataEncoder.hashDomain(c),TypedDataEncoder.from(l).hash(et)])}static hash(c,l,et){return(0,em.w)(TypedDataEncoder.encode(c,l,et))}static resolveNames(c,l,et,eo){var es,ec,el,ed;return es=this,ec=void 0,el=void 0,ed=function*(){c=(0,eb.DC)(c);let es={};c.verifyingContract&&!(0,ep.A7)(c.verifyingContract,20)&&(es[c.verifyingContract]="0x");let ec=TypedDataEncoder.from(l);for(let c in ec.visit(et,(c,l)=>("address"!==c||(0,ep.A7)(l,20)||(es[l]="0x"),l)),es)es[c]=yield eo(c);return c.verifyingContract&&es[c.verifyingContract]&&(c.verifyingContract=es[c.verifyingContract]),{domain:c,value:et=ec.visit(et,(c,l)=>"address"===c&&es[l]?es[l]:l)}},new(el||(el=Promise))(function(c,l){function fulfilled(c){try{step(ed.next(c))}catch(c){l(c)}}function rejected(c){try{step(ed.throw(c))}catch(c){l(c)}}function step(l){var et;l.done?c(l.value):((et=l.value)instanceof el?et:new el(function(c){c(et)})).then(fulfilled,rejected)}step((ed=ed.apply(es,ec||[])).next())})}static getPayload(c,l,et){TypedDataEncoder.hashDomain(c);let eo={},es=[];eO.forEach(l=>{let et=c[l];null!=et&&(eo[l]=eT[l](et),es.push({name:l,type:eR[l]}))});let ec=TypedDataEncoder.from(l),el=(0,eb.DC)(l);return el.EIP712Domain?eE.throwArgumentError("types must not contain EIP712Domain type","types.EIP712Domain",l):el.EIP712Domain=es,ec.encode(et),{types:el,domain:eo,primaryType:ec.primaryType,message:ec.visit(et,(c,l)=>{if(c.match(/^bytes(\d*)/))return(0,ep.Dv)((0,ep.lE)(l));if(c.match(/^u?int/))return ef.O$.from(l).toString();switch(c){case"address":return l.toLowerCase();case"bool":return!!l;case"string":return"string"!=typeof l&&eE.throwArgumentError("invalid string","value",l),l}return eE.throwArgumentError("unsupported type","type",c)})}}};let eN=ef.O$.from(0);var eM=et(7054),e$=et(56662),eB=et.n(e$),eD=et(55336),ej=et.n(eD);function createCommonjsModule(c,l,et){return c(et={path:l,exports:{},require:function(c,l){return function(){throw Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(c,null==l?et.path:l)}},et.exports),et.exports}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==et.g?et.g:"undefined"!=typeof self&&self;var eL=assert;function assert(c,l){if(!c)throw Error(l||"Assertion failed")}assert.equal=function(c,l,et){if(c!=l)throw Error(et||"Assertion failed: "+c+" != "+l)};var eF=createCommonjsModule(function(c,l){function zero2(c){return 1===c.length?"0"+c:c}function toHex(c){for(var l="",et=0;et>8,el=255&es;ec?et.push(ec,el):et.push(el)}return et},l.zero2=zero2,l.toHex=toHex,l.encode=function(c,l){return"hex"===l?toHex(c):c}}),eU=createCommonjsModule(function(c,l){l.assert=eL,l.toArray=eF.toArray,l.zero2=eF.zero2,l.toHex=eF.toHex,l.encode=eF.encode,l.getNAF=function(c,l,et){var eo=Array(Math.max(c.bitLength(),et)+1);eo.fill(0);for(var es=1<(es>>1)-1?(es>>1)-eh:eh,ec.isubn(ed)):ed=0,eo[el]=ed,ec.iushrn(1)}return eo},l.getJSF=function(c,l){var et=[[],[]];c=c.clone(),l=l.clone();for(var eo=0,es=0;c.cmpn(-eo)>0||l.cmpn(-es)>0;){var ec,el,ed,eh=c.andln(3)+eo&3,ef=l.andln(3)+es&3;3===eh&&(eh=-1),3===ef&&(ef=-1),el=(1&eh)==0?0:(3==(ec=c.andln(7)+eo&7)||5===ec)&&2===ef?-eh:eh,et[0].push(el),ed=(1&ef)==0?0:(3==(ec=l.andln(7)+es&7)||5===ec)&&2===eh?-ef:ef,et[1].push(ed),2*eo===el+1&&(eo=1-eo),2*es===ed+1&&(es=1-es),c.iushrn(1),l.iushrn(1)}return et},l.cachedProperty=function(c,l,et){var eo="_"+l;c.prototype[l]=function(){return void 0!==this[eo]?this[eo]:this[eo]=et.call(this)}},l.parseBytes=function(c){return"string"==typeof c?l.toArray(c,"hex"):c},l.intFromLE=function(c){return new(eB())(c,"hex","le")}}),ez=eU.getNAF,eH=eU.getJSF,eW=eU.assert;function BaseCurve(c,l){this.type=c,this.p=new(eB())(l.p,16),this.red=l.prime?eB().red(l.prime):eB().mont(this.p),this.zero=new(eB())(0).toRed(this.red),this.one=new(eB())(1).toRed(this.red),this.two=new(eB())(2).toRed(this.red),this.n=l.n&&new(eB())(l.n,16),this.g=l.g&&this.pointFromJSON(l.g,l.gRed),this._wnafT1=[,,,,],this._wnafT2=[,,,,],this._wnafT3=[,,,,],this._wnafT4=[,,,,],this._bitLength=this.n?this.n.bitLength():0;var et=this.n&&this.p.div(this.n);!et||et.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function BasePoint(c,l){this.curve=c,this.type=l,this.precomputed=null}BaseCurve.prototype.point=function(){throw Error("Not implemented")},BaseCurve.prototype.validate=function(){throw Error("Not implemented")},BaseCurve.prototype._fixedNafMul=function(c,l){eW(c.precomputed);var et,eo,es=c._getDoubles(),ec=ez(l,1,this._bitLength),el=(1<=et;eh--)eo=(eo<<1)+ec[eh];ed.push(eo)}for(var ef=this.jpoint(null,null,null),ep=this.jpoint(null,null,null),eg=el;eg>0;eg--){for(et=0;et=0;ed--){for(var eh=0;ed>=0&&0===ec[ed];ed--)eh++;if(ed>=0&&eh++,el=el.dblp(eh),ed<0)break;var ef=ec[ed];eW(0!==ef),el="affine"===c.type?ef>0?el.mixedAdd(es[ef-1>>1]):el.mixedAdd(es[-ef-1>>1].neg()):ef>0?el.add(es[ef-1>>1]):el.add(es[-ef-1>>1].neg())}return"affine"===c.type?el.toP():el},BaseCurve.prototype._wnafMulAdd=function(c,l,et,eo,es){var ec,el,ed,eh=this._wnafT1,ef=this._wnafT2,ep=this._wnafT3,eg=0;for(ec=0;ec=1;ec-=2){var eb=ec-1,ey=ec;if(1!==eh[eb]||1!==eh[ey]){ep[eb]=ez(et[eb],eh[eb],this._bitLength),ep[ey]=ez(et[ey],eh[ey],this._bitLength),eg=Math.max(ep[eb].length,eg),eg=Math.max(ep[ey].length,eg);continue}var e_=[l[eb],null,null,l[ey]];0===l[eb].y.cmp(l[ey].y)?(e_[1]=l[eb].add(l[ey]),e_[2]=l[eb].toJ().mixedAdd(l[ey].neg())):0===l[eb].y.cmp(l[ey].y.redNeg())?(e_[1]=l[eb].toJ().mixedAdd(l[ey]),e_[2]=l[eb].add(l[ey].neg())):(e_[1]=l[eb].toJ().mixedAdd(l[ey]),e_[2]=l[eb].toJ().mixedAdd(l[ey].neg()));var ew=[-3,-1,-5,-7,0,7,5,1,3],eE=eH(et[eb],et[ey]);for(el=0,eg=Math.max(eE[0].length,eg),ep[eb]=Array(eg),ep[ey]=Array(eg);el=0;ec--){for(var eA=0;ec>=0;){var eI=!0;for(el=0;el=0&&eA++,ek=ek.dblp(eA),ec<0)break;for(el=0;el0?ed=ef[el][eP-1>>1]:eP<0&&(ed=ef[el][-eP-1>>1].neg()),ek="affine"===ed.type?ek.mixedAdd(ed):ek.add(ed))}}for(ec=0;ec=Math.ceil((c.bitLength()+1)/l.step)},BasePoint.prototype._getDoubles=function(c,l){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var et=[this],eo=this,es=0;eses[0].cmp(es[1])?es[0]:es[1]).toRed(this.red)}if(c.lambda)et=new(eB())(c.lambda,16);else{var ec=this._getEndoRoots(this.n);0===this.g.mul(ec[0]).x.cmp(this.g.x.redMul(l))?et=ec[0]:(et=ec[1],eG(0===this.g.mul(et).x.cmp(this.g.x.redMul(l))))}return eo=c.basis?c.basis.map(function(c){return{a:new(eB())(c.a,16),b:new(eB())(c.b,16)}}):this._getEndoBasis(et),{beta:l,lambda:et,basis:eo}}},ShortCurve.prototype._getEndoRoots=function(c){var l=c===this.p?this.red:eB().mont(c),et=new(eB())(2).toRed(l).redInvm(),eo=et.redNeg(),es=new(eB())(3).toRed(l).redNeg().redSqrt().redMul(et);return[eo.redAdd(es).fromRed(),eo.redSub(es).fromRed()]},ShortCurve.prototype._getEndoBasis=function(c){for(var l,et,eo,es,ec,el,ed,eh,ef,ep=this.n.ushrn(Math.floor(this.n.bitLength()/2)),eg=c,em=this.n.clone(),eb=new(eB())(1),ey=new(eB())(0),e_=new(eB())(0),ew=new(eB())(1),eE=0;0!==eg.cmpn(0);){var eS=em.div(eg);eh=em.sub(eS.mul(eg)),ef=e_.sub(eS.mul(eb));var ex=ew.sub(eS.mul(ey));if(!eo&&0>eh.cmp(ep))l=ed.neg(),et=eb,eo=eh.neg(),es=ef;else if(eo&&2==++eE)break;ed=eh,em=eg,eg=eh,e_=eb,eb=ef,ew=ey,ey=ex}ec=eh.neg(),el=ef;var ek=eo.sqr().add(es.sqr());return ec.sqr().add(el.sqr()).cmp(ek)>=0&&(ec=l,el=et),eo.negative&&(eo=eo.neg(),es=es.neg()),ec.negative&&(ec=ec.neg(),el=el.neg()),[{a:eo,b:es},{a:ec,b:el}]},ShortCurve.prototype._endoSplit=function(c){var l=this.endo.basis,et=l[0],eo=l[1],es=eo.b.mul(c).divRound(this.n),ec=et.b.neg().mul(c).divRound(this.n),el=es.mul(et.a),ed=ec.mul(eo.a),eh=es.mul(et.b),ef=ec.mul(eo.b);return{k1:c.sub(el).sub(ed),k2:eh.add(ef).neg()}},ShortCurve.prototype.pointFromX=function(c,l){(c=new(eB())(c,16)).red||(c=c.toRed(this.red));var et=c.redSqr().redMul(c).redIAdd(c.redMul(this.a)).redIAdd(this.b),eo=et.redSqrt();if(0!==eo.redSqr().redSub(et).cmp(this.zero))throw Error("invalid point");var es=eo.fromRed().isOdd();return(l&&!es||!l&&es)&&(eo=eo.redNeg()),this.point(c,eo)},ShortCurve.prototype.validate=function(c){if(c.inf)return!0;var l=c.x,et=c.y,eo=this.a.redMul(l),es=l.redSqr().redMul(l).redIAdd(eo).redIAdd(this.b);return 0===et.redSqr().redISub(es).cmpn(0)},ShortCurve.prototype._endoWnafMulAdd=function(c,l,et){for(var eo=this._endoWnafT1,es=this._endoWnafT2,ec=0;ec":""},Point.prototype.isInfinity=function(){return this.inf},Point.prototype.add=function(c){if(this.inf)return c;if(c.inf)return this;if(this.eq(c))return this.dbl();if(this.neg().eq(c)||0===this.x.cmp(c.x))return this.curve.point(null,null);var l=this.y.redSub(c.y);0!==l.cmpn(0)&&(l=l.redMul(this.x.redSub(c.x).redInvm()));var et=l.redSqr().redISub(this.x).redISub(c.x),eo=l.redMul(this.x.redSub(et)).redISub(this.y);return this.curve.point(et,eo)},Point.prototype.dbl=function(){if(this.inf)return this;var c=this.y.redAdd(this.y);if(0===c.cmpn(0))return this.curve.point(null,null);var l=this.curve.a,et=this.x.redSqr(),eo=c.redInvm(),es=et.redAdd(et).redIAdd(et).redIAdd(l).redMul(eo),ec=es.redSqr().redISub(this.x.redAdd(this.x)),el=es.redMul(this.x.redSub(ec)).redISub(this.y);return this.curve.point(ec,el)},Point.prototype.getX=function(){return this.x.fromRed()},Point.prototype.getY=function(){return this.y.fromRed()},Point.prototype.mul=function(c){return(c=new(eB())(c,16),this.isInfinity())?this:this._hasDoubles(c)?this.curve._fixedNafMul(this,c):this.curve.endo?this.curve._endoWnafMulAdd([this],[c]):this.curve._wnafMul(this,c)},Point.prototype.mulAdd=function(c,l,et){var eo=[this,l],es=[c,et];return this.curve.endo?this.curve._endoWnafMulAdd(eo,es):this.curve._wnafMulAdd(1,eo,es,2)},Point.prototype.jmulAdd=function(c,l,et){var eo=[this,l],es=[c,et];return this.curve.endo?this.curve._endoWnafMulAdd(eo,es,!0):this.curve._wnafMulAdd(1,eo,es,2,!0)},Point.prototype.eq=function(c){return this===c||this.inf===c.inf&&(this.inf||0===this.x.cmp(c.x)&&0===this.y.cmp(c.y))},Point.prototype.neg=function(c){if(this.inf)return this;var l=this.curve.point(this.x,this.y.redNeg());if(c&&this.precomputed){var et=this.precomputed,negate=function(c){return c.neg()};l.precomputed={naf:et.naf&&{wnd:et.naf.wnd,points:et.naf.points.map(negate)},doubles:et.doubles&&{step:et.doubles.step,points:et.doubles.points.map(negate)}}}return l},Point.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},eV(JPoint,BaseCurve.BasePoint),ShortCurve.prototype.jpoint=function(c,l,et){return new JPoint(this,c,l,et)},JPoint.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var c=this.z.redInvm(),l=c.redSqr(),et=this.x.redMul(l),eo=this.y.redMul(l).redMul(c);return this.curve.point(et,eo)},JPoint.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},JPoint.prototype.add=function(c){if(this.isInfinity())return c;if(c.isInfinity())return this;var l=c.z.redSqr(),et=this.z.redSqr(),eo=this.x.redMul(l),es=c.x.redMul(et),ec=this.y.redMul(l.redMul(c.z)),el=c.y.redMul(et.redMul(this.z)),ed=eo.redSub(es),eh=ec.redSub(el);if(0===ed.cmpn(0))return 0!==eh.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var ef=ed.redSqr(),ep=ef.redMul(ed),eg=eo.redMul(ef),em=eh.redSqr().redIAdd(ep).redISub(eg).redISub(eg),eb=eh.redMul(eg.redISub(em)).redISub(ec.redMul(ep)),ey=this.z.redMul(c.z).redMul(ed);return this.curve.jpoint(em,eb,ey)},JPoint.prototype.mixedAdd=function(c){if(this.isInfinity())return c.toJ();if(c.isInfinity())return this;var l=this.z.redSqr(),et=this.x,eo=c.x.redMul(l),es=this.y,ec=c.y.redMul(l).redMul(this.z),el=et.redSub(eo),ed=es.redSub(ec);if(0===el.cmpn(0))return 0!==ed.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var eh=el.redSqr(),ef=eh.redMul(el),ep=et.redMul(eh),eg=ed.redSqr().redIAdd(ef).redISub(ep).redISub(ep),em=ed.redMul(ep.redISub(eg)).redISub(es.redMul(ef)),eb=this.z.redMul(el);return this.curve.jpoint(eg,em,eb)},JPoint.prototype.dblp=function(c){if(0===c||this.isInfinity())return this;if(!c)return this.dbl();if(this.curve.zeroA||this.curve.threeA){var l,et=this;for(l=0;l=0)return!1;if(et.redIAdd(es),0===this.x.cmp(et))return!0}},JPoint.prototype.inspect=function(){return this.isInfinity()?"":""},JPoint.prototype.isInfinity=function(){return 0===this.z.cmpn(0)};var eK=createCommonjsModule(function(c,l){l.base=BaseCurve,l.short=ShortCurve,l.mont=null,l.edwards=null}),eJ=createCommonjsModule(function(c,l){var et,eo=eU.assert;function PresetCurve(c){"short"===c.type?this.curve=new eK.short(c):"edwards"===c.type?this.curve=new eK.edwards(c):this.curve=new eK.mont(c),this.g=this.curve.g,this.n=this.curve.n,this.hash=c.hash,eo(this.g.validate(),"Invalid curve"),eo(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function defineCurve(c,et){Object.defineProperty(l,c,{configurable:!0,enumerable:!0,get:function(){var eo=new PresetCurve(et);return Object.defineProperty(l,c,{configurable:!0,enumerable:!0,value:eo}),eo}})}l.PresetCurve=PresetCurve,defineCurve("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:ej().sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),defineCurve("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:ej().sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),defineCurve("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:ej().sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),defineCurve("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:ej().sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),defineCurve("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:ej().sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),defineCurve("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:ej().sha256,gRed:!1,g:["9"]}),defineCurve("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:ej().sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{et=null.crash()}catch(c){et=void 0}defineCurve("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:ej().sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",et]})});function HmacDRBG(c){if(!(this instanceof HmacDRBG))return new HmacDRBG(c);this.hash=c.hash,this.predResist=!!c.predResist,this.outLen=this.hash.outSize,this.minEntropy=c.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var l=eF.toArray(c.entropy,c.entropyEnc||"hex"),et=eF.toArray(c.nonce,c.nonceEnc||"hex"),eo=eF.toArray(c.pers,c.persEnc||"hex");eL(l.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(l,et,eo)}HmacDRBG.prototype._init=function(c,l,et){var eo=c.concat(l).concat(et);this.K=Array(this.outLen/8),this.V=Array(this.outLen/8);for(var es=0;es=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(c.concat(et||[])),this._reseed=1},HmacDRBG.prototype.generate=function(c,l,et,eo){if(this._reseed>this.reseedInterval)throw Error("Reseed is required");"string"!=typeof l&&(eo=et,et=l,l=null),et&&(et=eF.toArray(et,eo||"hex"),this._update(et));for(var es=[];es.length"};var eY=eU.assert;function Signature(c,l){if(c instanceof Signature)return c;this._importDER(c,l)||(eY(c.r&&c.s,"Signature without r or s"),this.r=new(eB())(c.r,16),this.s=new(eB())(c.s,16),void 0===c.recoveryParam?this.recoveryParam=null:this.recoveryParam=c.recoveryParam)}function Position(){this.place=0}function getLength(c,l){var et=c[l.place++];if(!(128&et))return et;var eo=15&et;if(0===eo||eo>4)return!1;for(var es=0,ec=0,el=l.place;ec>>=0;return!(es<=127)&&(l.place=el,es)}function rmPadding(c){for(var l=0,et=c.length-1;!c[l]&&!(128&c[l+1])&&l>>3);for(c.push(128|et);--et;)c.push(l>>>(et<<3)&255);c.push(l)}Signature.prototype._importDER=function(c,l){c=eU.toArray(c,l);var et=new Position;if(48!==c[et.place++])return!1;var eo=getLength(c,et);if(!1===eo||eo+et.place!==c.length||2!==c[et.place++])return!1;var es=getLength(c,et);if(!1===es)return!1;var ec=c.slice(et.place,es+et.place);if(et.place+=es,2!==c[et.place++])return!1;var el=getLength(c,et);if(!1===el||c.length!==el+et.place)return!1;var ed=c.slice(et.place,el+et.place);if(0===ec[0]){if(!(128&ec[1]))return!1;ec=ec.slice(1)}if(0===ed[0]){if(!(128&ed[1]))return!1;ed=ed.slice(1)}return this.r=new(eB())(ec),this.s=new(eB())(ed),this.recoveryParam=null,!0},Signature.prototype.toDER=function(c){var l=this.r.toArray(),et=this.s.toArray();for(128&l[0]&&(l=[0].concat(l)),128&et[0]&&(et=[0].concat(et)),l=rmPadding(l),et=rmPadding(et);!et[0]&&!(128&et[1]);)et=et.slice(1);var eo=[2];constructLength(eo,l.length),(eo=eo.concat(l)).push(2),constructLength(eo,et.length);var es=eo.concat(et),ec=[48];return constructLength(ec,es.length),ec=ec.concat(es),eU.encode(ec,c)};var rand=function(){throw Error("unsupported")},eZ=eU.assert;function EC(c){if(!(this instanceof EC))return new EC(c);"string"==typeof c&&(eZ(Object.prototype.hasOwnProperty.call(eJ,c),"Unknown curve "+c),c=eJ[c]),c instanceof eJ.PresetCurve&&(c={curve:c}),this.curve=c.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=c.curve.g,this.g.precompute(c.curve.n.bitLength()+1),this.hash=c.hash||c.curve.hash}EC.prototype.keyPair=function(c){return new KeyPair(this,c)},EC.prototype.keyFromPrivate=function(c,l){return KeyPair.fromPrivate(this,c,l)},EC.prototype.keyFromPublic=function(c,l){return KeyPair.fromPublic(this,c,l)},EC.prototype.genKeyPair=function(c){c||(c={});for(var l=new HmacDRBG({hash:this.hash,pers:c.pers,persEnc:c.persEnc||"utf8",entropy:c.entropy||rand(this.hash.hmacStrength),entropyEnc:c.entropy&&c.entropyEnc||"utf8",nonce:this.n.toArray()}),et=this.n.byteLength(),eo=this.n.sub(new(eB())(2));;){var es=new(eB())(l.generate(et));if(!(es.cmp(eo)>0))return es.iaddn(1),this.keyFromPrivate(es)}},EC.prototype._truncateToN=function(c,l){var et=8*c.byteLength()-this.n.bitLength();return(et>0&&(c=c.ushrn(et)),!l&&c.cmp(this.n)>=0)?c.sub(this.n):c},EC.prototype.sign=function(c,l,et,eo){"object"==typeof et&&(eo=et,et=null),eo||(eo={}),l=this.keyFromPrivate(l,et),c=this._truncateToN(new(eB())(c,16));for(var es=this.n.byteLength(),ec=l.getPrivate().toArray("be",es),el=c.toArray("be",es),ed=new HmacDRBG({hash:this.hash,entropy:ec,nonce:el,pers:eo.pers,persEnc:eo.persEnc||"utf8"}),eh=this.n.sub(new(eB())(1)),ef=0;;ef++){var ep=eo.k?eo.k(ef):new(eB())(ed.generate(this.n.byteLength()));if(!(0>=(ep=this._truncateToN(ep,!0)).cmpn(1)||ep.cmp(eh)>=0)){var eg=this.g.mul(ep);if(!eg.isInfinity()){var em=eg.getX(),eb=em.umod(this.n);if(0!==eb.cmpn(0)){var ey=ep.invm(this.n).mul(eb.mul(l.getPrivate()).iadd(c));if(0!==(ey=ey.umod(this.n)).cmpn(0)){var e_=(eg.getY().isOdd()?1:0)|(0!==em.cmp(eb)?2:0);return eo.canonical&&ey.cmp(this.nh)>0&&(ey=this.n.sub(ey),e_^=1),new Signature({r:eb,s:ey,recoveryParam:e_})}}}}}},EC.prototype.verify=function(c,l,et,eo){c=this._truncateToN(new(eB())(c,16)),et=this.keyFromPublic(et,eo);var es,ec=(l=new Signature(l,"hex")).r,el=l.s;if(0>ec.cmpn(1)||ec.cmp(this.n)>=0||0>el.cmpn(1)||el.cmp(this.n)>=0)return!1;var ed=el.invm(this.n),eh=ed.mul(c).umod(this.n),ef=ed.mul(ec).umod(this.n);return this.curve._maxwellTrick?!(es=this.g.jmulAdd(eh,et.getPublic(),ef)).isInfinity()&&es.eqXToP(ec):!(es=this.g.mulAdd(eh,et.getPublic(),ef)).isInfinity()&&0===es.getX().umod(this.n).cmp(ec)},EC.prototype.recoverPubKey=function(c,l,et,eo){eZ((3&et)===et,"The recovery param is more than two bits"),l=new Signature(l,eo);var es=this.n,ec=new(eB())(c),el=l.r,ed=l.s,eh=1&et,ef=et>>1;if(el.cmp(this.curve.p.umod(this.curve.n))>=0&&ef)throw Error("Unable to find sencond key candinate");el=ef?this.curve.pointFromX(el.add(this.curve.n),eh):this.curve.pointFromX(el,eh);var ep=l.r.invm(es),eg=es.sub(ec).mul(ep).umod(es),em=ed.mul(ep).umod(es);return this.g.mulAdd(eg,el,em)},EC.prototype.getKeyRecoveryParam=function(c,l,et,eo){if(null!==(l=new Signature(l,eo)).recoveryParam)return l.recoveryParam;for(var es,ec=0;ec<4;ec++){try{es=this.recoverPubKey(c,l,ec)}catch(c){continue}if(es.eq(et))return ec}throw Error("Unable to find valid recovery factor")};var eX=createCommonjsModule(function(c,l){l.version="6.5.4",l.utils=eU,l.rand=function(){throw Error("unsupported")},l.curve=eK,l.curves=eJ,l.ec=EC,l.eddsa=null}).ec;let e0=new ey.Yd("signing-key/5.7.0"),e1=null;function getCurve(){return e1||(e1=new eX("secp256k1")),e1}let SigningKey=class SigningKey{constructor(c){(0,eb.zG)(this,"curve","secp256k1"),(0,eb.zG)(this,"privateKey",(0,ep.Dv)(c)),32!==(0,ep.E1)(this.privateKey)&&e0.throwArgumentError("invalid private key","privateKey","[[ REDACTED ]]");let l=getCurve().keyFromPrivate((0,ep.lE)(this.privateKey));(0,eb.zG)(this,"publicKey","0x"+l.getPublic(!1,"hex")),(0,eb.zG)(this,"compressedPublicKey","0x"+l.getPublic(!0,"hex")),(0,eb.zG)(this,"_isSigningKey",!0)}_addPoint(c){let l=getCurve().keyFromPublic((0,ep.lE)(this.publicKey)),et=getCurve().keyFromPublic((0,ep.lE)(c));return"0x"+l.pub.add(et.pub).encodeCompressed("hex")}signDigest(c){let l=getCurve().keyFromPrivate((0,ep.lE)(this.privateKey)),et=(0,ep.lE)(c);32!==et.length&&e0.throwArgumentError("bad digest length","digest",c);let eo=l.sign(et,{canonical:!0});return(0,ep.N)({recoveryParam:eo.recoveryParam,r:(0,ep.$m)("0x"+eo.r.toString(16),32),s:(0,ep.$m)("0x"+eo.s.toString(16),32)})}computeSharedSecret(c){let l=getCurve().keyFromPrivate((0,ep.lE)(this.privateKey)),et=getCurve().keyFromPublic((0,ep.lE)(computePublicKey(c)));return(0,ep.$m)("0x"+l.derive(et.getPublic()).toString(16),32)}static isSigningKey(c){return!!(c&&c._isSigningKey)}};function computePublicKey(c,l){let et=(0,ep.lE)(c);if(32===et.length){let c=new SigningKey(et);return l?"0x"+getCurve().keyFromPrivate(et).getPublic(!0,"hex"):c.publicKey}return 33===et.length?l?(0,ep.Dv)(et):"0x"+getCurve().keyFromPublic(et).getPublic(!1,"hex"):65===et.length?l?"0x"+getCurve().keyFromPublic(et).getPublic(!0,"hex"):(0,ep.Dv)(et):e0.throwArgumentError("invalid public or private key","key","[REDACTED]")}let e2=new ey.Yd("transactions/5.7.0");function handleAddress(c){return"0x"===c?null:(0,eg.Kn)(c)}function handleNumber(c){return"0x"===c?eN:ef.O$.from(c)}function recoverAddress(c,l){return function(c){let l=computePublicKey(c);return(0,eg.Kn)((0,ep.p3)((0,em.w)((0,ep.p3)(l,1)),12))}(function(c,l){let et=(0,ep.N)(l),eo={r:(0,ep.lE)(et.r),s:(0,ep.lE)(et.s)};return"0x"+getCurve().recoverPubKey((0,ep.lE)(c),eo,et.recoveryParam).encode("hex",!1)}((0,ep.lE)(c),l))}function formatNumber(c,l){let et=(0,ep.G1)(ef.O$.from(c).toHexString());return et.length>32&&e2.throwArgumentError("invalid length for "+l,"transaction:"+l,c),et}function accessSetify(c,l){return{address:(0,eg.Kn)(c),storageKeys:(l||[]).map((l,et)=>(32!==(0,ep.E1)(l)&&e2.throwArgumentError("invalid access list storageKey",`accessList[${c}:${et}]`,l),l.toLowerCase()))}}function accessListify(c){if(Array.isArray(c))return c.map((c,l)=>Array.isArray(c)?(c.length>2&&e2.throwArgumentError("access list expected to be [ address, storageKeys[] ]",`value[${l}]`,c),accessSetify(c[0],c[1])):accessSetify(c.address,c.storageKeys));let l=Object.keys(c).map(l=>{let et=c[l].reduce((c,l)=>(c[l]=!0,c),{});return accessSetify(l,Object.keys(et).sort())});return l.sort((c,l)=>c.address.localeCompare(l.address)),l}function formatAccessList(c){return accessListify(c).map(c=>[c.address,c.storageKeys])}function _serializeEip1559(c,l){if(null!=c.gasPrice){let l=ef.O$.from(c.gasPrice),et=ef.O$.from(c.maxFeePerGas||0);l.eq(et)||e2.throwArgumentError("mismatch EIP-1559 gasPrice != maxFeePerGas","tx",{gasPrice:l,maxFeePerGas:et})}let et=[formatNumber(c.chainId||0,"chainId"),formatNumber(c.nonce||0,"nonce"),formatNumber(c.maxPriorityFeePerGas||0,"maxPriorityFeePerGas"),formatNumber(c.maxFeePerGas||0,"maxFeePerGas"),formatNumber(c.gasLimit||0,"gasLimit"),null!=c.to?(0,eg.Kn)(c.to):"0x",formatNumber(c.value||0,"value"),c.data||"0x",formatAccessList(c.accessList||[])];if(l){let c=(0,ep.N)(l);et.push(formatNumber(c.recoveryParam,"recoveryParam")),et.push((0,ep.G1)(c.r)),et.push((0,ep.G1)(c.s))}return(0,ep.xs)(["0x02",eM.c(et)])}function _serializeEip2930(c,l){let et=[formatNumber(c.chainId||0,"chainId"),formatNumber(c.nonce||0,"nonce"),formatNumber(c.gasPrice||0,"gasPrice"),formatNumber(c.gasLimit||0,"gasLimit"),null!=c.to?(0,eg.Kn)(c.to):"0x",formatNumber(c.value||0,"value"),c.data||"0x",formatAccessList(c.accessList||[])];if(l){let c=(0,ep.N)(l);et.push(formatNumber(c.recoveryParam,"recoveryParam")),et.push((0,ep.G1)(c.r)),et.push((0,ep.G1)(c.s))}return(0,ep.xs)(["0x01",eM.c(et)])}function _parseEipSignature(c,l,et){try{let et=handleNumber(l[0]).toNumber();if(0!==et&&1!==et)throw Error("bad recid");c.v=et}catch(c){e2.throwArgumentError("invalid v for transaction type: 1","v",l[0])}c.r=(0,ep.$m)(l[1],32),c.s=(0,ep.$m)(l[2],32);try{let l=(0,em.w)(et(c));c.from=recoverAddress(l,{r:c.r,s:c.s,recoveryParam:c.v})}catch(c){}}function decode(c){c=atob(c);let l=[];for(let et=0;et{setTimeout(l,c)})}function bodyify(c,l){if(null==c)return null;if("string"==typeof c)return c;if((0,ep.Zq)(c)){if(l&&("text"===l.split("/")[0]||"application/json"===l.split(";")[0].trim()))try{return(0,ew.ZN)(c)}catch(c){}return(0,ep.Dv)(c)}return c}function fetchJson(c,l,et){let eo=null;if(null!=l){eo=(0,ew.Y0)(l);let et="string"==typeof c?{url:c}:(0,eb.DC)(c);if(et.headers){let c=0!==Object.keys(et.headers).filter(c=>"content-type"===c.toLowerCase()).length;c||(et.headers=(0,eb.DC)(et.headers),et.headers["content-type"]="application/json")}else et.headers={"content-type":"application/json"};c=et}return function(c,l,et){let eo="object"==typeof c&&null!=c.throttleLimit?c.throttleLimit:12;e3.assertArgument(eo>0&&eo%1==0,"invalid connection throttle limit","connection.throttleLimit",eo);let es="object"==typeof c?c.throttleCallback:null,ec="object"==typeof c&&"number"==typeof c.throttleSlotInterval?c.throttleSlotInterval:100;e3.assertArgument(ec>0&&ec%1==0,"invalid connection throttle slot interval","connection.throttleSlotInterval",ec);let el="object"==typeof c&&!!c.errorPassThrough,ed={},eh=null,ef={method:"GET"},eg=!1,em=12e4;if("string"==typeof c)eh=c;else if("object"==typeof c){if((null==c||null==c.url)&&e3.throwArgumentError("missing URL","connection.url",c),eh=c.url,"number"==typeof c.timeout&&c.timeout>0&&(em=c.timeout),c.headers)for(let l in c.headers)ed[l.toLowerCase()]={key:l,value:String(c.headers[l])},["if-none-match","if-modified-since"].indexOf(l.toLowerCase())>=0&&(eg=!0);if(ef.allowGzip=!!c.allowGzip,null!=c.user&&null!=c.password){"https:"!==eh.substring(0,6)&&!0!==c.allowInsecureAuthentication&&e3.throwError("basic authentication requires a secure https url",ey.Yd.errors.INVALID_ARGUMENT,{argument:"url",url:eh,user:c.user,password:"[REDACTED]"});let l=c.user+":"+c.password;ed.authorization={key:"Authorization",value:"Basic "+encode((0,ew.Y0)(l))}}null!=c.skipFetchSetup&&(ef.skipFetchSetup=!!c.skipFetchSetup),null!=c.fetchOptions&&(ef.fetchOptions=(0,eb.DC)(c.fetchOptions))}let e_=RegExp("^data:([^;:]*)?(;base64)?,(.*)$","i"),eE=eh?eh.match(e_):null;if(eE)try{var eS;let c={statusCode:200,statusMessage:"OK",headers:{"content-type":eE[1]||"text/plain"},body:eE[2]?decode(eE[3]):(eS=eE[3],(0,ew.Y0)(eS.replace(/%([0-9a-f][0-9a-f])/gi,(c,l)=>String.fromCharCode(parseInt(l,16)))))},l=c.body;return et&&(l=et(c.body,c)),Promise.resolve(l)}catch(c){e3.throwError("processing response error",ey.Yd.errors.SERVER_ERROR,{body:bodyify(eE[1],eE[2]),error:c,requestBody:null,requestMethod:"GET",url:eh})}l&&(ef.method="POST",ef.body=l,null==ed["content-type"]&&(ed["content-type"]={key:"Content-Type",value:"application/octet-stream"}),null==ed["content-length"]&&(ed["content-length"]={key:"Content-Length",value:String(l.length)}));let ex={};Object.keys(ed).forEach(c=>{let l=ed[c];ex[l.key]=l.value}),ef.headers=ex;let ek=function(){let c=null,l=new Promise(function(l,et){em&&(c=setTimeout(()=>{null!=c&&(c=null,et(e3.makeError("timeout",ey.Yd.errors.TIMEOUT,{requestBody:bodyify(ef.body,ex["content-type"]),requestMethod:ef.method,timeout:em,url:eh})))},em))});return{promise:l,cancel:function(){null!=c&&(clearTimeout(c),c=null)}}}(),eC=function(){var c,l,ed,em;return c=this,l=void 0,ed=void 0,em=function*(){for(let c=0;c{ec[l.toLowerCase()]=c}):eo.headers.keys().forEach(c=>{ec[c.toLowerCase()]=eo.headers.get(c)}),{headers:ec,statusCode:eo.status,statusMessage:eo.statusText,body:(0,ep.lE)(new Uint8Array(es))}},new(es||(es=Promise))(function(c,l){function fulfilled(c){try{step(ec.next(c))}catch(c){l(c)}}function rejected(c){try{step(ec.throw(c))}catch(c){l(c)}}function step(l){var et;l.done?c(l.value):((et=l.value)instanceof es?et:new es(function(c){c(et)})).then(fulfilled,rejected)}step((ec=ec.apply(et,eo||[])).next())})}(eh,ef),c=300)&&(ek.cancel(),e3.throwError("bad response",ey.Yd.errors.SERVER_ERROR,{status:l.statusCode,headers:l.headers,body:bodyify(ed,l.headers?l.headers["content-type"]:null),requestBody:bodyify(ef.body,ex["content-type"]),requestMethod:ef.method,url:eh})),et)try{let c=yield et(ed,l);return ek.cancel(),c}catch(et){if(et.throttleRetry&&c{let eo=null;if(null!=c)try{eo=JSON.parse((0,ew.ZN)(c))}catch(l){e3.throwError("invalid JSON",ey.Yd.errors.SERVER_ERROR,{body:c,error:l})}return et&&(eo=et(eo,l)),eo})}function poll(c,l){return l||(l={}),null==(l=(0,eb.DC)(l)).floor&&(l.floor=0),null==l.ceiling&&(l.ceiling=1e4),null==l.interval&&(l.interval=250),new Promise(function(et,eo){let es=null,ec=!1,cancel=()=>!ec&&(ec=!0,es&&clearTimeout(es),!0);l.timeout&&(es=setTimeout(()=>{cancel()&&eo(Error("timeout"))},l.timeout));let el=l.retryLimit,ed=0;!function check(){return c().then(function(c){if(void 0!==c)cancel()&&et(c);else if(l.oncePoll)l.oncePoll.once("poll",check);else if(l.onceBlock)l.onceBlock.once("block",check);else if(!ec){if(++ed>el){cancel()&&eo(Error("retry limit reached"));return}let c=l.interval*parseInt(String(Math.random()*Math.pow(2,ed)));cl.ceiling&&(c=l.ceiling),setTimeout(check,c)}return null},function(c){cancel()&&eo(c)})}()})}var e5=et(12312);let e6=new ey.Yd("abstract-provider/5.7.0");let ForkEvent=class ForkEvent extends eb.dk{static isForkEvent(c){return!!(c&&c._isForkEvent)}};let Provider=class Provider{constructor(){e6.checkAbstract(new.target,Provider),(0,eb.zG)(this,"_isProvider",!0)}getFeeData(){var c,l,et,eo;return c=this,l=void 0,et=void 0,eo=function*(){let{block:c,gasPrice:l}=yield(0,eb.mE)({block:this.getBlock("latest"),gasPrice:this.getGasPrice().catch(c=>null)}),et=null,eo=null,es=null;return c&&c.baseFeePerGas&&(et=c.baseFeePerGas,es=ef.O$.from("1500000000"),eo=c.baseFeePerGas.mul(2).add(es)),{lastBaseFeePerGas:et,maxFeePerGas:eo,maxPriorityFeePerGas:es,gasPrice:l}},new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})}addListener(c,l){return this.on(c,l)}removeListener(c,l){return this.off(c,l)}static isProvider(c){return!!(c&&c._isProvider)}};let BaseX=class BaseX{constructor(c){(0,eb.zG)(this,"alphabet",c),(0,eb.zG)(this,"base",c.length),(0,eb.zG)(this,"_alphabetMap",{}),(0,eb.zG)(this,"_leader",c.charAt(0));for(let l=0;l0;)et.push(eo%this.base),eo=eo/this.base|0}let eo="";for(let c=0;0===l[c]&&c=0;--c)eo+=this.alphabet[et[c]];return eo}decode(c){if("string"!=typeof c)throw TypeError("Expected String");let l=[];if(0===c.length)return new Uint8Array(l);l.push(0);for(let et=0;et>=8;for(;es>0;)l.push(255&es),es>>=8}for(let et=0;c[et]===this._leader&&et0&&Array.isArray(c)?flatDeep(c,l-1):et.push(c)})};return flatDeep(c,l),et}function read_ascending(c,l){let et=Array(c);for(let eo=0,es=-1;eol[c]):et}function read_transposed(c,l,et){let eo=Array(c).fill(void 0).map(()=>[]);for(let es=0;es>1:eo>>1}return et})(c,et).forEach((c,l)=>eo[l].push(c));return eo}let e8=(ec=function(c){let l=0;function u16(){return c[l++]<<8|c[l++]}let et=u16(),eo=1,es=[0,1];for(let c=1;c>--ed&1}let ef=0;for(let c=0;c<31;c++)ef=ef<<1|read_bit();let ep=[],eg=0,em=2147483648;for(;;){let c=Math.floor(((ef-eg+1)*eo-1)/em),l=0,ec=et;for(;ec-l>1;){let et=l+ec>>>1;c{switch(l-eb){case 3:return eb+65792+(c[el++]<<16|c[el++]<<8|c[el++]);case 2:return eb+256+(c[el++]<<8|c[el++]);case 1:return eb+c[el++];default:return l-1}})}(decode("AEQF2AO2DEsA2wIrAGsBRABxAN8AZwCcAEwAqgA0AGwAUgByADcATAAVAFYAIQAyACEAKAAYAFgAGwAjABQAMAAmADIAFAAfABQAKwATACoADgAbAA8AHQAYABoAGQAxADgALAAoADwAEwA9ABMAGgARAA4ADwAWABMAFgAIAA8AHgQXBYMA5BHJAS8JtAYoAe4AExozi0UAH21tAaMnBT8CrnIyhrMDhRgDygIBUAEHcoFHUPe8AXBjAewCjgDQR8IICIcEcQLwATXCDgzvHwBmBoHNAqsBdBcUAykgDhAMShskMgo8AY8jqAQfAUAfHw8BDw87MioGlCIPBwZCa4ELatMAAMspJVgsDl8AIhckSg8XAHdvTwBcIQEiDT4OPhUqbyECAEoAS34Aej8Ybx83JgT/Xw8gHxZ/7w8RICxPHA9vBw+Pfw8PHwAPFv+fAsAvCc8vEr8ivwD/EQ8Bol8OEBa/A78hrwAPCU8vESNvvwWfHwNfAVoDHr+ZAAED34YaAdJPAK7PLwSEgDLHAGo1Pz8Pvx9fUwMrpb8O/58VTzAPIBoXIyQJNF8hpwIVAT8YGAUADDNBaX3RAMomJCg9EhUeA29MABsZBTMNJipjOhc19gcIDR8bBwQHEggCWi6DIgLuAQYA+BAFCha3A5XiAEsqM7UFFgFLhAMjFTMYE1Klnw74nRVBG/ASCm0BYRN/BrsU3VoWy+S0vV8LQx+vN8gF2AC2AK5EAWwApgYDKmAAroQ0NDQ0AT+OCg7wAAIHRAbpNgVcBV0APTA5BfbPFgMLzcYL/QqqA82eBALKCjQCjqYCht0/k2+OAsXQAoP3ASTKDgDw6ACKAUYCMpIKJpRaAE4A5womABzZvs0REEKiACIQAd5QdAECAj4Ywg/wGqY2AVgAYADYvAoCGAEubA0gvAY2ALAAbpbvqpyEAGAEpgQAJgAG7gAgAEACmghUFwCqAMpAINQIwC4DthRAAPcycKgApoIdABwBfCisABoATwBqASIAvhnSBP8aH/ECeAKXAq40NjgDBTwFYQU6AXs3oABgAD4XNgmcCY1eCl5tIFZeUqGgyoNHABgAEQAaABNwWQAmABMATPMa3T34ADldyprmM1M2XociUQgLzvwAXT3xABgAEQAaABNwIGFAnADD8AAgAD4BBJWzaCcIAIEBFMAWwKoAAdq9BWAF5wLQpALEtQAKUSGkahR4GnJM+gsAwCgeFAiUAECQ0BQuL8AAIAAAADKeIheclvFqQAAETr4iAMxIARMgAMIoHhQIAn0E0pDQFC4HhznoAAAAIAI2C0/4lvFqQAAETgBJJwYCAy4ABgYAFAA8MBKYEH4eRhTkAjYeFcgACAYAeABsOqyQ5gRwDayqugEgaIIAtgoACgDmEABmBAWGme5OBJJA2m4cDeoAmITWAXwrMgOgAGwBCh6CBXYF1Tzg1wKAAFdiuABRAFwAXQBsAG8AdgBrAHYAbwCEAHEwfxQBVE5TEQADVFhTBwBDANILAqcCzgLTApQCrQL6vAAMAL8APLhNBKkE6glGKTAU4Dr4N2EYEwBCkABKk8rHAbYBmwIoAiU4Ajf/Aq4CowCAANIChzgaNBsCsTgeODcFXrgClQKdAqQBiQGYAqsCsjTsNHsfNPA0ixsAWTWiOAMFPDQSNCk2BDZHNow2TTZUNhk28Jk9VzI3QkEoAoICoQKwAqcAQAAxBV4FXbS9BW47YkIXP1ciUqs05DS/FwABUwJW11e6nHuYZmSh/RAYA8oMKvZ8KASoUAJYWAJ6ILAsAZSoqjpgA0ocBIhmDgDWAAawRDQoAAcuAj5iAHABZiR2AIgiHgCaAU68ACxuHAG0ygM8MiZIAlgBdF4GagJqAPZOHAMuBgoATkYAsABiAHgAMLoGDPj0HpKEBAAOJgAuALggTAHWAeAMEDbd20Uege0ADwAWADkAQgA9OHd+2MUQZBBhBgNNDkxxPxUQArEPqwvqERoM1irQ090ANK4H8ANYB/ADWANYB/AH8ANYB/ADWANYA1gDWBwP8B/YxRBkD00EcgWTBZAE2wiIJk4RhgctCNdUEnQjHEwDSgEBIypJITuYMxAlR0wRTQgIATZHbKx9PQNMMbBU+pCnA9AyVDlxBgMedhKlAC8PeCE1uk6DekxxpQpQT7NX9wBFBgASqwAS5gBJDSgAUCwGPQBI4zTYABNGAE2bAE3KAExdGABKaAbgAFBXAFCOAFBJABI2SWdObALDOq0//QomCZhvwHdTBkIQHCemEPgMNAG2ATwN7kvZBPIGPATKH34ZGg/OlZ0Ipi3eDO4m5C6igFsj9iqEBe5L9TzeC05RaQ9aC2YJ5DpkgU8DIgEOIowK3g06CG4Q9ArKbA3mEUYHOgPWSZsApgcCCxIdNhW2JhFirQsKOXgG/Br3C5AmsBMqev0F1BoiBk4BKhsAANAu6IWxWjJcHU9gBgQLJiPIFKlQIQ0mQLh4SRocBxYlqgKSQ3FKiFE3HpQh9zw+DWcuFFF9B/Y8BhlQC4I8n0asRQ8R0z6OPUkiSkwtBDaALDAnjAnQD4YMunxzAVoJIgmyDHITMhEYN8YIOgcaLpclJxYIIkaWYJsE+KAD9BPSAwwFQAlCBxQDthwuEy8VKgUOgSXYAvQ21i60ApBWgQEYBcwPJh/gEFFH4Q7qCJwCZgOEJewALhUiABginAhEZABgj9lTBi7MCMhqbSN1A2gU6GIRdAeSDlgHqBw0FcAc4nDJXgyGCSiksAlcAXYJmgFgBOQICjVcjKEgQmdUi1kYnCBiQUBd/QIyDGYVoES+h3kCjA9sEhwBNgF0BzoNAgJ4Ee4RbBCWCOyGBTW2M/k6JgRQIYQgEgooA1BszwsoJvoM+WoBpBJjAw00PnfvZ6xgtyUX/gcaMsZBYSHyC5NPzgydGsIYQ1QvGeUHwAP0GvQn60FYBgADpAQUOk4z7wS+C2oIjAlAAEoOpBgH2BhrCnKM0QEyjAG4mgNYkoQCcJAGOAcMAGgMiAV65gAeAqgIpAAGANADWAA6Aq4HngAaAIZCAT4DKDABIuYCkAOUCDLMAZYwAfQqBBzEDBYA+DhuSwLDsgKAa2ajBd5ZAo8CSjYBTiYEBk9IUgOwcuIA3ABMBhTgSAEWrEvMG+REAeBwLADIAPwABjYHBkIBzgH0bgC4AWALMgmjtLYBTuoqAIQAFmwB2AKKAN4ANgCA8gFUAE4FWvoF1AJQSgESMhksWGIBvAMgATQBDgB6BsyOpsoIIARuB9QCEBwV4gLvLwe2AgMi4BPOQsYCvd9WADIXUu5eZwqoCqdeaAC0YTQHMnM9UQAPH6k+yAdy/BZIiQImSwBQ5gBQQzSaNTFWSTYBpwGqKQK38AFtqwBI/wK37gK3rQK3sAK6280C0gK33AK3zxAAUEIAUD9SklKDArekArw5AEQAzAHCO147WTteO1k7XjtZO147WTteO1kDmChYI03AVU0oJqkKbV9GYewMpw3VRMk6ShPcYFJgMxPJLbgUwhXPJVcZPhq9JwYl5VUKDwUt1GYxCC00dhe9AEApaYNCY4ceMQpMHOhTklT5LRwAskujM7ANrRsWREEFSHXuYisWDwojAmSCAmJDXE6wXDchAqH4AmiZAmYKAp+FOBwMAmY8AmYnBG8EgAN/FAN+kzkHOXgYOYM6JCQCbB4CMjc4CwJtyAJtr/CLADRoRiwBaADfAOIASwYHmQyOAP8MwwAOtgJ3MAJ2o0ACeUxEAni7Hl3cRa9G9AJ8QAJ6yQJ9CgJ88UgBSH5kJQAsFklZSlwWGErNAtECAtDNSygDiFADh+dExpEzAvKiXQQDA69Lz0wuJgTQTU1NsAKLQAKK2cIcCB5EaAa4Ao44Ao5dQZiCAo7aAo5deVG1UzYLUtVUhgKT/AKTDQDqAB1VH1WwVdEHLBwplocy4nhnRTw6ApegAu+zWCKpAFomApaQApZ9nQCqWa1aCoJOADwClrYClk9cRVzSApnMApllXMtdCBoCnJw5wzqeApwXAp+cAp65iwAeEDIrEAKd8gKekwC2PmE1YfACntQCoG8BqgKeoCACnk+mY8lkKCYsAiewAiZ/AqD8AqBN2AKmMAKlzwKoAAB+AqfzaH1osgAESmodatICrOQCrK8CrWgCrQMCVx4CVd0CseLYAx9PbJgCsr4OArLpGGzhbWRtSWADJc4Ctl08QG6RAylGArhfArlIFgK5K3hwN3DiAr0aAy2zAzISAr6JcgMDM3ICvhtzI3NQAsPMAsMFc4N0TDZGdOEDPKgDPJsDPcACxX0CxkgCxhGKAshqUgLIRQLJUALJLwJkngLd03h6YniveSZL0QMYpGcDAmH1GfSVJXsMXpNevBICz2wCz20wTFTT9BSgAMeuAs90ASrrA04TfkwGAtwoAtuLAtJQA1JdA1NgAQIDVY2AikABzBfuYUZ2AILPg44C2sgC2d+EEYRKpz0DhqYAMANkD4ZyWvoAVgLfZgLeuXR4AuIw7RUB8zEoAfScAfLTiALr9ALpcXoAAur6AurlAPpIAboC7ooC652Wq5cEAu5AA4XhmHpw4XGiAvMEAGoDjheZlAL3FAORbwOSiAL3mQL52gL4Z5odmqy8OJsfA52EAv77ARwAOp8dn7QDBY4DpmsDptoA0sYDBmuhiaIGCgMMSgFgASACtgNGAJwEgLpoBgC8BGzAEowcggCEDC6kdjoAJAM0C5IKRoABZCgiAIzw3AYBLACkfng9ogigkgNmWAN6AEQCvrkEVqTGAwCsBRbAA+4iQkMCHR072jI2PTbUNsk2RjY5NvA23TZKNiU3EDcZN5I+RTxDRTBCJkK5VBYKFhZfwQCWygU3AJBRHpu+OytgNxa61A40GMsYjsn7BVwFXQVcBV0FaAVdBVwFXQVcBV0FXAVdBVwFXUsaCNyKAK4AAQUHBwKU7oICoW1e7jAEzgPxA+YDwgCkBFDAwADABKzAAOxFLhitA1UFTDeyPkM+bj51QkRCuwTQWWQ8X+0AWBYzsACNA8xwzAGm7EZ/QisoCTAbLDs6fnLfb8H2GccsbgFw13M1HAVkBW/Jxsm9CNRO8E8FDD0FBQw9FkcClOYCoMFegpDfADgcMiA2AJQACB8AsigKAIzIEAJKeBIApY5yPZQIAKQiHb4fvj5BKSRPQrZCOz0oXyxgOywfKAnGbgMClQaCAkILXgdeCD9IIGUgQj5fPoY+dT52Ao5CM0dAX9BTVG9SDzFwWTQAbxBzJF/lOEIQQglCCkKJIAls5AcClQICoKPMODEFxhi6KSAbiyfIRrMjtCgdWCAkPlFBIitCsEJRzAbMAV/OEyQzDg0OAQQEJ36i328/Mk9AybDJsQlq3tDRApUKAkFzXf1d/j9uALYP6hCoFgCTGD8kPsFKQiobrm0+zj0KSD8kPnVCRBwMDyJRTHFgMTJa5rwXQiQ2YfI/JD7BMEJEHGINTw4TOFlIRzwJO0icMQpyPyQ+wzJCRBv6DVgnKB01NgUKj2bwYzMqCoBkznBgEF+zYDIocwRIX+NgHj4HICNfh2C4CwdwFWpTG/lgUhYGAwRfv2Ts8mAaXzVgml/XYIJfuWC4HI1gUF9pYJZgMR6ilQHMAOwLAlDRefC0in4AXAEJA6PjCwc0IamOANMMCAECRQDFNRTZBgd+CwQlRA+r6+gLBDEFBnwUBXgKATIArwAGRAAHA3cDdAN2A3kDdwN9A3oDdQN7A30DfAN4A3oDfQAYEAAlAtYASwMAUAFsAHcKAHcAmgB3AHUAdQB2AHVu8UgAygDAAHcAdQB1AHYAdQALCgB3AAsAmgB3AAsCOwB3AAtu8UgAygDAAHgKAJoAdwB3AHUAdQB2AHUAeAB1AHUAdgB1bvFIAMoAwAALCgCaAHcACwB3AAsCOwB3AAtu8UgAygDAAH4ACwGgALcBpwC6AahdAu0COwLtbvFIAMoAwAALCgCaAu0ACwLtAAsCOwLtAAtu8UgAygDAA24ACwNvAAu0VsQAAzsAABCkjUIpAAsAUIusOggWcgMeBxVsGwL67U/2HlzmWOEeOgALASvuAAseAfpKUpnpGgYJDCIZM6YyARUE9ThqAD5iXQgnAJYJPnOzw0ZAEZxEKsIAkA4DhAHnTAIDxxUDK0lxCQlPYgIvIQVYJQBVqE1GakUAKGYiDToSBA1EtAYAXQJYAIF8GgMHRyAAIAjOe9YncekRAA0KACUrjwE7Ayc6AAYWAqaiKG4McEcqANoN3+Mg9TwCBhIkuCny+JwUQ29L008JluRxu3K+oAdqiHOqFH0AG5SUIfUJ5SxCGfxdipRzqTmT4V5Zb+r1Uo4Vm+NqSSEl2mNvR2JhIa8SpYO6ntdwFXHCWTCK8f2+Hxo7uiG3drDycAuKIMP5bhi06ACnqArH1rz4Rqg//lm6SgJGEVbF9xJHISaR6HxqxSnkw6shDnelHKNEfGUXSJRJ1GcsmtJw25xrZMDK9gXSm1/YMkdX4/6NKYOdtk/NQ3/NnDASjTc3fPjIjW/5sVfVObX2oTDWkr1dF9f3kxBsD3/3aQO8hPfRz+e0uEiJqt1161griu7gz8hDDwtpy+F+BWtefnKHZPAxcZoWbnznhJpy0e842j36bcNzGnIEusgGX0a8ZxsnjcSsPDZ09yZ36fCQbriHeQ72JRMILNl6ePPf2HWoVwgWAm1fb3V2sAY0+B6rAXqSwPBgseVmoqsBTSrm91+XasMYYySI8eeRxH3ZvHkMz3BQ5aJ3iUVbYPNM3/7emRtjlsMgv/9VyTsyt/mK+8fgWeT6SoFaclXqn42dAIsvAarF5vNNWHzKSkKQ/8Hfk5ZWK7r9yliOsooyBjRhfkHP4Q2DkWXQi6FG/9r/IwbmkV5T7JSopHKn1pJwm9tb5Ot0oyN1Z2mPpKXHTxx2nlK08fKk1hEYA8WgVVWL5lgx0iTv+KdojJeU23ZDjmiubXOxVXJKKi2Wjuh2HLZOFLiSC7Tls5SMh4f+Pj6xUSrNjFqLGehRNB8lC0QSLNmkJJx/wSG3MnjE9T1CkPwJI0wH2lfzwETIiVqUxg0dfu5q39Gt+hwdcxkhhNvQ4TyrBceof3Mhs/IxFci1HmHr4FMZgXEEczPiGCx0HRwzAqDq2j9AVm1kwN0mRVLWLylgtoPNapF5cY4Y1wJh/e0BBwZj44YgZrDNqvD/9Hv7GFYdUQeDJuQ3EWI4HaKqavU1XjC/n41kT4L79kqGq0kLhdTZvgP3TA3fS0ozVz+5piZsoOtIvBUFoMKbNcmBL6YxxaUAusHB38XrS8dQMnQwJfUUkpRoGr5AUeWicvBTzyK9g77+yCkf5PAysL7r/JjcZgrbvRpMW9iyaxZvKO6ceZN2EwIxKwVFPuvFuiEPGCoagbMo+SpydLrXqBzNCDGFCrO/rkcwa2xhokQZ5CdZ0AsU3JfSqJ6n5I14YA+P/uAgfhPU84Tlw7cEFfp7AEE8ey4sP12PTt4Cods1GRgDOB5xvyiR5m+Bx8O5nBCNctU8BevfV5A08x6RHd5jcwPTMDSZJOedIZ1cGQ704lxbAzqZOP05ZxaOghzSdvFBHYqomATARyAADK4elP8Ly3IrUZKfWh23Xy20uBUmLS4Pfagu9+oyVa2iPgqRP3F2CTUsvJ7+RYnN8fFZbU/HVvxvcFFDKkiTqV5UBZ3Gz54JAKByi9hkKMZJvuGgcSYXFmw08UyoQyVdfTD1/dMkCHXcTGAKeROgArsvmRrQTLUOXioOHGK2QkjHuoYFgXciZoTJd6Fs5q1QX1G+p/e26hYsEf7QZD1nnIyl/SFkNtYYmmBhpBrxl9WbY0YpHWRuw2Ll/tj9mD8P4snVzJl4F9J+1arVeTb9E5r2ILH04qStjxQNwn3m4YNqxmaNbLAqW2TN6LidwuJRqS+NXbtqxoeDXpxeGWmxzSkWxjkyCkX4NQRme6q5SAcC+M7+9ETfA/EwrzQajKakCwYyeunP6ZFlxU2oMEn1Pz31zeStW74G406ZJFCl1wAXIoUKkWotYEpOuXB1uVNxJ63dpJEqfxBeptwIHNrPz8BllZoIcBoXwgfJ+8VAUnVPvRvexnw0Ma/WiGYuJO5y8QTvEYBigFmhUxY5RqzE8OcywN/8m4UYrlaniJO75XQ6KSo9+tWHlu+hMi0UVdiKQp7NelnoZUzNaIyBPVeOwK6GNp+FfHuPOoyhaWuNvTYFkvxscMQWDh+zeFCFkgwbXftiV23ywJ4+uwRqmg9k3KzwIQpzppt8DBBOMbrqwQM5Gb05sEwdKzMiAqOloaA/lr0KA+1pr0/+HiWoiIjHA/wir2nIuS3PeU/ji3O6ZwoxcR1SZ9FhtLC5S0FIzFhbBWcGVP/KpxOPSiUoAdWUpqKH++6Scz507iCcxYI6rdMBICPJZea7OcmeFw5mObJSiqpjg2UoWNIs+cFhyDSt6geV5qgi3FunmwwDoGSMgerFOZGX1m0dMCYo5XOruxO063dwENK9DbnVM9wYFREzh4vyU1WYYJ/LRRp6oxgjqP/X5a8/4Af6p6NWkQferzBmXme0zY/4nwMJm/wd1tIqSwGz+E3xPEAOoZlJit3XddD7/BT1pllzOx+8bmQtANQ/S6fZexc6qi3W+Q2xcmXTUhuS5mpHQRvcxZUN0S5+PL9lXWUAaRZhEH8hTdAcuNMMCuVNKTEGtSUKNi3O6KhSaTzck8csZ2vWRZ+d7mW8c4IKwXIYd25S/zIftPkwPzufjEvOHWVD1m+FjpDVUTV0DGDuHj6QnaEwLu/dEgdLQOg9E1Sro9XHJ8ykLAwtPu+pxqKDuFexqON1sKQm7rwbE1E68UCfA/erovrTCG+DBSNg0l4goDQvZN6uNlbyLpcZAwj2UclycvLpIZMgv4yRlpb3YuMftozorbcGVHt/VeDV3+Fdf1TP0iuaCsPi2G4XeGhsyF1ubVDxkoJhmniQ0/jSg/eYML9KLfnCFgISWkp91eauR3IQvED0nAPXK+6hPCYs+n3+hCZbiskmVMG2da+0EsZPonUeIY8EbfusQXjsK/eFDaosbPjEfQS0RKG7yj5GG69M7MeO1HmiUYocgygJHL6M1qzUDDwUSmr99V7Sdr2F3JjQAJY+F0yH33Iv3+C9M38eML7gTgmNu/r2bUMiPvpYbZ6v1/IaESirBHNa7mPKn4dEmYg7v/+HQgPN1G79jBQ1+soydfDC2r+h2Bl/KIc5KjMK7OH6nb1jLsNf0EHVe2KBiE51ox636uyG6Lho0t3J34L5QY/ilE3mikaF4HKXG1mG1rCevT1Vv6GavltxoQe/bMrpZvRggnBxSEPEeEzkEdOxTnPXHVjUYdw8JYvjB/o7Eegc3Ma+NUxLLnsK0kJlinPmUHzHGtrk5+CAbVzFOBqpyy3QVUnzTDfC/0XD94/okH+OB+i7g9lolhWIjSnfIb+Eq43ZXOWmwvjyV/qqD+t0e+7mTEM74qP/Ozt8nmC7mRpyu63OB4KnUzFc074SqoyPUAgM+/TJGFo6T44EHnQU4X4z6qannVqgw/U7zCpwcmXV1AubIrvOmkKHazJAR55ePjp5tLBsN8vAqs3NAHdcEHOR2xQ0lsNAFzSUuxFQCFYvXLZJdOj9p4fNq6p0HBGUik2YzaI4xySy91KzhQ0+q1hjxvImRwPRf76tChlRkhRCi74NXZ9qUNeIwP+s5p+3m5nwPdNOHgSLD79n7O9m1n1uDHiMntq4nkYwV5OZ1ENbXxFd4PgrlvavZsyUO4MqYlqqn1O8W/I1dEZq5dXhrbETLaZIbC2Kj/Aa/QM+fqUOHdf0tXAQ1huZ3cmWECWSXy/43j35+Mvq9xws7JKseriZ1pEWKc8qlzNrGPUGcVgOa9cPJYIJsGnJTAUsEcDOEVULO5x0rXBijc1lgXEzQQKhROf8zIV82w8eswc78YX11KYLWQRcgHNJElBxfXr72lS2RBSl07qTKorO2uUDZr3sFhYsvnhLZn0A94KRzJ/7DEGIAhW5ZWFpL8gEwu1aLA9MuWZzNwl8Oze9Y+bX+v9gywRVnoB5I/8kXTXU3141yRLYrIOOz6SOnyHNy4SieqzkBXharjfjqq1q6tklaEbA8Qfm2DaIPs7OTq/nvJBjKfO2H9bH2cCMh1+5gspfycu8f/cuuRmtDjyqZ7uCIMyjdV3a+p3fqmXsRx4C8lujezIFHnQiVTXLXuI1XrwN3+siYYj2HHTvESUx8DlOTXpak9qFRK+L3mgJ1WsD7F4cu1aJoFoYQnu+wGDMOjJM3kiBQWHCcvhJ/HRdxodOQp45YZaOTA22Nb4XKCVxqkbwMYFhzYQYIAnCW8FW14uf98jhUG2zrKhQQ0q0CEq0t5nXyvUyvR8DvD69LU+g3i+HFWQMQ8PqZuHD+sNKAV0+M6EJC0szq7rEr7B5bQ8BcNHzvDMc9eqB5ZCQdTf80Obn4uzjwpYU7SISdtV0QGa9D3Wrh2BDQtpBKxaNFV+/Cy2P/Sv+8s7Ud0Fd74X4+o/TNztWgETUapy+majNQ68Lq3ee0ZO48VEbTZYiH1Co4OlfWef82RWeyUXo7woM03PyapGfikTnQinoNq5z5veLpeMV3HCAMTaZmA1oGLAn7XS3XYsz+XK7VMQsc4XKrmDXOLU/pSXVNUq8dIqTba///3x6LiLS6xs1xuCAYSfcQ3+rQgmu7uvf3THKt5Ooo97TqcbRqxx7EASizaQCBQllG/rYxVapMLgtLbZS64w1MDBMXX+PQpBKNwqUKOf2DDRDUXQf9EhOS0Qj4nTmlA8dzSLz/G1d+Ud8MTy/6ghhdiLpeerGY/UlDOfiuqFsMUU5/UYlP+BAmgRLuNpvrUaLlVkrqDievNVEAwF+4CoM1MZTmjxjJMsKJq+u8Zd7tNCUFy6LiyYXRJQ4VyvEQFFaCGKsxIwQkk7EzZ6LTJq2hUuPhvAW+gQnSG6J+MszC+7QCRHcnqDdyNRJ6T9xyS87A6MDutbzKGvGktpbXqtzWtXb9HsfK2cBMomjN9a4y+TaJLnXxAeX/HWzmf4cR4vALt/P4w4qgKY04ml4ZdLOinFYS6cup3G/1ie4+t1eOnpBNlqGqs75ilzkT4+DsZQxNvaSKJ//6zIbbk/M7LOhFmRc/1R+kBtz7JFGdZm/COotIdvQoXpTqP/1uqEUmCb/QWoGLMwO5ANcHzxdY48IGP5+J+zKOTBFZ4Pid+GTM+Wq12MV/H86xEJptBa6T+p3kgpwLedManBHC2GgNrFpoN2xnrMz9WFWX/8/ygSBkavq2Uv7FdCsLEYLu9LLIvAU0bNRDtzYl+/vXmjpIvuJFYjmI0im6QEYqnIeMsNjXG4vIutIGHijeAG/9EDBozKV5cldkHbLxHh25vT+ZEzbhXlqvpzKJwcEgfNwLAKFeo0/pvEE10XDB+EXRTXtSzJozQKFFAJhMxYkVaCW+E9AL7tMeU8acxidHqzb6lX4691UsDpy/LLRmT+epgW56+5Cw8tB4kMUv6s9lh3eRKbyGs+H/4mQMaYzPTf2OOdokEn+zzgvoD3FqNKk8QqGAXVsqcGdXrT62fSPkR2vROFi68A6se86UxRUk4cajfPyCC4G5wDhD+zNq4jodQ4u4n/m37Lr36n4LIAAsVr02dFi9AiwA81MYs2rm4eDlDNmdMRvEKRHfBwW5DdMNp0jPFZMeARqF/wL4XBfd+EMLBfMzpH5GH6NaW+1vrvMdg+VxDzatk3MXgO3ro3P/DpcC6+Mo4MySJhKJhSR01SGGGp5hPWmrrUgrv3lDnP+HhcI3nt3YqBoVAVTBAQT5iuhTg8nvPtd8ZeYj6w1x6RqGUBrSku7+N1+BaasZvjTk64RoIDlL8brpEcJx3OmY7jLoZsswdtmhfC/G21llXhITOwmvRDDeTTPbyASOa16cF5/A1fZAidJpqju3wYAy9avPR1ya6eNp9K8XYrrtuxlqi+bDKwlfrYdR0RRiKRVTLOH85+ZY7XSmzRpfZBJjaTa81VDcJHpZnZnSQLASGYW9l51ZV/h7eVzTi3Hv6hUsgc/51AqJRTkpbFVLXXszoBL8nBX0u/0jBLT8nH+fJePbrwURT58OY+UieRjd1vs04w0VG5VN2U6MoGZkQzKN/ptz0Q366dxoTGmj7i1NQGHi9GgnquXFYdrCfZBmeb7s0T6yrdlZH5cZuwHFyIJ/kAtGsTg0xH5taAAq44BAk1CPk9KVVbqQzrCUiFdF/6gtlPQ8bHHc1G1W92MXGZ5HEHftyLYs8mbD/9xYRUWkHmlM0zC2ilJlnNgV4bfALpQghxOUoZL7VTqtCHIaQSXm+YUMnpkXybnV+A6xlm2CVy8fn0Xlm2XRa0+zzOa21JWWmixfiPMSCZ7qA4rS93VN3pkpF1s5TonQjisHf7iU9ZGvUPOAKZcR1pbeVf/Ul7OhepGCaId9wOtqo7pJ7yLcBZ0pFkOF28y4zEI/kcUNmutBHaQpBdNM8vjCS6HZRokkeo88TBAjGyG7SR+6vUgTcyK9Imalj0kuxz0wmK+byQU11AiJFk/ya5dNduRClcnU64yGu/ieWSeOos1t3ep+RPIWQ2pyTYVbZltTbsb7NiwSi3AV+8KLWk7LxCnfZUetEM8ThnsSoGH38/nyAwFguJp8FjvlHtcWZuU4hPva0rHfr0UhOOJ/F6vS62FW7KzkmRll2HEc7oUq4fyi5T70Vl7YVIfsPHUCdHesf9Lk7WNVWO75JDkYbMI8TOW8JKVtLY9d6UJRITO8oKo0xS+o99Yy04iniGHAaGj88kEWgwv0OrHdY/nr76DOGNS59hXCGXzTKUvDl9iKpLSWYN1lxIeyywdNpTkhay74w2jFT6NS8qkjo5CxA1yfSYwp6AJIZNKIeEK5PJAW7ORgWgwp0VgzYpqovMrWxbu+DGZ6Lhie1RAqpzm8VUzKJOH3mCzWuTOLsN3VT/dv2eeYe9UjbR8YTBsLz7q60VN1sU51k+um1f8JxD5pPhbhSC8rRaB454tmh6YUWrJI3+GWY0qeWioj/tbkYITOkJaeuGt4JrJvHA+l0Gu7kY7XOaa05alMnRWVCXqFgLIwSY4uF59Ue5SU4QKuc/HamDxbr0x6csCetXGoP7Qn1Bk/J9DsynO/UD6iZ1Hyrz+jit0hDCwi/E9OjgKTbB3ZQKQ/0ZOvevfNHG0NK4Aj3Cp7NpRk07RT1i/S0EL93Ag8GRgKI9CfpajKyK6+Jj/PI1KO5/85VAwz2AwzP8FTBb075IxCXv6T9RVvWT2tUaqxDS92zrGUbWzUYk9mSs82pECH+fkqsDt93VW++4YsR/dHCYcQSYTO/KaBMDj9LSD/J/+z20Kq8XvZUAIHtm9hRPP3ItbuAu2Hm5lkPs92pd7kCxgRs0xOVBnZ13ccdA0aunrwv9SdqElJRC3g+oCu+nXyCgmXUs9yMjTMAIHfxZV+aPKcZeUBWt057Xo85Ks1Ir5gzEHCWqZEhrLZMuF11ziGtFQUds/EESajhagzcKsxamcSZxGth4UII+adPhQkUnx2WyN+4YWR+r3f8MnkyGFuR4zjzxJS8WsQYR5PTyRaD9ixa6Mh741nBHbzfjXHskGDq179xaRNrCIB1z1xRfWfjqw2pHc1zk9xlPpL8sQWAIuETZZhbnmL54rceXVNRvUiKrrqIkeogsl0XXb17ylNb0f4GA9Wd44vffEG8FSZGHEL2fbaTGRcSiCeA8PmA/f6Hz8HCS76fXUHwgwkzSwlI71ekZ7Fapmlk/KC+Hs8hUcw3N2LN5LhkVYyizYFl/uPeVP5lsoJHhhfWvvSWruCUW1ZcJOeuTbrDgywJ/qG07gZJplnTvLcYdNaH0KMYOYMGX+rB4NGPFmQsNaIwlWrfCezxre8zXBrsMT+edVLbLqN1BqB76JH4BvZTqUIMfGwPGEn+EnmTV86fPBaYbFL3DFEhjB45CewkXEAtJxk4/Ms2pPXnaRqdky0HOYdcUcE2zcXq4vaIvW2/v0nHFJH2XXe22ueDmq/18XGtELSq85j9X8q0tcNSSKJIX8FTuJF/Pf8j5PhqG2u+osvsLxYrvvfeVJL+4tkcXcr9JV7v0ERmj/X6fM3NC4j6dS1+9Umr2oPavqiAydTZPLMNRGY23LO9zAVDly7jD+70G5TPPLdhRIl4WxcYjLnM+SNcJ26FOrkrISUtPObIz5Zb3AG612krnpy15RMW+1cQjlnWFI6538qky9axd2oJmHIHP08KyP0ubGO+TQNOYuv2uh17yCIvR8VcStw7o1g0NM60sk+8Tq7YfIBJrtp53GkvzXH7OA0p8/n/u1satf/VJhtR1l8Wa6Gmaug7haSpaCaYQax6ta0mkutlb+eAOSG1aobM81D9A4iS1RRlzBBoVX6tU1S6WE2N9ORY6DfeLRC4l9Rvr5h95XDWB2mR1d4WFudpsgVYwiTwT31ljskD8ZyDOlm5DkGh9N/UB/0AI5Xvb8ZBmai2hQ4BWMqFwYnzxwB26YHSOv9WgY3JXnvoN+2R4rqGVh/LLDMtpFP+SpMGJNWvbIl5SOodbCczW2RKleksPoUeGEzrjtKHVdtZA+kfqO+rVx/iclCqwoopepvJpSTDjT+b9GWylGRF8EDbGlw6eUzmJM95Ovoz+kwLX3c2fTjFeYEsE7vUZm3mqdGJuKh2w9/QGSaqRHs99aScGOdDqkFcACoqdbBoQqqjamhH6Q9ng39JCg3lrGJwd50Qk9ovnqBTr8MME7Ps2wiVfygUmPoUBJJfJWX5Nda0nuncbFkA==")),es=0,()=>ec[es++]),e9=new Set(read_member_array(e8)),e7=new Set(read_member_array(e8)),tn=function(c){let l=[];for(;;){let et=c();if(0==et)break;l.push(function(c,l){let et=1+l(),eo=l(),es=function(c){let l=[];for(;;){let et=c();if(0==et)break;l.push(et)}return l}(l);return flat(read_transposed(es.length,1+c,l).map((c,l)=>{let ec=c[0],el=c.slice(1);return Array(es[l]).fill(void 0).map((c,l)=>{let es=l*eo;return[ec+l*et,el.map(c=>c+es)]})}))}(et,c))}for(;;){let et=c()-1;if(et<0)break;l.push(read_transposed(1+c(),1+et,c).map(c=>[c[0],c.slice(1)]))}return function(c){let l={};for(let et=0;etc-l),function read(){let c=[];for(;;){let l=read_member_array(e8,eo);if(0==l.length)break;c.push({set:new Set(l),node:read()})}c.sort((c,l)=>l.set.size-c.set.size);let l=e8();return{branches:c,valid:l%3,fe0f:!!(1&(l=l/3|0)),save:1==(l>>=1),check:2==l}}());function filter_fe0f(c){return c.filter(c=>65039!=c)}function ens_normalize_post_check(c){for(let l of c.split(".")){let c=(0,ew.XL)(l);try{for(let l=c.lastIndexOf(95)-1;l>=0;l--)if(95!==c[l])throw Error("underscore only allowed at start");if(c.length>=4&&c.every(c=>c<128)&&45===c[2]&&45===c[3])throw Error("invalid label extension")}catch(c){throw Error(`Invalid label "${l}": ${c.message}`)}}return c}let ts=new ey.Yd(e_),ta=new Uint8Array(32);function checkComponent(c){if(0===c.length)throw Error("invalid ENS name; empty component");return c}function ensNameSplit(c){let l=(0,ew.Y0)(ens_normalize_post_check(function(c,l){let et=(0,ew.XL)(c).reverse(),eo=[];for(;et.length;){let c=function(c,l){var et;let eo,es;let ec=to,el=[],ed=c.length;for(l&&(l.length=0);ed;){let eh=c[--ed];if(!(ec=null===(et=ec.branches.find(c=>c.set.has(eh)))||void 0===et?void 0:et.node))break;if(ec.save)es=eh;else if(ec.check&&eh===es)break;el.push(eh),ec.fe0f&&(el.push(65039),ed>0&&65039==c[ed-1]&&ed--),ec.valid&&(eo=el.slice(),2==ec.valid&&eo.splice(1,1),l&&l.push(...c.slice(ed).reverse()),c.length=ed)}return eo}(et);if(c){eo.push(...l(c));continue}let es=et.pop();if(e9.has(es)){eo.push(es);continue}if(e7.has(es))continue;let ec=tn[es];if(ec){eo.push(...ec);continue}throw Error(`Disallowed codepoint: 0x${es.toString(16).toUpperCase()}`)}return ens_normalize_post_check(String.fromCodePoint(...eo).normalize("NFC"))}(c,filter_fe0f))),et=[];if(0===c.length)return et;let eo=0;for(let c=0;c=l.length)throw Error("invalid ENS name; empty component");return et.push(checkComponent(l.slice(eo))),et}function namehash(c){"string"!=typeof c&&ts.throwArgumentError("invalid ENS name; not a string","name",c);let l=ta,et=ensNameSplit(c);for(;et.length;)l=(0,em.w)((0,ep.zo)([l,(0,em.w)(et.pop())]));return(0,ep.Dv)(l)}ta.fill(0);let tc=new ey.Yd("networks/5.7.1");function ethDefaultProvider(c){let func=function(l,et){null==et&&(et={});let eo=[];if(l.InfuraProvider&&"-"!==et.infura)try{eo.push(new l.InfuraProvider(c,et.infura))}catch(c){}if(l.EtherscanProvider&&"-"!==et.etherscan)try{eo.push(new l.EtherscanProvider(c,et.etherscan))}catch(c){}if(l.AlchemyProvider&&"-"!==et.alchemy)try{eo.push(new l.AlchemyProvider(c,et.alchemy))}catch(c){}if(l.PocketProvider&&"-"!==et.pocket)try{let es=new l.PocketProvider(c,et.pocket);es.network&&-1===["goerli","ropsten","rinkeby","sepolia"].indexOf(es.network.name)&&eo.push(es)}catch(c){}if(l.CloudflareProvider&&"-"!==et.cloudflare)try{eo.push(new l.CloudflareProvider(c))}catch(c){}if(l.AnkrProvider&&"-"!==et.ankr)try{let es=new l.AnkrProvider(c,et.ankr);es.network&&-1===["ropsten"].indexOf(es.network.name)&&eo.push(es)}catch(c){}if(0===eo.length)return null;if(l.FallbackProvider){let es=1;return null!=et.quorum?es=et.quorum:"homestead"===c&&(es=2),new l.FallbackProvider(eo,es)}return eo[0]};return func.renetwork=function(c){return ethDefaultProvider(c)},func}function etcDefaultProvider(c,l){let func=function(et,eo){return et.JsonRpcProvider?new et.JsonRpcProvider(c,l):null};return func.renetwork=function(l){return etcDefaultProvider(c,l)},func}let tl={chainId:1,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"homestead",_defaultProvider:ethDefaultProvider("homestead")},td={chainId:3,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"ropsten",_defaultProvider:ethDefaultProvider("ropsten")},th={chainId:63,name:"classicMordor",_defaultProvider:etcDefaultProvider("https://www.ethercluster.com/mordor","classicMordor")},tf={unspecified:{chainId:0,name:"unspecified"},homestead:tl,mainnet:tl,morden:{chainId:2,name:"morden"},ropsten:td,testnet:td,rinkeby:{chainId:4,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"rinkeby",_defaultProvider:ethDefaultProvider("rinkeby")},kovan:{chainId:42,name:"kovan",_defaultProvider:ethDefaultProvider("kovan")},goerli:{chainId:5,ensAddress:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e",name:"goerli",_defaultProvider:ethDefaultProvider("goerli")},kintsugi:{chainId:1337702,name:"kintsugi"},sepolia:{chainId:11155111,name:"sepolia",_defaultProvider:ethDefaultProvider("sepolia")},classic:{chainId:61,name:"classic",_defaultProvider:etcDefaultProvider("https://www.ethercluster.com/etc","classic")},classicMorden:{chainId:62,name:"classicMorden"},classicMordor:th,classicTestnet:th,classicKotti:{chainId:6,name:"classicKotti",_defaultProvider:etcDefaultProvider("https://www.ethercluster.com/kotti","classicKotti")},xdai:{chainId:100,name:"xdai"},matic:{chainId:137,name:"matic",_defaultProvider:ethDefaultProvider("matic")},maticmum:{chainId:80001,name:"maticmum"},optimism:{chainId:10,name:"optimism",_defaultProvider:ethDefaultProvider("optimism")},"optimism-kovan":{chainId:69,name:"optimism-kovan"},"optimism-goerli":{chainId:420,name:"optimism-goerli"},arbitrum:{chainId:42161,name:"arbitrum"},"arbitrum-rinkeby":{chainId:421611,name:"arbitrum-rinkeby"},"arbitrum-goerli":{chainId:421613,name:"arbitrum-goerli"},bnb:{chainId:56,name:"bnb"},bnbt:{chainId:97,name:"bnbt"}};function sha256(c){return"0x"+ej().sha256().update((0,ep.lE)(c)).digest("hex")}new ey.Yd("sha2/5.7.0");var tp=et(76942),tg=et.n(tp);let tm=new ey.Yd(e5.i);let Formatter=class Formatter{constructor(){this.formats=this.getDefaultFormats()}getDefaultFormats(){let c={},l=this.address.bind(this),et=this.bigNumber.bind(this),eo=this.blockTag.bind(this),es=this.data.bind(this),ec=this.hash.bind(this),el=this.hex.bind(this),ed=this.number.bind(this),eh=this.type.bind(this);return c.transaction={hash:ec,type:eh,accessList:Formatter.allowNull(this.accessList.bind(this),null),blockHash:Formatter.allowNull(ec,null),blockNumber:Formatter.allowNull(ed,null),transactionIndex:Formatter.allowNull(ed,null),confirmations:Formatter.allowNull(ed,null),from:l,gasPrice:Formatter.allowNull(et),maxPriorityFeePerGas:Formatter.allowNull(et),maxFeePerGas:Formatter.allowNull(et),gasLimit:et,to:Formatter.allowNull(l,null),value:et,nonce:ed,data:es,r:Formatter.allowNull(this.uint256),s:Formatter.allowNull(this.uint256),v:Formatter.allowNull(ed),creates:Formatter.allowNull(l,null),raw:Formatter.allowNull(es)},c.transactionRequest={from:Formatter.allowNull(l),nonce:Formatter.allowNull(ed),gasLimit:Formatter.allowNull(et),gasPrice:Formatter.allowNull(et),maxPriorityFeePerGas:Formatter.allowNull(et),maxFeePerGas:Formatter.allowNull(et),to:Formatter.allowNull(l),value:Formatter.allowNull(et),data:Formatter.allowNull(c=>this.data(c,!0)),type:Formatter.allowNull(ed),accessList:Formatter.allowNull(this.accessList.bind(this),null)},c.receiptLog={transactionIndex:ed,blockNumber:ed,transactionHash:ec,address:l,topics:Formatter.arrayOf(ec),data:es,logIndex:ed,blockHash:ec},c.receipt={to:Formatter.allowNull(this.address,null),from:Formatter.allowNull(this.address,null),contractAddress:Formatter.allowNull(l,null),transactionIndex:ed,root:Formatter.allowNull(el),gasUsed:et,logsBloom:Formatter.allowNull(es),blockHash:ec,transactionHash:ec,logs:Formatter.arrayOf(this.receiptLog.bind(this)),blockNumber:ed,confirmations:Formatter.allowNull(ed,null),cumulativeGasUsed:et,effectiveGasPrice:Formatter.allowNull(et),status:Formatter.allowNull(ed),type:eh},c.block={hash:Formatter.allowNull(ec),parentHash:ec,number:ed,timestamp:ed,nonce:Formatter.allowNull(el),difficulty:this.difficulty.bind(this),gasLimit:et,gasUsed:et,miner:Formatter.allowNull(l),extraData:es,transactions:Formatter.allowNull(Formatter.arrayOf(ec)),baseFeePerGas:Formatter.allowNull(et)},c.blockWithTransactions=(0,eb.DC)(c.block),c.blockWithTransactions.transactions=Formatter.allowNull(Formatter.arrayOf(this.transactionResponse.bind(this))),c.filter={fromBlock:Formatter.allowNull(eo,void 0),toBlock:Formatter.allowNull(eo,void 0),blockHash:Formatter.allowNull(ec,void 0),address:Formatter.allowNull(l,void 0),topics:Formatter.allowNull(this.topics.bind(this),void 0)},c.filterLog={blockNumber:Formatter.allowNull(ed),blockHash:Formatter.allowNull(ec),transactionIndex:ed,removed:Formatter.allowNull(this.boolean.bind(this)),address:l,data:Formatter.allowFalsish(es,"0x"),topics:Formatter.arrayOf(ec),transactionHash:ec,logIndex:ed},c}accessList(c){return accessListify(c||[])}number(c){return"0x"===c?0:ef.O$.from(c).toNumber()}type(c){return"0x"===c||null==c?0:ef.O$.from(c).toNumber()}bigNumber(c){return ef.O$.from(c)}boolean(c){if("boolean"==typeof c)return c;if("string"==typeof c){if("true"===(c=c.toLowerCase()))return!0;if("false"===c)return!1}throw Error("invalid boolean - "+c)}hex(c,l){return"string"==typeof c&&(l||"0x"===c.substring(0,2)||(c="0x"+c),(0,ep.A7)(c))?c.toLowerCase():tm.throwArgumentError("invalid hash","value",c)}data(c,l){let et=this.hex(c,l);if(et.length%2!=0)throw Error("invalid data; odd-length - "+c);return et}address(c){return(0,eg.Kn)(c)}callAddress(c){if(!(0,ep.A7)(c,32))return null;let l=(0,eg.Kn)((0,ep.p3)(c,12));return"0x0000000000000000000000000000000000000000"===l?null:l}contractAddress(c){return(0,eg.CR)(c)}blockTag(c){if(null==c)return"latest";if("earliest"===c)return"0x0";switch(c){case"earliest":return"0x0";case"latest":case"pending":case"safe":case"finalized":return c}if("number"==typeof c||(0,ep.A7)(c))return(0,ep.$P)(c);throw Error("invalid blockTag")}hash(c,l){let et=this.hex(c,l);return 32!==(0,ep.E1)(et)?tm.throwArgumentError("invalid hash","value",c):et}difficulty(c){if(null==c)return null;let l=ef.O$.from(c);try{return l.toNumber()}catch(c){}return null}uint256(c){if(!(0,ep.A7)(c))throw Error("invalid uint256");return(0,ep.$m)(c,32)}_block(c,l){null!=c.author&&null==c.miner&&(c.miner=c.author);let et=null!=c._difficulty?c._difficulty:c.difficulty,eo=Formatter.check(l,c);return eo._difficulty=null==et?null:ef.O$.from(et),eo}block(c){return this._block(c,this.formats.block)}blockWithTransactions(c){return this._block(c,this.formats.blockWithTransactions)}transactionRequest(c){return Formatter.check(this.formats.transactionRequest,c)}transactionResponse(c){null!=c.gas&&null==c.gasLimit&&(c.gasLimit=c.gas),c.to&&ef.O$.from(c.to).isZero()&&(c.to="0x0000000000000000000000000000000000000000"),null!=c.input&&null==c.data&&(c.data=c.input),null==c.to&&null==c.creates&&(c.creates=this.contractAddress(c)),(1===c.type||2===c.type)&&null==c.accessList&&(c.accessList=[]);let l=Formatter.check(this.formats.transaction,c);if(null!=c.chainId){let et=c.chainId;(0,ep.A7)(et)&&(et=ef.O$.from(et).toNumber()),l.chainId=et}else{let et=c.networkId;null==et&&null==l.v&&(et=c.chainId),(0,ep.A7)(et)&&(et=ef.O$.from(et).toNumber()),"number"!=typeof et&&null!=l.v&&((et=(l.v-35)/2)<0&&(et=0),et=parseInt(et)),"number"!=typeof et&&(et=0),l.chainId=et}return l.blockHash&&"x"===l.blockHash.replace(/0/g,"")&&(l.blockHash=null),l}transaction(c){return function(c){let l=(0,ep.lE)(c);if(l[0]>127)return function(c){let l=eM.J(c);9!==l.length&&6!==l.length&&e2.throwArgumentError("invalid raw transaction","rawTransaction",c);let et={nonce:handleNumber(l[0]).toNumber(),gasPrice:handleNumber(l[1]),gasLimit:handleNumber(l[2]),to:handleAddress(l[3]),value:handleNumber(l[4]),data:l[5],chainId:0};if(6===l.length)return et;try{et.v=ef.O$.from(l[6]).toNumber()}catch(c){return et}if(et.r=(0,ep.$m)(l[7],32),et.s=(0,ep.$m)(l[8],32),ef.O$.from(et.r).isZero()&&ef.O$.from(et.s).isZero())et.chainId=et.v,et.v=0;else{et.chainId=Math.floor((et.v-35)/2),et.chainId<0&&(et.chainId=0);let eo=et.v-27,es=l.slice(0,6);0!==et.chainId&&(es.push((0,ep.Dv)(et.chainId)),es.push("0x"),es.push("0x"),eo-=2*et.chainId+8);let ec=(0,em.w)(eM.c(es));try{et.from=recoverAddress(ec,{r:(0,ep.Dv)(et.r),s:(0,ep.Dv)(et.s),recoveryParam:eo})}catch(c){}et.hash=(0,em.w)(c)}return et.type=null,et}(l);switch(l[0]){case 1:return function(c){let l=eM.J(c.slice(1));8!==l.length&&11!==l.length&&e2.throwArgumentError("invalid component count for transaction type: 1","payload",(0,ep.Dv)(c));let et={type:1,chainId:handleNumber(l[0]).toNumber(),nonce:handleNumber(l[1]).toNumber(),gasPrice:handleNumber(l[2]),gasLimit:handleNumber(l[3]),to:handleAddress(l[4]),value:handleNumber(l[5]),data:l[6],accessList:accessListify(l[7])};return 8===l.length||(et.hash=(0,em.w)(c),_parseEipSignature(et,l.slice(8),_serializeEip2930)),et}(l);case 2:return function(c){let l=eM.J(c.slice(1));9!==l.length&&12!==l.length&&e2.throwArgumentError("invalid component count for transaction type: 2","payload",(0,ep.Dv)(c));let et=handleNumber(l[2]),eo=handleNumber(l[3]),es={type:2,chainId:handleNumber(l[0]).toNumber(),nonce:handleNumber(l[1]).toNumber(),maxPriorityFeePerGas:et,maxFeePerGas:eo,gasPrice:null,gasLimit:handleNumber(l[4]),to:handleAddress(l[5]),value:handleNumber(l[6]),data:l[7],accessList:accessListify(l[8])};return 9===l.length||(es.hash=(0,em.w)(c),_parseEipSignature(es,l.slice(9),_serializeEip1559)),es}(l)}return e2.throwError(`unsupported transaction type: ${l[0]}`,ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:"parseTransaction",transactionType:l[0]})}(c)}receiptLog(c){return Formatter.check(this.formats.receiptLog,c)}receipt(c){let l=Formatter.check(this.formats.receipt,c);if(null!=l.root){if(l.root.length<=4){let c=ef.O$.from(l.root).toNumber();0===c||1===c?(null!=l.status&&l.status!==c&&tm.throwArgumentError("alt-root-status/status mismatch","value",{root:l.root,status:l.status}),l.status=c,delete l.root):tm.throwArgumentError("invalid alt-root-status","value.root",l.root)}else 66!==l.root.length&&tm.throwArgumentError("invalid root hash","value.root",l.root)}return null!=l.status&&(l.byzantium=!0),l}topics(c){return Array.isArray(c)?c.map(c=>this.topics(c)):null!=c?this.hash(c,!0):null}filter(c){return Formatter.check(this.formats.filter,c)}filterLog(c){return Formatter.check(this.formats.filterLog,c)}static check(c,l){let et={};for(let eo in c)try{let es=c[eo](l[eo]);void 0!==es&&(et[eo]=es)}catch(c){throw c.checkKey=eo,c.checkValue=l[eo],c}return et}static allowNull(c,l){return function(et){return null==et?l:c(et)}}static allowFalsish(c,l){return function(et){return et?c(et):l}}static arrayOf(c){return function(l){if(!Array.isArray(l))throw Error("not an array");let et=[];return l.forEach(function(l){et.push(c(l))}),et}}};var base_provider_awaiter=function(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})};let tb=new ey.Yd(e5.i);function checkTopic(c){return null==c?"null":(32!==(0,ep.E1)(c)&&tb.throwArgumentError("invalid topic","topic",c),c.toLowerCase())}function serializeTopics(c){for(c=c.slice();c.length>0&&null==c[c.length-1];)c.pop();return c.map(c=>{if(!Array.isArray(c))return checkTopic(c);{let l={};c.forEach(c=>{l[checkTopic(c)]=!0});let et=Object.keys(l);return et.sort(),et.join("|")}}).join("&")}function getEventTag(c){if("string"==typeof c){if(c=c.toLowerCase(),32===(0,ep.E1)(c))return"tx:"+c;if(-1===c.indexOf(":"))return c}else if(Array.isArray(c))return"filter:*:"+serializeTopics(c);else if(ForkEvent.isForkEvent(c))throw tb.warn("not implemented"),Error("not implemented");else if(c&&"object"==typeof c)return"filter:"+(c.address||"*")+":"+serializeTopics(c.topics||[]);throw Error("invalid event - "+c)}function getTime(){return new Date().getTime()}function stall(c){return new Promise(l=>{setTimeout(l,c)})}let ty=["block","network","pending","poll"];let Event=class Event{constructor(c,l,et){(0,eb.zG)(this,"tag",c),(0,eb.zG)(this,"listener",l),(0,eb.zG)(this,"once",et),this._lastBlockNumber=-2,this._inflight=!1}get event(){switch(this.type){case"tx":return this.hash;case"filter":return this.filter}return this.tag}get type(){return this.tag.split(":")[0]}get hash(){let c=this.tag.split(":");return"tx"!==c[0]?null:c[1]}get filter(){var c;let l=this.tag.split(":");if("filter"!==l[0])return null;let et=l[1],eo=""===(c=l[2])?[]:c.split(/&/g).map(c=>{if(""===c)return[];let l=c.split("|").map(c=>"null"===c?null:c);return 1===l.length?l[0]:l}),es={};return eo.length>0&&(es.topics=eo),et&&"*"!==et&&(es.address=et),es}pollable(){return this.tag.indexOf(":")>=0||ty.indexOf(this.tag)>=0}};let t_={0:{symbol:"btc",p2pkh:0,p2sh:5,prefix:"bc"},2:{symbol:"ltc",p2pkh:48,p2sh:50,prefix:"ltc"},3:{symbol:"doge",p2pkh:30,p2sh:22},60:{symbol:"eth",ilk:"eth"},61:{symbol:"etc",ilk:"eth"},700:{symbol:"xdai",ilk:"eth"}};function bytes32ify(c){return(0,ep.$m)(ef.O$.from(c).toHexString(),32)}function base58Encode(c){return e4.encode((0,ep.zo)([c,(0,ep.p3)(sha256(sha256(c)),0,4)]))}let tw=RegExp("^(ipfs)://(.*)$","i"),tE=[RegExp("^(https)://(.*)$","i"),RegExp("^(data):(.*)$","i"),tw,RegExp("^eip155:[0-9]+/(erc[0-9]+):(.*)$","i")];function _parseString(c,l){try{return(0,ew.ZN)(_parseBytes(c,l))}catch(c){}return null}function _parseBytes(c,l){if("0x"===c)return null;let et=ef.O$.from((0,ep.p3)(c,l,l+32)).toNumber(),eo=ef.O$.from((0,ep.p3)(c,et,et+32)).toNumber();return(0,ep.p3)(c,et+32,et+32+eo)}function getIpfsLink(c){return c.match(/^ipfs:\/\/ipfs\//i)?c=c.substring(12):c.match(/^ipfs:\/\//i)?c=c.substring(7):tb.throwArgumentError("unsupported IPFS format","link",c),`https://gateway.ipfs.io/ipfs/${c}`}function numPad(c){let l=(0,ep.lE)(c);if(l.length>32)throw Error("internal; should not happen");let et=new Uint8Array(32);return et.set(l,32-l.length),et}function encodeBytes(c){let l=[],et=0;for(let eo=0;eoef.O$.from(c).eq(1)).catch(c=>{if(c.code===ey.Yd.errors.CALL_EXCEPTION)return!1;throw this._supportsEip2544=null,c})),this._supportsEip2544}_fetch(c,l){return base_provider_awaiter(this,void 0,void 0,function*(){let et={to:this.address,ccipReadEnabled:!0,data:(0,ep.xs)([c,namehash(this.name),l||"0x"])},eo=!1;if(yield this.supportsWildcard()){var es;eo=!0,et.data=(0,ep.xs)(["0x9061b923",encodeBytes([(es=this.name,(0,ep.Dv)((0,ep.zo)(ensNameSplit(es).map(c=>{if(c.length>63)throw Error("invalid DNS encoded entry; length exceeds 63 bytes");let l=new Uint8Array(c.length+1);return l.set(c,1),l[0]=l.length-1,l})))+"00"),et.data])])}try{let c=yield this.provider.call(et);return(0,ep.lE)(c).length%32==4&&tb.throwError("resolver threw error",ey.Yd.errors.CALL_EXCEPTION,{transaction:et,data:c}),eo&&(c=_parseBytes(c,0)),c}catch(c){if(c.code===ey.Yd.errors.CALL_EXCEPTION)return null;throw c}})}_fetchBytes(c,l){return base_provider_awaiter(this,void 0,void 0,function*(){let et=yield this._fetch(c,l);return null!=et?_parseBytes(et,0):null})}_getAddress(c,l){let et=t_[String(c)];if(null==et&&tb.throwError(`unsupported coin type: ${c}`,ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${c})`}),"eth"===et.ilk)return this.provider.formatter.address(l);let eo=(0,ep.lE)(l);if(null!=et.p2pkh){let c=l.match(/^0x76a9([0-9a-f][0-9a-f])([0-9a-f]*)88ac$/);if(c){let l=parseInt(c[1],16);if(c[2].length===2*l&&l>=1&&l<=75)return base58Encode((0,ep.zo)([[et.p2pkh],"0x"+c[2]]))}}if(null!=et.p2sh){let c=l.match(/^0xa9([0-9a-f][0-9a-f])([0-9a-f]*)87$/);if(c){let l=parseInt(c[1],16);if(c[2].length===2*l&&l>=1&&l<=75)return base58Encode((0,ep.zo)([[et.p2sh],"0x"+c[2]]))}}if(null!=et.prefix){let c=eo[1],l=eo[0];if(0===l?20!==c&&32!==c&&(l=-1):l=-1,l>=0&&eo.length===2+c&&c>=1&&c<=75){let c=tg().toWords(eo.slice(2));return c.unshift(l),tg().encode(et.prefix,c)}}return null}getAddress(c){return base_provider_awaiter(this,void 0,void 0,function*(){if(null==c&&(c=60),60===c)try{let c=yield this._fetch("0x3b3b57de");if("0x"===c||"0x0000000000000000000000000000000000000000000000000000000000000000"===c)return null;return this.provider.formatter.callAddress(c)}catch(c){if(c.code===ey.Yd.errors.CALL_EXCEPTION)return null;throw c}let l=yield this._fetchBytes("0xf1cb7e06",bytes32ify(c));if(null==l||"0x"===l)return null;let et=this._getAddress(c,l);return null==et&&tb.throwError("invalid or unsupported coin data",ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:`getAddress(${c})`,coinType:c,data:l}),et})}getAvatar(){return base_provider_awaiter(this,void 0,void 0,function*(){let c=[{type:"name",content:this.name}];try{let l=yield this.getText("avatar");if(null==l)return null;for(let et=0;etc[l]);return"sia://"+l}return tb.throwError("invalid or unsupported content hash data",ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:"getContentHash()",data:c})})}getText(c){return base_provider_awaiter(this,void 0,void 0,function*(){let l=(0,ew.Y0)(c);(l=(0,ep.zo)([bytes32ify(64),bytes32ify(l.length),l])).length%32!=0&&(l=(0,ep.zo)([l,(0,ep.$m)("0x",32-c.length%32)]));let et=yield this._fetchBytes("0x59d1d43c",(0,ep.Dv)(l));return null==et||"0x"===et?null:(0,ew.ZN)(et)})}};let tS=null,tx=1;let BaseProvider=class BaseProvider extends Provider{constructor(c){if(super(),this._events=[],this._emitted={block:-2},this.disableCcipRead=!1,this.formatter=new.target.getFormatter(),(0,eb.zG)(this,"anyNetwork","any"===c),this.anyNetwork&&(c=this.detectNetwork()),c instanceof Promise)this._networkPromise=c,c.catch(c=>{}),this._ready().catch(c=>{});else{let l=(0,eb.tu)(new.target,"getNetwork")(c);l?((0,eb.zG)(this,"_network",l),this.emit("network",l,null)):tb.throwArgumentError("invalid network","network",c)}this._maxInternalBlockNumber=-1024,this._lastBlockNumber=-2,this._maxFilterBlockRange=10,this._pollingInterval=4e3,this._fastQueryDate=0}_ready(){return base_provider_awaiter(this,void 0,void 0,function*(){if(null==this._network){let c=null;if(this._networkPromise)try{c=yield this._networkPromise}catch(c){}null==c&&(c=yield this.detectNetwork()),c||tb.throwError("no network detected",ey.Yd.errors.UNKNOWN_ERROR,{}),null==this._network&&(this.anyNetwork?this._network=c:(0,eb.zG)(this,"_network",c),this.emit("network",c,null))}return this._network})}get ready(){return poll(()=>this._ready().then(c=>c,c=>{if(c.code!==ey.Yd.errors.NETWORK_ERROR||"noNetwork"!==c.event)throw c}))}static getFormatter(){return null==tS&&(tS=new Formatter),tS}static getNetwork(c){return function(c){if(null==c)return null;if("number"==typeof c){for(let l in tf){let et=tf[l];if(et.chainId===c)return{name:et.name,chainId:et.chainId,ensAddress:et.ensAddress||null,_defaultProvider:et._defaultProvider||null}}return{chainId:c,name:"unknown"}}if("string"==typeof c){let l=tf[c];return null==l?null:{name:l.name,chainId:l.chainId,ensAddress:l.ensAddress,_defaultProvider:l._defaultProvider||null}}let l=tf[c.name];if(!l)return"number"!=typeof c.chainId&&tc.throwArgumentError("invalid network chainId","network",c),c;0!==c.chainId&&c.chainId!==l.chainId&&tc.throwArgumentError("network chainId mismatch","network",c);let et=c._defaultProvider||null;if(null==et&&l._defaultProvider){var eo;et=(eo=l._defaultProvider)&&"function"==typeof eo.renetwork?l._defaultProvider.renetwork(c):l._defaultProvider}return{name:c.name,chainId:l.chainId,ensAddress:c.ensAddress||l.ensAddress||null,_defaultProvider:et}}(null==c?"homestead":c)}ccipReadFetch(c,l,et){return base_provider_awaiter(this,void 0,void 0,function*(){if(this.disableCcipRead||0===et.length)return null;let eo=c.to.toLowerCase(),es=l.toLowerCase(),ec=[];for(let c=0;c=0?null:JSON.stringify({data:es,sender:eo}),eh=yield fetchJson({url:el,errorPassThrough:!0},ed,(c,l)=>(c.status=l.statusCode,c));if(eh.data)return eh.data;let ef=eh.message||"unknown error";if(eh.status>=400&&eh.status<500)return tb.throwError(`response not found during CCIP fetch: ${ef}`,ey.Yd.errors.SERVER_ERROR,{url:l,errorMessage:ef});ec.push(ef)}return tb.throwError(`error encountered during CCIP fetch: ${ec.map(c=>JSON.stringify(c)).join(", ")}`,ey.Yd.errors.SERVER_ERROR,{urls:et,errorMessages:ec})})}_getInternalBlockNumber(c){return base_provider_awaiter(this,void 0,void 0,function*(){if(yield this._ready(),c>0)for(;this._internalBlockNumber;){let l=this._internalBlockNumber;try{let et=yield l;if(getTime()-et.respTime<=c)return et.blockNumber;break}catch(c){if(this._internalBlockNumber===l)break}}let l=getTime(),et=(0,eb.mE)({blockNumber:this.perform("getBlockNumber",{}),networkError:this.getNetwork().then(c=>null,c=>c)}).then(({blockNumber:c,networkError:eo})=>{if(eo)throw this._internalBlockNumber===et&&(this._internalBlockNumber=null),eo;let es=getTime();return(c=ef.O$.from(c).toNumber()){this._internalBlockNumber===et&&(this._internalBlockNumber=null)}),(yield et).blockNumber})}poll(){return base_provider_awaiter(this,void 0,void 0,function*(){let c=tx++,l=[],et=null;try{et=yield this._getInternalBlockNumber(100+this.pollingInterval/2)}catch(c){this.emit("error",c);return}if(this._setFastBlockNumber(et),this.emit("poll",c,et),et===this._lastBlockNumber){this.emit("didPoll",c);return}if(-2===this._emitted.block&&(this._emitted.block=et-1),Math.abs(this._emitted.block-et)>1e3)tb.warn(`network block skew detected; skipping block events (emitted=${this._emitted.block} blockNumber${et})`),this.emit("error",tb.makeError("network block skew detected",ey.Yd.errors.NETWORK_ERROR,{blockNumber:et,event:"blockSkew",previousBlockNumber:this._emitted.block})),this.emit("block",et);else for(let c=this._emitted.block+1;c<=et;c++)this.emit("block",c);this._emitted.block!==et&&(this._emitted.block=et,Object.keys(this._emitted).forEach(c=>{if("block"===c)return;let l=this._emitted[c];"pending"!==l&&et-l>12&&delete this._emitted[c]})),-2===this._lastBlockNumber&&(this._lastBlockNumber=et-1),this._events.forEach(c=>{switch(c.type){case"tx":{let et=c.hash,eo=this.getTransactionReceipt(et).then(c=>(c&&null!=c.blockNumber&&(this._emitted["t:"+et]=c.blockNumber,this.emit(et,c)),null)).catch(c=>{this.emit("error",c)});l.push(eo);break}case"filter":if(!c._inflight){c._inflight=!0,-2===c._lastBlockNumber&&(c._lastBlockNumber=et-1);let eo=c.filter;eo.fromBlock=c._lastBlockNumber+1,eo.toBlock=et;let es=eo.toBlock-this._maxFilterBlockRange;es>eo.fromBlock&&(eo.fromBlock=es),eo.fromBlock<0&&(eo.fromBlock=0);let ec=this.getLogs(eo).then(l=>{c._inflight=!1,0!==l.length&&l.forEach(l=>{l.blockNumber>c._lastBlockNumber&&(c._lastBlockNumber=l.blockNumber),this._emitted["b:"+l.blockHash]=l.blockNumber,this._emitted["t:"+l.transactionHash]=l.blockNumber,this.emit(eo,l)})}).catch(l=>{this.emit("error",l),c._inflight=!1});l.push(ec)}}}),this._lastBlockNumber=et,Promise.all(l).then(()=>{this.emit("didPoll",c)}).catch(c=>{this.emit("error",c)})})}resetEventsBlock(c){this._lastBlockNumber=c-1,this.polling&&this.poll()}get network(){return this._network}detectNetwork(){return base_provider_awaiter(this,void 0,void 0,function*(){return tb.throwError("provider does not support network detection",ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:"provider.detectNetwork"})})}getNetwork(){return base_provider_awaiter(this,void 0,void 0,function*(){let c=yield this._ready(),l=yield this.detectNetwork();if(c.chainId!==l.chainId){if(this.anyNetwork)return this._network=l,this._lastBlockNumber=-2,this._fastBlockNumber=null,this._fastBlockNumberPromise=null,this._fastQueryDate=0,this._emitted.block=-2,this._maxInternalBlockNumber=-1024,this._internalBlockNumber=null,this.emit("network",l,c),yield stall(0),this._network;let et=tb.makeError("underlying network changed",ey.Yd.errors.NETWORK_ERROR,{event:"changed",network:c,detectedNetwork:l});throw this.emit("error",et),et}return c})}get blockNumber(){return this._getInternalBlockNumber(100+this.pollingInterval/2).then(c=>{this._setFastBlockNumber(c)},c=>{}),null!=this._fastBlockNumber?this._fastBlockNumber:-1}get polling(){return null!=this._poller}set polling(c){c&&!this._poller?(this._poller=setInterval(()=>{this.poll()},this.pollingInterval),this._bootstrapPoll||(this._bootstrapPoll=setTimeout(()=>{this.poll(),this._bootstrapPoll=setTimeout(()=>{this._poller||this.poll(),this._bootstrapPoll=null},this.pollingInterval)},0))):!c&&this._poller&&(clearInterval(this._poller),this._poller=null)}get pollingInterval(){return this._pollingInterval}set pollingInterval(c){if("number"!=typeof c||c<=0||parseInt(String(c))!=c)throw Error("invalid polling interval");this._pollingInterval=c,this._poller&&(clearInterval(this._poller),this._poller=setInterval(()=>{this.poll()},this._pollingInterval))}_getFastBlockNumber(){let c=getTime();return c-this._fastQueryDate>2*this._pollingInterval&&(this._fastQueryDate=c,this._fastBlockNumberPromise=this.getBlockNumber().then(c=>((null==this._fastBlockNumber||c>this._fastBlockNumber)&&(this._fastBlockNumber=c),this._fastBlockNumber))),this._fastBlockNumberPromise}_setFastBlockNumber(c){(null==this._fastBlockNumber||!(cthis._fastBlockNumber)&&(this._fastBlockNumber=c,this._fastBlockNumberPromise=Promise.resolve(c)))}waitForTransaction(c,l,et){return base_provider_awaiter(this,void 0,void 0,function*(){return this._waitForTransaction(c,null==l?1:l,et||0,null)})}_waitForTransaction(c,l,et,eo){return base_provider_awaiter(this,void 0,void 0,function*(){let es=yield this.getTransactionReceipt(c);return(es?es.confirmations:0)>=l?es:new Promise((es,ec)=>{let el=[],ed=!1,alreadyDone=function(){return!!ed||(ed=!0,el.forEach(c=>{c()}),!1)},minedHandler=c=>{c.confirmations{this.removeListener(c,minedHandler)}),eo){let et=eo.startBlock,es=null,replaceHandler=el=>base_provider_awaiter(this,void 0,void 0,function*(){ed||(yield stall(1e3),this.getTransactionCount(eo.from).then(eh=>base_provider_awaiter(this,void 0,void 0,function*(){if(!ed){if(eh<=eo.nonce)et=el;else{{let l=yield this.getTransaction(c);if(l&&null!=l.blockNumber)return}for(null==es&&(es=et-3){ed||this.once("block",replaceHandler)}))});if(ed)return;this.once("block",replaceHandler),el.push(()=>{this.removeListener("block",replaceHandler)})}if("number"==typeof et&&et>0){let c=setTimeout(()=>{alreadyDone()||ec(tb.makeError("timeout exceeded",ey.Yd.errors.TIMEOUT,{timeout:et}))},et);c.unref&&c.unref(),el.push(()=>{clearTimeout(c)})}})})}getBlockNumber(){return base_provider_awaiter(this,void 0,void 0,function*(){return this._getInternalBlockNumber(0)})}getGasPrice(){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let c=yield this.perform("getGasPrice",{});try{return ef.O$.from(c)}catch(l){return tb.throwError("bad result from backend",ey.Yd.errors.SERVER_ERROR,{method:"getGasPrice",result:c,error:l})}})}getBalance(c,l){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let et=yield(0,eb.mE)({address:this._getAddress(c),blockTag:this._getBlockTag(l)}),eo=yield this.perform("getBalance",et);try{return ef.O$.from(eo)}catch(c){return tb.throwError("bad result from backend",ey.Yd.errors.SERVER_ERROR,{method:"getBalance",params:et,result:eo,error:c})}})}getTransactionCount(c,l){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let et=yield(0,eb.mE)({address:this._getAddress(c),blockTag:this._getBlockTag(l)}),eo=yield this.perform("getTransactionCount",et);try{return ef.O$.from(eo).toNumber()}catch(c){return tb.throwError("bad result from backend",ey.Yd.errors.SERVER_ERROR,{method:"getTransactionCount",params:et,result:eo,error:c})}})}getCode(c,l){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let et=yield(0,eb.mE)({address:this._getAddress(c),blockTag:this._getBlockTag(l)}),eo=yield this.perform("getCode",et);try{return(0,ep.Dv)(eo)}catch(c){return tb.throwError("bad result from backend",ey.Yd.errors.SERVER_ERROR,{method:"getCode",params:et,result:eo,error:c})}})}getStorageAt(c,l,et){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let eo=yield(0,eb.mE)({address:this._getAddress(c),blockTag:this._getBlockTag(et),position:Promise.resolve(l).then(c=>(0,ep.$P)(c))}),es=yield this.perform("getStorageAt",eo);try{return(0,ep.Dv)(es)}catch(c){return tb.throwError("bad result from backend",ey.Yd.errors.SERVER_ERROR,{method:"getStorageAt",params:eo,result:es,error:c})}})}_wrapTransaction(c,l,et){if(null!=l&&32!==(0,ep.E1)(l))throw Error("invalid response - sendTransaction");return null!=l&&c.hash!==l&&tb.throwError("Transaction hash mismatch from Provider.sendTransaction.",ey.Yd.errors.UNKNOWN_ERROR,{expectedHash:c.hash,returnedHash:l}),c.wait=(l,eo)=>base_provider_awaiter(this,void 0,void 0,function*(){let es;null==l&&(l=1),null==eo&&(eo=0),0!==l&&null!=et&&(es={data:c.data,from:c.from,nonce:c.nonce,to:c.to,value:c.value,startBlock:et});let ec=yield this._waitForTransaction(c.hash,l,eo,es);return null==ec&&0===l?null:(this._emitted["t:"+c.hash]=ec.blockNumber,0===ec.status&&tb.throwError("transaction failed",ey.Yd.errors.CALL_EXCEPTION,{transactionHash:c.hash,transaction:c,receipt:ec}),ec)}),c}sendTransaction(c){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let l=yield Promise.resolve(c).then(c=>(0,ep.Dv)(c)),et=this.formatter.transaction(c);null==et.confirmations&&(et.confirmations=0);let eo=yield this._getInternalBlockNumber(100+2*this.pollingInterval);try{let c=yield this.perform("sendTransaction",{signedTransaction:l});return this._wrapTransaction(et,c,eo)}catch(c){throw c.transaction=et,c.transactionHash=et.hash,c}})}_getTransactionRequest(c){return base_provider_awaiter(this,void 0,void 0,function*(){let l=yield c,et={};return["from","to"].forEach(c=>{null!=l[c]&&(et[c]=Promise.resolve(l[c]).then(c=>c?this._getAddress(c):null))}),["gasLimit","gasPrice","maxFeePerGas","maxPriorityFeePerGas","value"].forEach(c=>{null!=l[c]&&(et[c]=Promise.resolve(l[c]).then(c=>c?ef.O$.from(c):null))}),["type"].forEach(c=>{null!=l[c]&&(et[c]=Promise.resolve(l[c]).then(c=>null!=c?c:null))}),l.accessList&&(et.accessList=this.formatter.accessList(l.accessList)),["data"].forEach(c=>{null!=l[c]&&(et[c]=Promise.resolve(l[c]).then(c=>c?(0,ep.Dv)(c):null))}),this.formatter.transactionRequest((yield(0,eb.mE)(et)))})}_getFilter(c){return base_provider_awaiter(this,void 0,void 0,function*(){c=yield c;let l={};return null!=c.address&&(l.address=this._getAddress(c.address)),["blockHash","topics"].forEach(et=>{null!=c[et]&&(l[et]=c[et])}),["fromBlock","toBlock"].forEach(et=>{null!=c[et]&&(l[et]=this._getBlockTag(c[et]))}),this.formatter.filter((yield(0,eb.mE)(l)))})}_call(c,l,et){return base_provider_awaiter(this,void 0,void 0,function*(){et>=10&&tb.throwError("CCIP read exceeded maximum redirections",ey.Yd.errors.SERVER_ERROR,{redirects:et,transaction:c});let eo=c.to,es=yield this.perform("call",{transaction:c,blockTag:l});if(et>=0&&"latest"===l&&null!=eo&&"0x556f1830"===es.substring(0,10)&&(0,ep.E1)(es)%32==4)try{let ec=(0,ep.p3)(es,4),el=(0,ep.p3)(ec,0,32);ef.O$.from(el).eq(eo)||tb.throwError("CCIP Read sender did not match",ey.Yd.errors.CALL_EXCEPTION,{name:"OffchainLookup",signature:"OffchainLookup(address,string[],bytes,bytes4,bytes)",transaction:c,data:es});let ed=[],eh=ef.O$.from((0,ep.p3)(ec,32,64)).toNumber(),eg=ef.O$.from((0,ep.p3)(ec,eh,eh+32)).toNumber(),em=(0,ep.p3)(ec,eh+32);for(let l=0;lbase_provider_awaiter(this,void 0,void 0,function*(){let c=yield this.perform("getBlock",eo);if(null==c)return null!=eo.blockHash&&null==this._emitted["b:"+eo.blockHash]||null!=eo.blockTag&&et>this._emitted.block?null:void 0;if(l){let l=null;for(let et=0;etthis._wrapTransaction(c)),et}return this.formatter.block(c)}),{oncePoll:this})})}getBlock(c){return this._getBlock(c,!1)}getBlockWithTransactions(c){return this._getBlock(c,!0)}getTransaction(c){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork(),c=yield c;let l={transactionHash:this.formatter.hash(c,!0)};return poll(()=>base_provider_awaiter(this,void 0,void 0,function*(){let et=yield this.perform("getTransaction",l);if(null==et)return null==this._emitted["t:"+c]?null:void 0;let eo=this.formatter.transactionResponse(et);if(null==eo.blockNumber)eo.confirmations=0;else if(null==eo.confirmations){let c=yield this._getInternalBlockNumber(100+2*this.pollingInterval),l=c-eo.blockNumber+1;l<=0&&(l=1),eo.confirmations=l}return this._wrapTransaction(eo)}),{oncePoll:this})})}getTransactionReceipt(c){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork(),c=yield c;let l={transactionHash:this.formatter.hash(c,!0)};return poll(()=>base_provider_awaiter(this,void 0,void 0,function*(){let et=yield this.perform("getTransactionReceipt",l);if(null==et)return null==this._emitted["t:"+c]?null:void 0;if(null==et.blockHash)return;let eo=this.formatter.receipt(et);if(null==eo.blockNumber)eo.confirmations=0;else if(null==eo.confirmations){let c=yield this._getInternalBlockNumber(100+2*this.pollingInterval),l=c-eo.blockNumber+1;l<=0&&(l=1),eo.confirmations=l}return eo}),{oncePoll:this})})}getLogs(c){return base_provider_awaiter(this,void 0,void 0,function*(){yield this.getNetwork();let l=yield(0,eb.mE)({filter:this._getFilter(c)}),et=yield this.perform("getLogs",l);return et.forEach(c=>{null==c.removed&&(c.removed=!1)}),Formatter.arrayOf(this.formatter.filterLog.bind(this.formatter))(et)})}getEtherPrice(){return base_provider_awaiter(this,void 0,void 0,function*(){return yield this.getNetwork(),this.perform("getEtherPrice",{})})}_getBlockTag(c){return base_provider_awaiter(this,void 0,void 0,function*(){if("number"==typeof(c=yield c)&&c<0){c%1&&tb.throwArgumentError("invalid BlockTag","blockTag",c);let l=yield this._getInternalBlockNumber(100+2*this.pollingInterval);return(l+=c)<0&&(l=0),this.formatter.blockTag(l)}return this.formatter.blockTag(c)})}getResolver(c){return base_provider_awaiter(this,void 0,void 0,function*(){let l=c;for(;;){if(""===l||"."===l||"eth"!==c&&"eth"===l)return null;let et=yield this._getResolver(l,"getResolver");if(null!=et){let eo=new Resolver(this,et,c);if(l!==c&&!(yield eo.supportsWildcard()))return null;return eo}l=l.split(".").slice(1).join(".")}})}_getResolver(c,l){return base_provider_awaiter(this,void 0,void 0,function*(){null==l&&(l="ENS");let et=yield this.getNetwork();et.ensAddress||tb.throwError("network does not support ENS",ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:l,network:et.name});try{let l=yield this.call({to:et.ensAddress,data:"0x0178b8bf"+namehash(c).substring(2)});return this.formatter.callAddress(l)}catch(c){}return null})}resolveName(c){return base_provider_awaiter(this,void 0,void 0,function*(){c=yield c;try{return Promise.resolve(this.formatter.address(c))}catch(l){if((0,ep.A7)(c))throw l}"string"!=typeof c&&tb.throwArgumentError("invalid ENS name","name",c);let l=yield this.getResolver(c);return l?yield l.getAddress():null})}lookupAddress(c){return base_provider_awaiter(this,void 0,void 0,function*(){c=yield c,c=this.formatter.address(c);let l=c.substring(2).toLowerCase()+".addr.reverse",et=yield this._getResolver(l,"lookupAddress");if(null==et)return null;let eo=_parseString((yield this.call({to:et,data:"0x691f3431"+namehash(l).substring(2)})),0),es=yield this.resolveName(eo);return es!=c?null:eo})}getAvatar(c){return base_provider_awaiter(this,void 0,void 0,function*(){let l=null;if((0,ep.A7)(c)){let et=this.formatter.address(c),eo=et.substring(2).toLowerCase()+".addr.reverse",es=yield this._getResolver(eo,"getAvatar");if(!es)return null;l=new Resolver(this,es,eo);try{let c=yield l.getAvatar();if(c)return c.url}catch(c){if(c.code!==ey.Yd.errors.CALL_EXCEPTION)throw c}try{let c=_parseString((yield this.call({to:es,data:"0x691f3431"+namehash(eo).substring(2)})),0);l=yield this.getResolver(c)}catch(c){if(c.code!==ey.Yd.errors.CALL_EXCEPTION)throw c;return null}}else if(!(l=yield this.getResolver(c)))return null;let et=yield l.getAvatar();return null==et?null:et.url})}perform(c,l){return tb.throwError(c+" not implemented",ey.Yd.errors.NOT_IMPLEMENTED,{operation:c})}_startEvent(c){this.polling=this._events.filter(c=>c.pollable()).length>0}_stopEvent(c){this.polling=this._events.filter(c=>c.pollable()).length>0}_addEventListener(c,l,et){let eo=new Event(getEventTag(c),l,et);return this._events.push(eo),this._startEvent(eo),this}on(c,l){return this._addEventListener(c,l,!1)}once(c,l){return this._addEventListener(c,l,!0)}emit(c,...l){let et=!1,eo=[],es=getEventTag(c);return this._events=this._events.filter(c=>c.tag!==es||(setTimeout(()=>{c.listener.apply(this,l)},0),et=!0,!c.once||(eo.push(c),!1))),eo.forEach(c=>{this._stopEvent(c)}),et}listenerCount(c){if(!c)return this._events.length;let l=getEventTag(c);return this._events.filter(c=>c.tag===l).length}listeners(c){if(null==c)return this._events.map(c=>c.listener);let l=getEventTag(c);return this._events.filter(c=>c.tag===l).map(c=>c.listener)}off(c,l){if(null==l)return this.removeAllListeners(c);let et=[],eo=!1,es=getEventTag(c);return this._events=this._events.filter(c=>c.tag!==es||c.listener!=l||!!eo||(eo=!0,et.push(c),!1)),et.forEach(c=>{this._stopEvent(c)}),this}removeAllListeners(c){let l=[];if(null==c)l=this._events,this._events=[];else{let et=getEventTag(c);this._events=this._events.filter(c=>c.tag!==et||(l.push(c),!1))}return l.forEach(c=>{this._stopEvent(c)}),this}};var json_rpc_provider_awaiter=function(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})};let tk=new ey.Yd(e5.i),tC=["call","estimateGas"];function spelunk(c,l){if(null==c)return null;if("string"==typeof c.message&&c.message.match("reverted")){let et=(0,ep.A7)(c.data)?c.data:null;if(!l||et)return{message:c.message,data:et}}if("object"==typeof c){for(let et in c){let eo=spelunk(c[et],l);if(eo)return eo}return null}if("string"==typeof c)try{return spelunk(JSON.parse(c),l)}catch(c){}return null}function checkError(c,l,et){let eo=et.transaction||et.signedTransaction;if("call"===c){let c=spelunk(l,!0);if(c)return c.data;tk.throwError("missing revert data in call exception; Transaction reverted without a reason string",ey.Yd.errors.CALL_EXCEPTION,{data:"0x",transaction:eo,error:l})}if("estimateGas"===c){let et=spelunk(l.body,!1);null==et&&(et=spelunk(l,!1)),et&&tk.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ey.Yd.errors.UNPREDICTABLE_GAS_LIMIT,{reason:et.message,method:c,transaction:eo,error:l})}let es=l.message;throw l.code===ey.Yd.errors.SERVER_ERROR&&l.error&&"string"==typeof l.error.message?es=l.error.message:"string"==typeof l.body?es=l.body:"string"==typeof l.responseText&&(es=l.responseText),(es=(es||"").toLowerCase()).match(/insufficient funds|base fee exceeds gas limit|InsufficientFunds/i)&&tk.throwError("insufficient funds for intrinsic transaction cost",ey.Yd.errors.INSUFFICIENT_FUNDS,{error:l,method:c,transaction:eo}),es.match(/nonce (is )?too low/i)&&tk.throwError("nonce has already been used",ey.Yd.errors.NONCE_EXPIRED,{error:l,method:c,transaction:eo}),es.match(/replacement transaction underpriced|transaction gas price.*too low/i)&&tk.throwError("replacement fee too low",ey.Yd.errors.REPLACEMENT_UNDERPRICED,{error:l,method:c,transaction:eo}),es.match(/only replay-protected/i)&&tk.throwError("legacy pre-eip-155 transactions not supported",ey.Yd.errors.UNSUPPORTED_OPERATION,{error:l,method:c,transaction:eo}),tC.indexOf(c)>=0&&es.match(/gas required exceeds allowance|always failing transaction|execution reverted|revert/)&&tk.throwError("cannot estimate gas; transaction may fail or may require manual gas limit",ey.Yd.errors.UNPREDICTABLE_GAS_LIMIT,{error:l,method:c,transaction:eo}),l}function timer(c){return new Promise(function(l){setTimeout(l,c)})}function getResult(c){if(c.error){let l=Error(c.error.message);throw l.code=c.error.code,l.data=c.error.data,l}return c.result}function getLowerCase(c){return c?c.toLowerCase():c}let tA={};let JsonRpcSigner=class JsonRpcSigner extends eh.E{constructor(c,l,et){if(super(),c!==tA)throw Error("do not call the JsonRpcSigner constructor directly; use provider.getSigner");(0,eb.zG)(this,"provider",l),null==et&&(et=0),"string"==typeof et?((0,eb.zG)(this,"_address",this.provider.formatter.address(et)),(0,eb.zG)(this,"_index",null)):"number"==typeof et?((0,eb.zG)(this,"_index",et),(0,eb.zG)(this,"_address",null)):tk.throwArgumentError("invalid address or index","addressOrIndex",et)}connect(c){return tk.throwError("cannot alter JSON-RPC Signer connection",ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:"connect"})}connectUnchecked(){return new UncheckedJsonRpcSigner(tA,this.provider,this._address||this._index)}getAddress(){return this._address?Promise.resolve(this._address):this.provider.send("eth_accounts",[]).then(c=>(c.length<=this._index&&tk.throwError("unknown account #"+this._index,ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:"getAddress"}),this.provider.formatter.address(c[this._index])))}sendUncheckedTransaction(c){c=(0,eb.DC)(c);let l=this.getAddress().then(c=>(c&&(c=c.toLowerCase()),c));if(null==c.gasLimit){let et=(0,eb.DC)(c);et.from=l,c.gasLimit=this.provider.estimateGas(et)}return null!=c.to&&(c.to=Promise.resolve(c.to).then(c=>json_rpc_provider_awaiter(this,void 0,void 0,function*(){if(null==c)return null;let l=yield this.provider.resolveName(c);return null==l&&tk.throwArgumentError("provided ENS name resolves to null","tx.to",c),l}))),(0,eb.mE)({tx:(0,eb.mE)(c),sender:l}).then(({tx:l,sender:et})=>{null!=l.from?l.from.toLowerCase()!==et&&tk.throwArgumentError("from address mismatch","transaction",c):l.from=et;let eo=this.provider.constructor.hexlifyTransaction(l,{from:!0});return this.provider.send("eth_sendTransaction",[eo]).then(c=>c,c=>("string"==typeof c.message&&c.message.match(/user denied/i)&&tk.throwError("user rejected transaction",ey.Yd.errors.ACTION_REJECTED,{action:"sendTransaction",transaction:l}),checkError("sendTransaction",c,eo)))})}signTransaction(c){return tk.throwError("signing transactions is unsupported",ey.Yd.errors.UNSUPPORTED_OPERATION,{operation:"signTransaction"})}sendTransaction(c){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){let l=yield this.provider._getInternalBlockNumber(100+2*this.provider.pollingInterval),et=yield this.sendUncheckedTransaction(c);try{return yield poll(()=>json_rpc_provider_awaiter(this,void 0,void 0,function*(){let c=yield this.provider.getTransaction(et);if(null!==c)return this.provider._wrapTransaction(c,et,l)}),{oncePoll:this.provider})}catch(c){throw c.transactionHash=et,c}})}signMessage(c){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){let l="string"==typeof c?(0,ew.Y0)(c):c,et=yield this.getAddress();try{return yield this.provider.send("personal_sign",[(0,ep.Dv)(l),et.toLowerCase()])}catch(l){throw"string"==typeof l.message&&l.message.match(/user denied/i)&&tk.throwError("user rejected signing",ey.Yd.errors.ACTION_REJECTED,{action:"signMessage",from:et,messageData:c}),l}})}_legacySignMessage(c){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){let l="string"==typeof c?(0,ew.Y0)(c):c,et=yield this.getAddress();try{return yield this.provider.send("eth_sign",[et.toLowerCase(),(0,ep.Dv)(l)])}catch(l){throw"string"==typeof l.message&&l.message.match(/user denied/i)&&tk.throwError("user rejected signing",ey.Yd.errors.ACTION_REJECTED,{action:"_legacySignMessage",from:et,messageData:c}),l}})}_signTypedData(c,l,et){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){let eo=yield TypedDataEncoder.resolveNames(c,l,et,c=>this.provider.resolveName(c)),es=yield this.getAddress();try{return yield this.provider.send("eth_signTypedData_v4",[es.toLowerCase(),JSON.stringify(TypedDataEncoder.getPayload(eo.domain,l,eo.value))])}catch(c){throw"string"==typeof c.message&&c.message.match(/user denied/i)&&tk.throwError("user rejected signing",ey.Yd.errors.ACTION_REJECTED,{action:"_signTypedData",from:es,messageData:{domain:eo.domain,types:l,value:eo.value}}),c}})}unlock(c){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){let l=this.provider,et=yield this.getAddress();return l.send("personal_unlockAccount",[et.toLowerCase(),c,null])})}};let UncheckedJsonRpcSigner=class UncheckedJsonRpcSigner extends JsonRpcSigner{sendTransaction(c){return this.sendUncheckedTransaction(c).then(c=>({hash:c,nonce:null,gasLimit:null,gasPrice:null,data:null,value:null,chainId:null,confirmations:0,from:null,wait:l=>this.provider.waitForTransaction(c,l)}))}};let tI={chainId:!0,data:!0,gasLimit:!0,gasPrice:!0,nonce:!0,to:!0,value:!0,type:!0,accessList:!0,maxFeePerGas:!0,maxPriorityFeePerGas:!0};let JsonRpcProvider=class JsonRpcProvider extends BaseProvider{constructor(c,l){let et=l;null==et&&(et=new Promise((c,l)=>{setTimeout(()=>{this.detectNetwork().then(l=>{c(l)},c=>{l(c)})},0)})),super(et),c||(c=(0,eb.tu)(this.constructor,"defaultUrl")()),"string"==typeof c?(0,eb.zG)(this,"connection",Object.freeze({url:c})):(0,eb.zG)(this,"connection",Object.freeze((0,eb.DC)(c))),this._nextId=42}get _cache(){return null==this._eventLoopCache&&(this._eventLoopCache={}),this._eventLoopCache}static defaultUrl(){return"http://localhost:8545"}detectNetwork(){return this._cache.detectNetwork||(this._cache.detectNetwork=this._uncachedDetectNetwork(),setTimeout(()=>{this._cache.detectNetwork=null},0)),this._cache.detectNetwork}_uncachedDetectNetwork(){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){yield timer(0);let c=null;try{c=yield this.send("eth_chainId",[])}catch(l){try{c=yield this.send("net_version",[])}catch(c){}}if(null!=c){let l=(0,eb.tu)(this.constructor,"getNetwork");try{return l(ef.O$.from(c).toNumber())}catch(l){return tk.throwError("could not detect network",ey.Yd.errors.NETWORK_ERROR,{chainId:c,event:"invalidNetwork",serverError:l})}}return tk.throwError("could not detect network",ey.Yd.errors.NETWORK_ERROR,{event:"noNetwork"})})}getSigner(c){return new JsonRpcSigner(tA,this,c)}getUncheckedSigner(c){return this.getSigner(c).connectUnchecked()}listAccounts(){return this.send("eth_accounts",[]).then(c=>c.map(c=>this.formatter.address(c)))}send(c,l){let et={method:c,params:l,id:this._nextId++,jsonrpc:"2.0"};this.emit("debug",{action:"request",request:(0,eb.p$)(et),provider:this});let eo=["eth_chainId","eth_blockNumber"].indexOf(c)>=0;if(eo&&this._cache[c])return this._cache[c];let es=fetchJson(this.connection,JSON.stringify(et),getResult).then(c=>(this.emit("debug",{action:"response",request:et,response:c,provider:this}),c),c=>{throw this.emit("debug",{action:"response",error:c,request:et,provider:this}),c});return eo&&(this._cache[c]=es,setTimeout(()=>{this._cache[c]=null},0)),es}prepareRequest(c,l){switch(c){case"getBlockNumber":return["eth_blockNumber",[]];case"getGasPrice":return["eth_gasPrice",[]];case"getBalance":return["eth_getBalance",[getLowerCase(l.address),l.blockTag]];case"getTransactionCount":return["eth_getTransactionCount",[getLowerCase(l.address),l.blockTag]];case"getCode":return["eth_getCode",[getLowerCase(l.address),l.blockTag]];case"getStorageAt":return["eth_getStorageAt",[getLowerCase(l.address),(0,ep.$m)(l.position,32),l.blockTag]];case"sendTransaction":return["eth_sendRawTransaction",[l.signedTransaction]];case"getBlock":if(l.blockTag)return["eth_getBlockByNumber",[l.blockTag,!!l.includeTransactions]];if(l.blockHash)return["eth_getBlockByHash",[l.blockHash,!!l.includeTransactions]];break;case"getTransaction":return["eth_getTransactionByHash",[l.transactionHash]];case"getTransactionReceipt":return["eth_getTransactionReceipt",[l.transactionHash]];case"call":{let c=(0,eb.tu)(this.constructor,"hexlifyTransaction");return["eth_call",[c(l.transaction,{from:!0}),l.blockTag]]}case"estimateGas":{let c=(0,eb.tu)(this.constructor,"hexlifyTransaction");return["eth_estimateGas",[c(l.transaction,{from:!0})]]}case"getLogs":return l.filter&&null!=l.filter.address&&(l.filter.address=getLowerCase(l.filter.address)),["eth_getLogs",[l.filter]]}return null}perform(c,l){return json_rpc_provider_awaiter(this,void 0,void 0,function*(){if("call"===c||"estimateGas"===c){let c=l.transaction;if(c&&null!=c.type&&ef.O$.from(c.type).isZero()&&null==c.maxFeePerGas&&null==c.maxPriorityFeePerGas){let et=yield this.getFeeData();null==et.maxFeePerGas&&null==et.maxPriorityFeePerGas&&((l=(0,eb.DC)(l)).transaction=(0,eb.DC)(c),delete l.transaction.type)}}let et=this.prepareRequest(c,l);null==et&&tk.throwError(c+" not implemented",ey.Yd.errors.NOT_IMPLEMENTED,{operation:c});try{return yield this.send(et[0],et[1])}catch(et){return checkError(c,et,l)}})}_startEvent(c){"pending"===c.tag&&this._startPending(),super._startEvent(c)}_startPending(){if(null!=this._pendingFilter)return;let c=this,l=this.send("eth_newPendingTransactionFilter",[]);this._pendingFilter=l,l.then(function(et){return function poll(){c.send("eth_getFilterChanges",[et]).then(function(et){if(c._pendingFilter!=l)return null;let eo=Promise.resolve();return et.forEach(function(l){c._emitted["t:"+l.toLowerCase()]="pending",eo=eo.then(function(){return c.getTransaction(l).then(function(l){return c.emit("pending",l),null})})}),eo.then(function(){return timer(1e3)})}).then(function(){if(c._pendingFilter!=l){c.send("eth_uninstallFilter",[et]);return}return setTimeout(function(){poll()},0),null}).catch(c=>{})}(),et}).catch(c=>{})}_stopEvent(c){"pending"===c.tag&&0===this.listenerCount("pending")&&(this._pendingFilter=null),super._stopEvent(c)}static hexlifyTransaction(c,l){let et=(0,eb.DC)(tI);if(l)for(let c in l)l[c]&&(et[c]=!0);(0,eb.uj)(c,et);let eo={};return["chainId","gasLimit","gasPrice","type","maxFeePerGas","maxPriorityFeePerGas","nonce","value"].forEach(function(l){if(null==c[l])return;let et=(0,ep.$P)(ef.O$.from(c[l]));"gasLimit"===l&&(l="gas"),eo[l]=et}),["from","to","data"].forEach(function(l){null!=c[l]&&(eo[l]=(0,ep.Dv)(c[l]))}),c.accessList&&(eo.accessList=accessListify(c.accessList)),eo}}},61127:function(c,l,et){"use strict";et.d(l,{c:function(){return StaticJsonRpcProvider}});var eo=et(17213),es=et(36288),ec=et(12312),el=et(32074);let ed=new es.Yd(ec.i);let StaticJsonRpcProvider=class StaticJsonRpcProvider extends el.r{detectNetwork(){var c,l,et,ec;let el=Object.create(null,{detectNetwork:{get:()=>super.detectNetwork}});return c=this,l=void 0,et=void 0,ec=function*(){let c=this.network;return null==c&&((c=yield el.detectNetwork.call(this))||ed.throwError("no network detected",es.Yd.errors.UNKNOWN_ERROR,{}),null==this._network&&((0,eo.zG)(this,"_network",c),this.emit("network",c,null))),c},new(et||(et=Promise))(function(eo,es){function fulfilled(c){try{step(ec.next(c))}catch(c){es(c)}}function rejected(c){try{step(ec.throw(c))}catch(c){es(c)}}function step(c){var l;c.done?eo(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((ec=ec.apply(c,l||[])).next())})}}},56955:function(c,l,et){"use strict";et.d(l,{Q:function(){return Web3Provider}});var eo=et(17213),es=et(36288),ec=et(12312),el=et(32074);let ed=new es.Yd(ec.i),eh=1;function buildWeb3LegacyFetcher(c,l){let et="Web3LegacyFetcher";return function(c,es){let ec={method:c,params:es,id:eh++,jsonrpc:"2.0"};return new Promise((c,es)=>{this.emit("debug",{action:"request",fetcher:et,request:(0,eo.p$)(ec),provider:this}),l(ec,(l,eo)=>{if(l)return this.emit("debug",{action:"response",fetcher:et,error:l,request:ec,provider:this}),es(l);if(this.emit("debug",{action:"response",fetcher:et,request:ec,response:eo,provider:this}),eo.error){let c=Error(eo.error.message);return c.code=eo.error.code,c.data=eo.error.data,es(c)}c(eo.result)})})}}let Web3Provider=class Web3Provider extends el.r{constructor(c,l){null==c&&ed.throwArgumentError("missing provider","provider",c);let et=null,es=null,ec=null;"function"==typeof c?(et="unknown:",es=c):(((et=c.host||c.path||"")||!c.isMetaMask||(et="metamask"),ec=c,c.request)?(""===et&&(et="eip-1193:"),es=function(l,et){null==et&&(et=[]);let es={method:l,params:et};return this.emit("debug",{action:"request",fetcher:"Eip1193Fetcher",request:(0,eo.p$)(es),provider:this}),c.request(es).then(c=>(this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:es,response:c,provider:this}),c),c=>{throw this.emit("debug",{action:"response",fetcher:"Eip1193Fetcher",request:es,error:c,provider:this}),c})}):c.sendAsync?es=buildWeb3LegacyFetcher(c,c.sendAsync.bind(c)):c.send?es=buildWeb3LegacyFetcher(c,c.send.bind(c)):ed.throwArgumentError("unsupported provider","provider",c),et||(et="unknown:")),super(et,l),(0,eo.zG)(this,"jsonRpcFetchFunc",es),(0,eo.zG)(this,"provider",ec)}send(c,l){return this.jsonRpcFetchFunc(c,l)}}},7054:function(c,l,et){"use strict";et.d(l,{J:function(){return decode},c:function(){return encode}});var eo=et(57273),es=et(36288);let ec=new es.Yd("rlp/5.7.0");function arrayifyInteger(c){let l=[];for(;c;)l.unshift(255&c),c>>=8;return l}function unarrayifyInteger(c,l,et){let eo=0;for(let es=0;esl+1+eo&&ec.throwError("child data too short",es.Yd.errors.BUFFER_OVERRUN,{})}return{consumed:1+eo,result:el}}function _decode(c,l){if(0===c.length&&ec.throwError("data too short",es.Yd.errors.BUFFER_OVERRUN,{}),c[l]>=248){let et=c[l]-247;l+1+et>c.length&&ec.throwError("data short segment too short",es.Yd.errors.BUFFER_OVERRUN,{});let eo=unarrayifyInteger(c,l+1,et);return l+1+et+eo>c.length&&ec.throwError("data long segment too short",es.Yd.errors.BUFFER_OVERRUN,{}),_decodeChildren(c,l,l+1+et,et+eo)}if(c[l]>=192){let et=c[l]-192;return l+1+et>c.length&&ec.throwError("data array too short",es.Yd.errors.BUFFER_OVERRUN,{}),_decodeChildren(c,l,l+1,et)}if(c[l]>=184){let et=c[l]-183;l+1+et>c.length&&ec.throwError("data array too short",es.Yd.errors.BUFFER_OVERRUN,{});let el=unarrayifyInteger(c,l+1,et);l+1+et+el>c.length&&ec.throwError("data array too short",es.Yd.errors.BUFFER_OVERRUN,{});let ed=(0,eo.Dv)(c.slice(l+1+et,l+1+et+el));return{consumed:1+et+el,result:ed}}if(c[l]>=128){let et=c[l]-128;l+1+et>c.length&&ec.throwError("data too short",es.Yd.errors.BUFFER_OVERRUN,{});let el=(0,eo.Dv)(c.slice(l+1,l+1+et));return{consumed:1+et,result:el}}return{consumed:1,result:(0,eo.Dv)(c[l])}}function decode(c){let l=(0,eo.lE)(c),et=_decode(l,0);return et.consumed!==l.length&&ec.throwArgumentError("invalid rlp data","data",c),et.result}},58337:function(c,l,et){"use strict";et.d(l,{Y0:function(){return toUtf8Bytes},XL:function(){return toUtf8CodePoints},ZN:function(){return toUtf8String}});var eo,es,ec,el,ed=et(57273),eh=et(36288);let ef=new eh.Yd("strings/5.7.0");function ignoreFunc(c,l,et,eo,es){if(c===el.BAD_PREFIX||c===el.UNEXPECTED_CONTINUE){let c=0;for(let eo=l+1;eo>6==2;eo++)c++;return c}return c===el.OVERRUN?et.length-l-1:0}(eo=ec||(ec={})).current="",eo.NFC="NFC",eo.NFD="NFD",eo.NFKC="NFKC",eo.NFKD="NFKD",(es=el||(el={})).UNEXPECTED_CONTINUE="unexpected continuation byte",es.BAD_PREFIX="bad codepoint prefix",es.OVERRUN="string overrun",es.MISSING_CONTINUE="missing continuation byte",es.OUT_OF_RANGE="out of UTF-8 range",es.UTF16_SURROGATE="UTF-16 surrogate",es.OVERLONG="overlong representation";let ep=Object.freeze({error:function(c,l,et,eo,es){return ef.throwArgumentError(`invalid codepoint at offset ${l}; ${c}`,"bytes",et)},ignore:ignoreFunc,replace:function(c,l,et,eo,es){return c===el.OVERLONG?(eo.push(es),0):(eo.push(65533),ignoreFunc(c,l,et,eo,es))}});function getUtf8CodePoints(c,l){null==l&&(l=ep.error),c=(0,ed.lE)(c);let et=[],eo=0;for(;eo>7==0){et.push(es);continue}let ec=null,ed=null;if((224&es)==192)ec=1,ed=127;else if((240&es)==224)ec=2,ed=2047;else if((248&es)==240)ec=3,ed=65535;else{(192&es)==128?eo+=l(el.UNEXPECTED_CONTINUE,eo-1,c,et):eo+=l(el.BAD_PREFIX,eo-1,c,et);continue}if(eo-1+ec>=c.length){eo+=l(el.OVERRUN,eo-1,c,et);continue}let eh=es&(1<<8-ec-1)-1;for(let es=0;es1114111){eo+=l(el.OUT_OF_RANGE,eo-1-ec,c,et,eh);continue}if(eh>=55296&&eh<=57343){eo+=l(el.UTF16_SURROGATE,eo-1-ec,c,et,eh);continue}if(eh<=ed){eo+=l(el.OVERLONG,eo-1-ec,c,et,eh);continue}et.push(eh)}}return et}function toUtf8Bytes(c,l=ec.current){l!=ec.current&&(ef.checkNormalize(),c=c.normalize(l));let et=[];for(let l=0;l>6|192),et.push(63&eo|128);else if((64512&eo)==55296){l++;let es=c.charCodeAt(l);if(l>=c.length||(64512&es)!=56320)throw Error("invalid utf-8 string");let ec=65536+((1023&eo)<<10)+(1023&es);et.push(ec>>18|240),et.push(ec>>12&63|128),et.push(ec>>6&63|128),et.push(63&ec|128)}else et.push(eo>>12|224),et.push(eo>>6&63|128),et.push(63&eo|128)}return(0,ed.lE)(et)}function toUtf8String(c,l){return getUtf8CodePoints(c,l).map(c=>c<=65535?String.fromCharCode(c):String.fromCharCode(((c-=65536)>>10&1023)+55296,(1023&c)+56320)).join("")}function toUtf8CodePoints(c,l=ec.current){return getUtf8CodePoints(toUtf8Bytes(c,l))}},76303:function(c,l,et){"use strict";et.d(l,{dF:function(){return formatEther},vz:function(){return parseUnits}});var eo=et(57273),es=et(36288),ec=et(68334),el=et(92598);let ed=new es.Yd(ec.i),eh={},ef=el.O$.from(0),ep=el.O$.from(-1);function throwFault(c,l,et,eo){let ec={fault:l,operation:et};return void 0!==eo&&(ec.value=eo),ed.throwError(c,es.Yd.errors.NUMERIC_FAULT,ec)}let eg="0";for(;eg.length<256;)eg+=eg;function getMultiplier(c){if("number"!=typeof c)try{c=el.O$.from(c).toNumber()}catch(c){}return"number"==typeof c&&c>=0&&c<=256&&!(c%1)?"1"+eg.substring(0,c):ed.throwArgumentError("invalid decimal size","decimals",c)}function formatFixed(c,l){null==l&&(l=0);let et=getMultiplier(l);c=el.O$.from(c);let eo=c.lt(ef);eo&&(c=c.mul(ep));let es=c.mod(et).toString();for(;es.length2&&ed.throwArgumentError("too many decimal points","value",c);let ec=es[0],eh=es[1];for(ec||(ec="0"),eh||(eh="0");"0"===eh[eh.length-1];)eh=eh.substring(0,eh.length-1);for(eh.length>et.length-1&&throwFault("fractional component exceeds decimals","underflow","parseFixed"),""===eh&&(eh="0");eh.lengthnull==c[l]?eo:(typeof c[l]!==et&&ed.throwArgumentError("invalid fixed format ("+l+" not "+et+")","format."+l,c[l]),c[l]);l=check("signed","boolean",l),et=check("width","number",et),eo=check("decimals","number",eo)}return et%8&&ed.throwArgumentError("invalid fixed format width (not byte aligned)","format.width",et),eo>80&&ed.throwArgumentError("invalid fixed format (decimals too large)","format.decimals",eo),new FixedFormat(eh,l,et,eo)}};let FixedNumber=class FixedNumber{constructor(c,l,et,eo){c!==eh&&ed.throwError("cannot use FixedNumber constructor; use FixedNumber.from",es.Yd.errors.UNSUPPORTED_OPERATION,{operation:"new FixedFormat"}),this.format=eo,this._hex=l,this._value=et,this._isFixedNumber=!0,Object.freeze(this)}_checkFormat(c){this.format.name!==c.format.name&&ed.throwArgumentError("incompatible format; use fixedNumber.toFormat","other",c)}addUnsafe(c){this._checkFormat(c);let l=parseFixed(this._value,this.format.decimals),et=parseFixed(c._value,c.format.decimals);return FixedNumber.fromValue(l.add(et),this.format.decimals,this.format)}subUnsafe(c){this._checkFormat(c);let l=parseFixed(this._value,this.format.decimals),et=parseFixed(c._value,c.format.decimals);return FixedNumber.fromValue(l.sub(et),this.format.decimals,this.format)}mulUnsafe(c){this._checkFormat(c);let l=parseFixed(this._value,this.format.decimals),et=parseFixed(c._value,c.format.decimals);return FixedNumber.fromValue(l.mul(et).div(this.format._multiplier),this.format.decimals,this.format)}divUnsafe(c){this._checkFormat(c);let l=parseFixed(this._value,this.format.decimals),et=parseFixed(c._value,c.format.decimals);return FixedNumber.fromValue(l.mul(this.format._multiplier).div(et),this.format.decimals,this.format)}floor(){let c=this.toString().split(".");1===c.length&&c.push("0");let l=FixedNumber.from(c[0],this.format),et=!c[1].match(/^(0*)$/);return this.isNegative()&&et&&(l=l.subUnsafe(em.toFormat(l.format))),l}ceiling(){let c=this.toString().split(".");1===c.length&&c.push("0");let l=FixedNumber.from(c[0],this.format),et=!c[1].match(/^(0*)$/);return!this.isNegative()&&et&&(l=l.addUnsafe(em.toFormat(l.format))),l}round(c){null==c&&(c=0);let l=this.toString().split(".");if(1===l.length&&l.push("0"),(c<0||c>80||c%1)&&ed.throwArgumentError("invalid decimal count","decimals",c),l[1].length<=c)return this;let et=FixedNumber.from("1"+eg.substring(0,c),this.format),eo=eb.toFormat(this.format);return this.mulUnsafe(et).addUnsafe(eo).floor().divUnsafe(et)}isZero(){return"0.0"===this._value||"0"===this._value}isNegative(){return"-"===this._value[0]}toString(){return this._value}toHexString(c){if(null==c)return this._hex;c%8&&ed.throwArgumentError("invalid byte width","width",c);let l=el.O$.from(this._hex).fromTwos(this.format.width).toTwos(c).toHexString();return(0,eo.$m)(l,c/8)}toUnsafeFloat(){return parseFloat(this.toString())}toFormat(c){return FixedNumber.fromString(this._value,c)}static fromValue(c,l,et){return null!=et||null==l||(0,el.Zm)(l)||(et=l,l=null),null==l&&(l=0),null==et&&(et="fixed"),FixedNumber.fromString(formatFixed(c,l),FixedFormat.from(et))}static fromString(c,l){null==l&&(l="fixed");let et=FixedFormat.from(l),es=parseFixed(c,et.decimals);!et.signed&&es.lt(ef)&&throwFault("unsigned value cannot be negative","overflow","value",c);let ec=null;et.signed?ec=es.toTwos(et.width).toHexString():(ec=es.toHexString(),ec=(0,eo.$m)(ec,et.width/8));let el=formatFixed(es,et.decimals);return new FixedNumber(eh,ec,el,et)}static fromBytes(c,l){null==l&&(l="fixed");let et=FixedFormat.from(l);if((0,eo.lE)(c).length>et.width/8)throw Error("overflow");let es=el.O$.from(c);et.signed&&(es=es.fromTwos(et.width));let ec=es.toTwos((et.signed?0:1)+et.width).toHexString(),ed=formatFixed(es,et.decimals);return new FixedNumber(eh,ec,ed,et)}static from(c,l){if("string"==typeof c)return FixedNumber.fromString(c,l);if((0,eo._t)(c))return FixedNumber.fromBytes(c,l);try{return FixedNumber.fromValue(c,0,l)}catch(c){if(c.code!==es.Yd.errors.INVALID_ARGUMENT)throw c}return ed.throwArgumentError("invalid FixedNumber value","value",c)}static isFixedNumber(c){return!!(c&&c._isFixedNumber)}};let em=FixedNumber.from(1),eb=FixedNumber.from("0.5"),ey=new es.Yd("units/5.7.0"),e_=["wei","kwei","mwei","gwei","szabo","finney","ether"];function parseUnits(c,l){if("string"!=typeof c&&ey.throwArgumentError("value must be a string","value",c),"string"==typeof l){let c=e_.indexOf(l);-1!==c&&(l=3*c)}return parseFixed(c,null!=l?l:18)}function formatEther(c){return function(c,l){if("string"==typeof l){let c=e_.indexOf(l);-1!==c&&(l=3*c)}return formatFixed(c,null!=l?l:18)}(c,18)}},12941:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(512);function safeApply(c,l,et){try{Reflect.apply(c,l,et)}catch(c){setTimeout(()=>{throw c})}}let SafeEventEmitter=class SafeEventEmitter extends eo.EventEmitter{emit(c,...l){let et="error"===c,eo=this._events;if(void 0!==eo)et=et&&void 0===eo.error;else if(!et)return!1;if(et){let c;if(l.length>0&&([c]=l),c instanceof Error)throw c;let et=Error(`Unhandled error.${c?` (${c.message})`:""}`);throw et.context=c,et}let es=eo[c];if(void 0===es)return!1;if("function"==typeof es)safeApply(es,this,l);else{let c=es.length,et=function(c){let l=c.length,et=Array(l);for(let eo=0;eo{var et,ec;let el,ed;let eh=null!==(et=l.paddingRequired)&&void 0!==et&&et,ef=null!==(ec=l.characterSet)&&void 0!==ec?ec:"base64";return"base64"===ef?el=String.raw`[A-Za-z0-9+\/]`:((0,es.assert)("base64url"===ef),el=String.raw`[-_A-Za-z0-9]`),ed=eh?RegExp(`^(?:${el}{4})*(?:${el}{3}=|${el}{2}==)?$`,"u"):RegExp(`^(?:${el}{4})*(?:${el}{2,3}|${el}{3}=|${el}{2}==)?$`,"u"),(0,eo.pattern)(c,ed)}},83747:function(c,l,et){"use strict";var eo=et(67133).Buffer;Object.defineProperty(l,"__esModule",{value:!0}),l.createDataView=l.concatBytes=l.valueToBytes=l.stringToBytes=l.numberToBytes=l.signedBigIntToBytes=l.bigIntToBytes=l.hexToBytes=l.bytesToString=l.bytesToNumber=l.bytesToSignedBigInt=l.bytesToBigInt=l.bytesToHex=l.assertIsBytes=l.isBytes=void 0;let es=et(93514),ec=et(15377),el=function(){let c=[];return()=>{if(0===c.length)for(let l=0;l<256;l++)c.push(l.toString(16).padStart(2,"0"));return c}}();function isBytes(c){return c instanceof Uint8Array}function assertIsBytes(c){(0,es.assert)(isBytes(c),"Value must be a Uint8Array.")}function bytesToHex(c){if(assertIsBytes(c),0===c.length)return"0x";let l=el(),et=Array(c.length);for(let eo=0;eo=BigInt(0),"Value must be a non-negative bigint.");let l=c.toString(16);return hexToBytes(l)}function numberToBytes(c){(0,es.assert)("number"==typeof c,"Value must be a number."),(0,es.assert)(c>=0,"Value must be a non-negative number."),(0,es.assert)(Number.isSafeInteger(c),"Value is not a safe integer. Use `bigIntToBytes` instead.");let l=c.toString(16);return hexToBytes(l)}function stringToBytes(c){return(0,es.assert)("string"==typeof c,"Value must be a string."),new TextEncoder().encode(c)}function valueToBytes(c){if("bigint"==typeof c)return bigIntToBytes(c);if("number"==typeof c)return numberToBytes(c);if("string"==typeof c)return c.startsWith("0x")?hexToBytes(c):stringToBytes(c);if(isBytes(c))return c;throw TypeError(`Unsupported value type: "${typeof c}".`)}l.isBytes=isBytes,l.assertIsBytes=assertIsBytes,l.bytesToHex=bytesToHex,l.bytesToBigInt=bytesToBigInt,l.bytesToSignedBigInt=function(c){assertIsBytes(c);let l=BigInt(0);for(let et of c)l=(l<0,"Byte length must be greater than 0."),(0,es.assert)(function(c,l){(0,es.assert)(l>0);let et=c>>BigInt(31);return!((~c&et)+(c&~et)>>BigInt(8*l+-1))}(c,l),"Byte length is too small to represent the given value.");let et=c,eo=new Uint8Array(l);for(let c=0;c>=BigInt(8);return eo.reverse()},l.numberToBytes=numberToBytes,l.stringToBytes=stringToBytes,l.valueToBytes=valueToBytes,l.concatBytes=function(c){let l=Array(c.length),et=0;for(let eo=0;eoc.call(l,et,eo,this))}get(c){return ec(this,et,"f").get(c)}has(c){return ec(this,et,"f").has(c)}keys(){return ec(this,et,"f").keys()}values(){return ec(this,et,"f").values()}toString(){return`FrozenMap(${this.size}) {${this.size>0?` ${[...this.entries()].map(([c,l])=>`${String(c)} => ${String(l)}`).join(", ")} `:""}}`}};l.FrozenMap=FrozenMap;let FrozenSet=class FrozenSet{constructor(c){eo.set(this,void 0),es(this,eo,new Set(c),"f"),Object.freeze(this)}get size(){return ec(this,eo,"f").size}[(eo=new WeakMap,Symbol.iterator)](){return ec(this,eo,"f")[Symbol.iterator]()}entries(){return ec(this,eo,"f").entries()}forEach(c,l){return ec(this,eo,"f").forEach((et,eo,es)=>c.call(l,et,eo,this))}has(c){return ec(this,eo,"f").has(c)}keys(){return ec(this,eo,"f").keys()}values(){return ec(this,eo,"f").values()}toString(){return`FrozenSet(${this.size}) {${this.size>0?` ${[...this.values()].map(c=>String(c)).join(", ")} `:""}}`}};l.FrozenSet=FrozenSet,Object.freeze(FrozenMap),Object.freeze(FrozenMap.prototype),Object.freeze(FrozenSet),Object.freeze(FrozenSet.prototype)},15377:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.remove0x=l.add0x=l.assertIsStrictHexString=l.assertIsHexString=l.isStrictHexString=l.isHexString=l.StrictHexStruct=l.HexStruct=void 0;let eo=et(13142),es=et(93514);function isHexString(c){return(0,eo.is)(c,l.HexStruct)}function isStrictHexString(c){return(0,eo.is)(c,l.StrictHexStruct)}l.HexStruct=(0,eo.pattern)((0,eo.string)(),/^(?:0x)?[0-9a-f]+$/iu),l.StrictHexStruct=(0,eo.pattern)((0,eo.string)(),/^0x[0-9a-f]+$/iu),l.isHexString=isHexString,l.isStrictHexString=isStrictHexString,l.assertIsHexString=function(c){(0,es.assert)(isHexString(c),"Value must be a hexadecimal string.")},l.assertIsStrictHexString=function(c){(0,es.assert)(isStrictHexString(c),'Value must be a hexadecimal string, starting with "0x".')},l.add0x=function(c){return c.startsWith("0x")?c:c.startsWith("0X")?`0x${c.substring(2)}`:`0x${c}`},l.remove0x=function(c){return c.startsWith("0x")||c.startsWith("0X")?c.substring(2):c}},30377:function(c,l,et){"use strict";var eo=this&&this.__createBinding||(Object.create?function(c,l,et,eo){void 0===eo&&(eo=et);var es=Object.getOwnPropertyDescriptor(l,et);(!es||("get"in es?!l.__esModule:es.writable||es.configurable))&&(es={enumerable:!0,get:function(){return l[et]}}),Object.defineProperty(c,eo,es)}:function(c,l,et,eo){void 0===eo&&(eo=et),c[eo]=l[et]}),es=this&&this.__exportStar||function(c,l){for(var et in c)"default"===et||Object.prototype.hasOwnProperty.call(l,et)||eo(l,c,et)};Object.defineProperty(l,"__esModule",{value:!0}),es(et(93514),l),es(et(90484),l),es(et(83747),l),es(et(88015),l),es(et(90183),l),es(et(62523),l),es(et(15377),l),es(et(62586),l),es(et(83551),l),es(et(16663),l),es(et(63058),l),es(et(91713),l),es(et(23687),l),es(et(78129),l)},62586:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.validateJsonAndGetSize=l.getJsonRpcIdValidator=l.assertIsJsonRpcError=l.isJsonRpcError=l.assertIsJsonRpcFailure=l.isJsonRpcFailure=l.assertIsJsonRpcSuccess=l.isJsonRpcSuccess=l.assertIsJsonRpcResponse=l.isJsonRpcResponse=l.assertIsPendingJsonRpcResponse=l.isPendingJsonRpcResponse=l.JsonRpcResponseStruct=l.JsonRpcFailureStruct=l.JsonRpcSuccessStruct=l.PendingJsonRpcResponseStruct=l.assertIsJsonRpcRequest=l.isJsonRpcRequest=l.assertIsJsonRpcNotification=l.isJsonRpcNotification=l.JsonRpcNotificationStruct=l.JsonRpcRequestStruct=l.JsonRpcParamsStruct=l.JsonRpcErrorStruct=l.JsonRpcIdStruct=l.JsonRpcVersionStruct=l.jsonrpc2=l.isValidJson=l.JsonStruct=void 0;let eo=et(13142),es=et(93514),ec=et(16663);function validateJsonAndGetSize(c,l=!1){let et=new Set;return function getJsonSerializableInfo(c,l){if(void 0===c)return[!1,0];if(null===c)return[!0,l?0:ec.JsonSize.Null];let eo=typeof c;try{if("function"===eo)return[!1,0];if("string"===eo||c instanceof String)return[!0,l?0:(0,ec.calculateStringSize)(c)+2*ec.JsonSize.Quote];if("boolean"===eo||c instanceof Boolean){if(l)return[!0,0];return[!0,!0==c?ec.JsonSize.True:ec.JsonSize.False]}if("number"===eo||c instanceof Number){if(l)return[!0,0];return[!0,(0,ec.calculateNumberSize)(c)]}else if(c instanceof Date){if(l)return[!0,0];return[!0,isNaN(c.getDate())?ec.JsonSize.Null:ec.JsonSize.Date+2*ec.JsonSize.Quote]}}catch(c){return[!1,0]}if(!(0,ec.isPlainObject)(c)&&!Array.isArray(c)||et.has(c))return[!1,0];et.add(c);try{return[!0,Object.entries(c).reduce((eo,[es,el],ed,eh)=>{let[ef,ep]=getJsonSerializableInfo(el,l);if(!ef)throw Error("JSON validation did not pass. Validation process stopped.");if(et.delete(c),l)return 0;let eg=Array.isArray(c)?0:es.length+ec.JsonSize.Comma+2*ec.JsonSize.Colon,em=ed{let[l]=validateJsonAndGetSize(c,!0);return!!l||"Expected a valid JSON-serializable value"}),l.isValidJson=function(c){return(0,eo.is)(c,l.JsonStruct)},l.jsonrpc2="2.0",l.JsonRpcVersionStruct=(0,eo.literal)(l.jsonrpc2),l.JsonRpcIdStruct=(0,eo.nullable)((0,eo.union)([(0,eo.number)(),(0,eo.string)()])),l.JsonRpcErrorStruct=(0,eo.object)({code:(0,eo.integer)(),message:(0,eo.string)(),data:(0,eo.optional)(l.JsonStruct),stack:(0,eo.optional)((0,eo.string)())}),l.JsonRpcParamsStruct=(0,eo.optional)((0,eo.union)([(0,eo.record)((0,eo.string)(),l.JsonStruct),(0,eo.array)(l.JsonStruct)])),l.JsonRpcRequestStruct=(0,eo.object)({id:l.JsonRpcIdStruct,jsonrpc:l.JsonRpcVersionStruct,method:(0,eo.string)(),params:l.JsonRpcParamsStruct}),l.JsonRpcNotificationStruct=(0,eo.omit)(l.JsonRpcRequestStruct,["id"]),l.isJsonRpcNotification=function(c){return(0,eo.is)(c,l.JsonRpcNotificationStruct)},l.assertIsJsonRpcNotification=function(c,et){(0,es.assertStruct)(c,l.JsonRpcNotificationStruct,"Invalid JSON-RPC notification",et)},l.isJsonRpcRequest=function(c){return(0,eo.is)(c,l.JsonRpcRequestStruct)},l.assertIsJsonRpcRequest=function(c,et){(0,es.assertStruct)(c,l.JsonRpcRequestStruct,"Invalid JSON-RPC request",et)},l.PendingJsonRpcResponseStruct=(0,eo.object)({id:l.JsonRpcIdStruct,jsonrpc:l.JsonRpcVersionStruct,result:(0,eo.optional)((0,eo.unknown)()),error:(0,eo.optional)(l.JsonRpcErrorStruct)}),l.JsonRpcSuccessStruct=(0,eo.object)({id:l.JsonRpcIdStruct,jsonrpc:l.JsonRpcVersionStruct,result:l.JsonStruct}),l.JsonRpcFailureStruct=(0,eo.object)({id:l.JsonRpcIdStruct,jsonrpc:l.JsonRpcVersionStruct,error:l.JsonRpcErrorStruct}),l.JsonRpcResponseStruct=(0,eo.union)([l.JsonRpcSuccessStruct,l.JsonRpcFailureStruct]),l.isPendingJsonRpcResponse=function(c){return(0,eo.is)(c,l.PendingJsonRpcResponseStruct)},l.assertIsPendingJsonRpcResponse=function(c,et){(0,es.assertStruct)(c,l.PendingJsonRpcResponseStruct,"Invalid pending JSON-RPC response",et)},l.isJsonRpcResponse=function(c){return(0,eo.is)(c,l.JsonRpcResponseStruct)},l.assertIsJsonRpcResponse=function(c,et){(0,es.assertStruct)(c,l.JsonRpcResponseStruct,"Invalid JSON-RPC response",et)},l.isJsonRpcSuccess=function(c){return(0,eo.is)(c,l.JsonRpcSuccessStruct)},l.assertIsJsonRpcSuccess=function(c,et){(0,es.assertStruct)(c,l.JsonRpcSuccessStruct,"Invalid JSON-RPC success response",et)},l.isJsonRpcFailure=function(c){return(0,eo.is)(c,l.JsonRpcFailureStruct)},l.assertIsJsonRpcFailure=function(c,et){(0,es.assertStruct)(c,l.JsonRpcFailureStruct,"Invalid JSON-RPC failure response",et)},l.isJsonRpcError=function(c){return(0,eo.is)(c,l.JsonRpcErrorStruct)},l.assertIsJsonRpcError=function(c,et){(0,es.assertStruct)(c,l.JsonRpcErrorStruct,"Invalid JSON-RPC error",et)},l.getJsonRpcIdValidator=function(c){let{permitEmptyString:l,permitFractions:et,permitNull:eo}=Object.assign({permitEmptyString:!0,permitFractions:!1,permitNull:!0},c);return c=>!!("number"==typeof c&&(et||Number.isInteger(c))||"string"==typeof c&&(l||c.length>0)||eo&&null===c)},l.validateJsonAndGetSize=validateJsonAndGetSize},83551:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.createModuleLogger=l.createProjectLogger=void 0;let es=eo(et(4461)),ec=(0,es.default)("metamask");l.createProjectLogger=function(c){return ec.extend(c)},l.createModuleLogger=function(c,l){return c.extend(l)}},16663:function(c,l){"use strict";var et;function isASCII(c){return 127>=c.charCodeAt(0)}Object.defineProperty(l,"__esModule",{value:!0}),l.calculateNumberSize=l.calculateStringSize=l.isASCII=l.isPlainObject=l.ESCAPE_CHARACTERS_REGEXP=l.JsonSize=l.hasProperty=l.isObject=l.isNullOrUndefined=l.isNonEmptyArray=void 0,l.isNonEmptyArray=function(c){return Array.isArray(c)&&c.length>0},l.isNullOrUndefined=function(c){return null==c},l.isObject=function(c){return!!c&&"object"==typeof c&&!Array.isArray(c)},l.hasProperty=(c,l)=>Object.hasOwnProperty.call(c,l),(et=l.JsonSize||(l.JsonSize={}))[et.Null=4]="Null",et[et.Comma=1]="Comma",et[et.Wrapper=1]="Wrapper",et[et.True=4]="True",et[et.False=5]="False",et[et.Quote=1]="Quote",et[et.Colon=1]="Colon",et[et.Date=24]="Date",l.ESCAPE_CHARACTERS_REGEXP=/"|\\|\n|\r|\t/gu,l.isPlainObject=function(c){if("object"!=typeof c||null===c)return!1;try{let l=c;for(;null!==Object.getPrototypeOf(l);)l=Object.getPrototypeOf(l);return Object.getPrototypeOf(c)===l}catch(c){return!1}},l.isASCII=isASCII,l.calculateStringSize=function(c){var et;let eo=c.split("").reduce((c,l)=>isASCII(l)?c+1:c+2,0);return eo+(null!==(et=c.match(l.ESCAPE_CHARACTERS_REGEXP))&&void 0!==et?et:[]).length},l.calculateNumberSize=function(c){return c.toString().length}},63058:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.hexToBigInt=l.hexToNumber=l.bigIntToHex=l.numberToHex=void 0;let eo=et(93514),es=et(15377);l.numberToHex=c=>((0,eo.assert)("number"==typeof c,"Value must be a number."),(0,eo.assert)(c>=0,"Value must be a non-negative number."),(0,eo.assert)(Number.isSafeInteger(c),"Value is not a safe integer. Use `bigIntToHex` instead."),(0,es.add0x)(c.toString(16))),l.bigIntToHex=c=>((0,eo.assert)("bigint"==typeof c,"Value must be a bigint."),(0,eo.assert)(c>=0,"Value must be a non-negative bigint."),(0,es.add0x)(c.toString(16))),l.hexToNumber=c=>{(0,es.assertIsHexString)(c);let l=parseInt(c,16);return(0,eo.assert)(Number.isSafeInteger(l),"Value is not a safe integer. Use `hexToBigInt` instead."),l},l.hexToBigInt=c=>((0,es.assertIsHexString)(c),BigInt((0,es.add0x)(c)))},91713:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0})},23687:function(c,l){"use strict";var et;Object.defineProperty(l,"__esModule",{value:!0}),l.timeSince=l.inMilliseconds=l.Duration=void 0,(et=l.Duration||(l.Duration={}))[et.Millisecond=1]="Millisecond",et[et.Second=1e3]="Second",et[et.Minute=6e4]="Minute",et[et.Hour=36e5]="Hour",et[et.Day=864e5]="Day",et[et.Week=6048e5]="Week",et[et.Year=31536e6]="Year";let isNonNegativeInteger=c=>Number.isInteger(c)&&c>=0,assertIsNonNegativeInteger=(c,l)=>{if(!isNonNegativeInteger(c))throw Error(`"${l}" must be a non-negative integer. Received: "${c}".`)};l.inMilliseconds=function(c,l){return assertIsNonNegativeInteger(c,"count"),c*l},l.timeSince=function(c){return assertIsNonNegativeInteger(c,"timestamp"),Date.now()-c}},78129:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.satisfiesVersionRange=l.gtRange=l.gtVersion=l.assertIsSemVerRange=l.assertIsSemVerVersion=l.isValidSemVerRange=l.isValidSemVerVersion=l.VersionRangeStruct=l.VersionStruct=void 0;let eo=et(97258),es=et(13142),ec=et(93514);l.VersionStruct=(0,es.refine)((0,es.string)(),"Version",c=>null!==(0,eo.valid)(c)||`Expected SemVer version, got "${c}"`),l.VersionRangeStruct=(0,es.refine)((0,es.string)(),"Version range",c=>null!==(0,eo.validRange)(c)||`Expected SemVer range, got "${c}"`),l.isValidSemVerVersion=function(c){return(0,es.is)(c,l.VersionStruct)},l.isValidSemVerRange=function(c){return(0,es.is)(c,l.VersionRangeStruct)},l.assertIsSemVerVersion=function(c){(0,ec.assertStruct)(c,l.VersionStruct)},l.assertIsSemVerRange=function(c){(0,ec.assertStruct)(c,l.VersionRangeStruct)},l.gtVersion=function(c,l){return(0,eo.gt)(c,l)},l.gtRange=function(c,l){return(0,eo.gtr)(c,l)},l.satisfiesVersionRange=function(c,l){return(0,eo.satisfies)(c,l,{includePrerelease:!0})}},99655:function(c,l,et){let eo=Symbol("SemVer ANY");let Comparator=class Comparator{static get ANY(){return eo}constructor(c,l){if(l=es(l),c instanceof Comparator){if(!!l.loose===c.loose)return c;c=c.value}eh("comparator",c=c.trim().split(/\s+/).join(" "),l),this.options=l,this.loose=!!l.loose,this.parse(c),this.semver===eo?this.value="":this.value=this.operator+this.semver.version,eh("comp",this)}parse(c){let l=this.options.loose?ec[el.COMPARATORLOOSE]:ec[el.COMPARATOR],et=c.match(l);if(!et)throw TypeError(`Invalid comparator: ${c}`);this.operator=void 0!==et[1]?et[1]:"","="===this.operator&&(this.operator=""),et[2]?this.semver=new ef(et[2],this.options.loose):this.semver=eo}toString(){return this.value}test(c){if(eh("Comparator.test",c,this.options.loose),this.semver===eo||c===eo)return!0;if("string"==typeof c)try{c=new ef(c,this.options)}catch(c){return!1}return ed(c,this.operator,this.semver,this.options)}intersects(c,l){if(!(c instanceof Comparator))throw TypeError("a Comparator is required");return""===this.operator?""===this.value||new ep(c.value,l).test(this.value):""===c.operator?""===c.value||new ep(this.value,l).test(c.semver):!((l=es(l)).includePrerelease&&("<0.0.0-0"===this.value||"<0.0.0-0"===c.value)||!l.includePrerelease&&(this.value.startsWith("<0.0.0")||c.value.startsWith("<0.0.0")))&&!!(this.operator.startsWith(">")&&c.operator.startsWith(">")||this.operator.startsWith("<")&&c.operator.startsWith("<")||this.semver.version===c.semver.version&&this.operator.includes("=")&&c.operator.includes("=")||ed(this.semver,"<",c.semver,l)&&this.operator.startsWith(">")&&c.operator.startsWith("<")||ed(this.semver,">",c.semver,l)&&this.operator.startsWith("<")&&c.operator.startsWith(">"))}};c.exports=Comparator;let es=et(7207),{safeRe:ec,t:el}=et(29516),ed=et(94221),eh=et(3900),ef=et(50035),ep=et(86791)},86791:function(c,l,et){let Range=class Range{constructor(c,l){if(l=ec(l),c instanceof Range){if(!!l.loose===c.loose&&!!l.includePrerelease===c.includePrerelease)return c;return new Range(c.raw,l)}if(c instanceof el)return this.raw=c.value,this.set=[[c]],this.format(),this;if(this.options=l,this.loose=!!l.loose,this.includePrerelease=!!l.includePrerelease,this.raw=c.trim().split(/\s+/).join(" "),this.set=this.raw.split("||").map(c=>this.parseRange(c.trim())).filter(c=>c.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let c=this.set[0];if(this.set=this.set.filter(c=>!isNullSet(c[0])),0===this.set.length)this.set=[c];else if(this.set.length>1){for(let c of this.set)if(1===c.length&&isAny(c[0])){this.set=[c];break}}}this.format()}format(){return this.range=this.set.map(c=>c.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(c){let l=(this.options.includePrerelease&&ey)|(this.options.loose&&e_),et=l+":"+c,eo=es.get(et);if(eo)return eo;let ec=this.options.loose,eh=ec?ef[ep.HYPHENRANGELOOSE]:ef[ep.HYPHENRANGE];ed("hyphen replace",c=c.replace(eh,hyphenReplace(this.options.includePrerelease))),ed("comparator trim",c=c.replace(ef[ep.COMPARATORTRIM],eg)),ed("tilde trim",c=c.replace(ef[ep.TILDETRIM],em)),ed("caret trim",c=c.replace(ef[ep.CARETTRIM],eb));let ew=c.split(" ").map(c=>parseComparator(c,this.options)).join(" ").split(/\s+/).map(c=>replaceGTE0(c,this.options));ec&&(ew=ew.filter(c=>(ed("loose invalid filter",c,this.options),!!c.match(ef[ep.COMPARATORLOOSE])))),ed("range list",ew);let eE=new Map,eS=ew.map(c=>new el(c,this.options));for(let c of eS){if(isNullSet(c))return[c];eE.set(c.value,c)}eE.size>1&&eE.has("")&&eE.delete("");let ex=[...eE.values()];return es.set(et,ex),ex}intersects(c,l){if(!(c instanceof Range))throw TypeError("a Range is required");return this.set.some(et=>isSatisfiable(et,l)&&c.set.some(c=>isSatisfiable(c,l)&&et.every(et=>c.every(c=>et.intersects(c,l)))))}test(c){if(!c)return!1;if("string"==typeof c)try{c=new eh(c,this.options)}catch(c){return!1}for(let l=0;l"<0.0.0-0"===c.value,isAny=c=>""===c.value,isSatisfiable=(c,l)=>{let et=!0,eo=c.slice(),es=eo.pop();for(;et&&eo.length;)et=eo.every(c=>es.intersects(c,l)),es=eo.pop();return et},parseComparator=(c,l)=>(ed("comp",c,l),ed("caret",c=replaceCarets(c,l)),ed("tildes",c=replaceTildes(c,l)),ed("xrange",c=replaceXRanges(c,l)),ed("stars",c=replaceStars(c,l)),c),isX=c=>!c||"x"===c.toLowerCase()||"*"===c,replaceTildes=(c,l)=>c.trim().split(/\s+/).map(c=>replaceTilde(c,l)).join(" "),replaceTilde=(c,l)=>{let et=l.loose?ef[ep.TILDELOOSE]:ef[ep.TILDE];return c.replace(et,(l,et,eo,es,ec)=>{let el;return ed("tilde",c,l,et,eo,es,ec),isX(et)?el="":isX(eo)?el=`>=${et}.0.0 <${+et+1}.0.0-0`:isX(es)?el=`>=${et}.${eo}.0 <${et}.${+eo+1}.0-0`:ec?(ed("replaceTilde pr",ec),el=`>=${et}.${eo}.${es}-${ec} <${et}.${+eo+1}.0-0`):el=`>=${et}.${eo}.${es} <${et}.${+eo+1}.0-0`,ed("tilde return",el),el})},replaceCarets=(c,l)=>c.trim().split(/\s+/).map(c=>replaceCaret(c,l)).join(" "),replaceCaret=(c,l)=>{ed("caret",c,l);let et=l.loose?ef[ep.CARETLOOSE]:ef[ep.CARET],eo=l.includePrerelease?"-0":"";return c.replace(et,(l,et,es,ec,el)=>{let eh;return ed("caret",c,l,et,es,ec,el),isX(et)?eh="":isX(es)?eh=`>=${et}.0.0${eo} <${+et+1}.0.0-0`:isX(ec)?eh="0"===et?`>=${et}.${es}.0${eo} <${et}.${+es+1}.0-0`:`>=${et}.${es}.0${eo} <${+et+1}.0.0-0`:el?(ed("replaceCaret pr",el),eh="0"===et?"0"===es?`>=${et}.${es}.${ec}-${el} <${et}.${es}.${+ec+1}-0`:`>=${et}.${es}.${ec}-${el} <${et}.${+es+1}.0-0`:`>=${et}.${es}.${ec}-${el} <${+et+1}.0.0-0`):(ed("no pr"),eh="0"===et?"0"===es?`>=${et}.${es}.${ec}${eo} <${et}.${es}.${+ec+1}-0`:`>=${et}.${es}.${ec}${eo} <${et}.${+es+1}.0-0`:`>=${et}.${es}.${ec} <${+et+1}.0.0-0`),ed("caret return",eh),eh})},replaceXRanges=(c,l)=>(ed("replaceXRanges",c,l),c.split(/\s+/).map(c=>replaceXRange(c,l)).join(" ")),replaceXRange=(c,l)=>{c=c.trim();let et=l.loose?ef[ep.XRANGELOOSE]:ef[ep.XRANGE];return c.replace(et,(et,eo,es,ec,el,eh)=>{ed("xRange",c,et,eo,es,ec,el,eh);let ef=isX(es),ep=ef||isX(ec),eg=ep||isX(el);return"="===eo&&eg&&(eo=""),eh=l.includePrerelease?"-0":"",ef?et=">"===eo||"<"===eo?"<0.0.0-0":"*":eo&&eg?(ep&&(ec=0),el=0,">"===eo?(eo=">=",ep?(es=+es+1,ec=0):ec=+ec+1,el=0):"<="===eo&&(eo="<",ep?es=+es+1:ec=+ec+1),"<"===eo&&(eh="-0"),et=`${eo+es}.${ec}.${el}${eh}`):ep?et=`>=${es}.0.0${eh} <${+es+1}.0.0-0`:eg&&(et=`>=${es}.${ec}.0${eh} <${es}.${+ec+1}.0-0`),ed("xRange return",et),et})},replaceStars=(c,l)=>(ed("replaceStars",c,l),c.trim().replace(ef[ep.STAR],"")),replaceGTE0=(c,l)=>(ed("replaceGTE0",c,l),c.trim().replace(ef[l.includePrerelease?ep.GTE0PRE:ep.GTE0],"")),hyphenReplace=c=>(l,et,eo,es,ec,el,ed,eh,ef,ep,eg,em,eb)=>(et=isX(eo)?"":isX(es)?`>=${eo}.0.0${c?"-0":""}`:isX(ec)?`>=${eo}.${es}.0${c?"-0":""}`:el?`>=${et}`:`>=${et}${c?"-0":""}`,eh=isX(ef)?"":isX(ep)?`<${+ef+1}.0.0-0`:isX(eg)?`<${ef}.${+ep+1}.0-0`:em?`<=${ef}.${ep}.${eg}-${em}`:c?`<${ef}.${ep}.${+eg+1}-0`:`<=${eh}`,`${et} ${eh}`.trim()),testSet=(c,l,et)=>{for(let et=0;et0){let eo=c[et].semver;if(eo.major===l.major&&eo.minor===l.minor&&eo.patch===l.patch)return!0}return!1}return!0}},50035:function(c,l,et){let eo=et(3900),{MAX_LENGTH:es,MAX_SAFE_INTEGER:ec}=et(74037),{safeRe:el,t:ed}=et(29516),eh=et(7207),{compareIdentifiers:ef}=et(83957);let SemVer=class SemVer{constructor(c,l){if(l=eh(l),c instanceof SemVer){if(!!l.loose===c.loose&&!!l.includePrerelease===c.includePrerelease)return c;c=c.version}else if("string"!=typeof c)throw TypeError(`Invalid version. Must be a string. Got type "${typeof c}".`);if(c.length>es)throw TypeError(`version is longer than ${es} characters`);eo("SemVer",c,l),this.options=l,this.loose=!!l.loose,this.includePrerelease=!!l.includePrerelease;let et=c.trim().match(l.loose?el[ed.LOOSE]:el[ed.FULL]);if(!et)throw TypeError(`Invalid Version: ${c}`);if(this.raw=c,this.major=+et[1],this.minor=+et[2],this.patch=+et[3],this.major>ec||this.major<0)throw TypeError("Invalid major version");if(this.minor>ec||this.minor<0)throw TypeError("Invalid minor version");if(this.patch>ec||this.patch<0)throw TypeError("Invalid patch version");et[4]?this.prerelease=et[4].split(".").map(c=>{if(/^[0-9]+$/.test(c)){let l=+c;if(l>=0&&l=0;)"number"==typeof this.prerelease[eo]&&(this.prerelease[eo]++,eo=-2);if(-1===eo){if(l===this.prerelease.join(".")&&!1===et)throw Error("invalid increment argument: identifier already exists");this.prerelease.push(c)}}if(l){let eo=[l,c];!1===et&&(eo=[l]),0===ef(this.prerelease[0],l)?isNaN(this.prerelease[1])&&(this.prerelease=eo):this.prerelease=eo}break}default:throw Error(`invalid increment argument: ${c}`)}return this.raw=this.format(),this.build.length&&(this.raw+=`+${this.build.join(".")}`),this}};c.exports=SemVer},84192:function(c,l,et){let eo=et(73125);c.exports=(c,l)=>{let et=eo(c.trim().replace(/^[=v]+/,""),l);return et?et.version:null}},94221:function(c,l,et){let eo=et(65966),es=et(90637),ec=et(70995),el=et(33116),ed=et(65976),eh=et(30548);c.exports=(c,l,et,ef)=>{switch(l){case"===":return"object"==typeof c&&(c=c.version),"object"==typeof et&&(et=et.version),c===et;case"!==":return"object"==typeof c&&(c=c.version),"object"==typeof et&&(et=et.version),c!==et;case"":case"=":case"==":return eo(c,et,ef);case"!=":return es(c,et,ef);case">":return ec(c,et,ef);case">=":return el(c,et,ef);case"<":return ed(c,et,ef);case"<=":return eh(c,et,ef);default:throw TypeError(`Invalid operator: ${l}`)}}},7573:function(c,l,et){let eo=et(50035),es=et(73125),{safeRe:ec,t:el}=et(29516);c.exports=(c,l)=>{if(c instanceof eo)return c;if("number"==typeof c&&(c=String(c)),"string"!=typeof c)return null;let et=null;if((l=l||{}).rtl){let l;for(;(l=ec[el.COERCERTL].exec(c))&&(!et||et.index+et[0].length!==c.length);)et&&l.index+l[0].length===et.index+et[0].length||(et=l),ec[el.COERCERTL].lastIndex=l.index+l[1].length+l[2].length;ec[el.COERCERTL].lastIndex=-1}else et=c.match(ec[el.COERCE]);return null===et?null:es(`${et[2]}.${et[3]||"0"}.${et[4]||"0"}`,l)}},48977:function(c,l,et){let eo=et(50035);c.exports=(c,l,et)=>{let es=new eo(c,et),ec=new eo(l,et);return es.compare(ec)||es.compareBuild(ec)}},90700:function(c,l,et){let eo=et(51037);c.exports=(c,l)=>eo(c,l,!0)},51037:function(c,l,et){let eo=et(50035);c.exports=(c,l,et)=>new eo(c,et).compare(new eo(l,et))},72803:function(c,l,et){let eo=et(73125);c.exports=(c,l)=>{let et=eo(c,null,!0),es=eo(l,null,!0),ec=et.compare(es);if(0===ec)return null;let el=ec>0,ed=el?et:es,eh=el?es:et,ef=!!ed.prerelease.length,ep=!!eh.prerelease.length;if(ep&&!ef)return eh.patch||eh.minor?ed.patch?"patch":ed.minor?"minor":"major":"major";let eg=ef?"pre":"";return et.major!==es.major?eg+"major":et.minor!==es.minor?eg+"minor":et.patch!==es.patch?eg+"patch":"prerelease"}},65966:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>0===eo(c,l,et)},70995:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>eo(c,l,et)>0},33116:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>eo(c,l,et)>=0},2468:function(c,l,et){let eo=et(50035);c.exports=(c,l,et,es,ec)=>{"string"==typeof et&&(ec=es,es=et,et=void 0);try{return new eo(c instanceof eo?c.version:c,et).inc(l,es,ec).version}catch(c){return null}}},65976:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>0>eo(c,l,et)},30548:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>0>=eo(c,l,et)},77836:function(c,l,et){let eo=et(50035);c.exports=(c,l)=>new eo(c,l).major},65602:function(c,l,et){let eo=et(50035);c.exports=(c,l)=>new eo(c,l).minor},90637:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>0!==eo(c,l,et)},73125:function(c,l,et){let eo=et(50035);c.exports=(c,l,et=!1)=>{if(c instanceof eo)return c;try{return new eo(c,l)}catch(c){if(!et)return null;throw c}}},74586:function(c,l,et){let eo=et(50035);c.exports=(c,l)=>new eo(c,l).patch},53419:function(c,l,et){let eo=et(73125);c.exports=(c,l)=>{let et=eo(c,l);return et&&et.prerelease.length?et.prerelease:null}},46066:function(c,l,et){let eo=et(51037);c.exports=(c,l,et)=>eo(l,c,et)},91749:function(c,l,et){let eo=et(48977);c.exports=(c,l)=>c.sort((c,et)=>eo(et,c,l))},64286:function(c,l,et){let eo=et(86791);c.exports=(c,l,et)=>{try{l=new eo(l,et)}catch(c){return!1}return l.test(c)}},38262:function(c,l,et){let eo=et(48977);c.exports=(c,l)=>c.sort((c,et)=>eo(c,et,l))},8222:function(c,l,et){let eo=et(73125);c.exports=(c,l)=>{let et=eo(c,l);return et?et.version:null}},97258:function(c,l,et){let eo=et(29516),es=et(74037),ec=et(50035),el=et(83957),ed=et(73125),eh=et(8222),ef=et(84192),ep=et(2468),eg=et(72803),em=et(77836),eb=et(65602),ey=et(74586),e_=et(53419),ew=et(51037),eE=et(46066),eS=et(90700),ex=et(48977),ek=et(38262),eC=et(91749),eA=et(70995),eI=et(65976),eP=et(65966),eR=et(90637),eO=et(33116),eT=et(30548),eN=et(94221),eM=et(7573),e$=et(99655),eB=et(86791),eD=et(64286),ej=et(95762),eL=et(29721),eF=et(45898),eU=et(74714),ez=et(68019),eH=et(93932),eW=et(91326),eV=et(19853),eG=et(41901),eK=et(15074),eJ=et(69130);c.exports={parse:ed,valid:eh,clean:ef,inc:ep,diff:eg,major:em,minor:eb,patch:ey,prerelease:e_,compare:ew,rcompare:eE,compareLoose:eS,compareBuild:ex,sort:ek,rsort:eC,gt:eA,lt:eI,eq:eP,neq:eR,gte:eO,lte:eT,cmp:eN,coerce:eM,Comparator:e$,Range:eB,satisfies:eD,toComparators:ej,maxSatisfying:eL,minSatisfying:eF,minVersion:eU,validRange:ez,outside:eH,gtr:eW,ltr:eV,intersects:eG,simplifyRange:eK,subset:eJ,SemVer:ec,re:eo.re,src:eo.src,tokens:eo.t,SEMVER_SPEC_VERSION:es.SEMVER_SPEC_VERSION,RELEASE_TYPES:es.RELEASE_TYPES,compareIdentifiers:el.compareIdentifiers,rcompareIdentifiers:el.rcompareIdentifiers}},74037:function(c){let l=Number.MAX_SAFE_INTEGER||9007199254740991;c.exports={MAX_LENGTH:256,MAX_SAFE_COMPONENT_LENGTH:16,MAX_SAFE_BUILD_LENGTH:250,MAX_SAFE_INTEGER:l,RELEASE_TYPES:["major","premajor","minor","preminor","patch","prepatch","prerelease"],SEMVER_SPEC_VERSION:"2.0.0",FLAG_INCLUDE_PRERELEASE:1,FLAG_LOOSE:2}},3900:function(c,l,et){var eo=et(25566);let es="object"==typeof eo&&eo.env&&eo.env.NODE_DEBUG&&/\bsemver\b/i.test(eo.env.NODE_DEBUG)?(...c)=>console.error("SEMVER",...c):()=>{};c.exports=es},83957:function(c){let l=/^[0-9]+$/,compareIdentifiers=(c,et)=>{let eo=l.test(c),es=l.test(et);return eo&&es&&(c=+c,et=+et),c===et?0:eo&&!es?-1:es&&!eo?1:ccompareIdentifiers(l,c)}},7207:function(c){let l=Object.freeze({loose:!0}),et=Object.freeze({});c.exports=c=>c?"object"!=typeof c?l:c:et},29516:function(c,l,et){let{MAX_SAFE_COMPONENT_LENGTH:eo,MAX_SAFE_BUILD_LENGTH:es,MAX_LENGTH:ec}=et(74037),el=et(3900);l=c.exports={};let ed=l.re=[],eh=l.safeRe=[],ef=l.src=[],ep=l.t={},eg=0,em="[a-zA-Z0-9-]",eb=[["\\s",1],["\\d",ec],[em,es]],makeSafeRegex=c=>{for(let[l,et]of eb)c=c.split(`${l}*`).join(`${l}{0,${et}}`).split(`${l}+`).join(`${l}{1,${et}}`);return c},createToken=(c,l,et)=>{let eo=makeSafeRegex(l),es=eg++;el(c,es,l),ep[c]=es,ef[es]=l,ed[es]=new RegExp(l,et?"g":void 0),eh[es]=new RegExp(eo,et?"g":void 0)};createToken("NUMERICIDENTIFIER","0|[1-9]\\d*"),createToken("NUMERICIDENTIFIERLOOSE","\\d+"),createToken("NONNUMERICIDENTIFIER",`\\d*[a-zA-Z-]${em}*`),createToken("MAINVERSION",`(${ef[ep.NUMERICIDENTIFIER]})\\.(${ef[ep.NUMERICIDENTIFIER]})\\.(${ef[ep.NUMERICIDENTIFIER]})`),createToken("MAINVERSIONLOOSE",`(${ef[ep.NUMERICIDENTIFIERLOOSE]})\\.(${ef[ep.NUMERICIDENTIFIERLOOSE]})\\.(${ef[ep.NUMERICIDENTIFIERLOOSE]})`),createToken("PRERELEASEIDENTIFIER",`(?:${ef[ep.NUMERICIDENTIFIER]}|${ef[ep.NONNUMERICIDENTIFIER]})`),createToken("PRERELEASEIDENTIFIERLOOSE",`(?:${ef[ep.NUMERICIDENTIFIERLOOSE]}|${ef[ep.NONNUMERICIDENTIFIER]})`),createToken("PRERELEASE",`(?:-(${ef[ep.PRERELEASEIDENTIFIER]}(?:\\.${ef[ep.PRERELEASEIDENTIFIER]})*))`),createToken("PRERELEASELOOSE",`(?:-?(${ef[ep.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${ef[ep.PRERELEASEIDENTIFIERLOOSE]})*))`),createToken("BUILDIDENTIFIER",`${em}+`),createToken("BUILD",`(?:\\+(${ef[ep.BUILDIDENTIFIER]}(?:\\.${ef[ep.BUILDIDENTIFIER]})*))`),createToken("FULLPLAIN",`v?${ef[ep.MAINVERSION]}${ef[ep.PRERELEASE]}?${ef[ep.BUILD]}?`),createToken("FULL",`^${ef[ep.FULLPLAIN]}$`),createToken("LOOSEPLAIN",`[v=\\s]*${ef[ep.MAINVERSIONLOOSE]}${ef[ep.PRERELEASELOOSE]}?${ef[ep.BUILD]}?`),createToken("LOOSE",`^${ef[ep.LOOSEPLAIN]}$`),createToken("GTLT","((?:<|>)?=?)"),createToken("XRANGEIDENTIFIERLOOSE",`${ef[ep.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`),createToken("XRANGEIDENTIFIER",`${ef[ep.NUMERICIDENTIFIER]}|x|X|\\*`),createToken("XRANGEPLAIN",`[v=\\s]*(${ef[ep.XRANGEIDENTIFIER]})(?:\\.(${ef[ep.XRANGEIDENTIFIER]})(?:\\.(${ef[ep.XRANGEIDENTIFIER]})(?:${ef[ep.PRERELEASE]})?${ef[ep.BUILD]}?)?)?`),createToken("XRANGEPLAINLOOSE",`[v=\\s]*(${ef[ep.XRANGEIDENTIFIERLOOSE]})(?:\\.(${ef[ep.XRANGEIDENTIFIERLOOSE]})(?:\\.(${ef[ep.XRANGEIDENTIFIERLOOSE]})(?:${ef[ep.PRERELEASELOOSE]})?${ef[ep.BUILD]}?)?)?`),createToken("XRANGE",`^${ef[ep.GTLT]}\\s*${ef[ep.XRANGEPLAIN]}$`),createToken("XRANGELOOSE",`^${ef[ep.GTLT]}\\s*${ef[ep.XRANGEPLAINLOOSE]}$`),createToken("COERCE",`(^|[^\\d])(\\d{1,${eo}})(?:\\.(\\d{1,${eo}}))?(?:\\.(\\d{1,${eo}}))?(?:$|[^\\d])`),createToken("COERCERTL",ef[ep.COERCE],!0),createToken("LONETILDE","(?:~>?)"),createToken("TILDETRIM",`(\\s*)${ef[ep.LONETILDE]}\\s+`,!0),l.tildeTrimReplace="$1~",createToken("TILDE",`^${ef[ep.LONETILDE]}${ef[ep.XRANGEPLAIN]}$`),createToken("TILDELOOSE",`^${ef[ep.LONETILDE]}${ef[ep.XRANGEPLAINLOOSE]}$`),createToken("LONECARET","(?:\\^)"),createToken("CARETTRIM",`(\\s*)${ef[ep.LONECARET]}\\s+`,!0),l.caretTrimReplace="$1^",createToken("CARET",`^${ef[ep.LONECARET]}${ef[ep.XRANGEPLAIN]}$`),createToken("CARETLOOSE",`^${ef[ep.LONECARET]}${ef[ep.XRANGEPLAINLOOSE]}$`),createToken("COMPARATORLOOSE",`^${ef[ep.GTLT]}\\s*(${ef[ep.LOOSEPLAIN]})$|^$`),createToken("COMPARATOR",`^${ef[ep.GTLT]}\\s*(${ef[ep.FULLPLAIN]})$|^$`),createToken("COMPARATORTRIM",`(\\s*)${ef[ep.GTLT]}\\s*(${ef[ep.LOOSEPLAIN]}|${ef[ep.XRANGEPLAIN]})`,!0),l.comparatorTrimReplace="$1$2$3",createToken("HYPHENRANGE",`^\\s*(${ef[ep.XRANGEPLAIN]})\\s+-\\s+(${ef[ep.XRANGEPLAIN]})\\s*$`),createToken("HYPHENRANGELOOSE",`^\\s*(${ef[ep.XRANGEPLAINLOOSE]})\\s+-\\s+(${ef[ep.XRANGEPLAINLOOSE]})\\s*$`),createToken("STAR","(<|>)?=?\\s*\\*"),createToken("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),createToken("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")},91326:function(c,l,et){let eo=et(93932);c.exports=(c,l,et)=>eo(c,l,">",et)},41901:function(c,l,et){let eo=et(86791);c.exports=(c,l,et)=>(c=new eo(c,et),l=new eo(l,et),c.intersects(l,et))},19853:function(c,l,et){let eo=et(93932);c.exports=(c,l,et)=>eo(c,l,"<",et)},29721:function(c,l,et){let eo=et(50035),es=et(86791);c.exports=(c,l,et)=>{let ec=null,el=null,ed=null;try{ed=new es(l,et)}catch(c){return null}return c.forEach(c=>{ed.test(c)&&(!ec||-1===el.compare(c))&&(ec=c,el=new eo(ec,et))}),ec}},45898:function(c,l,et){let eo=et(50035),es=et(86791);c.exports=(c,l,et)=>{let ec=null,el=null,ed=null;try{ed=new es(l,et)}catch(c){return null}return c.forEach(c=>{ed.test(c)&&(!ec||1===el.compare(c))&&(ec=c,el=new eo(ec,et))}),ec}},74714:function(c,l,et){let eo=et(50035),es=et(86791),ec=et(70995);c.exports=(c,l)=>{c=new es(c,l);let et=new eo("0.0.0");if(c.test(et)||(et=new eo("0.0.0-0"),c.test(et)))return et;et=null;for(let l=0;l{let l=new eo(c.semver.version);switch(c.operator){case">":0===l.prerelease.length?l.patch++:l.prerelease.push(0),l.raw=l.format();case"":case">=":(!el||ec(l,el))&&(el=l);break;case"<":case"<=":break;default:throw Error(`Unexpected operation: ${c.operator}`)}}),el&&(!et||ec(et,el))&&(et=el)}return et&&c.test(et)?et:null}},93932:function(c,l,et){let eo=et(50035),es=et(99655),{ANY:ec}=es,el=et(86791),ed=et(64286),eh=et(70995),ef=et(65976),ep=et(30548),eg=et(33116);c.exports=(c,l,et,em)=>{let eb,ey,e_,ew,eE;switch(c=new eo(c,em),l=new el(l,em),et){case">":eb=eh,ey=ep,e_=ef,ew=">",eE=">=";break;case"<":eb=ef,ey=eg,e_=eh,ew="<",eE="<=";break;default:throw TypeError('Must provide a hilo val of "<" or ">"')}if(ed(c,l,em))return!1;for(let et=0;et{c.semver===ec&&(c=new es(">=0.0.0")),el=el||c,ed=ed||c,eb(c.semver,el.semver,em)?el=c:e_(c.semver,ed.semver,em)&&(ed=c)}),el.operator===ew||el.operator===eE||(!ed.operator||ed.operator===ew)&&ey(c,ed.semver)||ed.operator===eE&&e_(c,ed.semver))return!1}return!0}},15074:function(c,l,et){let eo=et(64286),es=et(51037);c.exports=(c,l,et)=>{let ec=[],el=null,ed=null,eh=c.sort((c,l)=>es(c,l,et));for(let c of eh){let es=eo(c,l,et);es?(ed=c,el||(el=c)):(ed&&ec.push([el,ed]),ed=null,el=null)}el&&ec.push([el,null]);let ef=[];for(let[c,l]of ec)c===l?ef.push(c):l||c!==eh[0]?l?c===eh[0]?ef.push(`<=${l}`):ef.push(`${c} - ${l}`):ef.push(`>=${c}`):ef.push("*");let ep=ef.join(" || "),eg="string"==typeof l.raw?l.raw:String(l);return ep.length=0.0.0-0")],ef=[new es(">=0.0.0")],simpleSubset=(c,l,et)=>{let eo,es,ep,eg,em,eb,ey;if(c===l)return!0;if(1===c.length&&c[0].semver===ec){if(1===l.length&&l[0].semver===ec)return!0;c=et.includePrerelease?eh:ef}if(1===l.length&&l[0].semver===ec){if(et.includePrerelease)return!0;l=ef}let e_=new Set;for(let l of c)">"===l.operator||">="===l.operator?eo=higherGT(eo,l,et):"<"===l.operator||"<="===l.operator?es=lowerLT(es,l,et):e_.add(l.semver);if(e_.size>1||eo&&es&&((ep=ed(eo.semver,es.semver,et))>0||0===ep&&(">="!==eo.operator||"<="!==es.operator)))return null;for(let c of e_){if(eo&&!el(c,String(eo),et)||es&&!el(c,String(es),et))return null;for(let eo of l)if(!el(c,String(eo),et))return!1;return!0}let ew=!!es&&!et.includePrerelease&&!!es.semver.prerelease.length&&es.semver,eE=!!eo&&!et.includePrerelease&&!!eo.semver.prerelease.length&&eo.semver;for(let c of(ew&&1===ew.prerelease.length&&"<"===es.operator&&0===ew.prerelease[0]&&(ew=!1),l)){if(ey=ey||">"===c.operator||">="===c.operator,eb=eb||"<"===c.operator||"<="===c.operator,eo){if(eE&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===eE.major&&c.semver.minor===eE.minor&&c.semver.patch===eE.patch&&(eE=!1),">"===c.operator||">="===c.operator){if((eg=higherGT(eo,c,et))===c&&eg!==eo)return!1}else if(">="===eo.operator&&!el(eo.semver,String(c),et))return!1}if(es){if(ew&&c.semver.prerelease&&c.semver.prerelease.length&&c.semver.major===ew.major&&c.semver.minor===ew.minor&&c.semver.patch===ew.patch&&(ew=!1),"<"===c.operator||"<="===c.operator){if((em=lowerLT(es,c,et))===c&&em!==es)return!1}else if("<="===es.operator&&!el(es.semver,String(c),et))return!1}if(!c.operator&&(es||eo)&&0!==ep)return!1}return(!eo||!eb||!!es||0===ep)&&(!es||!ey||!!eo||0===ep)&&!eE&&!ew},higherGT=(c,l,et)=>{if(!c)return l;let eo=ed(c.semver,l.semver,et);return eo>0?c:eo<0?l:">"===l.operator&&">="===c.operator?l:c},lowerLT=(c,l,et)=>{if(!c)return l;let eo=ed(c.semver,l.semver,et);return eo<0?c:eo>0?l:"<"===l.operator&&"<="===c.operator?l:c};c.exports=(c,l,et={})=>{if(c===l)return!0;c=new eo(c,et),l=new eo(l,et);let es=!1;e:for(let eo of c.set){for(let c of l.set){let l=simpleSubset(eo,c,et);if(es=es||null!==l,l)continue e}if(es)return!1}return!0}},95762:function(c,l,et){let eo=et(86791);c.exports=(c,l)=>new eo(c,l).set.map(c=>c.map(c=>c.value).join(" ").trim().split(" "))},68019:function(c,l,et){let eo=et(86791);c.exports=(c,l)=>{try{return new eo(c,l).range||"*"}catch(c){return null}}},13076:function(c){"use strict";var l=Object.prototype.hasOwnProperty,et="~";function Events(){}function EE(c,l,et){this.fn=c,this.context=l,this.once=et||!1}function addListener(c,l,eo,es,ec){if("function"!=typeof eo)throw TypeError("The listener must be a function");var el=new EE(eo,es||c,ec),ed=et?et+l:l;return c._events[ed]?c._events[ed].fn?c._events[ed]=[c._events[ed],el]:c._events[ed].push(el):(c._events[ed]=el,c._eventsCount++),c}function clearEvent(c,l){0==--c._eventsCount?c._events=new Events:delete c._events[l]}function EventEmitter(){this._events=new Events,this._eventsCount=0}Object.create&&(Events.prototype=Object.create(null),new Events().__proto__||(et=!1)),EventEmitter.prototype.eventNames=function(){var c,eo,es=[];if(0===this._eventsCount)return es;for(eo in c=this._events)l.call(c,eo)&&es.push(et?eo.slice(1):eo);return Object.getOwnPropertySymbols?es.concat(Object.getOwnPropertySymbols(c)):es},EventEmitter.prototype.listeners=function(c){var l=et?et+c:c,eo=this._events[l];if(!eo)return[];if(eo.fn)return[eo.fn];for(var es=0,ec=eo.length,el=Array(ec);es!eg.Gw.some(l=>l.id===c));c.length&&(console.warn("You have configured wagmi to use chains that are not default supported by Privy. Please make sure you add these chains to the PrivyProvider's config.additionalChains property."),c.forEach(c=>console.warn(`- Chain ${c.name} is not supported by default, and must be added to config.additionalChains.`)))}this.#r=c,this.#e=et,this.#e&&(this.ready=!0)}getActiveWallet(){return this.#e}async setActiveWallet(c){if(this.#e?.connectorType===c.connectorType&&this.#e?.walletClientType===c.walletClientType&&this.#e?.address===c.address)return;this.#e=c;let l=await this.getChainId();await this.#n();let et=await this.getChainId();l&&l!==et&&await this.switchChain(l),this.onAccountsChanged([this.#e.address])}async connect({chainId:c}={}){this.emit("message",{type:"connecting"});let l=await this.getAccount();await this.#n();let et=await this.getChainId(),eo=this.isChainUnsupported(et);return c&&et!==c&&(et=(await this.switchChain(c)).id,eo=this.isChainUnsupported(et)),{account:l,chain:{id:et,unsupported:eo}}}async disconnect(){this.#t&&this.#i(this.#t),await this.#r()}async getAccount(){if(!this.#e)throw new es.N;return(0,el.K)(this.#e.address)}async getChainId(){return p(await (await this.getProvider()).request({method:"eth_chainId"}))}async getProvider(){if(!this.#e)throw new es.N;if(!this.#t)try{let c=await this.#e.getEthereumProvider();this.#t=c}catch{throw new es.N}return this.#t}async getWalletClient({chainId:c}={}){let[l,et]=await Promise.all([this.getProvider(),this.getAccount()]),eo=this.chains.find(l=>l.id===c);return(0,ed.K)({account:et,chain:eo,transport:(0,eh.P)(l)})}async isAuthorized(){let[c,l,et]=await Promise.all([this.getProvider(),this.getAccount(),this.#e?.isConnected()]);return!!l&&!!c&&!!et}async switchChain(c){let l=await this.getProvider(),et=(0,ef.eC)(c);try{let eo=new Promise(l=>{let i=({chain:et})=>{et?.id===c&&(this.off("change",i),l())};this.on("change",i)});return await Promise.all([eo,l.request({method:"wallet_switchEthereumChain",params:[{chainId:et.toString()}]})]),this.chains.find(l=>l.id===c)??{id:c,name:`Chain ${et}`,network:`${et}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}}}catch(es){let eo=this.chains.find(l=>l.id===c);if(!eo)throw new ec.X4({chainId:c,connectorId:this.id});if(4902===es.code)try{return await l.request({method:"wallet_addEthereumChain",params:[{chainId:et,chainName:eo.name,nativeCurrency:eo.nativeCurrency,rpcUrls:[eo.rpcUrls.public?.http[0]??""],blockExplorerUrls:this.getBlockExplorerUrls(eo)}]}),eo}catch(c){throw new ep.ab(c)}throw this.#o(es)?new ep.ab(es):new ep.x3(es)}}onAccountsChanged=c=>{0===c.length?this.emit("disconnect"):this.emit("change",{account:(0,el.K)(this.#e.address)})};onChainChanged=c=>{let l=p(c),et=this.isChainUnsupported(l);this.emit("change",{chain:{id:l,unsupported:et}})};onDisconnect=()=>{this.ready=!1,this.emit("disconnect")};#o(c){return/(user rejected)/i.test(c.message)}#s(c){c.on("accountsChanged",this.onAccountsChanged),c.on("chainChanged",this.onChainChanged),c.on("disconnect",this.onDisconnect)}#i(c){c.removeListener("accountsChanged",this.onAccountsChanged),c.removeListener("chainChanged",this.onChainChanged),c.removeListener("disconnect",this.onDisconnect)}async #n(){let c=this.#t;this.#t=void 0;let l=await this.getProvider();c&&this.#i(c),this.#s(l),this.ready=!0}},ew=(0,em.createContext)({}),k=({wagmiChainsConfig:c,children:l})=>{let{logout:et}=(0,eg.sv)(),{wallets:eo}=(0,eg.rB)(),{chains:es,publicClient:ec}=c,el=(0,em.useRef)(new e_({logout:et,chains:es})),ed=(0,em.useRef)((0,eb._g)({autoConnect:!0,connectors:[el.current],publicClient:ec}));return(0,em.useEffect)(()=>{(async()=>{let c=eo[0];c&&await el.current.setActiveWallet(c)})()},[eo.length]),(0,em.useEffect)(()=>{(async()=>{let c=el.current.getActiveWallet();if(c&&await c.isConnected())return;let l=eo[0];l&&await el.current.setActiveWallet(l)})()},[eo]),(0,ey.jsx)(ew.Provider,{value:{connector:el.current},children:(0,ey.jsx)(eb.eM,{config:ed.current,children:l})})},L=()=>{let{connector:c}=(0,em.useContext)(ew),{wallets:l}=(0,eg.rB)(),[et,eo]=(0,em.useState)(),{refetch:es}=(0,eb.py)();(0,em.useEffect)(()=>{let i=()=>{let et=c.getActiveWallet();eo(l.find(c=>c.address===et?.address&&c.connectorType===et.connectorType&&c.walletClientType===et.walletClientType)??et)};return i(),c.on("change",i),()=>{c.off("change",i)}},[l]),(0,em.useEffect)(()=>{es()},[et]);let r=async l=>c.setActiveWallet(l);return{ready:c.ready,wallet:et,setActiveWallet:r}}},34310:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});var eo=et(62140);function writeUint16BE(c,l,et){return void 0===l&&(l=new Uint8Array(2)),void 0===et&&(et=0),l[et+0]=c>>>8,l[et+1]=c>>>0,l}function writeUint16LE(c,l,et){return void 0===l&&(l=new Uint8Array(2)),void 0===et&&(et=0),l[et+0]=c>>>0,l[et+1]=c>>>8,l}function readInt32BE(c,l){return void 0===l&&(l=0),c[l]<<24|c[l+1]<<16|c[l+2]<<8|c[l+3]}function readUint32BE(c,l){return void 0===l&&(l=0),(c[l]<<24|c[l+1]<<16|c[l+2]<<8|c[l+3])>>>0}function readInt32LE(c,l){return void 0===l&&(l=0),c[l+3]<<24|c[l+2]<<16|c[l+1]<<8|c[l]}function readUint32LE(c,l){return void 0===l&&(l=0),(c[l+3]<<24|c[l+2]<<16|c[l+1]<<8|c[l])>>>0}function writeUint32BE(c,l,et){return void 0===l&&(l=new Uint8Array(4)),void 0===et&&(et=0),l[et+0]=c>>>24,l[et+1]=c>>>16,l[et+2]=c>>>8,l[et+3]=c>>>0,l}function writeUint32LE(c,l,et){return void 0===l&&(l=new Uint8Array(4)),void 0===et&&(et=0),l[et+0]=c>>>0,l[et+1]=c>>>8,l[et+2]=c>>>16,l[et+3]=c>>>24,l}function writeUint64BE(c,l,et){return void 0===l&&(l=new Uint8Array(8)),void 0===et&&(et=0),writeUint32BE(c/4294967296>>>0,l,et),writeUint32BE(c>>>0,l,et+4),l}function writeUint64LE(c,l,et){return void 0===l&&(l=new Uint8Array(8)),void 0===et&&(et=0),writeUint32LE(c>>>0,l,et),writeUint32LE(c/4294967296>>>0,l,et+4),l}l.readInt16BE=function(c,l){return void 0===l&&(l=0),(c[l+0]<<8|c[l+1])<<16>>16},l.readUint16BE=function(c,l){return void 0===l&&(l=0),(c[l+0]<<8|c[l+1])>>>0},l.readInt16LE=function(c,l){return void 0===l&&(l=0),(c[l+1]<<8|c[l])<<16>>16},l.readUint16LE=function(c,l){return void 0===l&&(l=0),(c[l+1]<<8|c[l])>>>0},l.writeUint16BE=writeUint16BE,l.writeInt16BE=writeUint16BE,l.writeUint16LE=writeUint16LE,l.writeInt16LE=writeUint16LE,l.readInt32BE=readInt32BE,l.readUint32BE=readUint32BE,l.readInt32LE=readInt32LE,l.readUint32LE=readUint32LE,l.writeUint32BE=writeUint32BE,l.writeInt32BE=writeUint32BE,l.writeUint32LE=writeUint32LE,l.writeInt32LE=writeUint32LE,l.readInt64BE=function(c,l){void 0===l&&(l=0);var et=readInt32BE(c,l),eo=readInt32BE(c,l+4);return 4294967296*et+eo-(eo>>31)*4294967296},l.readUint64BE=function(c,l){return void 0===l&&(l=0),4294967296*readUint32BE(c,l)+readUint32BE(c,l+4)},l.readInt64LE=function(c,l){void 0===l&&(l=0);var et=readInt32LE(c,l);return 4294967296*readInt32LE(c,l+4)+et-(et>>31)*4294967296},l.readUint64LE=function(c,l){void 0===l&&(l=0);var et=readUint32LE(c,l);return 4294967296*readUint32LE(c,l+4)+et},l.writeUint64BE=writeUint64BE,l.writeInt64BE=writeUint64BE,l.writeUint64LE=writeUint64LE,l.writeInt64LE=writeUint64LE,l.readUintBE=function(c,l,et){if(void 0===et&&(et=0),c%8!=0)throw Error("readUintBE supports only bitLengths divisible by 8");if(c/8>l.length-et)throw Error("readUintBE: array is too short for the given bitLength");for(var eo=0,es=1,ec=c/8+et-1;ec>=et;ec--)eo+=l[ec]*es,es*=256;return eo},l.readUintLE=function(c,l,et){if(void 0===et&&(et=0),c%8!=0)throw Error("readUintLE supports only bitLengths divisible by 8");if(c/8>l.length-et)throw Error("readUintLE: array is too short for the given bitLength");for(var eo=0,es=1,ec=et;ec=es;el--)et[el]=l/ec&255,ec*=256;return et},l.writeUintLE=function(c,l,et,es){if(void 0===et&&(et=new Uint8Array(c/8)),void 0===es&&(es=0),c%8!=0)throw Error("writeUintLE supports only bitLengths divisible by 8");if(!eo.isSafeInteger(l))throw Error("writeUintLE value must be an integer");for(var ec=1,el=es;el>>16|eN<<16)|0,ek=ek>>>20|ek<<12,eM^=eE=eE+eC|0,eC^=eR=eR+(eM=eM>>>16|eM<<16)|0,eC=eC>>>20|eC<<12,e$^=eS=eS+eA|0,eA^=eO=eO+(e$=e$>>>16|e$<<16)|0,eA=eA>>>20|eA<<12,eB^=ex=ex+eI|0,eI^=eT=eT+(eB=eB>>>16|eB<<16)|0,eI=eI>>>20|eI<<12,e$^=eS=eS+eA|0,eA^=eO=eO+(e$=e$>>>24|e$<<8)|0,eA=eA>>>25|eA<<7,eB^=ex=ex+eI|0,eI^=eT=eT+(eB=eB>>>24|eB<<8)|0,eI=eI>>>25|eI<<7,eM^=eE=eE+eC|0,eC^=eR=eR+(eM=eM>>>24|eM<<8)|0,eC=eC>>>25|eC<<7,eN^=ew=ew+ek|0,ek^=eP=eP+(eN=eN>>>24|eN<<8)|0,ek=ek>>>25|ek<<7,eB^=ew=ew+eC|0,eC^=eO=eO+(eB=eB>>>16|eB<<16)|0,eC=eC>>>20|eC<<12,eN^=eE=eE+eA|0,eA^=eT=eT+(eN=eN>>>16|eN<<16)|0,eA=eA>>>20|eA<<12,eM^=eS=eS+eI|0,eI^=eP=eP+(eM=eM>>>16|eM<<16)|0,eI=eI>>>20|eI<<12,e$^=ex=ex+ek|0,ek^=eR=eR+(e$=e$>>>16|e$<<16)|0,ek=ek>>>20|ek<<12,eM^=eS=eS+eI|0,eI^=eP=eP+(eM=eM>>>24|eM<<8)|0,eI=eI>>>25|eI<<7,e$^=ex=ex+ek|0,ek^=eR=eR+(e$=e$>>>24|e$<<8)|0,ek=ek>>>25|ek<<7,eN^=eE=eE+eA|0,eA^=eT=eT+(eN=eN>>>24|eN<<8)|0,eA=eA>>>25|eA<<7,eB^=ew=ew+eC|0,eC^=eO=eO+(eB=eB>>>24|eB<<8)|0,eC=eC>>>25|eC<<7;eo.writeUint32LE(ew+1634760805|0,c,0),eo.writeUint32LE(eE+857760878|0,c,4),eo.writeUint32LE(eS+2036477234|0,c,8),eo.writeUint32LE(ex+1797285236|0,c,12),eo.writeUint32LE(ek+es|0,c,16),eo.writeUint32LE(eC+ec|0,c,20),eo.writeUint32LE(eA+el|0,c,24),eo.writeUint32LE(eI+ed|0,c,28),eo.writeUint32LE(eP+eh|0,c,32),eo.writeUint32LE(eR+ef|0,c,36),eo.writeUint32LE(eO+ep|0,c,40),eo.writeUint32LE(eT+eg|0,c,44),eo.writeUint32LE(eN+em|0,c,48),eo.writeUint32LE(eM+eb|0,c,52),eo.writeUint32LE(e$+ey|0,c,56),eo.writeUint32LE(eB+e_|0,c,60)}(ef,ed,c);for(var eg=ep;eg>>=8,l++;if(eo>0)throw Error("ChaCha: counter overflow")}(ed,0,eh)}return es.wipe(ef),0===el&&es.wipe(ed),ec}l.streamXOR=streamXOR,l.stream=function(c,l,et,eo){return void 0===eo&&(eo=0),es.wipe(et),streamXOR(c,l,et,et,eo)}},51040:function(c,l,et){"use strict";var eo=et(48733),es=et(66508),ec=et(55277),el=et(34310),ed=et(51448);l.Cv=32,l.WH=12,l.pg=16;var eh=new Uint8Array(16),ef=function(){function ChaCha20Poly1305(c){if(this.nonceLength=l.WH,this.tagLength=l.pg,c.length!==l.Cv)throw Error("ChaCha20Poly1305 needs 32-byte key");this._key=new Uint8Array(c)}return ChaCha20Poly1305.prototype.seal=function(c,l,et,es){if(c.length>16)throw Error("ChaCha20Poly1305: incorrect nonce length");var el,ed=new Uint8Array(16);ed.set(c,ed.length-c.length);var eh=new Uint8Array(32);eo.stream(this._key,ed,eh,4);var ef=l.length+this.tagLength;if(es){if(es.length!==ef)throw Error("ChaCha20Poly1305: incorrect destination length");el=es}else el=new Uint8Array(ef);return eo.streamXOR(this._key,ed,l,el,4),this._authenticate(el.subarray(el.length-this.tagLength,el.length),eh,el.subarray(0,el.length-this.tagLength),et),ec.wipe(ed),el},ChaCha20Poly1305.prototype.open=function(c,l,et,es){if(c.length>16)throw Error("ChaCha20Poly1305: incorrect nonce length");if(l.length0&&ed.update(eh.subarray(eo.length%16))),ed.update(et),et.length%16>0&&ed.update(eh.subarray(et.length%16));var ef=new Uint8Array(8);eo&&el.writeUint64LE(eo.length,ef),ed.update(ef),el.writeUint64LE(et.length,ef),ed.update(ef);for(var ep=ed.digest(),eg=0;eg>>8}Object.defineProperty(l,"__esModule",{value:!0}),l.select=function(c,l,et){return~(c-1)&l|c-1&et},l.lessOrEqual=function(c,l){return(0|c)-(0|l)-1>>>31&1},l.compare=compare,l.equal=function(c,l){return 0!==c.length&&0!==l.length&&0!==compare(c,l)}},80237:function(c,l,et){"use strict";l.Xx=l._w=l.aP=l.KS=l.jQ=void 0,et(35077);let eo=et(52564);function gf(c){let l=new Float64Array(16);if(c)for(let et=0;et>16&1),et[c-1]&=65535;et[15]=eo[15]-32767-(et[14]>>16&1);let c=et[15]>>16&1;et[14]&=65535,sel25519(eo,et,1-c)}for(let l=0;l<16;l++)c[2*l]=255&eo[l],c[2*l+1]=eo[l]>>8}gf([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]);function add(c,l,et){for(let eo=0;eo<16;eo++)c[eo]=l[eo]+et[eo]}function sub(c,l,et){for(let eo=0;eo<16;eo++)c[eo]=l[eo]-et[eo]}function mul(c,l,et){let eo,es,ec=0,el=0,ed=0,eh=0,ef=0,ep=0,eg=0,em=0,eb=0,ey=0,e_=0,ew=0,eE=0,eS=0,ex=0,ek=0,eC=0,eA=0,eI=0,eP=0,eR=0,eO=0,eT=0,eN=0,eM=0,e$=0,eB=0,eD=0,ej=0,eL=0,eF=0,eU=et[0],ez=et[1],eH=et[2],eW=et[3],eV=et[4],eG=et[5],eK=et[6],eJ=et[7],eQ=et[8],eY=et[9],eZ=et[10],eX=et[11],e0=et[12],e1=et[13],e2=et[14],e3=et[15];ec+=(eo=l[0])*eU,el+=eo*ez,ed+=eo*eH,eh+=eo*eW,ef+=eo*eV,ep+=eo*eG,eg+=eo*eK,em+=eo*eJ,eb+=eo*eQ,ey+=eo*eY,e_+=eo*eZ,ew+=eo*eX,eE+=eo*e0,eS+=eo*e1,ex+=eo*e2,ek+=eo*e3,el+=(eo=l[1])*eU,ed+=eo*ez,eh+=eo*eH,ef+=eo*eW,ep+=eo*eV,eg+=eo*eG,em+=eo*eK,eb+=eo*eJ,ey+=eo*eQ,e_+=eo*eY,ew+=eo*eZ,eE+=eo*eX,eS+=eo*e0,ex+=eo*e1,ek+=eo*e2,eC+=eo*e3,ed+=(eo=l[2])*eU,eh+=eo*ez,ef+=eo*eH,ep+=eo*eW,eg+=eo*eV,em+=eo*eG,eb+=eo*eK,ey+=eo*eJ,e_+=eo*eQ,ew+=eo*eY,eE+=eo*eZ,eS+=eo*eX,ex+=eo*e0,ek+=eo*e1,eC+=eo*e2,eA+=eo*e3,eh+=(eo=l[3])*eU,ef+=eo*ez,ep+=eo*eH,eg+=eo*eW,em+=eo*eV,eb+=eo*eG,ey+=eo*eK,e_+=eo*eJ,ew+=eo*eQ,eE+=eo*eY,eS+=eo*eZ,ex+=eo*eX,ek+=eo*e0,eC+=eo*e1,eA+=eo*e2,eI+=eo*e3,ef+=(eo=l[4])*eU,ep+=eo*ez,eg+=eo*eH,em+=eo*eW,eb+=eo*eV,ey+=eo*eG,e_+=eo*eK,ew+=eo*eJ,eE+=eo*eQ,eS+=eo*eY,ex+=eo*eZ,ek+=eo*eX,eC+=eo*e0,eA+=eo*e1,eI+=eo*e2,eP+=eo*e3,ep+=(eo=l[5])*eU,eg+=eo*ez,em+=eo*eH,eb+=eo*eW,ey+=eo*eV,e_+=eo*eG,ew+=eo*eK,eE+=eo*eJ,eS+=eo*eQ,ex+=eo*eY,ek+=eo*eZ,eC+=eo*eX,eA+=eo*e0,eI+=eo*e1,eP+=eo*e2,eR+=eo*e3,eg+=(eo=l[6])*eU,em+=eo*ez,eb+=eo*eH,ey+=eo*eW,e_+=eo*eV,ew+=eo*eG,eE+=eo*eK,eS+=eo*eJ,ex+=eo*eQ,ek+=eo*eY,eC+=eo*eZ,eA+=eo*eX,eI+=eo*e0,eP+=eo*e1,eR+=eo*e2,eO+=eo*e3,em+=(eo=l[7])*eU,eb+=eo*ez,ey+=eo*eH,e_+=eo*eW,ew+=eo*eV,eE+=eo*eG,eS+=eo*eK,ex+=eo*eJ,ek+=eo*eQ,eC+=eo*eY,eA+=eo*eZ,eI+=eo*eX,eP+=eo*e0,eR+=eo*e1,eO+=eo*e2,eT+=eo*e3,eb+=(eo=l[8])*eU,ey+=eo*ez,e_+=eo*eH,ew+=eo*eW,eE+=eo*eV,eS+=eo*eG,ex+=eo*eK,ek+=eo*eJ,eC+=eo*eQ,eA+=eo*eY,eI+=eo*eZ,eP+=eo*eX,eR+=eo*e0,eO+=eo*e1,eT+=eo*e2,eN+=eo*e3,ey+=(eo=l[9])*eU,e_+=eo*ez,ew+=eo*eH,eE+=eo*eW,eS+=eo*eV,ex+=eo*eG,ek+=eo*eK,eC+=eo*eJ,eA+=eo*eQ,eI+=eo*eY,eP+=eo*eZ,eR+=eo*eX,eO+=eo*e0,eT+=eo*e1,eN+=eo*e2,eM+=eo*e3,e_+=(eo=l[10])*eU,ew+=eo*ez,eE+=eo*eH,eS+=eo*eW,ex+=eo*eV,ek+=eo*eG,eC+=eo*eK,eA+=eo*eJ,eI+=eo*eQ,eP+=eo*eY,eR+=eo*eZ,eO+=eo*eX,eT+=eo*e0,eN+=eo*e1,eM+=eo*e2,e$+=eo*e3,ew+=(eo=l[11])*eU,eE+=eo*ez,eS+=eo*eH,ex+=eo*eW,ek+=eo*eV,eC+=eo*eG,eA+=eo*eK,eI+=eo*eJ,eP+=eo*eQ,eR+=eo*eY,eO+=eo*eZ,eT+=eo*eX,eN+=eo*e0,eM+=eo*e1,e$+=eo*e2,eB+=eo*e3,eE+=(eo=l[12])*eU,eS+=eo*ez,ex+=eo*eH,ek+=eo*eW,eC+=eo*eV,eA+=eo*eG,eI+=eo*eK,eP+=eo*eJ,eR+=eo*eQ,eO+=eo*eY,eT+=eo*eZ,eN+=eo*eX,eM+=eo*e0,e$+=eo*e1,eB+=eo*e2,eD+=eo*e3,eS+=(eo=l[13])*eU,ex+=eo*ez,ek+=eo*eH,eC+=eo*eW,eA+=eo*eV,eI+=eo*eG,eP+=eo*eK,eR+=eo*eJ,eO+=eo*eQ,eT+=eo*eY,eN+=eo*eZ,eM+=eo*eX,e$+=eo*e0,eB+=eo*e1,eD+=eo*e2,ej+=eo*e3,ex+=(eo=l[14])*eU,ek+=eo*ez,eC+=eo*eH,eA+=eo*eW,eI+=eo*eV,eP+=eo*eG,eR+=eo*eK,eO+=eo*eJ,eT+=eo*eQ,eN+=eo*eY,eM+=eo*eZ,e$+=eo*eX,eB+=eo*e0,eD+=eo*e1,ej+=eo*e2,eL+=eo*e3,ek+=(eo=l[15])*eU,eC+=eo*ez,eA+=eo*eH,eI+=eo*eW,eP+=eo*eV,eR+=eo*eG,eO+=eo*eK,eT+=eo*eJ,eN+=eo*eQ,eM+=eo*eY,e$+=eo*eZ,eB+=eo*eX,eD+=eo*e0,ej+=eo*e1,eL+=eo*e2,eF+=eo*e3,ec+=38*eC,el+=38*eA,ed+=38*eI,eh+=38*eP,ef+=38*eR,ep+=38*eO,eg+=38*eT,em+=38*eN,eb+=38*eM,ey+=38*e$,e_+=38*eB,ew+=38*eD,eE+=38*ej,eS+=38*eL,ex+=38*eF,es=Math.floor((eo=ec+(es=1)+65535)/65536),ec=eo-65536*es,es=Math.floor((eo=el+es+65535)/65536),el=eo-65536*es,es=Math.floor((eo=ed+es+65535)/65536),ed=eo-65536*es,es=Math.floor((eo=eh+es+65535)/65536),eh=eo-65536*es,es=Math.floor((eo=ef+es+65535)/65536),ef=eo-65536*es,es=Math.floor((eo=ep+es+65535)/65536),ep=eo-65536*es,es=Math.floor((eo=eg+es+65535)/65536),eg=eo-65536*es,es=Math.floor((eo=em+es+65535)/65536),em=eo-65536*es,es=Math.floor((eo=eb+es+65535)/65536),eb=eo-65536*es,es=Math.floor((eo=ey+es+65535)/65536),ey=eo-65536*es,es=Math.floor((eo=e_+es+65535)/65536),e_=eo-65536*es,es=Math.floor((eo=ew+es+65535)/65536),ew=eo-65536*es,es=Math.floor((eo=eE+es+65535)/65536),eE=eo-65536*es,es=Math.floor((eo=eS+es+65535)/65536),eS=eo-65536*es,es=Math.floor((eo=ex+es+65535)/65536),ex=eo-65536*es,es=Math.floor((eo=ek+es+65535)/65536),ek=eo-65536*es,ec+=es-1+37*(es-1),es=Math.floor((eo=ec+(es=1)+65535)/65536),ec=eo-65536*es,es=Math.floor((eo=el+es+65535)/65536),el=eo-65536*es,es=Math.floor((eo=ed+es+65535)/65536),ed=eo-65536*es,es=Math.floor((eo=eh+es+65535)/65536),eh=eo-65536*es,es=Math.floor((eo=ef+es+65535)/65536),ef=eo-65536*es,es=Math.floor((eo=ep+es+65535)/65536),ep=eo-65536*es,es=Math.floor((eo=eg+es+65535)/65536),eg=eo-65536*es,es=Math.floor((eo=em+es+65535)/65536),em=eo-65536*es,es=Math.floor((eo=eb+es+65535)/65536),eb=eo-65536*es,es=Math.floor((eo=ey+es+65535)/65536),ey=eo-65536*es,es=Math.floor((eo=e_+es+65535)/65536),e_=eo-65536*es,es=Math.floor((eo=ew+es+65535)/65536),ew=eo-65536*es,es=Math.floor((eo=eE+es+65535)/65536),eE=eo-65536*es,es=Math.floor((eo=eS+es+65535)/65536),eS=eo-65536*es,es=Math.floor((eo=ex+es+65535)/65536),ex=eo-65536*es,es=Math.floor((eo=ek+es+65535)/65536),ek=eo-65536*es,ec+=es-1+37*(es-1),c[0]=ec,c[1]=el,c[2]=ed,c[3]=eh,c[4]=ef,c[5]=ep,c[6]=eg,c[7]=em,c[8]=eb,c[9]=ey,c[10]=e_,c[11]=ew,c[12]=eE,c[13]=eS,c[14]=ex,c[15]=ek}function edadd(c,l){let et=gf(),eo=gf(),es=gf(),ec=gf(),el=gf(),eh=gf(),ef=gf(),ep=gf(),eg=gf();sub(et,c[1],c[0]),sub(eg,l[1],l[0]),mul(et,et,eg),add(eo,c[0],c[1]),add(eg,l[0],l[1]),mul(eo,eo,eg),mul(es,c[3],l[3]),mul(es,es,ed),mul(ec,c[2],l[2]),add(ec,ec,ec),sub(el,eo,et),sub(eh,ec,es),add(ef,ec,es),add(ep,eo,et),mul(c[0],el,eh),mul(c[1],ep,ef),mul(c[2],ef,eh),mul(c[3],el,ep)}function cswap(c,l,et){for(let eo=0;eo<4;eo++)sel25519(c[eo],l[eo],et)}function pack(c,l){let et=gf(),eo=gf(),es=gf();(function(c,l){let et;let eo=gf();for(et=0;et<16;et++)eo[et]=l[et];for(et=253;et>=0;et--)mul(eo,eo,eo),2!==et&&4!==et&&mul(eo,eo,l);for(et=0;et<16;et++)c[et]=eo[et]})(es,l[2]),mul(et,l[0],es),mul(eo,l[1],es),pack25519(c,eo),c[31]^=function(c){let l=new Uint8Array(32);return pack25519(l,c),1&l[0]}(et)<<7}function scalarbase(c,l){let et=[gf(),gf(),gf(),gf()];set25519(et[0],eh),set25519(et[1],ef),set25519(et[2],el),mul(et[3],eh,ef),function(c,l,et){set25519(c[0],ec),set25519(c[1],el),set25519(c[2],el),set25519(c[3],ec);for(let eo=255;eo>=0;--eo){let es=et[eo/8|0]>>(7&eo)&1;cswap(c,l,es),edadd(l,c),edadd(c,c),cswap(c,l,es)}}(c,et,l)}l._w=function(c){if(c.length!==l.aP)throw Error(`ed25519: seed must be ${l.aP} bytes`);let et=(0,eo.hash)(c);et[0]&=248,et[31]&=127,et[31]|=64;let es=new Uint8Array(32),ec=[gf(),gf(),gf(),gf()];scalarbase(ec,et),pack(es,ec);let el=new Uint8Array(64);return el.set(c),el.set(es,32),{publicKey:es,secretKey:el}};let ep=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]);function modL(c,l){let et,eo,es,ec;for(eo=63;eo>=32;--eo){for(et=0,es=eo-32,ec=eo-12;es>4)*ep[es],et=l[es]>>8,l[es]&=255;for(es=0;es<32;es++)l[es]-=et*ep[es];for(eo=0;eo<32;eo++)l[eo+1]+=l[eo]>>8,c[eo]=255&l[eo]}function reduce(c){let l=new Float64Array(64);for(let et=0;et<64;et++)l[et]=c[et];for(let l=0;l<64;l++)c[l]=0;modL(c,l)}l.Xx=function(c,l){let et=new Float64Array(64),es=[gf(),gf(),gf(),gf()],ec=(0,eo.hash)(c.subarray(0,32));ec[0]&=248,ec[31]&=127,ec[31]|=64;let el=new Uint8Array(64);el.set(ec.subarray(32),32);let ed=new eo.SHA512;ed.update(el.subarray(32)),ed.update(l);let eh=ed.digest();ed.clean(),reduce(eh),scalarbase(es,eh),pack(el,es),ed.reset(),ed.update(el.subarray(0,32)),ed.update(c.subarray(32)),ed.update(l);let ef=ed.digest();reduce(ef);for(let c=0;c<32;c++)et[c]=eh[c];for(let c=0;c<32;c++)for(let l=0;l<32;l++)et[c+l]+=ef[c]*ec[l];return modL(el.subarray(32),et),el}},12621:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.isSerializableHash=function(c){return void 0!==c.saveState&&void 0!==c.restoreState&&void 0!==c.cleanSavedState}},20342:function(c,l,et){"use strict";var eo=et(9922),es=et(55277),ec=function(){function HKDF(c,l,et,es){void 0===et&&(et=new Uint8Array(0)),this._counter=new Uint8Array(1),this._hash=c,this._info=es;var ec=eo.hmac(this._hash,et,l);this._hmac=new eo.HMAC(c,ec),this._buffer=new Uint8Array(this._hmac.digestLength),this._bufpos=this._buffer.length}return HKDF.prototype._fillBuffer=function(){this._counter[0]++;var c=this._counter[0];if(0===c)throw Error("hkdf: cannot expand more");this._hmac.reset(),c>1&&this._hmac.update(this._buffer),this._info&&this._hmac.update(this._info),this._hmac.update(this._counter),this._hmac.finish(this._buffer),this._bufpos=0},HKDF.prototype.expand=function(c){for(var l=new Uint8Array(c),et=0;etthis.blockSize?this._inner.update(l).finish(et).clean():et.set(l);for(var es=0;es>>16&65535)*eo+et*(l>>>16&65535)<<16>>>0)|0},l.add=function(c,l){return c+l|0},l.sub=function(c,l){return c-l|0},l.rotl=function(c,l){return c<>>32-l},l.rotr=function(c,l){return c<<32-l|c>>>l},l.isInteger=Number.isInteger||function(c){return"number"==typeof c&&isFinite(c)&&Math.floor(c)===c},l.MAX_SAFE_INTEGER=9007199254740991,l.isSafeInteger=function(c){return l.isInteger(c)&&c>=-l.MAX_SAFE_INTEGER&&c<=l.MAX_SAFE_INTEGER}},66508:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});var eo=et(51448),es=et(55277);l.DIGEST_LENGTH=16;var ec=function(){function Poly1305(c){this.digestLength=l.DIGEST_LENGTH,this._buffer=new Uint8Array(16),this._r=new Uint16Array(10),this._h=new Uint16Array(10),this._pad=new Uint16Array(8),this._leftover=0,this._fin=0,this._finished=!1;var et=c[0]|c[1]<<8;this._r[0]=8191&et;var eo=c[2]|c[3]<<8;this._r[1]=(et>>>13|eo<<3)&8191;var es=c[4]|c[5]<<8;this._r[2]=(eo>>>10|es<<6)&7939;var ec=c[6]|c[7]<<8;this._r[3]=(es>>>7|ec<<9)&8191;var el=c[8]|c[9]<<8;this._r[4]=(ec>>>4|el<<12)&255,this._r[5]=el>>>1&8190;var ed=c[10]|c[11]<<8;this._r[6]=(el>>>14|ed<<2)&8191;var eh=c[12]|c[13]<<8;this._r[7]=(ed>>>11|eh<<5)&8065;var ef=c[14]|c[15]<<8;this._r[8]=(eh>>>8|ef<<8)&8191,this._r[9]=ef>>>5&127,this._pad[0]=c[16]|c[17]<<8,this._pad[1]=c[18]|c[19]<<8,this._pad[2]=c[20]|c[21]<<8,this._pad[3]=c[22]|c[23]<<8,this._pad[4]=c[24]|c[25]<<8,this._pad[5]=c[26]|c[27]<<8,this._pad[6]=c[28]|c[29]<<8,this._pad[7]=c[30]|c[31]<<8}return Poly1305.prototype._blocks=function(c,l,et){for(var eo=this._fin?0:2048,es=this._h[0],ec=this._h[1],el=this._h[2],ed=this._h[3],eh=this._h[4],ef=this._h[5],ep=this._h[6],eg=this._h[7],em=this._h[8],eb=this._h[9],ey=this._r[0],e_=this._r[1],ew=this._r[2],eE=this._r[3],eS=this._r[4],ex=this._r[5],ek=this._r[6],eC=this._r[7],eA=this._r[8],eI=this._r[9];et>=16;){var eP,eR=c[l+0]|c[l+1]<<8;es+=8191&eR;var eO=c[l+2]|c[l+3]<<8;ec+=(eR>>>13|eO<<3)&8191;var eT=c[l+4]|c[l+5]<<8;el+=(eO>>>10|eT<<6)&8191;var eN=c[l+6]|c[l+7]<<8;ed+=(eT>>>7|eN<<9)&8191;var eM=c[l+8]|c[l+9]<<8;eh+=(eN>>>4|eM<<12)&8191,ef+=eM>>>1&8191;var e$=c[l+10]|c[l+11]<<8;ep+=(eM>>>14|e$<<2)&8191;var eB=c[l+12]|c[l+13]<<8;eg+=(e$>>>11|eB<<5)&8191;var eD=c[l+14]|c[l+15]<<8;em+=(eB>>>8|eD<<8)&8191,eb+=eD>>>5|eo;var ej=0;ej=(eP=0+es*ey+ec*(5*eI)+el*(5*eA)+ed*(5*eC)+eh*(5*ek))>>>13,eP&=8191,eP+=ef*(5*ex)+ep*(5*eS)+eg*(5*eE)+em*(5*ew)+eb*(5*e_),ej+=eP>>>13,eP&=8191;var eL=ej;eL+=es*e_+ec*ey+el*(5*eI)+ed*(5*eA)+eh*(5*eC),ej=eL>>>13,eL&=8191,eL+=ef*(5*ek)+ep*(5*ex)+eg*(5*eS)+em*(5*eE)+eb*(5*ew),ej+=eL>>>13,eL&=8191;var eF=ej;eF+=es*ew+ec*e_+el*ey+ed*(5*eI)+eh*(5*eA),ej=eF>>>13,eF&=8191,eF+=ef*(5*eC)+ep*(5*ek)+eg*(5*ex)+em*(5*eS)+eb*(5*eE),ej+=eF>>>13,eF&=8191;var eU=ej;eU+=es*eE+ec*ew+el*e_+ed*ey+eh*(5*eI),ej=eU>>>13,eU&=8191,eU+=ef*(5*eA)+ep*(5*eC)+eg*(5*ek)+em*(5*ex)+eb*(5*eS),ej+=eU>>>13,eU&=8191;var ez=ej;ez+=es*eS+ec*eE+el*ew+ed*e_+eh*ey,ej=ez>>>13,ez&=8191,ez+=ef*(5*eI)+ep*(5*eA)+eg*(5*eC)+em*(5*ek)+eb*(5*ex),ej+=ez>>>13,ez&=8191;var eH=ej;eH+=es*ex+ec*eS+el*eE+ed*ew+eh*e_,ej=eH>>>13,eH&=8191,eH+=ef*ey+ep*(5*eI)+eg*(5*eA)+em*(5*eC)+eb*(5*ek),ej+=eH>>>13,eH&=8191;var eW=ej;eW+=es*ek+ec*ex+el*eS+ed*eE+eh*ew,ej=eW>>>13,eW&=8191,eW+=ef*e_+ep*ey+eg*(5*eI)+em*(5*eA)+eb*(5*eC),ej+=eW>>>13,eW&=8191;var eV=ej;eV+=es*eC+ec*ek+el*ex+ed*eS+eh*eE,ej=eV>>>13,eV&=8191,eV+=ef*ew+ep*e_+eg*ey+em*(5*eI)+eb*(5*eA),ej+=eV>>>13,eV&=8191;var eG=ej;eG+=es*eA+ec*eC+el*ek+ed*ex+eh*eS,ej=eG>>>13,eG&=8191,eG+=ef*eE+ep*ew+eg*e_+em*ey+eb*(5*eI),ej+=eG>>>13,eG&=8191;var eK=ej;eK+=es*eI+ec*eA+el*eC+ed*ek+eh*ex,ej=eK>>>13,eK&=8191,eK+=ef*eS+ep*eE+eg*ew+em*e_+eb*ey,ej+=eK>>>13,eK&=8191,eP=8191&(ej=(ej=(ej<<2)+ej|0)+eP|0),ej>>>=13,eL+=ej,es=eP,ec=eL,el=eF,ed=eU,eh=ez,ef=eH,ep=eW,eg=eV,em=eG,eb=eK,l+=16,et-=16}this._h[0]=es,this._h[1]=ec,this._h[2]=el,this._h[3]=ed,this._h[4]=eh,this._h[5]=ef,this._h[6]=ep,this._h[7]=eg,this._h[8]=em,this._h[9]=eb},Poly1305.prototype.finish=function(c,l){void 0===l&&(l=0);var et,eo,es,ec,el=new Uint16Array(10);if(this._leftover){for(ec=this._leftover,this._buffer[ec++]=1;ec<16;ec++)this._buffer[ec]=0;this._fin=1,this._blocks(this._buffer,0,16)}for(et=this._h[1]>>>13,this._h[1]&=8191,ec=2;ec<10;ec++)this._h[ec]+=et,et=this._h[ec]>>>13,this._h[ec]&=8191;for(this._h[0]+=5*et,et=this._h[0]>>>13,this._h[0]&=8191,this._h[1]+=et,et=this._h[1]>>>13,this._h[1]&=8191,this._h[2]+=et,el[0]=this._h[0]+5,et=el[0]>>>13,el[0]&=8191,ec=1;ec<10;ec++)el[ec]=this._h[ec]+et,et=el[ec]>>>13,el[ec]&=8191;for(el[9]-=8192,eo=(1^et)-1,ec=0;ec<10;ec++)el[ec]&=eo;for(ec=0,eo=~eo;ec<10;ec++)this._h[ec]=this._h[ec]&eo|el[ec];for(ec=1,this._h[0]=(this._h[0]|this._h[1]<<13)&65535,this._h[1]=(this._h[1]>>>3|this._h[2]<<10)&65535,this._h[2]=(this._h[2]>>>6|this._h[3]<<7)&65535,this._h[3]=(this._h[3]>>>9|this._h[4]<<4)&65535,this._h[4]=(this._h[4]>>>12|this._h[5]<<1|this._h[6]<<14)&65535,this._h[5]=(this._h[6]>>>2|this._h[7]<<11)&65535,this._h[6]=(this._h[7]>>>5|this._h[8]<<8)&65535,this._h[7]=(this._h[8]>>>8|this._h[9]<<5)&65535,es=this._h[0]+this._pad[0],this._h[0]=65535&es;ec<8;ec++)es=(this._h[ec]+this._pad[ec]|0)+(es>>>16)|0,this._h[ec]=65535&es;return c[l+0]=this._h[0]>>>0,c[l+1]=this._h[0]>>>8,c[l+2]=this._h[1]>>>0,c[l+3]=this._h[1]>>>8,c[l+4]=this._h[2]>>>0,c[l+5]=this._h[2]>>>8,c[l+6]=this._h[3]>>>0,c[l+7]=this._h[3]>>>8,c[l+8]=this._h[4]>>>0,c[l+9]=this._h[4]>>>8,c[l+10]=this._h[5]>>>0,c[l+11]=this._h[5]>>>8,c[l+12]=this._h[6]>>>0,c[l+13]=this._h[6]>>>8,c[l+14]=this._h[7]>>>0,c[l+15]=this._h[7]>>>8,this._finished=!0,this},Poly1305.prototype.update=function(c){var l,et=0,eo=c.length;if(this._leftover){(l=16-this._leftover)>eo&&(l=eo);for(var es=0;es=16&&(l=eo-eo%16,this._blocks(c,et,l),et+=l,eo-=l),eo){for(var es=0;es256)throw Error("randomString charset is too long");let es="",ed=et.length,eh=256-256%ed;for(;c>0;){let l=randomBytes(Math.ceil(256*c/eh),eo);for(let eo=0;eo0;eo++){let ec=l[eo];ec0){for(;this._bufferLength0;)this._buffer[this._bufferLength++]=c[et++],l--;this._bufferLength===this.blockSize&&(hashBlocks(this._temp,this._state,this._buffer,0,this.blockSize),this._bufferLength=0)}for(l>=this.blockSize&&(et=hashBlocks(this._temp,this._state,c,et,l),l%=this.blockSize);l>0;)this._buffer[this._bufferLength++]=c[et++],l--;return this},SHA256.prototype.finish=function(c){if(!this._finished){var l=this._bytesHashed,et=this._bufferLength,es=l%64<56?64:128;this._buffer[et]=128;for(var ec=et+1;ec0?new Uint8Array(this._buffer):void 0,bufferLength:this._bufferLength,bytesHashed:this._bytesHashed}},SHA256.prototype.restoreState=function(c){return this._state.set(c.state),this._bufferLength=c.bufferLength,c.buffer&&this._buffer.set(c.buffer),this._bytesHashed=c.bytesHashed,this._finished=!1,this},SHA256.prototype.cleanSavedState=function(c){es.wipe(c.state),c.buffer&&es.wipe(c.buffer),c.bufferLength=0,c.bytesHashed=0},SHA256}();l.mE=ec;var el=new Int32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]);function hashBlocks(c,l,et,es,ec){for(;ec>=64;){for(var ed=l[0],eh=l[1],ef=l[2],ep=l[3],eg=l[4],em=l[5],eb=l[6],ey=l[7],e_=0;e_<16;e_++){var ew=es+4*e_;c[e_]=eo.readUint32BE(et,ew)}for(var e_=16;e_<64;e_++){var eE=c[e_-2],eS=(eE>>>17|eE<<15)^(eE>>>19|eE<<13)^eE>>>10,ex=((eE=c[e_-15])>>>7|eE<<25)^(eE>>>18|eE<<14)^eE>>>3;c[e_]=(eS+c[e_-7]|0)+(ex+c[e_-16]|0)}for(var e_=0;e_<64;e_++){var eS=(((eg>>>6|eg<<26)^(eg>>>11|eg<<21)^(eg>>>25|eg<<7))+(eg&em^~eg&eb)|0)+(ey+(el[e_]+c[e_]|0)|0)|0,ex=((ed>>>2|ed<<30)^(ed>>>13|ed<<19)^(ed>>>22|ed<<10))+(ed&eh^ed&ef^eh&ef)|0;ey=eb,eb=em,em=eg,eg=ep+eS|0,ep=ef,ef=eh,eh=ed,ed=eS+ex|0}l[0]+=ed,l[1]+=eh,l[2]+=ef,l[3]+=ep,l[4]+=eg,l[5]+=em,l[6]+=eb,l[7]+=ey,es+=64,ec-=64}return es}l.vp=function(c){var l=new ec;l.update(c);var et=l.digest();return l.clean(),et}},52564:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});var eo=et(34310),es=et(55277);l.DIGEST_LENGTH=64,l.BLOCK_SIZE=128;var ec=function(){function SHA512(){this.digestLength=l.DIGEST_LENGTH,this.blockSize=l.BLOCK_SIZE,this._stateHi=new Int32Array(8),this._stateLo=new Int32Array(8),this._tempHi=new Int32Array(16),this._tempLo=new Int32Array(16),this._buffer=new Uint8Array(256),this._bufferLength=0,this._bytesHashed=0,this._finished=!1,this.reset()}return SHA512.prototype._initState=function(){this._stateHi[0]=1779033703,this._stateHi[1]=3144134277,this._stateHi[2]=1013904242,this._stateHi[3]=2773480762,this._stateHi[4]=1359893119,this._stateHi[5]=2600822924,this._stateHi[6]=528734635,this._stateHi[7]=1541459225,this._stateLo[0]=4089235720,this._stateLo[1]=2227873595,this._stateLo[2]=4271175723,this._stateLo[3]=1595750129,this._stateLo[4]=2917565137,this._stateLo[5]=725511199,this._stateLo[6]=4215389547,this._stateLo[7]=327033209},SHA512.prototype.reset=function(){return this._initState(),this._bufferLength=0,this._bytesHashed=0,this._finished=!1,this},SHA512.prototype.clean=function(){es.wipe(this._buffer),es.wipe(this._tempHi),es.wipe(this._tempLo),this.reset()},SHA512.prototype.update=function(c,et){if(void 0===et&&(et=c.length),this._finished)throw Error("SHA512: can't update because hash was finished.");var eo=0;if(this._bytesHashed+=et,this._bufferLength>0){for(;this._bufferLength0;)this._buffer[this._bufferLength++]=c[eo++],et--;this._bufferLength===this.blockSize&&(hashBlocks(this._tempHi,this._tempLo,this._stateHi,this._stateLo,this._buffer,0,this.blockSize),this._bufferLength=0)}for(et>=this.blockSize&&(eo=hashBlocks(this._tempHi,this._tempLo,this._stateHi,this._stateLo,c,eo,et),et%=this.blockSize);et>0;)this._buffer[this._bufferLength++]=c[eo++],et--;return this},SHA512.prototype.finish=function(c){if(!this._finished){var l=this._bytesHashed,et=this._bufferLength,es=l%128<112?128:256;this._buffer[et]=128;for(var ec=et+1;ec0?new Uint8Array(this._buffer):void 0,bufferLength:this._bufferLength,bytesHashed:this._bytesHashed}},SHA512.prototype.restoreState=function(c){return this._stateHi.set(c.stateHi),this._stateLo.set(c.stateLo),this._bufferLength=c.bufferLength,c.buffer&&this._buffer.set(c.buffer),this._bytesHashed=c.bytesHashed,this._finished=!1,this},SHA512.prototype.cleanSavedState=function(c){es.wipe(c.stateHi),es.wipe(c.stateLo),c.buffer&&es.wipe(c.buffer),c.bufferLength=0,c.bytesHashed=0},SHA512}();l.SHA512=ec;var el=new Int32Array([1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591]);function hashBlocks(c,l,et,es,ec,ed,eh){for(var ef,ep,eg,em,eb,ey,e_,ew,eE=et[0],eS=et[1],ex=et[2],ek=et[3],eC=et[4],eA=et[5],eI=et[6],eP=et[7],eR=es[0],eO=es[1],eT=es[2],eN=es[3],eM=es[4],e$=es[5],eB=es[6],eD=es[7];eh>=128;){for(var ej=0;ej<16;ej++){var eL=8*ej+ed;c[ej]=eo.readUint32BE(ec,eL),l[ej]=eo.readUint32BE(ec,eL+4)}for(var ej=0;ej<80;ej++){var eF=eE,eU=eS,ez=ex,eH=ek,eW=eC,eV=eA,eG=eI,eK=eP,eJ=eR,eQ=eO,eY=eT,eZ=eN,eX=eM,e0=e$,e1=eB,e2=eD;if(ef=eP,eb=65535&(ep=eD),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=(eC>>>14|eM<<18)^(eC>>>18|eM<<14)^(eM>>>9|eC<<23),eb+=65535&(ep=(eM>>>14|eC<<18)^(eM>>>18|eC<<14)^(eC>>>9|eM<<23)),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ef=eC&eA^~eC&eI,eb+=65535&(ep=eM&e$^~eM&eB),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ef=el[2*ej],eb+=65535&(ep=el[2*ej+1]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ef=c[ej%16],eb+=65535&(ep=l[ej%16]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,eg=65535&e_|ew<<16,em=65535&eb|ey<<16,ef=eg,eb=65535&(ep=em),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=(eE>>>28|eR<<4)^(eR>>>2|eE<<30)^(eR>>>7|eE<<25),eb+=65535&(ep=(eR>>>28|eE<<4)^(eE>>>2|eR<<30)^(eE>>>7|eR<<25)),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ef=eE&eS^eE&ex^eS&ex,eb+=65535&(ep=eR&eO^eR&eT^eO&eT),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,eK=65535&e_|ew<<16,e2=65535&eb|ey<<16,ef=eH,eb=65535&(ep=eZ),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=eg,eb+=65535&(ep=em),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,eH=65535&e_|ew<<16,eZ=65535&eb|ey<<16,eS=eF,ex=eU,ek=ez,eC=eH,eA=eW,eI=eV,eP=eG,eE=eK,eO=eJ,eT=eQ,eN=eY,eM=eZ,e$=eX,eB=e0,eD=e1,eR=e2,ej%16==15)for(var eL=0;eL<16;eL++)ef=c[eL],eb=65535&(ep=l[eL]),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=c[(eL+9)%16],eb+=65535&(ep=l[(eL+9)%16]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ef=((eg=c[(eL+1)%16])>>>1|(em=l[(eL+1)%16])<<31)^(eg>>>8|em<<24)^eg>>>7,eb+=65535&(ep=(em>>>1|eg<<31)^(em>>>8|eg<<24)^(em>>>7|eg<<25)),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ef=((eg=c[(eL+14)%16])>>>19|(em=l[(eL+14)%16])<<13)^(em>>>29|eg<<3)^eg>>>6,eb+=65535&(ep=(em>>>19|eg<<13)^(eg>>>29|em<<3)^(em>>>6|eg<<26)),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,c[eL]=65535&e_|ew<<16,l[eL]=65535&eb|ey<<16}ef=eE,eb=65535&(ep=eR),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[0],eb+=65535&(ep=es[0]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[0]=eE=65535&e_|ew<<16,es[0]=eR=65535&eb|ey<<16,ef=eS,eb=65535&(ep=eO),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[1],eb+=65535&(ep=es[1]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[1]=eS=65535&e_|ew<<16,es[1]=eO=65535&eb|ey<<16,ef=ex,eb=65535&(ep=eT),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[2],eb+=65535&(ep=es[2]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[2]=ex=65535&e_|ew<<16,es[2]=eT=65535&eb|ey<<16,ef=ek,eb=65535&(ep=eN),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[3],eb+=65535&(ep=es[3]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[3]=ek=65535&e_|ew<<16,es[3]=eN=65535&eb|ey<<16,ef=eC,eb=65535&(ep=eM),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[4],eb+=65535&(ep=es[4]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[4]=eC=65535&e_|ew<<16,es[4]=eM=65535&eb|ey<<16,ef=eA,eb=65535&(ep=e$),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[5],eb+=65535&(ep=es[5]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[5]=eA=65535&e_|ew<<16,es[5]=e$=65535&eb|ey<<16,ef=eI,eb=65535&(ep=eB),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[6],eb+=65535&(ep=es[6]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[6]=eI=65535&e_|ew<<16,es[6]=eB=65535&eb|ey<<16,ef=eP,eb=65535&(ep=eD),ey=ep>>>16,e_=65535&ef,ew=ef>>>16,ef=et[7],eb+=65535&(ep=es[7]),ey+=ep>>>16,e_+=65535&ef,ew+=ef>>>16,ey+=eb>>>16,e_+=ey>>>16,ew+=e_>>>16,et[7]=eP=65535&e_|ew<<16,es[7]=eD=65535&eb|ey<<16,ed+=128,eh-=128}return ed}l.hash=function(c){var l=new ec;l.update(c);var et=l.digest();return l.clean(),et}},55277:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.wipe=function(c){for(var l=0;l=0;--c){let l=et[c>>>3]>>>(7&c)&1;sel25519(es,ec,l),sel25519(ed,eh,l),add(ef,es,ed),sub(es,es,ed),add(ed,ec,eh),sub(ec,ec,eh),mul(eh,ef,ef),mul(ep,es,es),mul(es,ed,es),mul(ed,ec,ef),add(ef,es,ed),sub(es,es,ed),mul(ec,es,es),sub(ed,eh,ep),mul(es,ed,el),add(es,es,eh),mul(ed,ed,es),mul(es,eh,ep),mul(eh,ec,eo),mul(ec,ef,ef),sel25519(es,ec,l),sel25519(ed,eh,l)}for(let c=0;c<16;c++)eo[c+16]=es[c],eo[c+32]=ed[c],eo[c+48]=ec[c],eo[c+64]=eh[c];let eg=eo.subarray(32),em=eo.subarray(16);!function(c,l){let et=gf();for(let c=0;c<16;c++)et[c]=l[c];for(let c=253;c>=0;c--)mul(et,et,et),2!==c&&4!==c&&mul(et,et,l);for(let l=0;l<16;l++)c[l]=et[l]}(eg,eg),mul(em,em,eg);let eb=new Uint8Array(32);return!function(c,l){let et=gf(),eo=gf();for(let c=0;c<16;c++)eo[c]=l[c];car25519(eo),car25519(eo),car25519(eo);for(let c=0;c<2;c++){et[0]=eo[0]-65517;for(let c=1;c<15;c++)et[c]=eo[c]-65535-(et[c-1]>>16&1),et[c-1]&=65535;et[15]=eo[15]-32767-(et[14]>>16&1);let c=et[15]>>16&1;et[14]&=65535,sel25519(eo,et,1-c)}for(let l=0;l<16;l++)c[2*l]=255&eo[l],c[2*l+1]=eo[l]>>8}(eb,em),eb}l.Au=function(c){let et=(0,eo.randomBytes)(32,c),el=function(c){if(c.length!==l.KS)throw Error(`x25519: seed must be ${l.KS} bytes`);let et=new Uint8Array(c),eo=scalarMult(et,ec);return{publicKey:eo,secretKey:et}}(et);return(0,es.wipe)(et),el},l.gi=function(c,et,eo=!1){if(c.length!==l.kz)throw Error("X25519: incorrect secret key length");if(et.length!==l.kz)throw Error("X25519: incorrect public key length");let es=scalarMult(c,et);if(eo){let c=0;for(let l=0;l1)}function isMobile(){let c=browser_detectOS();return!!c&&(isAndroid()||isIOS())}function isNode(){let c=detectEnv(),l=!!c&&!!c.name&&"node"===c.name.toLowerCase();return l}function isBrowser(){let c=!isNode()&&!!ey();return c}let ef=es.sD,ep=es.$2,eg=es.uT,em=es.Me,eb=es.Gw,ey=es.jW,e_=es.UO,ew=es.k$,eE=es.VQ,eS=es.MX,ex=es.xP,ek=es.$o;function getClientMeta(){return eo.D()}let json_safeJsonParse=function(c){if("string"!=typeof c)throw Error(`Cannot safe json parse value of type ${typeof c}`);try{return JSON.parse(c)}catch(l){return c}},json_safeJsonStringify=function(c){return"string"==typeof c?c:JSON.stringify(c)};function setLocal(c,l){let et=json_safeJsonStringify(l),eo=ek();eo&&eo.setItem(c,et)}function getLocal(c){let l=null,et=ek();return et&&(l=et.getItem(c)),l?json_safeJsonParse(l):l}function removeLocal(c){let l=ek();l&&l.removeItem(c)}let eC="WALLETCONNECT_DEEPLINK_CHOICE";function formatIOSMobile(c,l){let et=encodeURIComponent(c);return l.universalLink?`${l.universalLink}/wc?uri=${et}`:l.deepLink?`${l.deepLink}${l.deepLink.endsWith(":")?"//":"/"}wc?uri=${et}`:""}function saveMobileLinkInfo(c){let l=c.href.split("?")[0];setLocal(eC,Object.assign(Object.assign({},c),{href:l}))}function getMobileRegistryEntry(c,l){return c.filter(c=>c.name.toLowerCase().includes(l.toLowerCase()))[0]}function getMobileLinkRegistry(c,l){let et=c;return l&&(et=l.map(l=>getMobileRegistryEntry(c,l)).filter(Boolean)),et}let eA="https://registry.walletconnect.com";function getWalletRegistryUrl(){return eA+"/api/v2/wallets"}function getDappRegistryUrl(){return eA+"/api/v2/dapps"}function formatMobileRegistryEntry(c,l="mobile"){var et;return{name:c.name||"",shortName:c.metadata.shortName||"",color:c.metadata.colors.primary||"",logo:null!==(et=c.image_url.sm)&&void 0!==et?et:"",universalLink:c[l].universal||"",deepLink:c[l].native||""}}function formatMobileRegistry(c,l="mobile"){return Object.values(c).filter(c=>!!c[l].universal||!!c[l].native).map(c=>formatMobileRegistryEntry(c,l))}},9527:function(c,l){"use strict";function getFromWindow(c){let l;return"undefined"!=typeof window&&void 0!==window[c]&&(l=window[c]),l}function getFromWindowOrThrow(c){let l=getFromWindow(c);if(!l)throw Error(`${c} is not defined in Window`);return l}l.$o=l.xP=l.MX=l.VQ=l.k$=l.UO=l.jW=l.Gw=l.Me=l.uT=l.$2=l.sD=void 0,l.sD=getFromWindow,l.$2=getFromWindowOrThrow,l.uT=function(){return getFromWindowOrThrow("document")},l.Me=function(){return getFromWindow("document")},l.Gw=function(){return getFromWindowOrThrow("navigator")},l.jW=function(){return getFromWindow("navigator")},l.UO=function(){return getFromWindowOrThrow("location")},l.k$=function(){return getFromWindow("location")},l.VQ=function(){return getFromWindowOrThrow("crypto")},l.MX=function(){return getFromWindow("crypto")},l.xP=function(){return getFromWindowOrThrow("localStorage")},l.$o=function(){return getFromWindow("localStorage")}},16411:function(c,l,et){"use strict";l.D=void 0;let eo=et(16909);l.D=function(){let c,l,et;try{c=eo.getDocumentOrThrow(),l=eo.getLocationOrThrow()}catch(c){return null}function getWindowMetadataOfAny(...l){let et=c.getElementsByTagName("meta");for(let c=0;ceo.getAttribute(c)).filter(c=>!!c&&l.includes(c));if(es.length&&es){let c=eo.getAttribute("content");if(c)return c}}return""}let es=((et=getWindowMetadataOfAny("name","og:site_name","og:title","twitter:title"))||(et=c.title),et),ec=function(){let c=getWindowMetadataOfAny("description","og:description","twitter:description","keywords");return c}(),el=l.origin,ed=function(){let et=c.getElementsByTagName("link"),eo=[];for(let c=0;c-1){let c=es.getAttribute("href");if(c){if(-1===c.toLowerCase().indexOf("https:")&&-1===c.toLowerCase().indexOf("http:")&&0!==c.indexOf("//")){let et=l.protocol+"//"+l.host;if(0===c.indexOf("/"))et+=c;else{let eo=l.pathname.split("/");eo.pop();let es=eo.join("/");et+=es+"/"+c}eo.push(et)}else if(0===c.indexOf("//")){let et=l.protocol+c;eo.push(et)}else eo.push(c)}}}return eo}();return{description:ec,url:el,icons:ed,name:es}}},16909:function(c,l){"use strict";function getFromWindow(c){let l;return"undefined"!=typeof window&&void 0!==window[c]&&(l=window[c]),l}function getFromWindowOrThrow(c){let l=getFromWindow(c);if(!l)throw Error(`${c} is not defined in Window`);return l}Object.defineProperty(l,"__esModule",{value:!0}),l.getLocalStorage=l.getLocalStorageOrThrow=l.getCrypto=l.getCryptoOrThrow=l.getLocation=l.getLocationOrThrow=l.getNavigator=l.getNavigatorOrThrow=l.getDocument=l.getDocumentOrThrow=l.getFromWindowOrThrow=l.getFromWindow=void 0,l.getFromWindow=getFromWindow,l.getFromWindowOrThrow=getFromWindowOrThrow,l.getDocumentOrThrow=function(){return getFromWindowOrThrow("document")},l.getDocument=function(){return getFromWindow("document")},l.getNavigatorOrThrow=function(){return getFromWindowOrThrow("navigator")},l.getNavigator=function(){return getFromWindow("navigator")},l.getLocationOrThrow=function(){return getFromWindowOrThrow("location")},l.getLocation=function(){return getFromWindow("location")},l.getCryptoOrThrow=function(){return getFromWindowOrThrow("crypto")},l.getCrypto=function(){return getFromWindow("crypto")},l.getLocalStorageOrThrow=function(){return getFromWindowOrThrow("localStorage")},l.getLocalStorage=function(){return getFromWindow("localStorage")}},81431:function(c,l,et){"use strict";function getBrowerCrypto(){return(null===et.g||void 0===et.g?void 0:et.g.crypto)||(null===et.g||void 0===et.g?void 0:et.g.msCrypto)||{}}function getSubtleCrypto(){let c=getBrowerCrypto();return c.subtle||c.webkitSubtle}Object.defineProperty(l,"__esModule",{value:!0}),l.isBrowserCryptoAvailable=l.getSubtleCrypto=l.getBrowerCrypto=void 0,l.getBrowerCrypto=getBrowerCrypto,l.getSubtleCrypto=getSubtleCrypto,l.isBrowserCryptoAvailable=function(){return!!getBrowerCrypto()&&!!getSubtleCrypto()}},51164:function(c,l,et){"use strict";var eo=et(25566);function isReactNative(){return"undefined"==typeof document&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product}function isNode(){return void 0!==eo&&void 0!==eo.versions&&void 0!==eo.versions.node}Object.defineProperty(l,"__esModule",{value:!0}),l.isBrowser=l.isNode=l.isReactNative=void 0,l.isReactNative=isReactNative,l.isNode=isNode,l.isBrowser=function(){return!isReactNative()&&!isNode()}},36014:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(75031);eo.__exportStar(et(81431),l),eo.__exportStar(et(51164),l)},75031:function(c,l,et){"use strict";et.r(l),et.d(l,{__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return __createBinding},__decorate:function(){return __decorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar},__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__read:function(){return __read},__rest:function(){return __rest},__spread:function(){return __spread},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */var extendStatics=function(c,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var et in l)l.hasOwnProperty(et)&&(c[et]=l[et])})(c,l)};function __extends(c,l){function __(){this.constructor=c}extendStatics(c,l),c.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(c){for(var l,et=1,eo=arguments.length;etl.indexOf(eo)&&(et[eo]=c[eo]);if(null!=c&&"function"==typeof Object.getOwnPropertySymbols)for(var es=0,eo=Object.getOwnPropertySymbols(c);esl.indexOf(eo[es])&&Object.prototype.propertyIsEnumerable.call(c,eo[es])&&(et[eo[es]]=c[eo[es]]);return et}function __decorate(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el}function __param(c,l){return function(et,eo){l(et,eo,c)}}function __metadata(c,l){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(c,l)}function __awaiter(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})}function __generator(c,l){var et,eo,es,ec,el={label:0,sent:function(){if(1&es[0])throw es[1];return es[1]},trys:[],ops:[]};return ec={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(ec[Symbol.iterator]=function(){return this}),ec;function verb(ec){return function(ed){return function(ec){if(et)throw TypeError("Generator is already executing.");for(;el;)try{if(et=1,eo&&(es=2&ec[0]?eo.return:ec[0]?eo.throw||((es=eo.return)&&es.call(eo),0):eo.next)&&!(es=es.call(eo,ec[1])).done)return es;switch(eo=0,es&&(ec=[2&ec[0],es.value]),ec[0]){case 0:case 1:es=ec;break;case 4:return el.label++,{value:ec[1],done:!1};case 5:el.label++,eo=ec[1],ec=[0];continue;case 7:ec=el.ops.pop(),el.trys.pop();continue;default:if(!(es=(es=el.trys).length>0&&es[es.length-1])&&(6===ec[0]||2===ec[0])){el=0;continue}if(3===ec[0]&&(!es||ec[1]>es[0]&&ec[1]=c.length&&(c=void 0),{value:c&&c[eo++],done:!c}}};throw TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(c,l){var et="function"==typeof Symbol&&c[Symbol.iterator];if(!et)return c;var eo,es,ec=et.call(c),el=[];try{for(;(void 0===l||l-- >0)&&!(eo=ec.next()).done;)el.push(eo.value)}catch(c){es={error:c}}finally{try{eo&&!eo.done&&(et=ec.return)&&et.call(ec)}finally{if(es)throw es.error}}return el}function __spread(){for(var c=[],l=0;l1||resume(c,l)})})}function resume(c,l){try{var et;(et=es[c](l)).value instanceof __await?Promise.resolve(et.value.v).then(fulfill,reject):settle(ec[0][2],et)}catch(c){settle(ec[0][3],c)}}function fulfill(c){resume("next",c)}function reject(c){resume("throw",c)}function settle(c,l){c(l),ec.shift(),ec.length&&resume(ec[0][0],ec[0][1])}}function __asyncDelegator(c){var l,et;return l={},verb("next"),verb("throw",function(c){throw c}),verb("return"),l[Symbol.iterator]=function(){return this},l;function verb(eo,es){l[eo]=c[eo]?function(l){return(et=!et)?{value:__await(c[eo](l)),done:"return"===eo}:es?es(l):l}:es}}function __asyncValues(c){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var l,et=c[Symbol.asyncIterator];return et?et.call(c):(c=__values(c),l={},verb("next"),verb("throw"),verb("return"),l[Symbol.asyncIterator]=function(){return this},l);function verb(et){l[et]=c[et]&&function(l){return new Promise(function(eo,es){!function(c,l,et,eo){Promise.resolve(eo).then(function(l){c({value:l,done:et})},l)}(eo,es,(l=c[et](l)).done,l.value)})}}}function __makeTemplateObject(c,l){return Object.defineProperty?Object.defineProperty(c,"raw",{value:l}):c.raw=l,c}function __importStar(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)Object.hasOwnProperty.call(c,et)&&(l[et]=c[et]);return l.default=c,l}function __importDefault(c){return c&&c.__esModule?c:{default:c}}function __classPrivateFieldGet(c,l){if(!l.has(c))throw TypeError("attempted to get private field on non-instance");return l.get(c)}function __classPrivateFieldSet(c,l,et){if(!l.has(c))throw TypeError("attempted to set private field on non-instance");return l.set(c,et),et}},37169:function(c,l,et){"use strict";et.d(l,{Gn:function(){return ix},gy:function(){return im},lI:function(){return ip}});var eo={};et.r(eo),et.d(eo,{identity:function(){return eP}});var es={};et.r(es),et.d(es,{base2:function(){return eR}});var ec={};et.r(ec),et.d(ec,{base8:function(){return eO}});var el={};et.r(el),et.d(el,{base10:function(){return eT}});var ed={};et.r(ed),et.d(ed,{base16:function(){return eN},base16upper:function(){return eM}});var eh={};et.r(eh),et.d(eh,{base32:function(){return e$},base32hex:function(){return eL},base32hexpad:function(){return eU},base32hexpadupper:function(){return ez},base32hexupper:function(){return eF},base32pad:function(){return eD},base32padupper:function(){return ej},base32upper:function(){return eB},base32z:function(){return eH}});var ef={};et.r(ef),et.d(ef,{base36:function(){return eW},base36upper:function(){return eV}});var ep={};et.r(ep),et.d(ep,{base58btc:function(){return eG},base58flickr:function(){return eK}});var eg={};et.r(eg),et.d(eg,{base64:function(){return eJ},base64pad:function(){return eQ},base64url:function(){return eY},base64urlpad:function(){return eZ}});var em={};et.r(em),et.d(em,{base256emoji:function(){return e2}});var eb={};et.r(eb),et.d(eb,{sha256:function(){return e5},sha512:function(){return e6}});var ey={};et.r(ey),et.d(ey,{identity:function(){return e4}});var e_={};et.r(e_),et.d(e_,{code:function(){return e9},decode:function(){return raw_decode},encode:function(){return raw_encode},name:function(){return e8}});var ew={};et.r(ew),et.d(ew,{code:function(){return ts},decode:function(){return json_decode},encode:function(){return json_encode},name:function(){return to}});var eE=et(512),eS=et.n(eE),ex=et(51040),ek=et(20342),eC=et(35077),eA=et(87853),eI=et(38195);function as_uint8array_asUint8Array(c){return null!=globalThis.Buffer?new Uint8Array(c.buffer,c.byteOffset,c.byteLength):c}function allocUnsafe(c=0){return null!=globalThis.Buffer&&null!=globalThis.Buffer.allocUnsafe?as_uint8array_asUint8Array(globalThis.Buffer.allocUnsafe(c)):new Uint8Array(c)}function concat(c,l){l||(l=c.reduce((c,l)=>c+l.length,0));let et=allocUnsafe(l),eo=0;for(let l of c)et.set(l,eo),eo+=l.length;return as_uint8array_asUint8Array(et)}var base_x=function(c,l){if(c.length>=255)throw TypeError("Alphabet too long");for(var et=new Uint8Array(256),eo=0;eo>>0,el=new Uint8Array(ec);c[l];){var ep=et[c.charCodeAt(l)];if(255===ep)return;for(var eg=0,em=ec-1;(0!==ep||eg>>0,el[em]=ep%256>>>0,ep=ep/256>>>0;if(0!==ep)throw Error("Non-zero carry");es=eg,l++}if(" "!==c[l]){for(var eb=ec-es;eb!==ec&&0===el[eb];)eb++;for(var ey=new Uint8Array(eo+(ec-eb)),e_=eo;eb!==ec;)ey[e_++]=el[eb++];return ey}}}return{encode:function(l){if(l instanceof Uint8Array||(ArrayBuffer.isView(l)?l=new Uint8Array(l.buffer,l.byteOffset,l.byteLength):Array.isArray(l)&&(l=Uint8Array.from(l))),!(l instanceof Uint8Array))throw TypeError("Expected Uint8Array");if(0===l.length)return"";for(var et=0,eo=0,es=0,ec=l.length;es!==ec&&0===l[es];)es++,et++;for(var el=(ec-es)*ep+1>>>0,ef=new Uint8Array(el);es!==ec;){for(var eg=l[es],em=0,eb=el-1;(0!==eg||em>>0,ef[eb]=eg%ed>>>0,eg=eg/ed>>>0;if(0!==eg)throw Error("Non-zero carry");eo=em,es++}for(var ey=el-eo;ey!==el&&0===ef[ey];)ey++;for(var e_=eh.repeat(et);ey{if(c===l)return!0;if(c.byteLength!==l.byteLength)return!1;for(let et=0;et{if(c instanceof Uint8Array&&"Uint8Array"===c.constructor.name)return c;if(c instanceof ArrayBuffer)return new Uint8Array(c);if(ArrayBuffer.isView(c))return new Uint8Array(c.buffer,c.byteOffset,c.byteLength);throw Error("Unknown type, must be binary type")},bytes_fromString=c=>new TextEncoder().encode(c),bytes_toString=c=>new TextDecoder().decode(c);let Encoder=class Encoder{constructor(c,l,et){this.name=c,this.prefix=l,this.baseEncode=et}encode(c){if(c instanceof Uint8Array)return`${this.prefix}${this.baseEncode(c)}`;throw Error("Unknown type, must be binary type")}};let Decoder=class Decoder{constructor(c,l,et){if(this.name=c,this.prefix=l,void 0===l.codePointAt(0))throw Error("Invalid prefix character");this.prefixCodePoint=l.codePointAt(0),this.baseDecode=et}decode(c){if("string"==typeof c){if(c.codePointAt(0)!==this.prefixCodePoint)throw Error(`Unable to decode multibase string ${JSON.stringify(c)}, ${this.name} decoder only supports inputs prefixed with ${this.prefix}`);return this.baseDecode(c.slice(this.prefix.length))}throw Error("Can only multibase decode strings")}or(c){return or(this,c)}};let ComposedDecoder=class ComposedDecoder{constructor(c){this.decoders=c}or(c){return or(this,c)}decode(c){let l=c[0],et=this.decoders[l];if(et)return et.decode(c);throw RangeError(`Unable to decode multibase string ${JSON.stringify(c)}, only inputs prefixed with ${Object.keys(this.decoders)} are supported`)}};let or=(c,l)=>new ComposedDecoder({...c.decoders||{[c.prefix]:c},...l.decoders||{[l.prefix]:l}});let Codec=class Codec{constructor(c,l,et,eo){this.name=c,this.prefix=l,this.baseEncode=et,this.baseDecode=eo,this.encoder=new Encoder(c,l,et),this.decoder=new Decoder(c,l,eo)}encode(c){return this.encoder.encode(c)}decode(c){return this.decoder.decode(c)}};let from=({name:c,prefix:l,encode:et,decode:eo})=>new Codec(c,l,et,eo),baseX=({prefix:c,name:l,alphabet:et})=>{let{encode:eo,decode:es}=base_x(et,l);return from({prefix:c,name:l,encode:eo,decode:c=>coerce(es(c))})},decode=(c,l,et,eo)=>{let es={};for(let c=0;c=8&&(ed-=8,el[ef++]=255&eh>>ed)}if(ed>=et||255&eh<<8-ed)throw SyntaxError("Unexpected end of data");return el},encode=(c,l,et)=>{let eo="="===l[l.length-1],es=(1<et;)el-=et,ec+=l[es&ed>>el];if(el&&(ec+=l[es&ed<from({prefix:l,name:c,encode:c=>encode(c,eo,et),decode:l=>decode(l,eo,et,c)}),eP=from({prefix:"\x00",name:"identity",encode:c=>bytes_toString(c),decode:c=>bytes_fromString(c)}),eR=rfc4648({prefix:"0",name:"base2",alphabet:"01",bitsPerChar:1}),eO=rfc4648({prefix:"7",name:"base8",alphabet:"01234567",bitsPerChar:3}),eT=baseX({prefix:"9",name:"base10",alphabet:"0123456789"}),eN=rfc4648({prefix:"f",name:"base16",alphabet:"0123456789abcdef",bitsPerChar:4}),eM=rfc4648({prefix:"F",name:"base16upper",alphabet:"0123456789ABCDEF",bitsPerChar:4}),e$=rfc4648({prefix:"b",name:"base32",alphabet:"abcdefghijklmnopqrstuvwxyz234567",bitsPerChar:5}),eB=rfc4648({prefix:"B",name:"base32upper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",bitsPerChar:5}),eD=rfc4648({prefix:"c",name:"base32pad",alphabet:"abcdefghijklmnopqrstuvwxyz234567=",bitsPerChar:5}),ej=rfc4648({prefix:"C",name:"base32padupper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=",bitsPerChar:5}),eL=rfc4648({prefix:"v",name:"base32hex",alphabet:"0123456789abcdefghijklmnopqrstuv",bitsPerChar:5}),eF=rfc4648({prefix:"V",name:"base32hexupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",bitsPerChar:5}),eU=rfc4648({prefix:"t",name:"base32hexpad",alphabet:"0123456789abcdefghijklmnopqrstuv=",bitsPerChar:5}),ez=rfc4648({prefix:"T",name:"base32hexpadupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV=",bitsPerChar:5}),eH=rfc4648({prefix:"h",name:"base32z",alphabet:"ybndrfg8ejkmcpqxot1uwisza345h769",bitsPerChar:5}),eW=baseX({prefix:"k",name:"base36",alphabet:"0123456789abcdefghijklmnopqrstuvwxyz"}),eV=baseX({prefix:"K",name:"base36upper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"}),eG=baseX({name:"base58btc",prefix:"z",alphabet:"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"}),eK=baseX({name:"base58flickr",prefix:"Z",alphabet:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"}),eJ=rfc4648({prefix:"m",name:"base64",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bitsPerChar:6}),eQ=rfc4648({prefix:"M",name:"base64pad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",bitsPerChar:6}),eY=rfc4648({prefix:"u",name:"base64url",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_",bitsPerChar:6}),eZ=rfc4648({prefix:"U",name:"base64urlpad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_=",bitsPerChar:6}),eX=Array.from("\uD83D\uDE80\uD83E\uDE90☄\uD83D\uDEF0\uD83C\uDF0C\uD83C\uDF11\uD83C\uDF12\uD83C\uDF13\uD83C\uDF14\uD83C\uDF15\uD83C\uDF16\uD83C\uDF17\uD83C\uDF18\uD83C\uDF0D\uD83C\uDF0F\uD83C\uDF0E\uD83D\uDC09☀\uD83D\uDCBB\uD83D\uDDA5\uD83D\uDCBE\uD83D\uDCBF\uD83D\uDE02❤\uD83D\uDE0D\uD83E\uDD23\uD83D\uDE0A\uD83D\uDE4F\uD83D\uDC95\uD83D\uDE2D\uD83D\uDE18\uD83D\uDC4D\uD83D\uDE05\uD83D\uDC4F\uD83D\uDE01\uD83D\uDD25\uD83E\uDD70\uD83D\uDC94\uD83D\uDC96\uD83D\uDC99\uD83D\uDE22\uD83E\uDD14\uD83D\uDE06\uD83D\uDE44\uD83D\uDCAA\uD83D\uDE09☺\uD83D\uDC4C\uD83E\uDD17\uD83D\uDC9C\uD83D\uDE14\uD83D\uDE0E\uD83D\uDE07\uD83C\uDF39\uD83E\uDD26\uD83C\uDF89\uD83D\uDC9E✌✨\uD83E\uDD37\uD83D\uDE31\uD83D\uDE0C\uD83C\uDF38\uD83D\uDE4C\uD83D\uDE0B\uD83D\uDC97\uD83D\uDC9A\uD83D\uDE0F\uD83D\uDC9B\uD83D\uDE42\uD83D\uDC93\uD83E\uDD29\uD83D\uDE04\uD83D\uDE00\uD83D\uDDA4\uD83D\uDE03\uD83D\uDCAF\uD83D\uDE48\uD83D\uDC47\uD83C\uDFB6\uD83D\uDE12\uD83E\uDD2D❣\uD83D\uDE1C\uD83D\uDC8B\uD83D\uDC40\uD83D\uDE2A\uD83D\uDE11\uD83D\uDCA5\uD83D\uDE4B\uD83D\uDE1E\uD83D\uDE29\uD83D\uDE21\uD83E\uDD2A\uD83D\uDC4A\uD83E\uDD73\uD83D\uDE25\uD83E\uDD24\uD83D\uDC49\uD83D\uDC83\uD83D\uDE33✋\uD83D\uDE1A\uD83D\uDE1D\uD83D\uDE34\uD83C\uDF1F\uD83D\uDE2C\uD83D\uDE43\uD83C\uDF40\uD83C\uDF37\uD83D\uDE3B\uD83D\uDE13⭐✅\uD83E\uDD7A\uD83C\uDF08\uD83D\uDE08\uD83E\uDD18\uD83D\uDCA6✔\uD83D\uDE23\uD83C\uDFC3\uD83D\uDC90☹\uD83C\uDF8A\uD83D\uDC98\uD83D\uDE20☝\uD83D\uDE15\uD83C\uDF3A\uD83C\uDF82\uD83C\uDF3B\uD83D\uDE10\uD83D\uDD95\uD83D\uDC9D\uD83D\uDE4A\uD83D\uDE39\uD83D\uDDE3\uD83D\uDCAB\uD83D\uDC80\uD83D\uDC51\uD83C\uDFB5\uD83E\uDD1E\uD83D\uDE1B\uD83D\uDD34\uD83D\uDE24\uD83C\uDF3C\uD83D\uDE2B⚽\uD83E\uDD19☕\uD83C\uDFC6\uD83E\uDD2B\uD83D\uDC48\uD83D\uDE2E\uD83D\uDE46\uD83C\uDF7B\uD83C\uDF43\uD83D\uDC36\uD83D\uDC81\uD83D\uDE32\uD83C\uDF3F\uD83E\uDDE1\uD83C\uDF81⚡\uD83C\uDF1E\uD83C\uDF88❌✊\uD83D\uDC4B\uD83D\uDE30\uD83E\uDD28\uD83D\uDE36\uD83E\uDD1D\uD83D\uDEB6\uD83D\uDCB0\uD83C\uDF53\uD83D\uDCA2\uD83E\uDD1F\uD83D\uDE41\uD83D\uDEA8\uD83D\uDCA8\uD83E\uDD2C✈\uD83C\uDF80\uD83C\uDF7A\uD83E\uDD13\uD83D\uDE19\uD83D\uDC9F\uD83C\uDF31\uD83D\uDE16\uD83D\uDC76\uD83E\uDD74▶➡❓\uD83D\uDC8E\uD83D\uDCB8⬇\uD83D\uDE28\uD83C\uDF1A\uD83E\uDD8B\uD83D\uDE37\uD83D\uDD7A⚠\uD83D\uDE45\uD83D\uDE1F\uD83D\uDE35\uD83D\uDC4E\uD83E\uDD32\uD83E\uDD20\uD83E\uDD27\uD83D\uDCCC\uD83D\uDD35\uD83D\uDC85\uD83E\uDDD0\uD83D\uDC3E\uD83C\uDF52\uD83D\uDE17\uD83E\uDD11\uD83C\uDF0A\uD83E\uDD2F\uD83D\uDC37☎\uD83D\uDCA7\uD83D\uDE2F\uD83D\uDC86\uD83D\uDC46\uD83C\uDFA4\uD83D\uDE47\uD83C\uDF51❄\uD83C\uDF34\uD83D\uDCA3\uD83D\uDC38\uD83D\uDC8C\uD83D\uDCCD\uD83E\uDD40\uD83E\uDD22\uD83D\uDC45\uD83D\uDCA1\uD83D\uDCA9\uD83D\uDC50\uD83D\uDCF8\uD83D\uDC7B\uD83E\uDD10\uD83E\uDD2E\uD83C\uDFBC\uD83E\uDD75\uD83D\uDEA9\uD83C\uDF4E\uD83C\uDF4A\uD83D\uDC7C\uD83D\uDC8D\uD83D\uDCE3\uD83E\uDD42"),e0=eX.reduce((c,l,et)=>(c[et]=l,c),[]),e1=eX.reduce((c,l,et)=>(c[l.codePointAt(0)]=et,c),[]),e2=from({prefix:"\uD83D\uDE80",name:"base256emoji",encode:function(c){return c.reduce((c,l)=>c+=e0[l],"")},decode:function(c){let l=[];for(let et of c){let c=e1[et.codePointAt(0)];if(void 0===c)throw Error(`Non-base256emoji character: ${et}`);l.push(c)}return new Uint8Array(l)}});function varint_encode(c,l,et){l=l||[];for(var eo=et=et||0;c>=2147483648;)l[et++]=255&c|128,c/=128;for(;-128&c;)l[et++]=255&c|128,c>>>=7;return l[et]=0|c,varint_encode.bytes=et-eo+1,l}function read(c,l){var et,eo=0,l=l||0,es=0,ec=l,el=c.length;do{if(ec>=el)throw read.bytes=0,RangeError("Could not decode varint");et=c[ec++],eo+=es<28?(127&et)<=128);return read.bytes=ec-l,eo}var e3={encode:varint_encode,decode:read,encodingLength:function(c){return c<128?1:c<16384?2:c<2097152?3:c<268435456?4:c<34359738368?5:c<4398046511104?6:c<562949953421312?7:c<72057594037927940?8:c<0x7fffffffffffffff?9:10}};let src_varint_decode=(c,l=0)=>{let et=e3.decode(c,l);return[et,e3.decode.bytes]},encodeTo=(c,l,et=0)=>(e3.encode(c,l,et),l),encodingLength=c=>e3.encodingLength(c),create=(c,l)=>{let et=l.byteLength,eo=encodingLength(c),es=eo+encodingLength(et),ec=new Uint8Array(es+et);return encodeTo(c,ec,0),encodeTo(et,ec,eo),ec.set(l,es),new Digest(c,et,l,ec)},digest_decode=c=>{let l=coerce(c),[et,eo]=src_varint_decode(l),[es,ec]=src_varint_decode(l.subarray(eo)),el=l.subarray(eo+ec);if(el.byteLength!==es)throw Error("Incorrect length");return new Digest(et,es,el,l)},digest_equals=(c,l)=>c===l||c.code===l.code&&c.size===l.size&&equals(c.bytes,l.bytes);let Digest=class Digest{constructor(c,l,et,eo){this.code=c,this.size=l,this.digest=et,this.bytes=eo}};let hasher_from=({name:c,code:l,encode:et})=>new Hasher(c,l,et);let Hasher=class Hasher{constructor(c,l,et){this.name=c,this.code=l,this.encode=et}digest(c){if(c instanceof Uint8Array){let l=this.encode(c);return l instanceof Uint8Array?create(this.code,l):l.then(c=>create(this.code,c))}throw Error("Unknown type, must be binary type")}};let sha=c=>async l=>new Uint8Array(await crypto.subtle.digest(c,l)),e5=hasher_from({name:"sha2-256",code:18,encode:sha("SHA-256")}),e6=hasher_from({name:"sha2-512",code:19,encode:sha("SHA-512")}),e4={code:0,name:"identity",encode:coerce,digest:c=>create(0,coerce(c))},e8="raw",e9=85,raw_encode=c=>coerce(c),raw_decode=c=>coerce(c),e7=new TextEncoder,tn=new TextDecoder,to="json",ts=512,json_encode=c=>e7.encode(JSON.stringify(c)),json_decode=c=>JSON.parse(tn.decode(c));let CID=class CID{constructor(c,l,et,eo){this.code=l,this.version=c,this.multihash=et,this.bytes=eo,this.byteOffset=eo.byteOffset,this.byteLength=eo.byteLength,this.asCID=this,this._baseCache=new Map,Object.defineProperties(this,{byteOffset:th,byteLength:th,code:td,version:td,multihash:td,bytes:td,_baseCache:th,asCID:th})}toV0(){if(0===this.version)return this;{let{code:c,multihash:l}=this;if(c!==ta)throw Error("Cannot convert a non dag-pb CID to CIDv0");if(l.code!==tc)throw Error("Cannot convert non sha2-256 multihash CID to CIDv0");return CID.createV0(l)}}toV1(){switch(this.version){case 0:{let{code:c,digest:l}=this.multihash,et=create(c,l);return CID.createV1(this.code,et)}case 1:return this;default:throw Error(`Can not convert CID version ${this.version} to version 0. This is a bug please report`)}}equals(c){return c&&this.code===c.code&&this.version===c.version&&digest_equals(this.multihash,c.multihash)}toString(c){let{bytes:l,version:et,_baseCache:eo}=this;return 0===et?toStringV0(l,eo,c||eG.encoder):toStringV1(l,eo,c||e$.encoder)}toJSON(){return{code:this.code,version:this.version,hash:this.multihash.bytes}}get[Symbol.toStringTag](){return"CID"}[Symbol.for("nodejs.util.inspect.custom")](){return"CID("+this.toString()+")"}static isCID(c){return deprecate(/^0\.0/,tf),!!(c&&(c[tl]||c.asCID===c))}get toBaseEncodedString(){throw Error("Deprecated, use .toString()")}get codec(){throw Error('"codec" property is deprecated, use integer "code" property instead')}get buffer(){throw Error("Deprecated .buffer property, use .bytes to get Uint8Array instead")}get multibaseName(){throw Error('"multibaseName" property is deprecated')}get prefix(){throw Error('"prefix" property is deprecated')}static asCID(c){if(c instanceof CID)return c;if(null!=c&&c.asCID===c){let{version:l,code:et,multihash:eo,bytes:es}=c;return new CID(l,et,eo,es||encodeCID(l,et,eo.bytes))}if(null==c||!0!==c[tl])return null;{let{version:l,multihash:et,code:eo}=c,es=digest_decode(et);return CID.create(l,eo,es)}}static create(c,l,et){if("number"!=typeof l)throw Error("String codecs are no longer supported");switch(c){case 0:if(l===ta)return new CID(c,l,et,et.bytes);throw Error(`Version 0 CID must use dag-pb (code: ${ta}) block encoding`);case 1:{let eo=encodeCID(c,l,et.bytes);return new CID(c,l,et,eo)}default:throw Error("Invalid version")}}static createV0(c){return CID.create(0,ta,c)}static createV1(c,l){return CID.create(1,c,l)}static decode(c){let[l,et]=CID.decodeFirst(c);if(et.length)throw Error("Incorrect length");return l}static decodeFirst(c){let l=CID.inspectBytes(c),et=l.size-l.multihashSize,eo=coerce(c.subarray(et,et+l.multihashSize));if(eo.byteLength!==l.multihashSize)throw Error("Incorrect length");let es=eo.subarray(l.multihashSize-l.digestSize),ec=new Digest(l.multihashCode,l.digestSize,es,eo),el=0===l.version?CID.createV0(ec):CID.createV1(l.codec,ec);return[el,c.subarray(l.size)]}static inspectBytes(c){let l=0,next=()=>{let[et,eo]=src_varint_decode(c.subarray(l));return l+=eo,et},et=next(),eo=ta;if(18===et?(et=0,l=0):1===et&&(eo=next()),0!==et&&1!==et)throw RangeError(`Invalid CID version ${et}`);let es=l,ec=next(),el=next(),ed=l+el;return{version:et,codec:eo,multihashCode:ec,digestSize:el,multihashSize:ed-es,size:ed}}static parse(c,l){let[et,eo]=parseCIDtoBytes(c,l),es=CID.decode(eo);return es._baseCache.set(et,c),es}};let parseCIDtoBytes=(c,l)=>{switch(c[0]){case"Q":return[eG.prefix,(l||eG).decode(`${eG.prefix}${c}`)];case eG.prefix:return[eG.prefix,(l||eG).decode(c)];case e$.prefix:return[e$.prefix,(l||e$).decode(c)];default:if(null==l)throw Error("To parse non base32 or base58btc encoded CID multibase decoder must be provided");return[c[0],l.decode(c)]}},toStringV0=(c,l,et)=>{let{prefix:eo}=et;if(eo!==eG.prefix)throw Error(`Cannot string encode V0 in ${et.name} encoding`);let es=l.get(eo);if(null!=es)return es;{let es=et.encode(c).slice(1);return l.set(eo,es),es}},toStringV1=(c,l,et)=>{let{prefix:eo}=et,es=l.get(eo);if(null!=es)return es;{let es=et.encode(c);return l.set(eo,es),es}},ta=112,tc=18,encodeCID=(c,l,et)=>{let eo=encodingLength(c),es=eo+encodingLength(l),ec=new Uint8Array(es+et.byteLength);return encodeTo(c,ec,0),encodeTo(l,ec,eo),ec.set(et,es),ec},tl=Symbol.for("@ipld/js-cid/CID"),td={writable:!1,configurable:!1,enumerable:!0},th={writable:!1,enumerable:!1,configurable:!1},deprecate=(c,l)=>{if(c.test("0.0.0-dev"))console.warn(l);else throw Error(l)},tf=`CID.isCID(v) is deprecated and will be removed in the next major release. +Following code pattern: + +if (CID.isCID(value)) { + doSomethingWithCID(value) +} + +Is replaced with: + +const cid = CID.asCID(value) +if (cid) { + // Make sure to use cid instead of value + doSomethingWithCID(cid) +} +`,tp={...eo,...es,...ec,...el,...ed,...eh,...ef,...ep,...eg,...em};function createCodec(c,l,et,eo){return{name:c,prefix:l,encoder:{name:c,prefix:l,encode:et},decoder:{decode:eo}}}({...eb,...ey});let tg=createCodec("utf8","u",c=>{let l=new TextDecoder("utf8");return"u"+l.decode(c)},c=>{let l=new TextEncoder;return l.encode(c.substring(1))}),tm=createCodec("ascii","a",c=>{let l="a";for(let et=0;et{c=c.substring(1);let l=allocUnsafe(c.length);for(let et=0;ettypeof l)||!c.length||c.every(l))}var tx=et(1426),tk=et(63943),tC=et(72058),tA=et(95097);let n=class n extends tA.q{constructor(c){super(),this.opts=c,this.protocol="wc",this.version=2}};let index_es_h=class index_es_h extends tA.q{constructor(c,l){super(),this.core=c,this.logger=l,this.records=new Map}};let a=class a{constructor(c,l){this.logger=c,this.core=l}};let u=class u extends tA.q{constructor(c,l){super(),this.relayer=c,this.logger=l}};let index_es_g=class index_es_g extends tA.q{constructor(c){super()}};let index_es_p=class index_es_p{constructor(c,l,et,eo){this.core=c,this.logger=l,this.name=et}};let d=class d extends tA.q{constructor(c,l){super(),this.relayer=c,this.logger=l}};let index_es_E=class index_es_E extends tA.q{constructor(c,l){super(),this.core=c,this.logger=l}};let y=class y{constructor(c,l){this.projectId=c,this.logger=l}};let b=class b{constructor(c){this.opts=c,this.protocol="wc",this.version=2}};let index_es_S=class index_es_S{constructor(c){this.client=c}};let JSONStringify=c=>JSON.stringify(c,(c,l)=>"bigint"==typeof l?l.toString()+"n":l),JSONParse=c=>{let l=c.replace(/([\[:])?(\d{17,}|(?:[9](?:[1-9]07199254740991|0[1-9]7199254740991|00[8-9]199254740991|007[2-9]99254740991|007199[3-9]54740991|0071992[6-9]4740991|00719925[5-9]740991|007199254[8-9]40991|0071992547[5-9]0991|00719925474[1-9]991|00719925474099[2-9])))([,\}\]])/g,'$1"$2n"$3');return JSON.parse(l,(c,l)=>{let et="string"==typeof l&&l.match(/^\d+n$/);return et?BigInt(l.substring(0,l.length-1)):l})};function esm_safeJsonParse(c){if("string"!=typeof c)throw Error(`Cannot safe json parse value of type ${typeof c}`);try{return JSONParse(c)}catch(l){return c}}function safeJsonStringify(c){return"string"==typeof c?c:JSONStringify(c)||""}var tI=et(80237);let tP="base64url",tR="base58btc";function encodeJSON(c){return to_string_toString(from_string_fromString(safeJsonStringify(c),"utf8"),tP)}function encodeIss(c){let l=from_string_fromString("K36",tR),et="z"+to_string_toString(concat([l,c]),tR);return["did","key",et].join(":")}function generateKeyPair(c=(0,eC.randomBytes)(32)){return tI._w(c)}async function signJWT(c,l,et,eo,es=(0,ty.fromMiliseconds)(Date.now())){var ec,el;let ed={alg:"EdDSA",typ:"JWT"},eh=encodeIss(eo.publicKey),ef={iss:eh,sub:c,aud:l,iat:es,exp:es+et},ep=from_string_fromString([encodeJSON((ec={header:ed,payload:ef}).header),encodeJSON(ec.payload)].join("."),"utf8"),eg=tI.Xx(eo.secretKey,ep);return[encodeJSON((el={header:ed,payload:ef,signature:eg}).header),encodeJSON(el.payload),to_string_toString(el.signature,tP)].join(".")}et(69859);var tO=et(25566),__spreadArray=function(c,l,et){if(et||2==arguments.length)for(var eo,es=0,ec=l.length;es"u")throw Error("missing sender public key");if(typeof c?.receiverPublicKey>"u")throw Error("missing receiver public key")}return{type:l,senderPublicKey:c?.senderPublicKey,receiverPublicKey:c?.receiverPublicKey}}function index_es_Fn(c){return 1===c.type&&"string"==typeof c.senderPublicKey&&"string"==typeof c.receiverPublicKey}var tU=Object.defineProperty,tz=Object.getOwnPropertySymbols,tq=Object.prototype.hasOwnProperty,tH=Object.prototype.propertyIsEnumerable,index_es_Ue=(c,l,et)=>l in c?tU(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,index_es_e=(c,l)=>{for(var et in l||(l={}))tq.call(l,et)&&index_es_Ue(c,et,l[et]);if(tz)for(var et of tz(l))tH.call(l,et)&&index_es_Ue(c,et,l[et]);return c};let tW={reactNative:"react-native",node:"node",browser:"browser",unknown:"unknown"};function index_es_te(){return"u">typeof tB&&"u">typeof tB.versions&&"u">typeof tB.versions.node}function index_es_j(){return!(0,t_.getDocument)()&&!!(0,t_.getNavigator)()&&"ReactNative"===navigator.product}function index_es_q(){return!index_es_te()&&!!(0,t_.getNavigator)()}function index_es_R(){return index_es_j()?tW.reactNative:index_es_te()?tW.node:index_es_q()?tW.browser:tW.unknown}function index_es_O(c,l){return c.filter(c=>l.includes(c)).length===c.length}function index_es_et(c){return Object.fromEntries(c.entries())}function index_es_nt(c){return new Map(Object.entries(c))}function index_es_st(c=ty.FIVE_MINUTES,l){let et,eo,es;let ec=(0,ty.toMiliseconds)(c||ty.FIVE_MINUTES);return{resolve:c=>{es&&et&&(clearTimeout(es),et(c))},reject:c=>{es&&eo&&(clearTimeout(es),eo(c))},done:()=>new Promise((c,el)=>{es=setTimeout(()=>{el(Error(l))},ec),et=c,eo=el})}}function index_es_it(c,l,et){return new Promise(async(eo,es)=>{let ec=setTimeout(()=>es(Error(et)),l);try{let l=await c;eo(l)}catch(c){es(c)}clearTimeout(ec)})}function index_es_re(c,l){if("string"==typeof l&&l.startsWith(`${c}:`))return l;if("topic"===c.toLowerCase()){if("string"!=typeof l)throw Error('Value must be "string" for expirer target type: topic');return`topic:${l}`}if("id"===c.toLowerCase()){if("number"!=typeof l)throw Error('Value must be "number" for expirer target type: id');return`id:${l}`}throw Error(`Unknown expirer target type: ${c}`)}function index_es_ut(c){let[l,et]=c.split(":"),eo={id:void 0,topic:void 0};if("topic"===l&&"string"==typeof et)eo.topic=et;else if("id"===l&&Number.isInteger(Number(et)))eo.id=Number(et);else throw Error(`Invalid target, expected id:number or topic:string, got ${l}:${et}`);return eo}function index_es_lt(c,l){return(0,ty.fromMiliseconds)((l||Date.now())+(0,ty.toMiliseconds)(c))}function index_es_dt(c){return Date.now()>=(0,ty.toMiliseconds)(c)}function index_es_ft(c,l){return`${c}${l?`:${l}`:""}`}function dist_index_es_S(c=[],l=[]){return[...new Set([...c,...l])]}async function index_es_pt({id:c,topic:l,wcDeepLink:eo}){try{if(!eo)return;let es="string"==typeof eo?JSON.parse(eo):eo,ec=es?.href;if("string"!=typeof ec)return;ec.endsWith("/")&&(ec=ec.slice(0,-1));let el=`${ec}/wc?requestId=${c}&sessionTopic=${l}`,ed=index_es_R();ed===tW.browser?el.startsWith("https://")?window.open(el,"_blank","noreferrer noopener"):window.open(el,"_self","noreferrer noopener"):ed===tW.reactNative&&"u">typeof(null==et.g?void 0:et.g.Linking)&&await et.g.Linking.openURL(el)}catch(c){console.error(c)}}function index_es_mt(c){return c?.relay||{protocol:"irn"}}function index_es_yt(c){let l=tE[c];if(typeof l>"u")throw Error(`Relay Protocol not supported: ${c}`);return l}var tV=Object.defineProperty,tG=Object.getOwnPropertySymbols,tK=Object.prototype.hasOwnProperty,tJ=Object.prototype.propertyIsEnumerable,index_es_qe=(c,l,et)=>l in c?tV(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,index_es_Et=(c,l)=>{for(var et in l||(l={}))tK.call(l,et)&&index_es_qe(c,et,l[et]);if(tG)for(var et of tG(l))tJ.call(l,et)&&index_es_qe(c,et,l[et]);return c};function index_es_A(c){let l=[];return c.forEach(c=>{let[et,eo]=c.split(":");l.push(`${et}:${eo}`)}),l}function index_es_oe(c){return c.includes(":")}function index_es_Xe(c){return index_es_oe(c)?c.split(":")[0]:c}Object.prototype.hasOwnProperty,Object.prototype.propertyIsEnumerable;let tQ={INVALID_METHOD:{message:"Invalid method.",code:1001},INVALID_EVENT:{message:"Invalid event.",code:1002},INVALID_UPDATE_REQUEST:{message:"Invalid update request.",code:1003},INVALID_EXTEND_REQUEST:{message:"Invalid extend request.",code:1004},INVALID_SESSION_SETTLE_REQUEST:{message:"Invalid session settle request.",code:1005},UNAUTHORIZED_METHOD:{message:"Unauthorized method.",code:3001},UNAUTHORIZED_EVENT:{message:"Unauthorized event.",code:3002},UNAUTHORIZED_UPDATE_REQUEST:{message:"Unauthorized update request.",code:3003},UNAUTHORIZED_EXTEND_REQUEST:{message:"Unauthorized extend request.",code:3004},USER_REJECTED:{message:"User rejected.",code:5e3},USER_REJECTED_CHAINS:{message:"User rejected chains.",code:5001},USER_REJECTED_METHODS:{message:"User rejected methods.",code:5002},USER_REJECTED_EVENTS:{message:"User rejected events.",code:5003},UNSUPPORTED_CHAINS:{message:"Unsupported chains.",code:5100},UNSUPPORTED_METHODS:{message:"Unsupported methods.",code:5101},UNSUPPORTED_EVENTS:{message:"Unsupported events.",code:5102},UNSUPPORTED_ACCOUNTS:{message:"Unsupported accounts.",code:5103},UNSUPPORTED_NAMESPACE_KEY:{message:"Unsupported namespace key.",code:5104},USER_DISCONNECTED:{message:"User disconnected.",code:6e3},SESSION_SETTLEMENT_FAILED:{message:"Session settlement failed.",code:7e3},WC_METHOD_UNSUPPORTED:{message:"Unsupported wc_ method.",code:10001}},tY={NOT_INITIALIZED:{message:"Not initialized.",code:1},NO_MATCHING_KEY:{message:"No matching key.",code:2},RESTORE_WILL_OVERRIDE:{message:"Restore will override.",code:3},RESUBSCRIBED:{message:"Resubscribed.",code:4},MISSING_OR_INVALID:{message:"Missing or invalid.",code:5},EXPIRED:{message:"Expired.",code:6},UNKNOWN_TYPE:{message:"Unknown type.",code:7},MISMATCHED_TOPIC:{message:"Mismatched topic.",code:8},NON_CONFORMING_NAMESPACES:{message:"Non conforming namespaces.",code:9}};function index_es_N(c,l){let{message:et,code:eo}=tY[c];return{message:l?`${et} ${l}`:et,code:eo}}function index_es_U(c,l){let{message:et,code:eo}=tQ[c];return{message:l?`${et} ${l}`:et,code:eo}}function index_es_D(c,l){return!!Array.isArray(c)&&(!("u">typeof l)||!c.length||c.every(l))}function index_es_B(c){return Object.getPrototypeOf(c)===Object.prototype&&Object.keys(c).length}function index_es_w(c){return typeof c>"u"}function dist_index_es_h(c,l){return!!(l&&index_es_w(c))||"string"==typeof c&&!!c.trim().length}function index_es_G(c,l){return!!(l&&index_es_w(c))||"number"==typeof c&&!isNaN(c)}function index_es_k(c){return!!(dist_index_es_h(c,!1)&&c.includes(":"))&&2===c.split(":").length}function index_es_ie(c){let l=!0;return index_es_D(c)?c.length&&(l=c.every(c=>dist_index_es_h(c,!1))):l=!1,l}function index_es_ce(c,l){let et=null;return Object.values(c).forEach(c=>{var eo;let es;if(et)return;let ec=(eo=`${l}, namespace`,es=null,index_es_ie(c?.methods)?index_es_ie(c?.events)||(es=index_es_U("UNSUPPORTED_EVENTS",`${eo}, events should be an array of strings or empty array for no events`)):es=index_es_U("UNSUPPORTED_METHODS",`${eo}, methods should be an array of strings or empty array for no methods`),es);ec&&(et=ec)}),et}function index_es_cn(c,l){let et=null;if(c&&index_es_B(c)){let eo;let es=index_es_ce(c,l);es&&(et=es);let ec=(eo=null,Object.values(c).forEach(c=>{var et,es;let ec;if(eo)return;let el=(et=c?.accounts,es=`${l} namespace`,ec=null,index_es_D(et)?et.forEach(c=>{ec||function(c){if(dist_index_es_h(c,!1)&&c.includes(":")){let l=c.split(":");if(3===l.length){let c=l[0]+":"+l[1];return!!l[2]&&index_es_k(c)}}return!1}(c)||(ec=index_es_U("UNSUPPORTED_ACCOUNTS",`${es}, account ${c} should be a string and conform to "namespace:chainId:address" format`))}):ec=index_es_U("UNSUPPORTED_ACCOUNTS",`${es}, accounts should be an array of strings conforming to "namespace:chainId:address" format`),ec);el&&(eo=el)}),eo);ec&&(et=ec)}else et=index_es_N("MISSING_OR_INVALID",`${l}, namespaces should be an object with data`);return et}function index_es_an(c){return dist_index_es_h(c.protocol,!0)}function index_es_xt(c){return"u">typeof c}function index_es_Gt(c,l){return!(!index_es_k(l)||!(function(c){let l=[];return Object.values(c).forEach(c=>{l.push(...index_es_A(c.accounts))}),l})(c).includes(l))}function index_es_un(c,l,et){let eo=null,es=function(c){let l={};return Object.keys(c).forEach(et=>{var eo;et.includes(":")?l[et]=c[et]:null==(eo=c[et].chains)||eo.forEach(eo=>{l[eo]={methods:c[et].methods,events:c[et].events}})}),l}(c),ec=function(c){let l={};return Object.keys(c).forEach(et=>{if(et.includes(":"))l[et]=c[et];else{let eo=index_es_A(c[et].accounts);eo?.forEach(eo=>{l[eo]={accounts:c[et].accounts.filter(c=>c.includes(`${eo}:`)),methods:c[et].methods,events:c[et].events}})}}),l}(l),el=Object.keys(es),ed=Object.keys(ec),eh=index_es_ln(Object.keys(c)),ef=index_es_ln(Object.keys(l)),ep=eh.filter(c=>!ef.includes(c));return ep.length&&(eo=index_es_N("NON_CONFORMING_NAMESPACES",`${et} namespaces keys don't satisfy requiredNamespaces. + Required: ${ep.toString()} + Received: ${Object.keys(l).toString()}`)),index_es_O(el,ed)||(eo=index_es_N("NON_CONFORMING_NAMESPACES",`${et} namespaces chains don't satisfy required namespaces. + Required: ${el.toString()} + Approved: ${ed.toString()}`)),Object.keys(l).forEach(c=>{if(!c.includes(":")||eo)return;let es=index_es_A(l[c].accounts);es.includes(c)||(eo=index_es_N("NON_CONFORMING_NAMESPACES",`${et} namespaces accounts don't satisfy namespace accounts for ${c} + Required: ${c} + Approved: ${es.toString()}`))}),el.forEach(c=>{eo||(index_es_O(es[c].methods,ec[c].methods)?index_es_O(es[c].events,ec[c].events)||(eo=index_es_N("NON_CONFORMING_NAMESPACES",`${et} namespaces events don't satisfy namespace events for ${c}`)):eo=index_es_N("NON_CONFORMING_NAMESPACES",`${et} namespaces methods don't satisfy namespace methods for ${c}`))}),eo}function index_es_ln(c){return[...new Set(c.map(c=>c.includes(":")?c.split(":")[0]:c))]}function index_es_Zt(){let c=index_es_R();return new Promise(l=>{switch(c){case tW.browser:l(index_es_q()&&navigator?.onLine);break;case tW.reactNative:l(index_es_fn());break;case tW.node:default:l(!0)}})}async function index_es_fn(){if(index_es_j()&&"u">typeof et.g&&null!=et.g&&et.g.NetInfo){let c=await (null==et.g?void 0:et.g.NetInfo.fetch());return c?.isConnected}return!0}let tZ={};let index_es_er=class index_es_er{static get(c){return tZ[c]}static set(c,l){tZ[c]=l}static delete(c){delete tZ[c]}};let tX="INTERNAL_ERROR",t0="SERVER_ERROR",t1=[-32700,-32600,-32601,-32602,-32603],t2={PARSE_ERROR:{code:-32700,message:"Parse error"},INVALID_REQUEST:{code:-32600,message:"Invalid Request"},METHOD_NOT_FOUND:{code:-32601,message:"Method not found"},INVALID_PARAMS:{code:-32602,message:"Invalid params"},[tX]:{code:-32603,message:"Internal error"},[t0]:{code:-32e3,message:"Server error"}};function getError(c){return Object.keys(t2).includes(c)?t2[c]:t2[t0]}function parseConnectionError(c,l,et){return c.message.includes("getaddrinfo ENOTFOUND")||c.message.includes("connect ECONNREFUSED")?Error(`Unavailable ${et} RPC url at ${l}`):c}var t3=et(36014);function payloadId(c=3){let l=Date.now()*Math.pow(10,c),et=Math.floor(Math.random()*Math.pow(10,c));return l+et}function getBigIntRpcId(c=6){return BigInt(payloadId(c))}function formatJsonRpcRequest(c,l,et){return{id:et||payloadId(),jsonrpc:"2.0",method:c,params:l}}function formatJsonRpcResult(c,l){return{id:c,jsonrpc:"2.0",result:l}}function formatJsonRpcError(c,l,et){var eo,es;return{id:c,jsonrpc:"2.0",error:void 0===(eo=l)?getError(tX):("string"==typeof eo&&(eo=Object.assign(Object.assign({},getError(t0)),{message:eo})),void 0!==et&&(eo.data=et),es=eo.code,t1.includes(es)&&(eo=function(c){let l=Object.values(t2).find(l=>l.code===c);return l||t2[t0]}(eo.code)),eo)}}let misc_IEvents=class misc_IEvents{};let IBaseJsonRpcProvider=class IBaseJsonRpcProvider extends misc_IEvents{constructor(){super()}};let IJsonRpcProvider=class IJsonRpcProvider extends IBaseJsonRpcProvider{constructor(c){super()}};function matchRegexProtocol(c,l){let et=function(c){let l=c.match(RegExp(/^\w+:/,"gi"));if(l&&l.length)return l[0]}(c);return void 0!==et&&new RegExp(l).test(et)}function isHttpUrl(c){return matchRegexProtocol(c,"^https?:")}function isWsUrl(c){return matchRegexProtocol(c,"^wss?:")}function isJsonRpcPayload(c){return"object"==typeof c&&"id"in c&&"jsonrpc"in c&&"2.0"===c.jsonrpc}function isJsonRpcRequest(c){return isJsonRpcPayload(c)&&"method"in c}function isJsonRpcResponse(c){return isJsonRpcPayload(c)&&(isJsonRpcResult(c)||isJsonRpcError(c))}function isJsonRpcResult(c){return"result"in c}function isJsonRpcError(c){return"error"in c}let JsonRpcProvider=class JsonRpcProvider extends IJsonRpcProvider{constructor(c){super(c),this.events=new eE.EventEmitter,this.hasRegisteredEventListeners=!1,this.connection=this.setConnection(c),this.connection.connected&&this.registerEventListeners()}async connect(c=this.connection){await this.open(c)}async disconnect(){await this.close()}on(c,l){this.events.on(c,l)}once(c,l){this.events.once(c,l)}off(c,l){this.events.off(c,l)}removeListener(c,l){this.events.removeListener(c,l)}async request(c,l){return this.requestStrict(formatJsonRpcRequest(c.method,c.params||[],c.id||getBigIntRpcId().toString()),l)}async requestStrict(c,l){return new Promise(async(et,eo)=>{if(!this.connection.connected)try{await this.open()}catch(c){eo(c)}this.events.on(`${c.id}`,c=>{isJsonRpcError(c)?eo(c.error):et(c.result)});try{await this.connection.send(c,l)}catch(c){eo(c)}})}setConnection(c=this.connection){return c}onPayload(c){this.events.emit("payload",c),isJsonRpcResponse(c)?this.events.emit(`${c.id}`,c):this.events.emit("message",{type:c.method,data:c.params})}onClose(c){c&&3e3===c.code&&this.events.emit("error",Error(`WebSocket connection closed abnormally with code: ${c.code} ${c.reason?`(${c.reason})`:""}`)),this.events.emit("disconnect")}async open(c=this.connection){this.connection===c&&this.connection.connected||(this.connection.connected&&this.close(),"string"==typeof c&&(await this.connection.open(c),c=this.connection),this.connection=this.setConnection(c),await this.connection.open(),this.registerEventListeners(),this.events.emit("connect"))}async close(){await this.connection.close()}registerEventListeners(){this.hasRegisteredEventListeners||(this.connection.on("payload",c=>this.onPayload(c)),this.connection.on("close",c=>this.onClose(c)),this.connection.on("error",c=>this.events.emit("error",c)),this.connection.on("register_error",c=>this.onClose()),this.hasRegisteredEventListeners=!0)}};let hasBuiltInWebSocket=()=>"undefined"!=typeof WebSocket||void 0!==et.g&&void 0!==et.g.WebSocket||"undefined"!=typeof window&&void 0!==window.WebSocket||"undefined"!=typeof self&&void 0!==self.WebSocket,truncateQuery=c=>c.split("?")[0],t5="undefined"!=typeof WebSocket?WebSocket:void 0!==et.g&&void 0!==et.g.WebSocket?et.g.WebSocket:"undefined"!=typeof window&&void 0!==window.WebSocket?window.WebSocket:"undefined"!=typeof self&&void 0!==self.WebSocket?self.WebSocket:et(91656);var t6=class{constructor(c){if(this.url=c,this.events=new eE.EventEmitter,this.registering=!1,!isWsUrl(c))throw Error(`Provided URL is not compatible with WebSocket connection: ${c}`);this.url=c}get connected(){return void 0!==this.socket}get connecting(){return this.registering}on(c,l){this.events.on(c,l)}once(c,l){this.events.once(c,l)}off(c,l){this.events.off(c,l)}removeListener(c,l){this.events.removeListener(c,l)}async open(c=this.url){await this.register(c)}async close(){return new Promise((c,l)=>{if(void 0===this.socket){l(Error("Connection already closed"));return}this.socket.onclose=l=>{this.onClose(l),c()},this.socket.close()})}async send(c,l){void 0===this.socket&&(this.socket=await this.register());try{this.socket.send(safeJsonStringify(c))}catch(l){this.onError(c.id,l)}}register(c=this.url){if(!isWsUrl(c))throw Error(`Provided URL is not compatible with WebSocket connection: ${c}`);if(this.registering){let c=this.events.getMaxListeners();return(this.events.listenerCount("register_error")>=c||this.events.listenerCount("open")>=c)&&this.events.setMaxListeners(c+1),new Promise((c,l)=>{this.events.once("register_error",c=>{this.resetMaxListeners(),l(c)}),this.events.once("open",()=>{if(this.resetMaxListeners(),void 0===this.socket)return l(Error("WebSocket connection is missing or invalid"));c(this.socket)})})}return this.url=c,this.registering=!0,new Promise((l,et)=>{let eo=(0,t3.isReactNative)()?void 0:{rejectUnauthorized:!RegExp("wss?://localhost(:d{2,5})?").test(c)},es=new t5(c,[],eo);hasBuiltInWebSocket()?es.onerror=c=>{et(this.emitError(c.error))}:es.on("error",c=>{et(this.emitError(c))}),es.onopen=()=>{this.onOpen(es),l(es)}})}onOpen(c){c.onmessage=c=>this.onPayload(c),c.onclose=c=>this.onClose(c),this.socket=c,this.registering=!1,this.events.emit("open")}onClose(c){this.socket=void 0,this.registering=!1,this.events.emit("close",c)}onPayload(c){if(void 0===c.data)return;let l="string"==typeof c.data?esm_safeJsonParse(c.data):c.data;this.events.emit("payload",l)}onError(c,l){let et=this.parseError(l),eo=et.message||et.toString(),es=formatJsonRpcError(c,eo);this.events.emit("payload",es)}parseError(c,l=this.url){return parseConnectionError(c,truncateQuery(l),"WS")}resetMaxListeners(){this.events.getMaxListeners()>10&&this.events.setMaxListeners(10)}emitError(c){let l=this.parseError(Error((null==c?void 0:c.message)||`WebSocket connection failed for host: ${truncateQuery(this.url)}`));return this.events.emit("register_error",l),l}},t4=et(99780),t8=et.n(t4),t9=et(25566),Vi=function(c,l){if(c.length>=255)throw TypeError("Alphabet too long");for(var et=new Uint8Array(256),eo=0;eo>>0,el=new Uint8Array(ec);c[l];){var ep=et[c.charCodeAt(l)];if(255===ep)return;for(var eg=0,em=ec-1;(0!==ep||eg>>0,el[em]=ep%256>>>0,ep=ep/256>>>0;if(0!==ep)throw Error("Non-zero carry");es=eg,l++}if(" "!==c[l]){for(var eb=ec-es;eb!==ec&&0===el[eb];)eb++;for(var ey=new Uint8Array(eo+(ec-eb)),e_=eo;eb!==ec;)ey[e_++]=el[eb++];return ey}}}return{encode:function(l){if(l instanceof Uint8Array||(ArrayBuffer.isView(l)?l=new Uint8Array(l.buffer,l.byteOffset,l.byteLength):Array.isArray(l)&&(l=Uint8Array.from(l))),!(l instanceof Uint8Array))throw TypeError("Expected Uint8Array");if(0===l.length)return"";for(var et=0,eo=0,es=0,ec=l.length;es!==ec&&0===l[es];)es++,et++;for(var el=(ec-es)*ep+1>>>0,ef=new Uint8Array(el);es!==ec;){for(var eg=l[es],em=0,eb=el-1;(0!==eg||em>>0,ef[eb]=eg%ed>>>0,eg=eg/ed>>>0;if(0!==eg)throw Error("Non-zero carry");eo=em,es++}for(var ey=el-eo;ey!==el&&0===ef[ey];)ey++;for(var e_=eh.repeat(et);ey{if(c instanceof Uint8Array&&"Uint8Array"===c.constructor.name)return c;if(c instanceof ArrayBuffer)return new Uint8Array(c);if(ArrayBuffer.isView(c))return new Uint8Array(c.buffer,c.byteOffset,c.byteLength);throw Error("Unknown type, must be binary type")},qi=c=>new TextEncoder().encode(c),ji=c=>new TextDecoder().decode(c);let Yi=class Yi{constructor(c,l,et){this.name=c,this.prefix=l,this.baseEncode=et}encode(c){if(c instanceof Uint8Array)return`${this.prefix}${this.baseEncode(c)}`;throw Error("Unknown type, must be binary type")}};let Gi=class Gi{constructor(c,l,et){if(this.name=c,this.prefix=l,void 0===l.codePointAt(0))throw Error("Invalid prefix character");this.prefixCodePoint=l.codePointAt(0),this.baseDecode=et}decode(c){if("string"==typeof c){if(c.codePointAt(0)!==this.prefixCodePoint)throw Error(`Unable to decode multibase string ${JSON.stringify(c)}, ${this.name} decoder only supports inputs prefixed with ${this.prefix}`);return this.baseDecode(c.slice(this.prefix.length))}throw Error("Can only multibase decode strings")}or(c){return dist_index_es_Ne(this,c)}};let Hi=class Hi{constructor(c){this.decoders=c}or(c){return dist_index_es_Ne(this,c)}decode(c){let l=c[0],et=this.decoders[l];if(et)return et.decode(c);throw RangeError(`Unable to decode multibase string ${JSON.stringify(c)}, only inputs prefixed with ${Object.keys(this.decoders)} are supported`)}};let dist_index_es_Ne=(c,l)=>new Hi({...c.decoders||{[c.prefix]:c},...l.decoders||{[l.prefix]:l}});let Ji=class Ji{constructor(c,l,et,eo){this.name=c,this.prefix=l,this.baseEncode=et,this.baseDecode=eo,this.encoder=new Yi(c,l,et),this.decoder=new Gi(c,l,eo)}encode(c){return this.encoder.encode(c)}decode(c){return this.decoder.decode(c)}};let index_es_W=({name:c,prefix:l,encode:et,decode:eo})=>new Ji(c,l,et,eo),dist_index_es_K=({prefix:c,name:l,alphabet:et})=>{let{encode:eo,decode:es}=Vi(et,l);return index_es_W({prefix:c,name:l,encode:eo,decode:c=>dist_index_es_ze(es(c))})},Wi=(c,l,et,eo)=>{let es={};for(let c=0;c=8&&(ed-=8,el[ef++]=255&eh>>ed)}if(ed>=et||255&eh<<8-ed)throw SyntaxError("Unexpected end of data");return el},Xi=(c,l,et)=>{let eo="="===l[l.length-1],es=(1<et;)el-=et,ec+=l[es&ed>>el];if(el&&(ec+=l[es&ed<index_es_W({prefix:l,name:c,encode:c=>Xi(c,eo,et),decode:l=>Wi(l,eo,et,c)}),t7=index_es_W({prefix:"\x00",name:"identity",encode:c=>ji(c),decode:c=>qi(c)});var re=Object.freeze({__proto__:null,identity:t7});let rt=dist_index_es_g({prefix:"0",name:"base2",alphabet:"01",bitsPerChar:1});var ro=Object.freeze({__proto__:null,base2:rt});let rs=dist_index_es_g({prefix:"7",name:"base8",alphabet:"01234567",bitsPerChar:3});var ra=Object.freeze({__proto__:null,base8:rs});let rc=dist_index_es_K({prefix:"9",name:"base10",alphabet:"0123456789"});var rl=Object.freeze({__proto__:null,base10:rc});let rd=dist_index_es_g({prefix:"f",name:"base16",alphabet:"0123456789abcdef",bitsPerChar:4}),rh=dist_index_es_g({prefix:"F",name:"base16upper",alphabet:"0123456789ABCDEF",bitsPerChar:4});var rp=Object.freeze({__proto__:null,base16:rd,base16upper:rh});let rg=dist_index_es_g({prefix:"b",name:"base32",alphabet:"abcdefghijklmnopqrstuvwxyz234567",bitsPerChar:5}),rm=dist_index_es_g({prefix:"B",name:"base32upper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",bitsPerChar:5}),rb=dist_index_es_g({prefix:"c",name:"base32pad",alphabet:"abcdefghijklmnopqrstuvwxyz234567=",bitsPerChar:5}),ry=dist_index_es_g({prefix:"C",name:"base32padupper",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567=",bitsPerChar:5}),r_=dist_index_es_g({prefix:"v",name:"base32hex",alphabet:"0123456789abcdefghijklmnopqrstuv",bitsPerChar:5}),rw=dist_index_es_g({prefix:"V",name:"base32hexupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",bitsPerChar:5}),rE=dist_index_es_g({prefix:"t",name:"base32hexpad",alphabet:"0123456789abcdefghijklmnopqrstuv=",bitsPerChar:5}),rS=dist_index_es_g({prefix:"T",name:"base32hexpadupper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV=",bitsPerChar:5}),rx=dist_index_es_g({prefix:"h",name:"base32z",alphabet:"ybndrfg8ejkmcpqxot1uwisza345h769",bitsPerChar:5});var rk=Object.freeze({__proto__:null,base32:rg,base32upper:rm,base32pad:rb,base32padupper:ry,base32hex:r_,base32hexupper:rw,base32hexpad:rE,base32hexpadupper:rS,base32z:rx});let rC=dist_index_es_K({prefix:"k",name:"base36",alphabet:"0123456789abcdefghijklmnopqrstuvwxyz"}),rA=dist_index_es_K({prefix:"K",name:"base36upper",alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"});var rI=Object.freeze({__proto__:null,base36:rC,base36upper:rA});let rP=dist_index_es_K({name:"base58btc",prefix:"z",alphabet:"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"}),rR=dist_index_es_K({name:"base58flickr",prefix:"Z",alphabet:"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"});var rO=Object.freeze({__proto__:null,base58btc:rP,base58flickr:rR});let rT=dist_index_es_g({prefix:"m",name:"base64",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",bitsPerChar:6}),rN=dist_index_es_g({prefix:"M",name:"base64pad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",bitsPerChar:6}),rM=dist_index_es_g({prefix:"u",name:"base64url",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_",bitsPerChar:6}),r$=dist_index_es_g({prefix:"U",name:"base64urlpad",alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_=",bitsPerChar:6});var rB=Object.freeze({__proto__:null,base64:rT,base64pad:rN,base64url:rM,base64urlpad:r$});let rD=Array.from("\uD83D\uDE80\uD83E\uDE90☄\uD83D\uDEF0\uD83C\uDF0C\uD83C\uDF11\uD83C\uDF12\uD83C\uDF13\uD83C\uDF14\uD83C\uDF15\uD83C\uDF16\uD83C\uDF17\uD83C\uDF18\uD83C\uDF0D\uD83C\uDF0F\uD83C\uDF0E\uD83D\uDC09☀\uD83D\uDCBB\uD83D\uDDA5\uD83D\uDCBE\uD83D\uDCBF\uD83D\uDE02❤\uD83D\uDE0D\uD83E\uDD23\uD83D\uDE0A\uD83D\uDE4F\uD83D\uDC95\uD83D\uDE2D\uD83D\uDE18\uD83D\uDC4D\uD83D\uDE05\uD83D\uDC4F\uD83D\uDE01\uD83D\uDD25\uD83E\uDD70\uD83D\uDC94\uD83D\uDC96\uD83D\uDC99\uD83D\uDE22\uD83E\uDD14\uD83D\uDE06\uD83D\uDE44\uD83D\uDCAA\uD83D\uDE09☺\uD83D\uDC4C\uD83E\uDD17\uD83D\uDC9C\uD83D\uDE14\uD83D\uDE0E\uD83D\uDE07\uD83C\uDF39\uD83E\uDD26\uD83C\uDF89\uD83D\uDC9E✌✨\uD83E\uDD37\uD83D\uDE31\uD83D\uDE0C\uD83C\uDF38\uD83D\uDE4C\uD83D\uDE0B\uD83D\uDC97\uD83D\uDC9A\uD83D\uDE0F\uD83D\uDC9B\uD83D\uDE42\uD83D\uDC93\uD83E\uDD29\uD83D\uDE04\uD83D\uDE00\uD83D\uDDA4\uD83D\uDE03\uD83D\uDCAF\uD83D\uDE48\uD83D\uDC47\uD83C\uDFB6\uD83D\uDE12\uD83E\uDD2D❣\uD83D\uDE1C\uD83D\uDC8B\uD83D\uDC40\uD83D\uDE2A\uD83D\uDE11\uD83D\uDCA5\uD83D\uDE4B\uD83D\uDE1E\uD83D\uDE29\uD83D\uDE21\uD83E\uDD2A\uD83D\uDC4A\uD83E\uDD73\uD83D\uDE25\uD83E\uDD24\uD83D\uDC49\uD83D\uDC83\uD83D\uDE33✋\uD83D\uDE1A\uD83D\uDE1D\uD83D\uDE34\uD83C\uDF1F\uD83D\uDE2C\uD83D\uDE43\uD83C\uDF40\uD83C\uDF37\uD83D\uDE3B\uD83D\uDE13⭐✅\uD83E\uDD7A\uD83C\uDF08\uD83D\uDE08\uD83E\uDD18\uD83D\uDCA6✔\uD83D\uDE23\uD83C\uDFC3\uD83D\uDC90☹\uD83C\uDF8A\uD83D\uDC98\uD83D\uDE20☝\uD83D\uDE15\uD83C\uDF3A\uD83C\uDF82\uD83C\uDF3B\uD83D\uDE10\uD83D\uDD95\uD83D\uDC9D\uD83D\uDE4A\uD83D\uDE39\uD83D\uDDE3\uD83D\uDCAB\uD83D\uDC80\uD83D\uDC51\uD83C\uDFB5\uD83E\uDD1E\uD83D\uDE1B\uD83D\uDD34\uD83D\uDE24\uD83C\uDF3C\uD83D\uDE2B⚽\uD83E\uDD19☕\uD83C\uDFC6\uD83E\uDD2B\uD83D\uDC48\uD83D\uDE2E\uD83D\uDE46\uD83C\uDF7B\uD83C\uDF43\uD83D\uDC36\uD83D\uDC81\uD83D\uDE32\uD83C\uDF3F\uD83E\uDDE1\uD83C\uDF81⚡\uD83C\uDF1E\uD83C\uDF88❌✊\uD83D\uDC4B\uD83D\uDE30\uD83E\uDD28\uD83D\uDE36\uD83E\uDD1D\uD83D\uDEB6\uD83D\uDCB0\uD83C\uDF53\uD83D\uDCA2\uD83E\uDD1F\uD83D\uDE41\uD83D\uDEA8\uD83D\uDCA8\uD83E\uDD2C✈\uD83C\uDF80\uD83C\uDF7A\uD83E\uDD13\uD83D\uDE19\uD83D\uDC9F\uD83C\uDF31\uD83D\uDE16\uD83D\uDC76\uD83E\uDD74▶➡❓\uD83D\uDC8E\uD83D\uDCB8⬇\uD83D\uDE28\uD83C\uDF1A\uD83E\uDD8B\uD83D\uDE37\uD83D\uDD7A⚠\uD83D\uDE45\uD83D\uDE1F\uD83D\uDE35\uD83D\uDC4E\uD83E\uDD32\uD83E\uDD20\uD83E\uDD27\uD83D\uDCCC\uD83D\uDD35\uD83D\uDC85\uD83E\uDDD0\uD83D\uDC3E\uD83C\uDF52\uD83D\uDE17\uD83E\uDD11\uD83C\uDF0A\uD83E\uDD2F\uD83D\uDC37☎\uD83D\uDCA7\uD83D\uDE2F\uD83D\uDC86\uD83D\uDC46\uD83C\uDFA4\uD83D\uDE47\uD83C\uDF51❄\uD83C\uDF34\uD83D\uDCA3\uD83D\uDC38\uD83D\uDC8C\uD83D\uDCCD\uD83E\uDD40\uD83E\uDD22\uD83D\uDC45\uD83D\uDCA1\uD83D\uDCA9\uD83D\uDC50\uD83D\uDCF8\uD83D\uDC7B\uD83E\uDD10\uD83E\uDD2E\uD83C\uDFBC\uD83E\uDD75\uD83D\uDEA9\uD83C\uDF4E\uD83C\uDF4A\uD83D\uDC7C\uD83D\uDC8D\uD83D\uDCE3\uD83E\uDD42"),rj=rD.reduce((c,l,et)=>(c[et]=l,c),[]),rL=rD.reduce((c,l,et)=>(c[l.codePointAt(0)]=et,c),[]),rF=index_es_W({prefix:"\uD83D\uDE80",name:"base256emoji",encode:function(c){return c.reduce((c,l)=>c+=rj[l],"")},decode:function(c){let l=[];for(let et of c){let c=rL[et.codePointAt(0)];if(void 0===c)throw Error(`Non-base256emoji character: ${et}`);l.push(c)}return new Uint8Array(l)}});var rU=Object.freeze({__proto__:null,base256emoji:rF});function dist_index_es_Fe(c,l,et){l=l||[],et=et||0;for(var eo=et;c>=2147483648;)l[et++]=255&c|128,c/=128;for(;-128&c;)l[et++]=255&c|128,c>>>=7;return l[et]=0|c,dist_index_es_Fe.bytes=et-eo+1,l}function dist_index_es_oe(c,l){var et,eo=0,l=l||0,es=0,ec=l,el=c.length;do{if(ec>=el)throw dist_index_es_oe.bytes=0,RangeError("Could not decode varint");et=c[ec++],eo+=es<28?(127&et)<=128);return dist_index_es_oe.bytes=ec-l,eo}var rz={encode:dist_index_es_Fe,decode:dist_index_es_oe,encodingLength:function(c){return c<128?1:c<16384?2:c<2097152?3:c<268435456?4:c<34359738368?5:c<4398046511104?6:c<562949953421312?7:c<72057594037927940?8:c<0x7fffffffffffffff?9:10}};let dist_index_es_ke=(c,l,et=0)=>(rz.encode(c,l,et),l),dist_index_es_Ke=c=>rz.encodingLength(c),index_es_he=(c,l)=>{let et=l.byteLength,eo=dist_index_es_Ke(c),es=eo+dist_index_es_Ke(et),ec=new Uint8Array(es+et);return dist_index_es_ke(c,ec,0),dist_index_es_ke(et,ec,eo),ec.set(l,es),new Zs(c,et,l,ec)};let Zs=class Zs{constructor(c,l,et,eo){this.code=c,this.size=l,this.digest=et,this.bytes=eo}};let dist_index_es_Be=({name:c,code:l,encode:et})=>new dist_index_es_er(c,l,et);let dist_index_es_er=class dist_index_es_er{constructor(c,l,et){this.name=c,this.code=l,this.encode=et}digest(c){if(c instanceof Uint8Array){let l=this.encode(c);return l instanceof Uint8Array?index_es_he(this.code,l):l.then(c=>index_es_he(this.code,c))}throw Error("Unknown type, must be binary type")}};let dist_index_es_Ve=c=>async l=>new Uint8Array(await crypto.subtle.digest(c,l)),rq=dist_index_es_Be({name:"sha2-256",code:18,encode:dist_index_es_Ve("SHA-256")}),rH=dist_index_es_Be({name:"sha2-512",code:19,encode:dist_index_es_Ve("SHA-512")});var rW=Object.freeze({__proto__:null,sha256:rq,sha512:rH}),rV=Object.freeze({__proto__:null,identity:{code:0,name:"identity",encode:dist_index_es_ze,digest:c=>index_es_he(0,dist_index_es_ze(c))}});new TextEncoder,new TextDecoder;let rG={...re,...ro,...ra,...rl,...rp,...rk,...rI,...rO,...rB,...rU};function dist_index_es_Ge(c){return null!=globalThis.Buffer?new Uint8Array(c.buffer,c.byteOffset,c.byteLength):c}function dist_index_es_He(c,l,et,eo){return{name:c,prefix:l,encoder:{name:c,prefix:l,encode:et},decoder:{decode:eo}}}({...rW,...rV});let rK=dist_index_es_He("utf8","u",c=>"u"+new TextDecoder("utf8").decode(c),c=>new TextEncoder().encode(c.substring(1))),rJ=dist_index_es_He("ascii","a",c=>{let l="a";for(let et=0;et{c=c.substring(1);let l=function(c=0){return null!=globalThis.Buffer&&null!=globalThis.Buffer.allocUnsafe?dist_index_es_Ge(globalThis.Buffer.allocUnsafe(c)):new Uint8Array(c)}(c.length);for(let et=0;et{if(!this.initialized){let c=await this.getKeyChain();"u">typeof c&&(this.keychain=c),this.initialized=!0}},this.has=c=>(this.isInitialized(),this.keychain.has(c)),this.set=async(c,l)=>{this.isInitialized(),this.keychain.set(c,l),await this.persist()},this.get=c=>{this.isInitialized();let l=this.keychain.get(c);if(typeof l>"u"){let{message:l}=index_es_N("NO_MATCHING_KEY",`${this.name}: ${c}`);throw Error(l)}return l},this.del=async c=>{this.isInitialized(),this.keychain.delete(c),await this.persist()},this.core=c,this.logger=(0,tC.generateChildLogger)(l,this.name)}get context(){return(0,tC.getLoggerContext)(this.logger)}get storageKey(){return this.storagePrefix+this.version+this.core.customStoragePrefix+"//"+this.name}async setKeyChain(c){await this.core.storage.setItem(this.storageKey,index_es_et(c))}async getKeyChain(){let c=await this.core.storage.getItem(this.storageKey);return"u">typeof c?index_es_nt(c):void 0}async persist(){await this.setKeyChain(this.keychain)}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}};let dist_index_es_t=class dist_index_es_t{constructor(c,l,et){this.core=c,this.logger=l,this.name="crypto",this.initialized=!1,this.init=async()=>{this.initialized||(await this.keychain.init(),this.initialized=!0)},this.hasKeys=c=>(this.isInitialized(),this.keychain.has(c)),this.getClientId=async()=>{this.isInitialized();let c=await this.getClientSeed(),l=generateKeyPair(c);return encodeIss(l.publicKey)},this.generateKeyPair=()=>{this.isInitialized();let c=function(){let c=eI.Au();return{privateKey:to_string_toString(c.secretKey,tj),publicKey:to_string_toString(c.publicKey,tj)}}();return this.setPrivateKey(c.publicKey,c.privateKey)},this.signJWT=async c=>{this.isInitialized();let l=await this.getClientSeed(),et=generateKeyPair(l),eo=index_es_Dn();return await signJWT(eo,c,r2,et)},this.generateSharedKey=(c,l,et)=>{this.isInitialized();let eo=this.getPrivateKey(c),es=function(c,l){let et=eI.gi(from_string_fromString(c,tj),from_string_fromString(l,tj),!0),eo=new ek.t(eA.mE,et).expand(32);return to_string_toString(eo,tj)}(eo,l);return this.setSymKey(es,et)},this.setSymKey=async(c,l)=>{this.isInitialized();let et=l||function(c){let l=(0,eA.vp)(from_string_fromString(c,tj));return to_string_toString(l,tj)}(c);return await this.keychain.set(et,c),et},this.deleteKeyPair=async c=>{this.isInitialized(),await this.keychain.del(c)},this.deleteSymKey=async c=>{this.isInitialized(),await this.keychain.del(c)},this.encode=async(c,l,et)=>{this.isInitialized();let eo=index_es_Re(et),es=safeJsonStringify(l);if(index_es_Fn(eo)){let l=eo.senderPublicKey,et=eo.receiverPublicKey;c=await this.generateSharedKey(l,et)}let ec=this.getSymKey(c),{type:el,senderPublicKey:ed}=eo;return function(c){var l;let et=(l="u">typeof c.type?c.type:0,from_string_fromString(`${l}`,tD));if(1===index_es_$(et)&&typeof c.senderPublicKey>"u")throw Error("Missing sender public key for type 1 envelope");let eo="u">typeof c.senderPublicKey?from_string_fromString(c.senderPublicKey,tj):void 0,es="u">typeof c.iv?from_string_fromString(c.iv,tj):(0,eC.randomBytes)(12),ec=new ex.OK(from_string_fromString(c.symKey,tj)).seal(es,from_string_fromString(c.message,tF));return function(c){if(1===index_es_$(c.type)){if(typeof c.senderPublicKey>"u")throw Error("Missing sender public key for type 1 envelope");return to_string_toString(concat([c.type,c.senderPublicKey,c.iv,c.sealed]),tL)}return to_string_toString(concat([c.type,c.iv,c.sealed]),tL)}({type:et,sealed:ec,iv:es,senderPublicKey:eo})}({type:el,symKey:ec,message:es,senderPublicKey:ed})},this.decode=async(c,l,et)=>{this.isInitialized();let eo=function(c,l){let et=index_es_ee(c);return index_es_Re({type:index_es_$(et.type),senderPublicKey:"u">typeof et.senderPublicKey?to_string_toString(et.senderPublicKey,tj):void 0,receiverPublicKey:l?.receiverPublicKey})}(l,et);if(index_es_Fn(eo)){let l=eo.receiverPublicKey,et=eo.senderPublicKey;c=await this.generateSharedKey(l,et)}try{let et=this.getSymKey(c),eo=function(c){let l=new ex.OK(from_string_fromString(c.symKey,tj)),{sealed:et,iv:eo}=index_es_ee(c.encoded),es=l.open(eo,et);if(null===es)throw Error("Failed to decrypt");return to_string_toString(es,tF)}({symKey:et,encoded:l});return esm_safeJsonParse(eo)}catch(l){this.logger.error(`Failed to decode message from topic: '${c}', clientId: '${await this.getClientId()}'`),this.logger.error(l)}},this.getPayloadType=c=>{let l=index_es_ee(c);return index_es_$(l.type)},this.getPayloadSenderPublicKey=c=>{let l=index_es_ee(c);return l.senderPublicKey?to_string_toString(l.senderPublicKey,tj):void 0},this.core=c,this.logger=(0,tC.generateChildLogger)(l,this.name),this.keychain=et||new dist_index_es_Rt(this.core,this.logger)}get context(){return(0,tC.getLoggerContext)(this.logger)}async setPrivateKey(c,l){return await this.keychain.set(c,l),c}getPrivateKey(c){return this.keychain.get(c)}async getClientSeed(){let c="";try{c=this.keychain.get(r1)}catch{c=index_es_Dn(),await this.keychain.set(r1,c)}return function(c,l="utf8"){let et=rQ[l];if(!et)throw Error(`Unsupported encoding "${l}"`);return("utf8"===l||"utf-8"===l)&&null!=globalThis.Buffer&&null!=globalThis.Buffer.from?dist_index_es_Ge(globalThis.Buffer.from(c,"utf-8")):et.decoder.decode(`${et.prefix}${c}`)}(c,"base16")}getSymKey(c){return this.keychain.get(c)}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}};let dist_index_es_St=class dist_index_es_St extends a{constructor(c,l){super(c,l),this.logger=c,this.core=l,this.messages=new Map,this.name="messages",this.version="0.3",this.initialized=!1,this.storagePrefix=rZ,this.init=async()=>{if(!this.initialized){this.logger.trace("Initialized");try{let c=await this.getRelayerMessages();"u">typeof c&&(this.messages=c),this.logger.debug(`Successfully Restored records for ${this.name}`),this.logger.trace({type:"method",method:"restore",size:this.messages.size})}catch(c){this.logger.debug(`Failed to Restore records for ${this.name}`),this.logger.error(c)}finally{this.initialized=!0}}},this.set=async(c,l)=>{this.isInitialized();let et=index_es_Mn(l),eo=this.messages.get(c);return typeof eo>"u"&&(eo={}),"u">typeof eo[et]||(eo[et]=l,this.messages.set(c,eo),await this.persist()),et},this.get=c=>{this.isInitialized();let l=this.messages.get(c);return typeof l>"u"&&(l={}),l},this.has=(c,l)=>{this.isInitialized();let et=this.get(c),eo=index_es_Mn(l);return"u">typeof et[eo]},this.del=async c=>{this.isInitialized(),this.messages.delete(c),await this.persist()},this.logger=(0,tC.generateChildLogger)(c,this.name),this.core=l}get context(){return(0,tC.getLoggerContext)(this.logger)}get storageKey(){return this.storagePrefix+this.version+this.core.customStoragePrefix+"//"+this.name}async setRelayerMessages(c){await this.core.storage.setItem(this.storageKey,index_es_et(c))}async getRelayerMessages(){let c=await this.core.storage.getItem(this.storageKey);return"u">typeof c?index_es_nt(c):void 0}async persist(){await this.setRelayerMessages(this.messages)}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}};let Dr=class Dr extends u{constructor(c,l){super(c,l),this.relayer=c,this.logger=l,this.events=new eE.EventEmitter,this.name="publisher",this.queue=new Map,this.publishTimeout=(0,ty.toMiliseconds)(ty.TEN_SECONDS),this.needsTransportRestart=!1,this.publish=async(c,l,et)=>{var eo;this.logger.debug("Publishing Payload"),this.logger.trace({type:"method",method:"publish",params:{topic:c,message:l,opts:et}});try{let es=et?.ttl||r3,ec=index_es_mt(et),el=et?.prompt||!1,ed=et?.tag||0,eh=et?.id||getBigIntRpcId().toString(),ef={topic:c,message:l,opts:{ttl:es,relay:ec,prompt:el,tag:ed,id:eh}},ep=setTimeout(()=>this.queue.set(eh,ef),this.publishTimeout);try{await await index_es_it(this.rpcPublish(c,l,es,ec,el,ed,eh),this.publishTimeout,"Failed to publish payload, please try again."),this.removeRequestFromQueue(eh),this.relayer.events.emit(r4.publish,ef)}catch(c){if(this.logger.debug("Publishing Payload stalled"),this.needsTransportRestart=!0,null!=(eo=et?.internal)&&eo.throwOnFailedPublish)throw this.removeRequestFromQueue(eh),c;return}finally{clearTimeout(ep)}this.logger.debug("Successfully Published Payload"),this.logger.trace({type:"method",method:"publish",params:{topic:c,message:l,opts:et}})}catch(c){throw this.logger.debug("Failed to Publish Payload"),this.logger.error(c),c}},this.on=(c,l)=>{this.events.on(c,l)},this.once=(c,l)=>{this.events.once(c,l)},this.off=(c,l)=>{this.events.off(c,l)},this.removeListener=(c,l)=>{this.events.removeListener(c,l)},this.relayer=c,this.logger=(0,tC.generateChildLogger)(l,this.name),this.registerEventListeners()}get context(){return(0,tC.getLoggerContext)(this.logger)}rpcPublish(c,l,et,eo,es,ec,el){var ed,eh,ef,ep;let eg={method:index_es_yt(eo.protocol).publish,params:{topic:c,message:l,ttl:et,prompt:es,tag:ec},id:el};return index_es_w(null==(ed=eg.params)?void 0:ed.prompt)&&(null==(eh=eg.params)||delete eh.prompt),index_es_w(null==(ef=eg.params)?void 0:ef.tag)&&(null==(ep=eg.params)||delete ep.tag),this.logger.debug("Outgoing Relay Payload"),this.logger.trace({type:"message",direction:"outgoing",request:eg}),this.relayer.request(eg)}removeRequestFromQueue(c){this.queue.delete(c)}checkQueue(){this.queue.forEach(async c=>{let{topic:l,message:et,opts:eo}=c;await this.publish(l,et,eo)})}registerEventListeners(){this.relayer.core.heartbeat.on(tk.HEARTBEAT_EVENTS.pulse,()=>{if(this.needsTransportRestart){this.needsTransportRestart=!1,this.relayer.events.emit(r4.connection_stalled);return}this.checkQueue()}),this.relayer.on(r4.message_ack,c=>{this.removeRequestFromQueue(c.id.toString())})}};let yr=class yr{constructor(){this.map=new Map,this.set=(c,l)=>{let et=this.get(c);this.exists(c,l)||this.map.set(c,[...et,l])},this.get=c=>this.map.get(c)||[],this.exists=(c,l)=>this.get(c).includes(l),this.delete=(c,l)=>{if(typeof l>"u"){this.map.delete(c);return}if(!this.map.has(c))return;let et=this.get(c);if(!this.exists(c,l))return;let eo=et.filter(c=>c!==l);if(!eo.length){this.map.delete(c);return}this.map.set(c,eo)},this.clear=()=>{this.map.clear()}}get topics(){return Array.from(this.map.keys())}};var np=Object.defineProperty,ng=Object.defineProperties,nm=Object.getOwnPropertyDescriptors,nb=Object.getOwnPropertySymbols,ny=Object.prototype.hasOwnProperty,n_=Object.prototype.propertyIsEnumerable,dist_index_es_Tt=(c,l,et)=>l in c?np(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,index_es_V=(c,l)=>{for(var et in l||(l={}))ny.call(l,et)&&dist_index_es_Tt(c,et,l[et]);if(nb)for(var et of nb(l))n_.call(l,et)&&dist_index_es_Tt(c,et,l[et]);return c},dist_index_es_De=(c,l)=>ng(c,nm(l));let dist_index_es_xt=class dist_index_es_xt extends d{constructor(c,l){super(c,l),this.relayer=c,this.logger=l,this.subscriptions=new Map,this.topicMap=new yr,this.events=new eE.EventEmitter,this.name="subscription",this.version="0.3",this.pending=new Map,this.cached=[],this.initialized=!1,this.pendingSubscriptionWatchLabel="pending_sub_watch_label",this.pollingInterval=20,this.storagePrefix=rZ,this.subscribeTimeout=1e4,this.restartInProgress=!1,this.batchSubscribeTopicsLimit=500,this.init=async()=>{this.initialized||(this.logger.trace("Initialized"),this.registerEventListeners(),this.clientId=await this.relayer.core.crypto.getClientId())},this.subscribe=async(c,l)=>{await this.restartToComplete(),this.isInitialized(),this.logger.debug("Subscribing Topic"),this.logger.trace({type:"method",method:"subscribe",params:{topic:c,opts:l}});try{let et=index_es_mt(l),eo={topic:c,relay:et};this.pending.set(c,eo);let es=await this.rpcSubscribe(c,et);return this.onSubscribe(es,eo),this.logger.debug("Successfully Subscribed Topic"),this.logger.trace({type:"method",method:"subscribe",params:{topic:c,opts:l}}),es}catch(c){throw this.logger.debug("Failed to Subscribe Topic"),this.logger.error(c),c}},this.unsubscribe=async(c,l)=>{await this.restartToComplete(),this.isInitialized(),"u">typeof l?.id?await this.unsubscribeById(c,l.id,l):await this.unsubscribeByTopic(c,l)},this.isSubscribed=async c=>!!this.topics.includes(c)||await new Promise((l,et)=>{let eo=new ty.Watch;eo.start(this.pendingSubscriptionWatchLabel);let es=setInterval(()=>{!this.pending.has(c)&&this.topics.includes(c)&&(clearInterval(es),eo.stop(this.pendingSubscriptionWatchLabel),l(!0)),eo.elapsed(this.pendingSubscriptionWatchLabel)>=nn&&(clearInterval(es),eo.stop(this.pendingSubscriptionWatchLabel),et(Error("Subscription resolution timeout")))},this.pollingInterval)}).catch(()=>!1),this.on=(c,l)=>{this.events.on(c,l)},this.once=(c,l)=>{this.events.once(c,l)},this.off=(c,l)=>{this.events.off(c,l)},this.removeListener=(c,l)=>{this.events.removeListener(c,l)},this.restart=async()=>{this.restartInProgress=!0,await this.restore(),await this.reset(),this.restartInProgress=!1},this.relayer=c,this.logger=(0,tC.generateChildLogger)(l,this.name),this.clientId=""}get context(){return(0,tC.getLoggerContext)(this.logger)}get storageKey(){return this.storagePrefix+this.version+this.relayer.core.customStoragePrefix+"//"+this.name}get length(){return this.subscriptions.size}get ids(){return Array.from(this.subscriptions.keys())}get values(){return Array.from(this.subscriptions.values())}get topics(){return this.topicMap.topics}hasSubscription(c,l){let et=!1;try{et=this.getSubscription(c).topic===l}catch{}return et}onEnable(){this.cached=[],this.initialized=!0}onDisable(){this.cached=this.values,this.subscriptions.clear(),this.topicMap.clear()}async unsubscribeByTopic(c,l){let et=this.topicMap.get(c);await Promise.all(et.map(async et=>await this.unsubscribeById(c,et,l)))}async unsubscribeById(c,l,et){this.logger.debug("Unsubscribing Topic"),this.logger.trace({type:"method",method:"unsubscribe",params:{topic:c,id:l,opts:et}});try{let eo=index_es_mt(et);await this.rpcUnsubscribe(c,l,eo);let es=index_es_U("USER_DISCONNECTED",`${this.name}, ${c}`);await this.onUnsubscribe(c,l,es),this.logger.debug("Successfully Unsubscribed Topic"),this.logger.trace({type:"method",method:"unsubscribe",params:{topic:c,id:l,opts:et}})}catch(c){throw this.logger.debug("Failed to Unsubscribe Topic"),this.logger.error(c),c}}async rpcSubscribe(c,l){let et={method:index_es_yt(l.protocol).subscribe,params:{topic:c}};this.logger.debug("Outgoing Relay Payload"),this.logger.trace({type:"payload",direction:"outgoing",request:et});try{await await index_es_it(this.relayer.request(et),this.subscribeTimeout)}catch{this.logger.debug("Outgoing Relay Subscribe Payload stalled"),this.relayer.events.emit(r4.connection_stalled)}return index_es_Mn(c+this.clientId)}async rpcBatchSubscribe(c){if(!c.length)return;let l=c[0].relay,et={method:index_es_yt(l.protocol).batchSubscribe,params:{topics:c.map(c=>c.topic)}};this.logger.debug("Outgoing Relay Payload"),this.logger.trace({type:"payload",direction:"outgoing",request:et});try{return await await index_es_it(this.relayer.request(et),this.subscribeTimeout)}catch{this.logger.debug("Outgoing Relay Payload stalled"),this.relayer.events.emit(r4.connection_stalled)}}rpcUnsubscribe(c,l,et){let eo={method:index_es_yt(et.protocol).unsubscribe,params:{topic:c,id:l}};return this.logger.debug("Outgoing Relay Payload"),this.logger.trace({type:"payload",direction:"outgoing",request:eo}),this.relayer.request(eo)}onSubscribe(c,l){this.setSubscription(c,dist_index_es_De(index_es_V({},l),{id:c})),this.pending.delete(l.topic)}onBatchSubscribe(c){c.length&&c.forEach(c=>{this.setSubscription(c.id,index_es_V({},c)),this.pending.delete(c.topic)})}async onUnsubscribe(c,l,et){this.events.removeAllListeners(l),this.hasSubscription(l,c)&&this.deleteSubscription(l,et),await this.relayer.messages.del(c)}async setRelayerSubscriptions(c){await this.relayer.core.storage.setItem(this.storageKey,c)}async getRelayerSubscriptions(){return await this.relayer.core.storage.getItem(this.storageKey)}setSubscription(c,l){this.subscriptions.has(c)||(this.logger.debug("Setting subscription"),this.logger.trace({type:"method",method:"setSubscription",id:c,subscription:l}),this.addSubscription(c,l))}addSubscription(c,l){this.subscriptions.set(c,index_es_V({},l)),this.topicMap.set(l.topic,c),this.events.emit(r7.created,l)}getSubscription(c){this.logger.debug("Getting subscription"),this.logger.trace({type:"method",method:"getSubscription",id:c});let l=this.subscriptions.get(c);if(!l){let{message:l}=index_es_N("NO_MATCHING_KEY",`${this.name}: ${c}`);throw Error(l)}return l}deleteSubscription(c,l){this.logger.debug("Deleting subscription"),this.logger.trace({type:"method",method:"deleteSubscription",id:c,reason:l});let et=this.getSubscription(c);this.subscriptions.delete(c),this.topicMap.delete(et.topic,c),this.events.emit(r7.deleted,dist_index_es_De(index_es_V({},et),{reason:l}))}async persist(){await this.setRelayerSubscriptions(this.values),this.events.emit(r7.sync)}async reset(){if(this.cached.length){let c=Math.ceil(this.cached.length/this.batchSubscribeTopicsLimit);for(let l=0;l"u"||!c.length)return;if(this.subscriptions.size){let{message:c}=index_es_N("RESTORE_WILL_OVERRIDE",this.name);throw this.logger.error(c),this.logger.error(`${this.name}: ${JSON.stringify(this.values)}`),Error(c)}this.cached=c,this.logger.debug(`Successfully Restored subscriptions for ${this.name}`),this.logger.trace({type:"method",method:"restore",subscriptions:this.values})}catch(c){this.logger.debug(`Failed to Restore subscriptions for ${this.name}`),this.logger.error(c)}}async batchSubscribe(c){if(!c.length)return;let l=await this.rpcBatchSubscribe(c);index_es_D(l)&&this.onBatchSubscribe(l.map((l,et)=>dist_index_es_De(index_es_V({},c[et]),{id:l})))}async onConnect(){this.restartInProgress||(await this.restart(),this.onEnable())}onDisconnect(){this.onDisable()}async checkPending(){if(!this.initialized||this.relayer.transportExplicitlyClosed)return;let c=[];this.pending.forEach(l=>{c.push(l)}),await this.batchSubscribe(c)}registerEventListeners(){this.relayer.core.heartbeat.on(tk.HEARTBEAT_EVENTS.pulse,async()=>{await this.checkPending()}),this.relayer.on(r4.connect,async()=>{await this.onConnect()}),this.relayer.on(r4.disconnect,()=>{this.onDisconnect()}),this.events.on(r7.created,async c=>{let l=r7.created;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,data:c}),await this.persist()}),this.events.on(r7.deleted,async c=>{let l=r7.deleted;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,data:c}),await this.persist()})}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}async restartToComplete(){this.restartInProgress&&await new Promise(c=>{let l=setInterval(()=>{this.restartInProgress||(clearInterval(l),c())},this.pollingInterval)})}};var nw=Object.defineProperty,nE=Object.getOwnPropertySymbols,nS=Object.prototype.hasOwnProperty,nx=Object.prototype.propertyIsEnumerable,dist_index_es_At=(c,l,et)=>l in c?nw(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,Rr=(c,l)=>{for(var et in l||(l={}))nS.call(l,et)&&dist_index_es_At(c,et,l[et]);if(nE)for(var et of nE(l))nx.call(l,et)&&dist_index_es_At(c,et,l[et]);return c};let dist_index_es_zt=class dist_index_es_zt extends index_es_g{constructor(c){super(c),this.protocol="wc",this.version=2,this.events=new eE.EventEmitter,this.name="relayer",this.transportExplicitlyClosed=!1,this.initialized=!1,this.connectionAttemptInProgress=!1,this.connectionStatusPollingInterval=20,this.staleConnectionErrors=["socket hang up","socket stalled"],this.hasExperiencedNetworkDisruption=!1,this.request=async c=>{this.logger.debug("Publishing Request Payload");try{return await this.toEstablishConnection(),await this.provider.request(c)}catch(c){throw this.logger.debug("Failed to Publish Request"),this.logger.error(c),c}},this.onPayloadHandler=c=>{this.onProviderPayload(c)},this.onConnectHandler=()=>{this.events.emit(r4.connect)},this.onDisconnectHandler=()=>{this.onProviderDisconnect()},this.onProviderErrorHandler=c=>{this.logger.error(c),this.events.emit(r4.error,c),this.logger.info("Fatal socket error received, closing transport"),this.transportClose()},this.registerProviderListeners=()=>{this.provider.on(r8.payload,this.onPayloadHandler),this.provider.on(r8.connect,this.onConnectHandler),this.provider.on(r8.disconnect,this.onDisconnectHandler),this.provider.on(r8.error,this.onProviderErrorHandler)},this.core=c.core,this.logger="u">typeof c.logger&&"string"!=typeof c.logger?(0,tC.generateChildLogger)(c.logger,this.name):(0,tC.pino)((0,tC.getDefaultLoggerOptions)({level:c.logger||"error"})),this.messages=new dist_index_es_St(this.logger,c.core),this.subscriber=new dist_index_es_xt(this,this.logger),this.publisher=new Dr(this,this.logger),this.relayUrl=c?.relayUrl||r5,this.projectId=c.projectId,this.provider={}}async init(){this.logger.trace("Initialized"),this.registerEventListeners(),await this.createProvider(),await Promise.all([this.messages.init(),this.subscriber.init()]);try{await this.transportOpen()}catch{this.logger.warn(`Connection via ${this.relayUrl} failed, attempting to connect via failover domain ${r6}...`),await this.restartTransport(r6)}this.initialized=!0,setTimeout(async()=>{0===this.subscriber.topics.length&&(this.logger.info("No topics subscribed to after init, closing transport"),await this.transportClose(),this.transportExplicitlyClosed=!1)},1e4)}get context(){return(0,tC.getLoggerContext)(this.logger)}get connected(){return this.provider.connection.connected}get connecting(){return this.provider.connection.connecting}async publish(c,l,et){this.isInitialized(),await this.publisher.publish(c,l,et),await this.recordMessageEvent({topic:c,message:l,publishedAt:Date.now()})}async subscribe(c,l){var et;let eo;this.isInitialized();let es=(null==(et=this.subscriber.topicMap.get(c))?void 0:et[0])||"";if(es)return es;let a=l=>{l.topic===c&&(this.subscriber.off(r7.created,a),eo())};return await Promise.all([new Promise(c=>{eo=c,this.subscriber.on(r7.created,a)}),new Promise(async et=>{es=await this.subscriber.subscribe(c,l),et()})]),es}async unsubscribe(c,l){this.isInitialized(),await this.subscriber.unsubscribe(c,l)}on(c,l){this.events.on(c,l)}once(c,l){this.events.once(c,l)}off(c,l){this.events.off(c,l)}removeListener(c,l){this.events.removeListener(c,l)}async transportClose(){this.transportExplicitlyClosed=!0,this.hasExperiencedNetworkDisruption&&this.connected?await index_es_it(this.provider.disconnect(),1e3,"provider.disconnect()").catch(()=>this.onProviderDisconnect()):this.connected&&await this.provider.disconnect()}async transportOpen(c){if(this.transportExplicitlyClosed=!1,await this.confirmOnlineStateOrThrow(),!this.connectionAttemptInProgress){c&&c!==this.relayUrl&&(this.relayUrl=c,await this.transportClose(),await this.createProvider()),this.connectionAttemptInProgress=!0;try{await Promise.all([new Promise(c=>{if(!this.initialized)return c();this.subscriber.once(r7.resubscribed,()=>{c()})}),new Promise(async(c,l)=>{try{await index_es_it(this.provider.connect(),1e4,`Socket stalled when trying to connect to ${this.relayUrl}`)}catch(c){l(c);return}c()})])}catch(c){if(this.logger.error(c),!this.isConnectionStalled(c.message))throw c;this.provider.events.emit(r8.disconnect)}finally{this.connectionAttemptInProgress=!1,this.hasExperiencedNetworkDisruption=!1}}}async restartTransport(c){await this.confirmOnlineStateOrThrow(),this.connectionAttemptInProgress||(this.relayUrl=c||this.relayUrl,await this.transportClose(),await this.createProvider(),await this.transportOpen())}async confirmOnlineStateOrThrow(){if(!await index_es_Zt())throw Error("No internet connection detected. Please restart your network and try again.")}isConnectionStalled(c){return this.staleConnectionErrors.some(l=>c.includes(l))}async createProvider(){this.provider.connection&&this.unregisterProviderListeners();let c=await this.core.crypto.signJWT(this.relayUrl);this.provider=new JsonRpcProvider(new t6(function({protocol:c,version:l,relayUrl:eo,sdkVersion:es,auth:ec,projectId:el,useOnCloseEvent:ed}){var eh;let ef;let ep=eo.split("?"),eg=function(c,l,eo){let es=function(){var c;if(index_es_R()===tW.reactNative&&"u">typeof et.g&&"u">typeof(null==et.g?void 0:et.g.Platform)){let{OS:c,Version:l}=et.g.Platform;return[c,l].join("-")}let l=c?parseUserAgent(c):"undefined"==typeof document&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product?new ReactNativeInfo:"undefined"!=typeof navigator?parseUserAgent(navigator.userAgent):void 0!==tO&&tO.version?new NodeInfo(tO.version.slice(1)):null;if(null===l)return"unknown";let eo=l.os?l.os.replace(" ","").toLowerCase():"unknown";return"browser"===l.type?[eo,l.name,l.version].join("-"):[eo,l.version].join("-")}(),ec=function(){var c;let l=index_es_R();return l===tW.browser?[l,(null==(c=(0,t_.getLocation)())?void 0:c.host)||"unknown"].join(":"):l}();return[[c,l].join("-"),["js",eo].join("-"),es,ec].join("/")}(c,l,es),em=(eh=ep[1]||"",ef=index_es_e(index_es_e({},ef=t$.parse(eh)),{auth:ec,ua:eg,projectId:el,useOnCloseEvent:ed||void 0}),eh=t$.stringify(ef));return ep[0]+"?"+em}({sdkVersion:"2.10.2",protocol:this.protocol,version:this.version,relayUrl:this.relayUrl,projectId:this.projectId,auth:c,useOnCloseEvent:!0}))),this.registerProviderListeners()}async recordMessageEvent(c){let{topic:l,message:et}=c;await this.messages.set(l,et)}async shouldIgnoreMessageEvent(c){let{topic:l,message:et}=c;if(!et||0===et.length)return this.logger.debug(`Ignoring invalid/empty message: ${et}`),!0;if(!await this.subscriber.isSubscribed(l))return this.logger.debug(`Ignoring message for non-subscribed topic ${l}`),!0;let eo=this.messages.has(l,et);return eo&&this.logger.debug(`Ignoring duplicate message: ${et}`),eo}async onProviderPayload(c){if(this.logger.debug("Incoming Relay Payload"),this.logger.trace({type:"payload",direction:"incoming",payload:c}),isJsonRpcRequest(c)){if(!c.method.endsWith("_subscription"))return;let l=c.params,{topic:et,message:eo,publishedAt:es}=l.data,ec={topic:et,message:eo,publishedAt:es};this.logger.debug("Emitting Relayer Payload"),this.logger.trace(Rr({type:"event",event:l.id},ec)),this.events.emit(l.id,ec),await this.acknowledgePayload(c),await this.onMessageEvent(ec)}else isJsonRpcResponse(c)&&this.events.emit(r4.message_ack,c)}async onMessageEvent(c){await this.shouldIgnoreMessageEvent(c)||(this.events.emit(r4.message,c),await this.recordMessageEvent(c))}async acknowledgePayload(c){let l=formatJsonRpcResult(c.id,!0);await this.provider.connection.send(l)}unregisterProviderListeners(){this.provider.off(r8.payload,this.onPayloadHandler),this.provider.off(r8.connect,this.onConnectHandler),this.provider.off(r8.disconnect,this.onDisconnectHandler),this.provider.off(r8.error,this.onProviderErrorHandler)}async registerEventListeners(){this.events.on(r4.connection_stalled,()=>{this.restartTransport().catch(c=>this.logger.error(c))});let c=await index_es_Zt();!function(c){switch(index_es_R()){case tW.browser:!index_es_j()&&index_es_q()&&(window.addEventListener("online",()=>c(!0)),window.addEventListener("offline",()=>c(!1)));break;case tW.reactNative:index_es_j()&&"u">typeof et.g&&null!=et.g&&et.g.NetInfo&&et.g?.NetInfo.addEventListener(l=>c(l?.isConnected));case tW.node:}}(async l=>{this.initialized&&c!==l&&(c=l,l?await this.restartTransport().catch(c=>this.logger.error(c)):(this.hasExperiencedNetworkDisruption=!0,await this.transportClose().catch(c=>this.logger.error(c))))})}onProviderDisconnect(){this.events.emit(r4.disconnect),this.attemptToReconnect()}attemptToReconnect(){this.transportExplicitlyClosed||(this.logger.info("attemptToReconnect called. Connecting..."),setTimeout(async()=>{await this.restartTransport().catch(c=>this.logger.error(c))},(0,ty.toMiliseconds)(r9)))}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}async toEstablishConnection(){if(await this.confirmOnlineStateOrThrow(),!this.connected){if(this.connectionAttemptInProgress)return await new Promise(c=>{let l=setInterval(()=>{this.connected&&(clearInterval(l),c())},this.connectionStatusPollingInterval)});await this.restartTransport()}}};var nk=Object.defineProperty,nC=Object.getOwnPropertySymbols,nA=Object.prototype.hasOwnProperty,nI=Object.prototype.propertyIsEnumerable,dist_index_es_Lt=(c,l,et)=>l in c?nk(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,dist_index_es_Ut=(c,l)=>{for(var et in l||(l={}))nA.call(l,et)&&dist_index_es_Lt(c,et,l[et]);if(nC)for(var et of nC(l))nI.call(l,et)&&dist_index_es_Lt(c,et,l[et]);return c};let dist_index_es_Ft=class dist_index_es_Ft extends index_es_p{constructor(c,l,et,eo=rZ,es){super(c,l,et,eo),this.core=c,this.logger=l,this.name=et,this.map=new Map,this.version="0.3",this.cached=[],this.initialized=!1,this.storagePrefix=rZ,this.init=async()=>{this.initialized||(this.logger.trace("Initialized"),await this.restore(),this.cached.forEach(c=>{var l;this.getKey&&null!==c&&!index_es_w(c)?this.map.set(this.getKey(c),c):(null==(l=c?.proposer)?void 0:l.publicKey)?this.map.set(c.id,c):c?.topic&&this.map.set(c.topic,c)}),this.cached=[],this.initialized=!0)},this.set=async(c,l)=>{this.isInitialized(),this.map.has(c)?await this.update(c,l):(this.logger.debug("Setting value"),this.logger.trace({type:"method",method:"set",key:c,value:l}),this.map.set(c,l),await this.persist())},this.get=c=>(this.isInitialized(),this.logger.debug("Getting value"),this.logger.trace({type:"method",method:"get",key:c}),this.getData(c)),this.getAll=c=>(this.isInitialized(),c?this.values.filter(l=>Object.keys(c).every(et=>t8()(l[et],c[et]))):this.values),this.update=async(c,l)=>{this.isInitialized(),this.logger.debug("Updating value"),this.logger.trace({type:"method",method:"update",key:c,update:l});let et=dist_index_es_Ut(dist_index_es_Ut({},this.getData(c)),l);this.map.set(c,et),await this.persist()},this.delete=async(c,l)=>{this.isInitialized(),this.map.has(c)&&(this.logger.debug("Deleting value"),this.logger.trace({type:"method",method:"delete",key:c,reason:l}),this.map.delete(c),await this.persist())},this.logger=(0,tC.generateChildLogger)(l,this.name),this.storagePrefix=eo,this.getKey=es}get context(){return(0,tC.getLoggerContext)(this.logger)}get storageKey(){return this.storagePrefix+this.version+this.core.customStoragePrefix+"//"+this.name}get length(){return this.map.size}get keys(){return Array.from(this.map.keys())}get values(){return Array.from(this.map.values())}async setDataStore(c){await this.core.storage.setItem(this.storageKey,c)}async getDataStore(){return await this.core.storage.getItem(this.storageKey)}getData(c){let l=this.map.get(c);if(!l){let{message:l}=index_es_N("NO_MATCHING_KEY",`${this.name}: ${c}`);throw this.logger.error(l),Error(l)}return l}async persist(){await this.setDataStore(this.values)}async restore(){try{let c=await this.getDataStore();if(typeof c>"u"||!c.length)return;if(this.map.size){let{message:c}=index_es_N("RESTORE_WILL_OVERRIDE",this.name);throw this.logger.error(c),Error(c)}this.cached=c,this.logger.debug(`Successfully Restored value for ${this.name}`),this.logger.trace({type:"method",method:"restore",value:this.values})}catch(c){this.logger.debug(`Failed to Restore value for ${this.name}`),this.logger.error(c)}}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}};let dist_index_es_$t=class dist_index_es_$t{constructor(c,l){this.core=c,this.logger=l,this.name="pairing",this.version="0.3",this.events=new(eS()),this.initialized=!1,this.storagePrefix=rZ,this.ignoredPayloadTypes=[1],this.registeredMethods=[],this.init=async()=>{this.initialized||(await this.pairings.init(),await this.cleanup(),this.registerRelayerEvents(),this.registerExpirerEvents(),this.initialized=!0,this.logger.trace("Initialized"))},this.register=({methods:c})=>{this.isInitialized(),this.registeredMethods=[...new Set([...this.registeredMethods,...c])]},this.create=async()=>{var c;this.isInitialized();let l=index_es_Dn(),et=await this.core.crypto.setSymKey(l),eo=index_es_lt(ty.FIVE_MINUTES),es={protocol:"irn"},ec=(c={protocol:this.core.protocol,version:this.core.version,topic:et,symKey:l,relay:es},`${c.protocol}:${c.topic}@${c.version}?`+t$.stringify(index_es_Et({symKey:c.symKey},function(c,l="-"){let et={};return Object.keys(c).forEach(eo=>{c[eo]&&(et["relay"+l+eo]=c[eo])}),et}(c.relay))));return await this.pairings.set(et,{topic:et,expiry:eo,relay:es,active:!1}),await this.core.relayer.subscribe(et),this.core.expirer.set(et,eo),{topic:et,uri:ec}},this.pair=async c=>{this.isInitialized(),this.isValidPair(c);let{topic:l,symKey:et,relay:eo}=function(c){var l;let et=c.indexOf(":"),eo=-1!==c.indexOf("?")?c.indexOf("?"):void 0,es=c.substring(0,et),ec=c.substring(et+1,eo).split("@"),el="u">typeof eo?c.substring(eo):"",ed=t$.parse(el);return{protocol:es,topic:(l=ec[0]).startsWith("//")?l.substring(2):l,version:parseInt(ec[1],10),symKey:ed.symKey,relay:function(c,l="-"){let et={},eo="relay"+l;return Object.keys(c).forEach(l=>{if(l.startsWith(eo)){let es=l.replace(eo,""),ec=c[l];et[es]=ec}}),et}(ed)}}(c.uri);if(this.pairings.keys.includes(l)&&this.pairings.get(l).active)throw Error(`Pairing already exists: ${l}. Please try again with a new connection URI.`);this.core.crypto.keychain.has(l)||(await this.core.crypto.setSymKey(et,l),await this.core.relayer.subscribe(l,{relay:eo}));let es=index_es_lt(ty.FIVE_MINUTES),ec={topic:l,relay:eo,expiry:es,active:!1};return await this.pairings.set(l,ec),this.core.expirer.set(l,es),c.activatePairing&&await this.activate({topic:l}),this.events.emit(ns.create,ec),ec},this.activate=async({topic:c})=>{this.isInitialized();let l=index_es_lt(ty.THIRTY_DAYS);await this.pairings.update(c,{active:!0,expiry:l}),this.core.expirer.set(c,l)},this.ping=async c=>{this.isInitialized(),await this.isValidPing(c);let{topic:l}=c;if(this.pairings.keys.includes(l)){let c=await this.sendRequest(l,"wc_pairingPing",{}),{done:et,resolve:eo,reject:es}=index_es_st();this.events.once(index_es_ft("pairing_ping",c),({error:c})=>{c?es(c):eo()}),await et()}},this.updateExpiry=async({topic:c,expiry:l})=>{this.isInitialized(),await this.pairings.update(c,{expiry:l})},this.updateMetadata=async({topic:c,metadata:l})=>{this.isInitialized(),await this.pairings.update(c,{peerMetadata:l})},this.getPairings=()=>(this.isInitialized(),this.pairings.values),this.disconnect=async c=>{this.isInitialized(),await this.isValidDisconnect(c);let{topic:l}=c;this.pairings.keys.includes(l)&&(await this.sendRequest(l,"wc_pairingDelete",index_es_U("USER_DISCONNECTED")),await this.deletePairing(l))},this.sendRequest=async(c,l,et)=>{let eo=formatJsonRpcRequest(l,et),es=await this.core.crypto.encode(c,eo),ec=no[l].req;return this.core.history.set(c,eo),this.core.relayer.publish(c,es,ec),eo.id},this.sendResult=async(c,l,et)=>{let eo=formatJsonRpcResult(c,et),es=await this.core.crypto.encode(l,eo),ec=await this.core.history.get(l,c),el=no[ec.request.method].res;await this.core.relayer.publish(l,es,el),await this.core.history.resolve(eo)},this.sendError=async(c,l,et)=>{let eo=formatJsonRpcError(c,et),es=await this.core.crypto.encode(l,eo),ec=await this.core.history.get(l,c),el=no[ec.request.method]?no[ec.request.method].res:no.unregistered_method.res;await this.core.relayer.publish(l,es,el),await this.core.history.resolve(eo)},this.deletePairing=async(c,l)=>{await this.core.relayer.unsubscribe(c),await Promise.all([this.pairings.delete(c,index_es_U("USER_DISCONNECTED")),this.core.crypto.deleteSymKey(c),l?Promise.resolve():this.core.expirer.del(c)])},this.cleanup=async()=>{let c=this.pairings.getAll().filter(c=>index_es_dt(c.expiry));await Promise.all(c.map(c=>this.deletePairing(c.topic)))},this.onRelayEventRequest=c=>{let{topic:l,payload:et}=c;switch(et.method){case"wc_pairingPing":return this.onPairingPingRequest(l,et);case"wc_pairingDelete":return this.onPairingDeleteRequest(l,et);default:return this.onUnknownRpcMethodRequest(l,et)}},this.onRelayEventResponse=async c=>{let{topic:l,payload:et}=c,eo=(await this.core.history.get(l,et.id)).request.method;return"wc_pairingPing"===eo?this.onPairingPingResponse(l,et):this.onUnknownRpcMethodResponse(eo)},this.onPairingPingRequest=async(c,l)=>{let{id:et}=l;try{this.isValidPing({topic:c}),await this.sendResult(et,c,!0),this.events.emit(ns.ping,{id:et,topic:c})}catch(l){await this.sendError(et,c,l),this.logger.error(l)}},this.onPairingPingResponse=(c,l)=>{let{id:et}=l;setTimeout(()=>{isJsonRpcResult(l)?this.events.emit(index_es_ft("pairing_ping",et),{}):isJsonRpcError(l)&&this.events.emit(index_es_ft("pairing_ping",et),{error:l.error})},500)},this.onPairingDeleteRequest=async(c,l)=>{let{id:et}=l;try{this.isValidDisconnect({topic:c}),await this.deletePairing(c),this.events.emit(ns.delete,{id:et,topic:c})}catch(l){await this.sendError(et,c,l),this.logger.error(l)}},this.onUnknownRpcMethodRequest=async(c,l)=>{let{id:et,method:eo}=l;try{if(this.registeredMethods.includes(eo))return;let l=index_es_U("WC_METHOD_UNSUPPORTED",eo);await this.sendError(et,c,l),this.logger.error(l)}catch(l){await this.sendError(et,c,l),this.logger.error(l)}},this.onUnknownRpcMethodResponse=c=>{this.registeredMethods.includes(c)||this.logger.error(index_es_U("WC_METHOD_UNSUPPORTED",c))},this.isValidPair=c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`pair() params: ${c}`);throw Error(l)}if(!function(c){if(dist_index_es_h(c,!1))try{return"u">typeof new URL(c)}catch{}return!1}(c.uri)){let{message:l}=index_es_N("MISSING_OR_INVALID",`pair() uri: ${c.uri}`);throw Error(l)}},this.isValidPing=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`ping() params: ${c}`);throw Error(l)}let{topic:l}=c;await this.isValidPairingTopic(l)},this.isValidDisconnect=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`disconnect() params: ${c}`);throw Error(l)}let{topic:l}=c;await this.isValidPairingTopic(l)},this.isValidPairingTopic=async c=>{if(!dist_index_es_h(c,!1)){let{message:l}=index_es_N("MISSING_OR_INVALID",`pairing topic should be a string: ${c}`);throw Error(l)}if(!this.pairings.keys.includes(c)){let{message:l}=index_es_N("NO_MATCHING_KEY",`pairing topic doesn't exist: ${c}`);throw Error(l)}if(index_es_dt(this.pairings.get(c).expiry)){await this.deletePairing(c);let{message:l}=index_es_N("EXPIRED",`pairing topic: ${c}`);throw Error(l)}},this.core=c,this.logger=(0,tC.generateChildLogger)(l,this.name),this.pairings=new dist_index_es_Ft(this.core,this.logger,this.name,this.storagePrefix)}get context(){return(0,tC.getLoggerContext)(this.logger)}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}registerRelayerEvents(){this.core.relayer.on(r4.message,async c=>{let{topic:l,message:et}=c;if(!this.pairings.keys.includes(l)||this.ignoredPayloadTypes.includes(this.core.crypto.getPayloadType(et)))return;let eo=await this.core.crypto.decode(l,et);try{isJsonRpcRequest(eo)?(this.core.history.set(l,eo),this.onRelayEventRequest({topic:l,payload:eo})):isJsonRpcResponse(eo)&&(await this.core.history.resolve(eo),await this.onRelayEventResponse({topic:l,payload:eo}),this.core.history.delete(l,eo.id))}catch(c){this.logger.error(c)}})}registerExpirerEvents(){this.core.expirer.on(nl.expired,async c=>{let{topic:l}=index_es_ut(c.target);l&&this.pairings.keys.includes(l)&&(await this.deletePairing(l,!0),this.events.emit(ns.expire,{topic:l}))})}};let dist_index_es_Mt=class dist_index_es_Mt extends index_es_h{constructor(c,l){super(c,l),this.core=c,this.logger=l,this.records=new Map,this.events=new eE.EventEmitter,this.name="history",this.version="0.3",this.cached=[],this.initialized=!1,this.storagePrefix=rZ,this.init=async()=>{this.initialized||(this.logger.trace("Initialized"),await this.restore(),this.cached.forEach(c=>this.records.set(c.id,c)),this.cached=[],this.registerEventListeners(),this.initialized=!0)},this.set=(c,l,et)=>{if(this.isInitialized(),this.logger.debug("Setting JSON-RPC request history record"),this.logger.trace({type:"method",method:"set",topic:c,request:l,chainId:et}),this.records.has(l.id))return;let eo={id:l.id,topic:c,request:{method:l.method,params:l.params||null},chainId:et,expiry:index_es_lt(ty.THIRTY_DAYS)};this.records.set(eo.id,eo),this.events.emit(nc.created,eo)},this.resolve=async c=>{if(this.isInitialized(),this.logger.debug("Updating JSON-RPC response history record"),this.logger.trace({type:"method",method:"update",response:c}),!this.records.has(c.id))return;let l=await this.getRecord(c.id);typeof l.response>"u"&&(l.response=isJsonRpcError(c)?{error:c.error}:{result:c.result},this.records.set(l.id,l),this.events.emit(nc.updated,l))},this.get=async(c,l)=>(this.isInitialized(),this.logger.debug("Getting record"),this.logger.trace({type:"method",method:"get",topic:c,id:l}),await this.getRecord(l)),this.delete=(c,l)=>{this.isInitialized(),this.logger.debug("Deleting record"),this.logger.trace({type:"method",method:"delete",id:l}),this.values.forEach(et=>{et.topic!==c||"u">typeof l&&et.id!==l||(this.records.delete(et.id),this.events.emit(nc.deleted,et))})},this.exists=async(c,l)=>(this.isInitialized(),!!this.records.has(l)&&(await this.getRecord(l)).topic===c),this.on=(c,l)=>{this.events.on(c,l)},this.once=(c,l)=>{this.events.once(c,l)},this.off=(c,l)=>{this.events.off(c,l)},this.removeListener=(c,l)=>{this.events.removeListener(c,l)},this.logger=(0,tC.generateChildLogger)(l,this.name)}get context(){return(0,tC.getLoggerContext)(this.logger)}get storageKey(){return this.storagePrefix+this.version+this.core.customStoragePrefix+"//"+this.name}get size(){return this.records.size}get keys(){return Array.from(this.records.keys())}get values(){return Array.from(this.records.values())}get pending(){let c=[];return this.values.forEach(l=>{if("u">typeof l.response)return;let et={topic:l.topic,request:formatJsonRpcRequest(l.request.method,l.request.params,l.id),chainId:l.chainId};return c.push(et)}),c}async setJsonRpcRecords(c){await this.core.storage.setItem(this.storageKey,c)}async getJsonRpcRecords(){return await this.core.storage.getItem(this.storageKey)}getRecord(c){this.isInitialized();let l=this.records.get(c);if(!l){let{message:l}=index_es_N("NO_MATCHING_KEY",`${this.name}: ${c}`);throw Error(l)}return l}async persist(){await this.setJsonRpcRecords(this.values),this.events.emit(nc.sync)}async restore(){try{let c=await this.getJsonRpcRecords();if(typeof c>"u"||!c.length)return;if(this.records.size){let{message:c}=index_es_N("RESTORE_WILL_OVERRIDE",this.name);throw this.logger.error(c),Error(c)}this.cached=c,this.logger.debug(`Successfully Restored records for ${this.name}`),this.logger.trace({type:"method",method:"restore",records:this.values})}catch(c){this.logger.debug(`Failed to Restore records for ${this.name}`),this.logger.error(c)}}registerEventListeners(){this.events.on(nc.created,c=>{let l=nc.created;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,record:c}),this.persist()}),this.events.on(nc.updated,c=>{let l=nc.updated;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,record:c}),this.persist()}),this.events.on(nc.deleted,c=>{let l=nc.deleted;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,record:c}),this.persist()}),this.core.heartbeat.on(tk.HEARTBEAT_EVENTS.pulse,()=>{this.cleanup()})}cleanup(){try{this.records.forEach(c=>{(0,ty.toMiliseconds)(c.expiry||0)-Date.now()<=0&&(this.logger.info(`Deleting expired history log: ${c.id}`),this.delete(c.topic,c.id))})}catch(c){this.logger.warn(c)}}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}};let dist_index_es_kt=class dist_index_es_kt extends index_es_E{constructor(c,l){super(c,l),this.core=c,this.logger=l,this.expirations=new Map,this.events=new eE.EventEmitter,this.name="expirer",this.version="0.3",this.cached=[],this.initialized=!1,this.storagePrefix=rZ,this.init=async()=>{this.initialized||(this.logger.trace("Initialized"),await this.restore(),this.cached.forEach(c=>this.expirations.set(c.target,c)),this.cached=[],this.registerEventListeners(),this.initialized=!0)},this.has=c=>{try{let l=this.formatTarget(c);return"u">typeof this.getExpiration(l)}catch{return!1}},this.set=(c,l)=>{this.isInitialized();let et=this.formatTarget(c),eo={target:et,expiry:l};this.expirations.set(et,eo),this.checkExpiry(et,eo),this.events.emit(nl.created,{target:et,expiration:eo})},this.get=c=>{this.isInitialized();let l=this.formatTarget(c);return this.getExpiration(l)},this.del=c=>{if(this.isInitialized(),this.has(c)){let l=this.formatTarget(c),et=this.getExpiration(l);this.expirations.delete(l),this.events.emit(nl.deleted,{target:l,expiration:et})}},this.on=(c,l)=>{this.events.on(c,l)},this.once=(c,l)=>{this.events.once(c,l)},this.off=(c,l)=>{this.events.off(c,l)},this.removeListener=(c,l)=>{this.events.removeListener(c,l)},this.logger=(0,tC.generateChildLogger)(l,this.name)}get context(){return(0,tC.getLoggerContext)(this.logger)}get storageKey(){return this.storagePrefix+this.version+this.core.customStoragePrefix+"//"+this.name}get length(){return this.expirations.size}get keys(){return Array.from(this.expirations.keys())}get values(){return Array.from(this.expirations.values())}formatTarget(c){if("string"==typeof c)return index_es_re("topic",c);if("number"==typeof c)return index_es_re("id",c);let{message:l}=index_es_N("UNKNOWN_TYPE",`Target type: ${typeof c}`);throw Error(l)}async setExpirations(c){await this.core.storage.setItem(this.storageKey,c)}async getExpirations(){return await this.core.storage.getItem(this.storageKey)}async persist(){await this.setExpirations(this.values),this.events.emit(nl.sync)}async restore(){try{let c=await this.getExpirations();if(typeof c>"u"||!c.length)return;if(this.expirations.size){let{message:c}=index_es_N("RESTORE_WILL_OVERRIDE",this.name);throw this.logger.error(c),Error(c)}this.cached=c,this.logger.debug(`Successfully Restored expirations for ${this.name}`),this.logger.trace({type:"method",method:"restore",expirations:this.values})}catch(c){this.logger.debug(`Failed to Restore expirations for ${this.name}`),this.logger.error(c)}}getExpiration(c){let l=this.expirations.get(c);if(!l){let{message:l}=index_es_N("NO_MATCHING_KEY",`${this.name}: ${c}`);throw this.logger.error(l),Error(l)}return l}checkExpiry(c,l){let{expiry:et}=l;(0,ty.toMiliseconds)(et)-Date.now()<=0&&this.expire(c,l)}expire(c,l){this.expirations.delete(c),this.events.emit(nl.expired,{target:c,expiration:l})}checkExpirations(){this.core.relayer.connected&&this.expirations.forEach((c,l)=>this.checkExpiry(l,c))}registerEventListeners(){this.core.heartbeat.on(tk.HEARTBEAT_EVENTS.pulse,()=>this.checkExpirations()),this.events.on(nl.created,c=>{let l=nl.created;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,data:c}),this.persist()}),this.events.on(nl.expired,c=>{let l=nl.expired;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,data:c}),this.persist()}),this.events.on(nl.deleted,c=>{let l=nl.deleted;this.logger.info(`Emitting ${l}`),this.logger.debug({type:"event",event:l,data:c}),this.persist()})}isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}}};let dist_index_es_Kt=class dist_index_es_Kt extends y{constructor(c,l){super(c,l),this.projectId=c,this.logger=l,this.name=nd,this.initialized=!1,this.queue=[],this.verifyDisabled=!1,this.init=async()=>{if(!(this.verifyDisabled||index_es_j())&&index_es_q()){this.verifyUrl!==nh&&this.removeIframe(),this.verifyUrl=nh;try{await this.createIframe()}catch(c){this.logger.info(`Verify iframe failed to load: ${this.verifyUrl}`),this.logger.info(c)}if(!this.initialized){this.removeIframe(),this.verifyUrl=nf;try{await this.createIframe()}catch(c){this.logger.info(`Verify iframe failed to load: ${this.verifyUrl}`),this.logger.info(c),this.verifyDisabled=!0}}}},this.register=async c=>{this.initialized?this.sendPost(c.attestationId):(this.addToQueue(c.attestationId),await this.init())},this.resolve=async c=>{let l;if(this.isDevEnv)return"";let et=c?.verifyUrl||nh;try{l=await this.fetchAttestation(c.attestationId,et)}catch(eo){this.logger.info(`failed to resolve attestation: ${c.attestationId} from url: ${et}`),this.logger.info(eo),l=await this.fetchAttestation(c.attestationId,nf)}return l},this.fetchAttestation=async(c,l)=>{this.logger.info(`resolving attestation: ${c} from url: ${l}`);let et=this.startAbortTimer(2*ty.ONE_SECOND),eo=await fetch(`${l}/attestation/${c}`,{signal:this.abortController.signal});return clearTimeout(et),200===eo.status?await eo.json():void 0},this.addToQueue=c=>{this.queue.push(c)},this.processQueue=()=>{0!==this.queue.length&&(this.queue.forEach(c=>this.sendPost(c)),this.queue=[])},this.sendPost=c=>{var l;try{if(!this.iframe)return;null==(l=this.iframe.contentWindow)||l.postMessage(c,"*"),this.logger.info(`postMessage sent: ${c} ${this.verifyUrl}`)}catch{}},this.createIframe=async()=>{let c;let s=l=>{"verify_ready"===l.data&&(this.initialized=!0,this.processQueue(),window.removeEventListener("message",s),c())};await Promise.race([new Promise(l=>{if(document.getElementById(nd))return l();window.addEventListener("message",s);let et=document.createElement("iframe");et.id=nd,et.src=`${this.verifyUrl}/${this.projectId}`,et.style.display="none",document.body.append(et),this.iframe=et,c=l}),new Promise((c,l)=>setTimeout(()=>{window.removeEventListener("message",s),l("verify iframe load timeout")},(0,ty.toMiliseconds)(ty.FIVE_SECONDS)))])},this.removeIframe=()=>{this.iframe&&(this.iframe.remove(),this.iframe=void 0,this.initialized=!1)},this.logger=(0,tC.generateChildLogger)(l,this.name),this.verifyUrl=nh,this.abortController=new AbortController,this.isDevEnv=index_es_te()&&t9.env.IS_VITEST}get context(){return(0,tC.getLoggerContext)(this.logger)}startAbortTimer(c){return this.abortController=new AbortController,setTimeout(()=>this.abortController.abort(),(0,ty.toMiliseconds)(c))}};var nP=Object.defineProperty,nR=Object.getOwnPropertySymbols,nO=Object.prototype.hasOwnProperty,nT=Object.prototype.propertyIsEnumerable,dist_index_es_Vt=(c,l,et)=>l in c?nP(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,dist_index_es_qt=(c,l)=>{for(var et in l||(l={}))nO.call(l,et)&&dist_index_es_Vt(c,et,l[et]);if(nR)for(var et of nR(l))nT.call(l,et)&&dist_index_es_Vt(c,et,l[et]);return c};let dist_index_es_ee=class dist_index_es_ee extends n{constructor(c){super(c),this.protocol="wc",this.version=2,this.name=rY,this.events=new eE.EventEmitter,this.initialized=!1,this.on=(c,l)=>this.events.on(c,l),this.once=(c,l)=>this.events.once(c,l),this.off=(c,l)=>this.events.off(c,l),this.removeListener=(c,l)=>this.events.removeListener(c,l),this.projectId=c?.projectId,this.relayUrl=c?.relayUrl||r5,this.customStoragePrefix=null!=c&&c.customStoragePrefix?`:${c.customStoragePrefix}`:"";let l="u">typeof c?.logger&&"string"!=typeof c?.logger?c.logger:(0,tC.pino)((0,tC.getDefaultLoggerOptions)({level:c?.logger||rX.logger}));this.logger=(0,tC.generateChildLogger)(l,this.name),this.heartbeat=new tk.HeartBeat,this.crypto=new dist_index_es_t(this,this.logger,c?.keychain),this.history=new dist_index_es_Mt(this,this.logger),this.expirer=new dist_index_es_kt(this,this.logger),this.storage=null!=c&&c.storage?c.storage:new tx.ZP(dist_index_es_qt(dist_index_es_qt({},r0),c?.storageOptions)),this.relayer=new dist_index_es_zt({core:this,logger:this.logger,relayUrl:this.relayUrl,projectId:this.projectId}),this.pairing=new dist_index_es_$t(this,this.logger),this.verify=new dist_index_es_Kt(this.projectId||"",this.logger)}static async init(c){let l=new dist_index_es_ee(c);await l.initialize();let et=await l.crypto.getClientId();return await l.storage.setItem("WALLETCONNECT_CLIENT_ID",et),l}get context(){return(0,tC.getLoggerContext)(this.logger)}async start(){this.initialized||await this.initialize()}async initialize(){this.logger.trace("Initialized");try{await this.crypto.init(),await this.history.init(),await this.expirer.init(),await this.relayer.init(),await this.heartbeat.init(),await this.pairing.init(),this.initialized=!0,this.logger.info("Core Initialization Success")}catch(c){throw this.logger.warn(`Core Initialization Failure at epoch ${Date.now()}`,c),this.logger.error(c.message),c}}};let nN="client",nM=`wc@2:${nN}:`,n$={name:nN,logger:"error"},nB="WALLETCONNECT_DEEPLINK_CHOICE",nD="Proposal expired",nj=ty.SEVEN_DAYS,nL={wc_sessionPropose:{req:{ttl:ty.FIVE_MINUTES,prompt:!0,tag:1100},res:{ttl:ty.FIVE_MINUTES,prompt:!1,tag:1101}},wc_sessionSettle:{req:{ttl:ty.FIVE_MINUTES,prompt:!1,tag:1102},res:{ttl:ty.FIVE_MINUTES,prompt:!1,tag:1103}},wc_sessionUpdate:{req:{ttl:ty.ONE_DAY,prompt:!1,tag:1104},res:{ttl:ty.ONE_DAY,prompt:!1,tag:1105}},wc_sessionExtend:{req:{ttl:ty.ONE_DAY,prompt:!1,tag:1106},res:{ttl:ty.ONE_DAY,prompt:!1,tag:1107}},wc_sessionRequest:{req:{ttl:ty.FIVE_MINUTES,prompt:!0,tag:1108},res:{ttl:ty.FIVE_MINUTES,prompt:!1,tag:1109}},wc_sessionEvent:{req:{ttl:ty.FIVE_MINUTES,prompt:!0,tag:1110},res:{ttl:ty.FIVE_MINUTES,prompt:!1,tag:1111}},wc_sessionDelete:{req:{ttl:ty.ONE_DAY,prompt:!1,tag:1112},res:{ttl:ty.ONE_DAY,prompt:!1,tag:1113}},wc_sessionPing:{req:{ttl:ty.THIRTY_SECONDS,prompt:!1,tag:1114},res:{ttl:ty.THIRTY_SECONDS,prompt:!1,tag:1115}}},nF={min:ty.FIVE_MINUTES,max:ty.SEVEN_DAYS},nU={idle:"IDLE",active:"ACTIVE"},nz=["wc_sessionPropose","wc_sessionRequest","wc_authRequest"];var nq=Object.defineProperty,nH=Object.defineProperties,nW=Object.getOwnPropertyDescriptors,nV=Object.getOwnPropertySymbols,nG=Object.prototype.hasOwnProperty,nK=Object.prototype.propertyIsEnumerable,dist_index_es_de=(c,l,et)=>l in c?nq(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,sign_client_dist_index_es_g=(c,l)=>{for(var et in l||(l={}))nG.call(l,et)&&dist_index_es_de(c,et,l[et]);if(nV)for(var et of nV(l))nK.call(l,et)&&dist_index_es_de(c,et,l[et]);return c},index_es_b=(c,l)=>nH(c,nW(l));let index_es_ps=class index_es_ps extends index_es_S{constructor(c){super(c),this.name="engine",this.events=new(eS()),this.initialized=!1,this.ignoredPayloadTypes=[1],this.requestQueue={state:nU.idle,queue:[]},this.sessionRequestQueue={state:nU.idle,queue:[]},this.requestQueueDelay=ty.ONE_SECOND,this.init=async()=>{this.initialized||(await this.cleanup(),this.registerRelayerEvents(),this.registerExpirerEvents(),this.registerPairingEvents(),this.client.core.pairing.register({methods:Object.keys(nL)}),this.initialized=!0,setTimeout(()=>{this.sessionRequestQueue.queue=this.getPendingSessionRequests(),this.processSessionRequestQueue()},(0,ty.toMiliseconds)(this.requestQueueDelay)))},this.connect=async c=>{await this.isInitialized();let l=index_es_b(sign_client_dist_index_es_g({},c),{requiredNamespaces:c.requiredNamespaces||{},optionalNamespaces:c.optionalNamespaces||{}});await this.isValidConnect(l);let{pairingTopic:et,requiredNamespaces:eo,optionalNamespaces:es,sessionProperties:ec,relays:el}=l,ed=et,eh,ef=!1;if(ed&&(ef=this.client.core.pairing.pairings.get(ed).active),!ed||!ef){let{topic:c,uri:l}=await this.client.core.pairing.create();ed=c,eh=l}let ep=await this.client.core.crypto.generateKeyPair(),eg=sign_client_dist_index_es_g({requiredNamespaces:eo,optionalNamespaces:es,relays:el??[{protocol:"irn"}],proposer:{publicKey:ep,metadata:this.client.metadata}},ec&&{sessionProperties:ec}),{reject:em,resolve:eb,done:ey}=index_es_st(ty.FIVE_MINUTES,nD);if(this.events.once(index_es_ft("session_connect"),async({error:c,session:l})=>{if(c)em(c);else if(l){l.self.publicKey=ep;let c=index_es_b(sign_client_dist_index_es_g({},l),{requiredNamespaces:l.requiredNamespaces,optionalNamespaces:l.optionalNamespaces});await this.client.session.set(l.topic,c),await this.setExpiry(l.topic,l.expiry),ed&&await this.client.core.pairing.updateMetadata({topic:ed,metadata:l.peer.metadata}),eb(c)}}),!ed){let{message:c}=index_es_N("NO_MATCHING_KEY",`connect() pairing topic: ${ed}`);throw Error(c)}let e_=await this.sendRequest({topic:ed,method:"wc_sessionPropose",params:eg}),ew=index_es_lt(ty.FIVE_MINUTES);return await this.setProposal(e_,sign_client_dist_index_es_g({id:e_,expiry:ew},eg)),{uri:eh,approval:ey}},this.pair=async c=>(await this.isInitialized(),await this.client.core.pairing.pair(c)),this.approve=async c=>{await this.isInitialized(),await this.isValidApprove(c);let{id:l,relayProtocol:et,namespaces:eo,sessionProperties:es}=c,ec=this.client.proposal.get(l),{pairingTopic:el,proposer:ed,requiredNamespaces:eh,optionalNamespaces:ef}=ec;el=el||"",index_es_B(eh)||(eh=function(c,l){let et=index_es_cn(c,l);if(et)throw Error(et.message);let eo={};for(let[l,et]of Object.entries(c))eo[l]={methods:et.methods,events:et.events,chains:et.accounts.map(c=>`${c.split(":")[0]}:${c.split(":")[1]}`)};return eo}(eo,"approve()"));let ep=await this.client.core.crypto.generateKeyPair(),eg=ed.publicKey,em=await this.client.core.crypto.generateSharedKey(ep,eg);el&&l&&(await this.client.core.pairing.updateMetadata({topic:el,metadata:ed.metadata}),await this.sendResult({id:l,topic:el,result:{relay:{protocol:et??"irn"},responderPublicKey:ep}}),await this.client.proposal.delete(l,index_es_U("USER_DISCONNECTED")),await this.client.core.pairing.activate({topic:el}));let eb=sign_client_dist_index_es_g({relay:{protocol:et??"irn"},namespaces:eo,requiredNamespaces:eh,optionalNamespaces:ef,pairingTopic:el,controller:{publicKey:ep,metadata:this.client.metadata},expiry:index_es_lt(nj)},es&&{sessionProperties:es});await this.client.core.relayer.subscribe(em),await this.sendRequest({topic:em,method:"wc_sessionSettle",params:eb,throwOnFailedPublish:!0});let ey=index_es_b(sign_client_dist_index_es_g({},eb),{topic:em,pairingTopic:el,acknowledged:!1,self:eb.controller,peer:{publicKey:ed.publicKey,metadata:ed.metadata},controller:ep});return await this.client.session.set(em,ey),await this.setExpiry(em,index_es_lt(nj)),{topic:em,acknowledged:()=>new Promise(c=>setTimeout(()=>c(this.client.session.get(em)),500))}},this.reject=async c=>{await this.isInitialized(),await this.isValidReject(c);let{id:l,reason:et}=c,{pairingTopic:eo}=this.client.proposal.get(l);eo&&(await this.sendError(l,eo,et),await this.client.proposal.delete(l,index_es_U("USER_DISCONNECTED")))},this.update=async c=>{await this.isInitialized(),await this.isValidUpdate(c);let{topic:l,namespaces:et}=c,eo=await this.sendRequest({topic:l,method:"wc_sessionUpdate",params:{namespaces:et}}),{done:es,resolve:ec,reject:el}=index_es_st();return this.events.once(index_es_ft("session_update",eo),({error:c})=>{c?el(c):ec()}),await this.client.session.update(l,{namespaces:et}),{acknowledged:es}},this.extend=async c=>{await this.isInitialized(),await this.isValidExtend(c);let{topic:l}=c,et=await this.sendRequest({topic:l,method:"wc_sessionExtend",params:{}}),{done:eo,resolve:es,reject:ec}=index_es_st();return this.events.once(index_es_ft("session_extend",et),({error:c})=>{c?ec(c):es()}),await this.setExpiry(l,index_es_lt(nj)),{acknowledged:eo}},this.request=async c=>{await this.isInitialized(),await this.isValidRequest(c);let{chainId:l,request:et,topic:eo,expiry:es}=c,ec=payloadId(),{done:el,resolve:ed,reject:eh}=index_es_st(es,"Request expired. Please try again.");return this.events.once(index_es_ft("session_request",ec),({error:c,result:l})=>{c?eh(c):ed(l)}),await Promise.all([new Promise(async c=>{await this.sendRequest({clientRpcId:ec,topic:eo,method:"wc_sessionRequest",params:{request:et,chainId:l},expiry:es,throwOnFailedPublish:!0}).catch(c=>eh(c)),this.client.events.emit("session_request_sent",{topic:eo,request:et,chainId:l,id:ec}),c()}),new Promise(async c=>{let l=await this.client.core.storage.getItem(nB);index_es_pt({id:ec,topic:eo,wcDeepLink:l}),c()}),el()]).then(c=>c[2])},this.respond=async c=>{await this.isInitialized(),await this.isValidRespond(c);let{topic:l,response:et}=c,{id:eo}=et;isJsonRpcResult(et)?await this.sendResult({id:eo,topic:l,result:et.result,throwOnFailedPublish:!0}):isJsonRpcError(et)&&await this.sendError(eo,l,et.error),this.cleanupAfterResponse(c)},this.ping=async c=>{await this.isInitialized(),await this.isValidPing(c);let{topic:l}=c;if(this.client.session.keys.includes(l)){let c=await this.sendRequest({topic:l,method:"wc_sessionPing",params:{}}),{done:et,resolve:eo,reject:es}=index_es_st();this.events.once(index_es_ft("session_ping",c),({error:c})=>{c?es(c):eo()}),await et()}else this.client.core.pairing.pairings.keys.includes(l)&&await this.client.core.pairing.ping({topic:l})},this.emit=async c=>{await this.isInitialized(),await this.isValidEmit(c);let{topic:l,event:et,chainId:eo}=c;await this.sendRequest({topic:l,method:"wc_sessionEvent",params:{event:et,chainId:eo}})},this.disconnect=async c=>{await this.isInitialized(),await this.isValidDisconnect(c);let{topic:l}=c;this.client.session.keys.includes(l)?(await this.sendRequest({topic:l,method:"wc_sessionDelete",params:index_es_U("USER_DISCONNECTED"),throwOnFailedPublish:!0}),await this.deleteSession(l)):await this.client.core.pairing.disconnect({topic:l})},this.find=c=>(this.isInitialized(),this.client.session.getAll().filter(l=>(function(c,l){let{requiredNamespaces:et}=l,eo=Object.keys(c.namespaces),es=Object.keys(et),ec=!0;return!!index_es_O(es,eo)&&(eo.forEach(l=>{let{accounts:eo,methods:es,events:el}=c.namespaces[l],ed=index_es_A(eo),eh=et[l];index_es_O(index_es_K(l,eh),ed)&&index_es_O(eh.methods,es)&&index_es_O(eh.events,el)||(ec=!1)}),ec)})(l,c))),this.getPendingSessionRequests=()=>(this.isInitialized(),this.client.pendingRequest.getAll()),this.cleanupDuplicatePairings=async c=>{if(c.pairingTopic)try{let l=this.client.core.pairing.pairings.get(c.pairingTopic),et=this.client.core.pairing.pairings.getAll().filter(et=>{var eo,es;return(null==(eo=et.peerMetadata)?void 0:eo.url)&&(null==(es=et.peerMetadata)?void 0:es.url)===c.peer.metadata.url&&et.topic&&et.topic!==l.topic});if(0===et.length)return;this.client.logger.info(`Cleaning up ${et.length} duplicate pairing(s)`),await Promise.all(et.map(c=>this.client.core.pairing.disconnect({topic:c.topic}))),this.client.logger.info("Duplicate pairings clean up finished")}catch(c){this.client.logger.error(c)}},this.deleteSession=async(c,l)=>{let{self:et}=this.client.session.get(c);await this.client.core.relayer.unsubscribe(c),this.client.session.delete(c,index_es_U("USER_DISCONNECTED")),this.client.core.crypto.keychain.has(et.publicKey)&&await this.client.core.crypto.deleteKeyPair(et.publicKey),this.client.core.crypto.keychain.has(c)&&await this.client.core.crypto.deleteSymKey(c),l||this.client.core.expirer.del(c),this.client.core.storage.removeItem(nB).catch(c=>this.client.logger.warn(c))},this.deleteProposal=async(c,l)=>{await Promise.all([this.client.proposal.delete(c,index_es_U("USER_DISCONNECTED")),l?Promise.resolve():this.client.core.expirer.del(c)])},this.deletePendingSessionRequest=async(c,l,et=!1)=>{await Promise.all([this.client.pendingRequest.delete(c,l),et?Promise.resolve():this.client.core.expirer.del(c)]),this.sessionRequestQueue.queue=this.sessionRequestQueue.queue.filter(l=>l.id!==c),et&&(this.sessionRequestQueue.state=nU.idle)},this.setExpiry=async(c,l)=>{this.client.session.keys.includes(c)&&await this.client.session.update(c,{expiry:l}),this.client.core.expirer.set(c,l)},this.setProposal=async(c,l)=>{await this.client.proposal.set(c,l),this.client.core.expirer.set(c,l.expiry)},this.setPendingSessionRequest=async c=>{let l=nL.wc_sessionRequest.req.ttl,{id:et,topic:eo,params:es,verifyContext:ec}=c;await this.client.pendingRequest.set(et,{id:et,topic:eo,params:es,verifyContext:ec}),l&&this.client.core.expirer.set(et,index_es_lt(l))},this.sendRequest=async c=>{let{topic:l,method:et,params:eo,expiry:es,relayRpcId:ec,clientRpcId:el,throwOnFailedPublish:ed}=c,eh=formatJsonRpcRequest(et,eo,el);if(index_es_q()&&nz.includes(et)){let c=index_es_Mn(JSON.stringify(eh));this.client.core.verify.register({attestationId:c})}let ef=await this.client.core.crypto.encode(l,eh),ep=nL[et].req;return es&&(ep.ttl=es),ec&&(ep.id=ec),this.client.core.history.set(l,eh),ed?(ep.internal=index_es_b(sign_client_dist_index_es_g({},ep.internal),{throwOnFailedPublish:!0}),await this.client.core.relayer.publish(l,ef,ep)):this.client.core.relayer.publish(l,ef,ep).catch(c=>this.client.logger.error(c)),eh.id},this.sendResult=async c=>{let{id:l,topic:et,result:eo,throwOnFailedPublish:es}=c,ec=formatJsonRpcResult(l,eo),el=await this.client.core.crypto.encode(et,ec),ed=await this.client.core.history.get(et,l),eh=nL[ed.request.method].res;es?(eh.internal=index_es_b(sign_client_dist_index_es_g({},eh.internal),{throwOnFailedPublish:!0}),await this.client.core.relayer.publish(et,el,eh)):this.client.core.relayer.publish(et,el,eh).catch(c=>this.client.logger.error(c)),await this.client.core.history.resolve(ec)},this.sendError=async(c,l,et)=>{let eo=formatJsonRpcError(c,et),es=await this.client.core.crypto.encode(l,eo),ec=await this.client.core.history.get(l,c),el=nL[ec.request.method].res;this.client.core.relayer.publish(l,es,el),await this.client.core.history.resolve(eo)},this.cleanup=async()=>{let c=[],l=[];this.client.session.getAll().forEach(l=>{index_es_dt(l.expiry)&&c.push(l.topic)}),this.client.proposal.getAll().forEach(c=>{index_es_dt(c.expiry)&&l.push(c.id)}),await Promise.all([...c.map(c=>this.deleteSession(c)),...l.map(c=>this.deleteProposal(c))])},this.onRelayEventRequest=async c=>{this.requestQueue.queue.push(c),await this.processRequestsQueue()},this.processRequestsQueue=async()=>{if(this.requestQueue.state===nU.active){this.client.logger.info("Request queue already active, skipping...");return}for(this.client.logger.info(`Request queue starting with ${this.requestQueue.queue.length} requests`);this.requestQueue.queue.length>0;){this.requestQueue.state=nU.active;let c=this.requestQueue.queue.shift();if(c)try{this.processRequest(c),await new Promise(c=>setTimeout(c,300))}catch(c){this.client.logger.warn(c)}}this.requestQueue.state=nU.idle},this.processRequest=c=>{let{topic:l,payload:et}=c,eo=et.method;switch(eo){case"wc_sessionPropose":return this.onSessionProposeRequest(l,et);case"wc_sessionSettle":return this.onSessionSettleRequest(l,et);case"wc_sessionUpdate":return this.onSessionUpdateRequest(l,et);case"wc_sessionExtend":return this.onSessionExtendRequest(l,et);case"wc_sessionPing":return this.onSessionPingRequest(l,et);case"wc_sessionDelete":return this.onSessionDeleteRequest(l,et);case"wc_sessionRequest":return this.onSessionRequest(l,et);case"wc_sessionEvent":return this.onSessionEventRequest(l,et);default:return this.client.logger.info(`Unsupported request method ${eo}`)}},this.onRelayEventResponse=async c=>{let{topic:l,payload:et}=c,eo=(await this.client.core.history.get(l,et.id)).request.method;switch(eo){case"wc_sessionPropose":return this.onSessionProposeResponse(l,et);case"wc_sessionSettle":return this.onSessionSettleResponse(l,et);case"wc_sessionUpdate":return this.onSessionUpdateResponse(l,et);case"wc_sessionExtend":return this.onSessionExtendResponse(l,et);case"wc_sessionPing":return this.onSessionPingResponse(l,et);case"wc_sessionRequest":return this.onSessionRequestResponse(l,et);default:return this.client.logger.info(`Unsupported response method ${eo}`)}},this.onRelayEventUnknownPayload=c=>{let{topic:l}=c,{message:et}=index_es_N("MISSING_OR_INVALID",`Decoded payload on topic ${l} is not identifiable as a JSON-RPC request or a response.`);throw Error(et)},this.onSessionProposeRequest=async(c,l)=>{let{params:et,id:eo}=l;try{this.isValidConnect(sign_client_dist_index_es_g({},l.params));let es=index_es_lt(ty.FIVE_MINUTES),ec=sign_client_dist_index_es_g({id:eo,pairingTopic:c,expiry:es},et);await this.setProposal(eo,ec);let el=index_es_Mn(JSON.stringify(l)),ed=await this.getVerifyContext(el,ec.proposer.metadata);this.client.events.emit("session_proposal",{id:eo,params:ec,verifyContext:ed})}catch(l){await this.sendError(eo,c,l),this.client.logger.error(l)}},this.onSessionProposeResponse=async(c,l)=>{let{id:et}=l;if(isJsonRpcResult(l)){let{result:eo}=l;this.client.logger.trace({type:"method",method:"onSessionProposeResponse",result:eo});let es=this.client.proposal.get(et);this.client.logger.trace({type:"method",method:"onSessionProposeResponse",proposal:es});let ec=es.proposer.publicKey;this.client.logger.trace({type:"method",method:"onSessionProposeResponse",selfPublicKey:ec});let el=eo.responderPublicKey;this.client.logger.trace({type:"method",method:"onSessionProposeResponse",peerPublicKey:el});let ed=await this.client.core.crypto.generateSharedKey(ec,el);this.client.logger.trace({type:"method",method:"onSessionProposeResponse",sessionTopic:ed});let eh=await this.client.core.relayer.subscribe(ed);this.client.logger.trace({type:"method",method:"onSessionProposeResponse",subscriptionId:eh}),await this.client.core.pairing.activate({topic:c})}else isJsonRpcError(l)&&(await this.client.proposal.delete(et,index_es_U("USER_DISCONNECTED")),this.events.emit(index_es_ft("session_connect"),{error:l.error}))},this.onSessionSettleRequest=async(c,l)=>{let{id:et,params:eo}=l;try{this.isValidSessionSettleRequest(eo);let{relay:et,controller:es,expiry:ec,namespaces:el,requiredNamespaces:ed,optionalNamespaces:eh,sessionProperties:ef,pairingTopic:ep}=l.params,eg=sign_client_dist_index_es_g({topic:c,relay:et,expiry:ec,namespaces:el,acknowledged:!0,pairingTopic:ep,requiredNamespaces:ed,optionalNamespaces:eh,controller:es.publicKey,self:{publicKey:"",metadata:this.client.metadata},peer:{publicKey:es.publicKey,metadata:es.metadata}},ef&&{sessionProperties:ef});await this.sendResult({id:l.id,topic:c,result:!0}),this.events.emit(index_es_ft("session_connect"),{session:eg}),this.cleanupDuplicatePairings(eg)}catch(l){await this.sendError(et,c,l),this.client.logger.error(l)}},this.onSessionSettleResponse=async(c,l)=>{let{id:et}=l;isJsonRpcResult(l)?(await this.client.session.update(c,{acknowledged:!0}),this.events.emit(index_es_ft("session_approve",et),{})):isJsonRpcError(l)&&(await this.client.session.delete(c,index_es_U("USER_DISCONNECTED")),this.events.emit(index_es_ft("session_approve",et),{error:l.error}))},this.onSessionUpdateRequest=async(c,l)=>{let{params:et,id:eo}=l;try{let l=`${c}_session_update`,es=index_es_er.get(l);if(es&&this.isRequestOutOfSync(es,eo)){this.client.logger.info(`Discarding out of sync request - ${eo}`);return}this.isValidUpdate(sign_client_dist_index_es_g({topic:c},et)),await this.client.session.update(c,{namespaces:et.namespaces}),await this.sendResult({id:eo,topic:c,result:!0}),this.client.events.emit("session_update",{id:eo,topic:c,params:et}),index_es_er.set(l,eo)}catch(l){await this.sendError(eo,c,l),this.client.logger.error(l)}},this.isRequestOutOfSync=(c,l)=>parseInt(l.toString().slice(0,-3))<=parseInt(c.toString().slice(0,-3)),this.onSessionUpdateResponse=(c,l)=>{let{id:et}=l;isJsonRpcResult(l)?this.events.emit(index_es_ft("session_update",et),{}):isJsonRpcError(l)&&this.events.emit(index_es_ft("session_update",et),{error:l.error})},this.onSessionExtendRequest=async(c,l)=>{let{id:et}=l;try{this.isValidExtend({topic:c}),await this.setExpiry(c,index_es_lt(nj)),await this.sendResult({id:et,topic:c,result:!0}),this.client.events.emit("session_extend",{id:et,topic:c})}catch(l){await this.sendError(et,c,l),this.client.logger.error(l)}},this.onSessionExtendResponse=(c,l)=>{let{id:et}=l;isJsonRpcResult(l)?this.events.emit(index_es_ft("session_extend",et),{}):isJsonRpcError(l)&&this.events.emit(index_es_ft("session_extend",et),{error:l.error})},this.onSessionPingRequest=async(c,l)=>{let{id:et}=l;try{this.isValidPing({topic:c}),await this.sendResult({id:et,topic:c,result:!0}),this.client.events.emit("session_ping",{id:et,topic:c})}catch(l){await this.sendError(et,c,l),this.client.logger.error(l)}},this.onSessionPingResponse=(c,l)=>{let{id:et}=l;setTimeout(()=>{isJsonRpcResult(l)?this.events.emit(index_es_ft("session_ping",et),{}):isJsonRpcError(l)&&this.events.emit(index_es_ft("session_ping",et),{error:l.error})},500)},this.onSessionDeleteRequest=async(c,l)=>{let{id:et}=l;try{this.isValidDisconnect({topic:c,reason:l.params}),await Promise.all([new Promise(l=>{this.client.core.relayer.once(r4.publish,async()=>{l(await this.deleteSession(c))})}),this.sendResult({id:et,topic:c,result:!0})]),this.client.events.emit("session_delete",{id:et,topic:c})}catch(c){this.client.logger.error(c)}},this.onSessionRequest=async(c,l)=>{let{id:et,params:eo}=l;try{this.isValidRequest(sign_client_dist_index_es_g({topic:c},eo));let l=index_es_Mn(JSON.stringify(formatJsonRpcRequest("wc_sessionRequest",eo,et))),es=this.client.session.get(c),ec=await this.getVerifyContext(l,es.peer.metadata),el={id:et,topic:c,params:eo,verifyContext:ec};await this.setPendingSessionRequest(el),this.addSessionRequestToSessionRequestQueue(el),this.processSessionRequestQueue()}catch(l){await this.sendError(et,c,l),this.client.logger.error(l)}},this.onSessionRequestResponse=(c,l)=>{let{id:et}=l;isJsonRpcResult(l)?this.events.emit(index_es_ft("session_request",et),{result:l.result}):isJsonRpcError(l)&&this.events.emit(index_es_ft("session_request",et),{error:l.error})},this.onSessionEventRequest=async(c,l)=>{let{id:et,params:eo}=l;try{let l=`${c}_session_event_${eo.event.name}`,es=index_es_er.get(l);if(es&&this.isRequestOutOfSync(es,et)){this.client.logger.info(`Discarding out of sync request - ${et}`);return}this.isValidEmit(sign_client_dist_index_es_g({topic:c},eo)),this.client.events.emit("session_event",{id:et,topic:c,params:eo}),index_es_er.set(l,et)}catch(l){await this.sendError(et,c,l),this.client.logger.error(l)}},this.addSessionRequestToSessionRequestQueue=c=>{this.sessionRequestQueue.queue.push(c)},this.cleanupAfterResponse=c=>{this.deletePendingSessionRequest(c.response.id,{message:"fulfilled",code:0}),setTimeout(()=>{this.sessionRequestQueue.state=nU.idle,this.processSessionRequestQueue()},(0,ty.toMiliseconds)(this.requestQueueDelay))},this.processSessionRequestQueue=()=>{if(this.sessionRequestQueue.state===nU.active){this.client.logger.info("session request queue is already active.");return}let c=this.sessionRequestQueue.queue[0];if(!c){this.client.logger.info("session request queue is empty.");return}try{this.sessionRequestQueue.state=nU.active,this.client.events.emit("session_request",c)}catch(c){this.client.logger.error(c)}},this.onPairingCreated=c=>{if(c.active)return;let l=this.client.proposal.getAll().find(l=>l.pairingTopic===c.topic);l&&this.onSessionProposeRequest(c.topic,formatJsonRpcRequest("wc_sessionPropose",{requiredNamespaces:l.requiredNamespaces,optionalNamespaces:l.optionalNamespaces,relays:l.relays,proposer:l.proposer},l.id))},this.isValidConnect=async c=>{let l;if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`connect() params: ${JSON.stringify(c)}`);throw Error(l)}let{pairingTopic:et,requiredNamespaces:eo,optionalNamespaces:es,sessionProperties:ec,relays:el}=c;if(index_es_w(et)||await this.isValidPairingTopic(et),l=!1,el?el&&index_es_D(el)&&el.length&&el.forEach(c=>{l=index_es_an(c)}):l=!0,!l){let{message:c}=index_es_N("MISSING_OR_INVALID",`connect() relays: ${el}`);throw Error(c)}index_es_w(eo)||0===index_es_B(eo)||this.validateNamespaces(eo,"requiredNamespaces"),index_es_w(es)||0===index_es_B(es)||this.validateNamespaces(es,"optionalNamespaces"),index_es_w(ec)||this.validateSessionProps(ec,"sessionProperties")},this.validateNamespaces=(c,l)=>{let et=function(c,l,et){let eo=null;if(c&&index_es_B(c)){let es;let ec=index_es_ce(c,l);ec&&(eo=ec);let el=(es=null,Object.entries(c).forEach(([c,eo])=>{var ec,el;let ed;if(es)return;let eh=(ec=index_es_K(c,eo),el=`${l} ${et}`,ed=null,index_es_D(ec)&&ec.length?ec.forEach(c=>{ed||index_es_k(c)||(ed=index_es_U("UNSUPPORTED_CHAINS",`${el}, chain ${c} should be a string and conform to "namespace:chainId" format`))}):index_es_k(c)||(ed=index_es_U("UNSUPPORTED_CHAINS",`${el}, chains must be defined as "namespace:chainId" e.g. "eip155:1": {...} in the namespace key OR as an array of CAIP-2 chainIds e.g. eip155: { chains: ["eip155:1", "eip155:5"] }`)),ed);eh&&(es=eh)}),es);el&&(eo=el)}else eo=index_es_N("MISSING_OR_INVALID",`${l}, ${et} should be an object with data`);return eo}(c,"connect()",l);if(et)throw Error(et.message)},this.isValidApprove=async c=>{if(!index_es_xt(c))throw Error(index_es_N("MISSING_OR_INVALID",`approve() params: ${c}`).message);let{id:l,namespaces:et,relayProtocol:eo,sessionProperties:es}=c;await this.isValidProposalId(l);let ec=this.client.proposal.get(l),el=index_es_cn(et,"approve()");if(el)throw Error(el.message);let ed=index_es_un(ec.requiredNamespaces,et,"approve()");if(ed)throw Error(ed.message);if(!dist_index_es_h(eo,!0)){let{message:c}=index_es_N("MISSING_OR_INVALID",`approve() relayProtocol: ${eo}`);throw Error(c)}index_es_w(es)||this.validateSessionProps(es,"sessionProperties")},this.isValidReject=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`reject() params: ${c}`);throw Error(l)}let{id:l,reason:et}=c;if(await this.isValidProposalId(l),!et||"object"!=typeof et||!et.code||!index_es_G(et.code,!1)||!et.message||!dist_index_es_h(et.message,!1)){let{message:c}=index_es_N("MISSING_OR_INVALID",`reject() reason: ${JSON.stringify(et)}`);throw Error(c)}},this.isValidSessionSettleRequest=c=>{let l;if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`onSessionSettleRequest() params: ${c}`);throw Error(l)}let{relay:et,controller:eo,namespaces:es,expiry:ec}=c;if(!index_es_an(et)){let{message:c}=index_es_N("MISSING_OR_INVALID","onSessionSettleRequest() relay protocol should be a string");throw Error(c)}let el=(l=null,dist_index_es_h(eo?.publicKey,!1)||(l=index_es_N("MISSING_OR_INVALID","onSessionSettleRequest() controller public key should be a string")),l);if(el)throw Error(el.message);let ed=index_es_cn(es,"onSessionSettleRequest()");if(ed)throw Error(ed.message);if(index_es_dt(ec)){let{message:c}=index_es_N("EXPIRED","onSessionSettleRequest()");throw Error(c)}},this.isValidUpdate=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`update() params: ${c}`);throw Error(l)}let{topic:l,namespaces:et}=c;await this.isValidSessionTopic(l);let eo=this.client.session.get(l),es=index_es_cn(et,"update()");if(es)throw Error(es.message);let ec=index_es_un(eo.requiredNamespaces,et,"update()");if(ec)throw Error(ec.message)},this.isValidExtend=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`extend() params: ${c}`);throw Error(l)}let{topic:l}=c;await this.isValidSessionTopic(l)},this.isValidRequest=async c=>{var l;if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`request() params: ${c}`);throw Error(l)}let{topic:et,request:eo,chainId:es,expiry:ec}=c;await this.isValidSessionTopic(et);let{namespaces:el}=this.client.session.get(et);if(!index_es_Gt(el,es)){let{message:c}=index_es_N("MISSING_OR_INVALID",`request() chainId: ${es}`);throw Error(c)}if(index_es_w(eo)||!dist_index_es_h(eo.method,!1)){let{message:c}=index_es_N("MISSING_OR_INVALID",`request() ${JSON.stringify(eo)}`);throw Error(c)}if(!(dist_index_es_h(l=eo.method,!1)&&(function(c,l){let et=[];return Object.values(c).forEach(c=>{index_es_A(c.accounts).includes(l)&&et.push(...c.methods)}),et})(el,es).includes(l))){let{message:c}=index_es_N("MISSING_OR_INVALID",`request() method: ${eo.method}`);throw Error(c)}if(ec&&(!index_es_G(ec,!1)||!(ec<=nF.max)||!(ec>=nF.min))){let{message:c}=index_es_N("MISSING_OR_INVALID",`request() expiry: ${ec}. Expiry must be a number (in seconds) between ${nF.min} and ${nF.max}`);throw Error(c)}},this.isValidRespond=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`respond() params: ${c}`);throw Error(l)}let{topic:l,response:et}=c;if(await this.isValidSessionTopic(l),index_es_w(et)||index_es_w(et.result)&&index_es_w(et.error)||!index_es_G(et.id,!1)||!dist_index_es_h(et.jsonrpc,!1)){let{message:c}=index_es_N("MISSING_OR_INVALID",`respond() response: ${JSON.stringify(et)}`);throw Error(c)}},this.isValidPing=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`ping() params: ${c}`);throw Error(l)}let{topic:l}=c;await this.isValidSessionOrPairingTopic(l)},this.isValidEmit=async c=>{var l;if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`emit() params: ${c}`);throw Error(l)}let{topic:et,event:eo,chainId:es}=c;await this.isValidSessionTopic(et);let{namespaces:ec}=this.client.session.get(et);if(!index_es_Gt(ec,es)){let{message:c}=index_es_N("MISSING_OR_INVALID",`emit() chainId: ${es}`);throw Error(c)}if(index_es_w(eo)||!dist_index_es_h(eo.name,!1)){let{message:c}=index_es_N("MISSING_OR_INVALID",`emit() event: ${JSON.stringify(eo)}`);throw Error(c)}if(!(dist_index_es_h(l=eo.name,!1)&&(function(c,l){let et=[];return Object.values(c).forEach(c=>{index_es_A(c.accounts).includes(l)&&et.push(...c.events)}),et})(ec,es).includes(l))){let{message:c}=index_es_N("MISSING_OR_INVALID",`emit() event: ${JSON.stringify(eo)}`);throw Error(c)}},this.isValidDisconnect=async c=>{if(!index_es_xt(c)){let{message:l}=index_es_N("MISSING_OR_INVALID",`disconnect() params: ${c}`);throw Error(l)}let{topic:l}=c;await this.isValidSessionOrPairingTopic(l)},this.getVerifyContext=async(c,l)=>{let et={verified:{verifyUrl:l.verifyUrl||nh,validation:"UNKNOWN",origin:l.url||""}};try{let eo=await this.client.core.verify.resolve({attestationId:c,verifyUrl:l.verifyUrl});eo&&(et.verified.origin=eo.origin,et.verified.isScam=eo.isScam,et.verified.validation=eo.origin===new URL(l.url).origin?"VALID":"INVALID")}catch(c){this.client.logger.info(c)}return this.client.logger.info(`Verify context: ${JSON.stringify(et)}`),et},this.validateSessionProps=(c,l)=>{Object.values(c).forEach(c=>{if(!dist_index_es_h(c,!1)){let{message:et}=index_es_N("MISSING_OR_INVALID",`${l} must be in Record format. Received: ${JSON.stringify(c)}`);throw Error(et)}})}}async isInitialized(){if(!this.initialized){let{message:c}=index_es_N("NOT_INITIALIZED",this.name);throw Error(c)}await this.client.core.relayer.confirmOnlineStateOrThrow()}registerRelayerEvents(){this.client.core.relayer.on(r4.message,async c=>{let{topic:l,message:et}=c;if(this.ignoredPayloadTypes.includes(this.client.core.crypto.getPayloadType(et)))return;let eo=await this.client.core.crypto.decode(l,et);try{isJsonRpcRequest(eo)?(this.client.core.history.set(l,eo),this.onRelayEventRequest({topic:l,payload:eo})):isJsonRpcResponse(eo)?(await this.client.core.history.resolve(eo),await this.onRelayEventResponse({topic:l,payload:eo}),this.client.core.history.delete(l,eo.id)):this.onRelayEventUnknownPayload({topic:l,payload:eo})}catch(c){this.client.logger.error(c)}})}registerExpirerEvents(){this.client.core.expirer.on(nl.expired,async c=>{let{topic:l,id:et}=index_es_ut(c.target);if(et&&this.client.pendingRequest.keys.includes(et))return await this.deletePendingSessionRequest(et,index_es_N("EXPIRED"),!0);l?this.client.session.keys.includes(l)&&(await this.deleteSession(l,!0),this.client.events.emit("session_expire",{topic:l})):et&&(await this.deleteProposal(et,!0),this.client.events.emit("proposal_expire",{id:et}))})}registerPairingEvents(){this.client.core.pairing.events.on(ns.create,c=>this.onPairingCreated(c))}isValidPairingTopic(c){if(!dist_index_es_h(c,!1)){let{message:l}=index_es_N("MISSING_OR_INVALID",`pairing topic should be a string: ${c}`);throw Error(l)}if(!this.client.core.pairing.pairings.keys.includes(c)){let{message:l}=index_es_N("NO_MATCHING_KEY",`pairing topic doesn't exist: ${c}`);throw Error(l)}if(index_es_dt(this.client.core.pairing.pairings.get(c).expiry)){let{message:l}=index_es_N("EXPIRED",`pairing topic: ${c}`);throw Error(l)}}async isValidSessionTopic(c){if(!dist_index_es_h(c,!1)){let{message:l}=index_es_N("MISSING_OR_INVALID",`session topic should be a string: ${c}`);throw Error(l)}if(!this.client.session.keys.includes(c)){let{message:l}=index_es_N("NO_MATCHING_KEY",`session topic doesn't exist: ${c}`);throw Error(l)}if(index_es_dt(this.client.session.get(c).expiry)){await this.deleteSession(c);let{message:l}=index_es_N("EXPIRED",`session topic: ${c}`);throw Error(l)}}async isValidSessionOrPairingTopic(c){if(this.client.session.keys.includes(c))await this.isValidSessionTopic(c);else if(this.client.core.pairing.pairings.keys.includes(c))this.isValidPairingTopic(c);else if(dist_index_es_h(c,!1)){let{message:l}=index_es_N("NO_MATCHING_KEY",`session or pairing topic doesn't exist: ${c}`);throw Error(l)}else{let{message:l}=index_es_N("MISSING_OR_INVALID",`session or pairing topic should be a string: ${c}`);throw Error(l)}}async isValidProposalId(c){if("number"!=typeof c){let{message:l}=index_es_N("MISSING_OR_INVALID",`proposal id should be a number: ${c}`);throw Error(l)}if(!this.client.proposal.keys.includes(c)){let{message:l}=index_es_N("NO_MATCHING_KEY",`proposal id doesn't exist: ${c}`);throw Error(l)}if(index_es_dt(this.client.proposal.get(c).expiry)){await this.deleteProposal(c);let{message:l}=index_es_N("EXPIRED",`proposal id: ${c}`);throw Error(l)}}};let index_es_hs=class index_es_hs extends dist_index_es_Ft{constructor(c,l){super(c,l,"proposal",nM),this.core=c,this.logger=l}};let index_es_ds=class index_es_ds extends dist_index_es_Ft{constructor(c,l){super(c,l,"session",nM),this.core=c,this.logger=l}};let index_es_us=class index_es_us extends dist_index_es_Ft{constructor(c,l){super(c,l,"request",nM,c=>c.id),this.core=c,this.logger=l}};let sign_client_dist_index_es_Q=class sign_client_dist_index_es_Q extends b{constructor(c){super(c),this.protocol="wc",this.version=2,this.name=n$.name,this.events=new eE.EventEmitter,this.on=(c,l)=>this.events.on(c,l),this.once=(c,l)=>this.events.once(c,l),this.off=(c,l)=>this.events.off(c,l),this.removeListener=(c,l)=>this.events.removeListener(c,l),this.removeAllListeners=c=>this.events.removeAllListeners(c),this.connect=async c=>{try{return await this.engine.connect(c)}catch(c){throw this.logger.error(c.message),c}},this.pair=async c=>{try{return await this.engine.pair(c)}catch(c){throw this.logger.error(c.message),c}},this.approve=async c=>{try{return await this.engine.approve(c)}catch(c){throw this.logger.error(c.message),c}},this.reject=async c=>{try{return await this.engine.reject(c)}catch(c){throw this.logger.error(c.message),c}},this.update=async c=>{try{return await this.engine.update(c)}catch(c){throw this.logger.error(c.message),c}},this.extend=async c=>{try{return await this.engine.extend(c)}catch(c){throw this.logger.error(c.message),c}},this.request=async c=>{try{return await this.engine.request(c)}catch(c){throw this.logger.error(c.message),c}},this.respond=async c=>{try{return await this.engine.respond(c)}catch(c){throw this.logger.error(c.message),c}},this.ping=async c=>{try{return await this.engine.ping(c)}catch(c){throw this.logger.error(c.message),c}},this.emit=async c=>{try{return await this.engine.emit(c)}catch(c){throw this.logger.error(c.message),c}},this.disconnect=async c=>{try{return await this.engine.disconnect(c)}catch(c){throw this.logger.error(c.message),c}},this.find=c=>{try{return this.engine.find(c)}catch(c){throw this.logger.error(c.message),c}},this.getPendingSessionRequests=()=>{try{return this.engine.getPendingSessionRequests()}catch(c){throw this.logger.error(c.message),c}},this.name=c?.name||n$.name,this.metadata=c?.metadata||(0,tw.D)()||{name:"",description:"",url:"",icons:[""]};let l="u">typeof c?.logger&&"string"!=typeof c?.logger?c.logger:(0,tC.pino)((0,tC.getDefaultLoggerOptions)({level:c?.logger||n$.logger}));this.core=c?.core||new dist_index_es_ee(c),this.logger=(0,tC.generateChildLogger)(l,this.name),this.session=new index_es_ds(this.core,this.logger),this.proposal=new index_es_hs(this.core,this.logger),this.pendingRequest=new index_es_us(this.core,this.logger),this.engine=new index_es_ps(this)}static async init(c){let l=new sign_client_dist_index_es_Q(c);return await l.initialize(),l}get context(){return(0,tC.getLoggerContext)(this.logger)}get pairing(){return this.core.pairing.pairings}async initialize(){this.logger.trace("Initialized");try{await this.core.start(),await this.session.init(),await this.proposal.init(),await this.pendingRequest.init(),await this.engine.init(),this.core.verify.init({verifyUrl:this.metadata.verifyUrl}),this.logger.info("SignClient Initialization Success")}catch(c){throw this.logger.info("SignClient Initialization Failure"),this.logger.error(c.message),c}}};var nJ=et(9366),nQ=et.n(nJ);let nY={headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST"};let HttpConnection=class HttpConnection{constructor(c,l=!1){if(this.url=c,this.disableProviderPing=l,this.events=new eE.EventEmitter,this.isAvailable=!1,this.registering=!1,!isHttpUrl(c))throw Error(`Provided URL is not compatible with HTTP connection: ${c}`);this.url=c,this.disableProviderPing=l}get connected(){return this.isAvailable}get connecting(){return this.registering}on(c,l){this.events.on(c,l)}once(c,l){this.events.once(c,l)}off(c,l){this.events.off(c,l)}removeListener(c,l){this.events.removeListener(c,l)}async open(c=this.url){await this.register(c)}async close(){if(!this.isAvailable)throw Error("Connection already closed");this.onClose()}async send(c,l){this.isAvailable||await this.register();try{let l=safeJsonStringify(c),et=await nQ()(this.url,Object.assign(Object.assign({},nY),{body:l})),eo=await et.json();this.onPayload({data:eo})}catch(l){this.onError(c.id,l)}}async register(c=this.url){if(!isHttpUrl(c))throw Error(`Provided URL is not compatible with HTTP connection: ${c}`);if(this.registering){let c=this.events.getMaxListeners();return(this.events.listenerCount("register_error")>=c||this.events.listenerCount("open")>=c)&&this.events.setMaxListeners(c+1),new Promise((c,l)=>{this.events.once("register_error",c=>{this.resetMaxListeners(),l(c)}),this.events.once("open",()=>{if(this.resetMaxListeners(),void 0===this.isAvailable)return l(Error("HTTP connection is missing or invalid"));c()})})}this.url=c,this.registering=!0;try{if(!this.disableProviderPing){let l=safeJsonStringify({id:1,jsonrpc:"2.0",method:"test",params:[]});await nQ()(c,Object.assign(Object.assign({},nY),{body:l}))}this.onOpen()}catch(l){let c=this.parseError(l);throw this.events.emit("register_error",c),this.onClose(),c}}onOpen(){this.isAvailable=!0,this.registering=!1,this.events.emit("open")}onClose(){this.isAvailable=!1,this.registering=!1,this.events.emit("close")}onPayload(c){if(void 0===c.data)return;let l="string"==typeof c.data?esm_safeJsonParse(c.data):c.data;this.events.emit("payload",l)}onError(c,l){let et=this.parseError(l),eo=et.message||et.toString(),es=formatJsonRpcError(c,eo);this.events.emit("payload",es)}parseError(c,l=this.url){return parseConnectionError(c,l,"HTTP")}resetMaxListeners(){this.events.getMaxListeners()>10&&this.events.setMaxListeners(10)}};let nZ="error",nX="wc@2:universal_provider:",n0={DEFAULT_CHAIN_CHANGED:"default_chain_changed"};var n1="u">typeof globalThis?globalThis:"u">typeof window?window:"u">typeof et.g?et.g:"u">typeof self?self:{},n2={exports:{}};/** + * @license + * Lodash + * Copyright OpenJS Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */!function(c,l){(function(){var et,eo="Expected a function",es="__lodash_hash_undefined__",ec="__lodash_placeholder__",el=1/0,ed=0/0,eh=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],ef="[object Arguments]",ep="[object Array]",eg="[object Boolean]",em="[object Date]",eb="[object Error]",ey="[object Function]",e_="[object GeneratorFunction]",ew="[object Map]",eE="[object Number]",eS="[object Object]",ex="[object Promise]",ek="[object RegExp]",eC="[object Set]",eA="[object String]",eI="[object Symbol]",eP="[object WeakMap]",eR="[object ArrayBuffer]",eO="[object DataView]",eT="[object Float32Array]",eN="[object Float64Array]",eM="[object Int8Array]",e$="[object Int16Array]",eB="[object Int32Array]",eD="[object Uint8Array]",ej="[object Uint8ClampedArray]",eL="[object Uint16Array]",eF="[object Uint32Array]",eU=/\b__p \+= '';/g,ez=/\b(__p \+=) '' \+/g,eH=/(__e\(.*?\)|\b__t\)) \+\n'';/g,eW=/&(?:amp|lt|gt|quot|#39);/g,eV=/[&<>"']/g,eG=RegExp(eW.source),eK=RegExp(eV.source),eJ=/<%-([\s\S]+?)%>/g,eQ=/<%([\s\S]+?)%>/g,eY=/<%=([\s\S]+?)%>/g,eZ=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,eX=/^\w*$/,e0=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,e1=/[\\^$.*+?()[\]{}|]/g,e2=RegExp(e1.source),e3=/^\s+/,e5=/\s/,e6=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,e4=/\{\n\/\* \[wrapped with (.+)\] \*/,e8=/,? & /,e9=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,e7=/[()=,{}\[\]\/\s]/,tn=/\\(\\)?/g,to=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ts=/\w*$/,ta=/^[-+]0x[0-9a-f]+$/i,tc=/^0b[01]+$/i,tl=/^\[object .+?Constructor\]$/,td=/^0o[0-7]+$/i,th=/^(?:0|[1-9]\d*)$/,tf=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,tp=/($^)/,tg=/['\n\r\u2028\u2029\\]/g,tm="\ud800-\udfff",tb="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",ty="\\u2700-\\u27bf",t_="a-z\\xdf-\\xf6\\xf8-\\xff",tw="A-Z\\xc0-\\xd6\\xd8-\\xde",tE="\\ufe0e\\ufe0f",tS="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",tx="['’]",tk="["+tS+"]",tC="["+tb+"]",tA="["+t_+"]",tI="[^"+tm+tS+"\\d+"+ty+t_+tw+"]",tP="\ud83c[\udffb-\udfff]",tR="[^"+tm+"]",tO="(?:\ud83c[\udde6-\uddff]){2}",tT="[\ud800-\udbff][\udc00-\udfff]",tN="["+tw+"]",tM="\\u200d",t$="(?:"+tA+"|"+tI+")",tB="(?:"+tx+"(?:d|ll|m|re|s|t|ve))?",tD="(?:"+tx+"(?:D|LL|M|RE|S|T|VE))?",tj="(?:"+tC+"|"+tP+")?",tL="["+tE+"]?",tF="(?:"+tM+"(?:"+[tR,tO,tT].join("|")+")"+tL+tj+")*",tU=tL+tj+tF,tz="(?:"+["["+ty+"]",tO,tT].join("|")+")"+tU,tq="(?:"+[tR+tC+"?",tC,tO,tT,"["+tm+"]"].join("|")+")",tH=RegExp(tx,"g"),tW=RegExp(tC,"g"),tV=RegExp(tP+"(?="+tP+")|"+tq+tU,"g"),tG=RegExp([tN+"?"+tA+"+"+tB+"(?="+[tk,tN,"$"].join("|")+")","(?:"+tN+"|"+tI+")+"+tD+"(?="+[tk,tN+t$,"$"].join("|")+")",tN+"?"+t$+"+"+tB,tN+"+"+tD,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])","\\d+",tz].join("|"),"g"),tK=RegExp("["+tM+tm+tb+tE+"]"),tJ=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,tQ=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],tY=-1,tZ={};tZ[eT]=tZ[eN]=tZ[eM]=tZ[e$]=tZ[eB]=tZ[eD]=tZ[ej]=tZ[eL]=tZ[eF]=!0,tZ[ef]=tZ[ep]=tZ[eR]=tZ[eg]=tZ[eO]=tZ[em]=tZ[eb]=tZ[ey]=tZ[ew]=tZ[eE]=tZ[eS]=tZ[ek]=tZ[eC]=tZ[eA]=tZ[eP]=!1;var tX={};tX[ef]=tX[ep]=tX[eR]=tX[eO]=tX[eg]=tX[em]=tX[eT]=tX[eN]=tX[eM]=tX[e$]=tX[eB]=tX[ew]=tX[eE]=tX[eS]=tX[ek]=tX[eC]=tX[eA]=tX[eI]=tX[eD]=tX[ej]=tX[eL]=tX[eF]=!0,tX[eb]=tX[ey]=tX[eP]=!1;var t0={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},t1=parseFloat,t2=parseInt,t3="object"==typeof n1&&n1&&n1.Object===Object&&n1,t5="object"==typeof self&&self&&self.Object===Object&&self,t6=t3||t5||Function("return this")(),t4=l&&!l.nodeType&&l,t8=t4&&c&&!c.nodeType&&c,t9=t8&&t8.exports===t4,t7=t9&&t3.process,re=function(){try{return t8&&t8.require&&t8.require("util").types||t7&&t7.binding&&t7.binding("util")}catch{}}(),rt=re&&re.isArrayBuffer,ro=re&&re.isDate,rs=re&&re.isMap,ra=re&&re.isRegExp,rc=re&&re.isSet,rl=re&&re.isTypedArray;function cn(c,l,et){switch(et.length){case 0:return c.call(l);case 1:return c.call(l,et[0]);case 2:return c.call(l,et[0],et[1]);case 3:return c.call(l,et[0],et[1],et[2])}return c.apply(l,et)}function Vo(c,l,et,eo){for(var es=-1,ec=null==c?0:c.length;++es-1}function Dr(c,l,et){for(var eo=-1,es=null==c?0:c.length;++eo-1;);return et}function Os(c,l){for(var et=c.length;et--&&Tt(l,c[et],0)>-1;);return et}var rh=Ur({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),rp=Ur({"&":"&","<":"<",">":">",'"':""","'":"'"});function cf(c){return"\\"+t0[c]}function Lt(c){return tK.test(c)}function qr(c){var l=-1,et=Array(c.size);return c.forEach(function(c,eo){et[++l]=[eo,c]}),et}function Rs(c,l){return function(et){return c(l(et))}}function tt(c,l){for(var et=-1,eo=c.length,es=0,el=[];++et",""":'"',"'":"'"}),rm=function h(c){var l,e5,tm,tb,ty=(c=null==c?t6:rm.defaults(t6.Object(),c,rm.pick(t6,tQ))).Array,t_=c.Date,tw=c.Error,tE=c.Function,tS=c.Math,tx=c.Object,tk=c.RegExp,tC=c.String,tA=c.TypeError,tI=ty.prototype,tP=tE.prototype,tR=tx.prototype,tO=c["__core-js_shared__"],tT=tP.toString,tN=tR.hasOwnProperty,tM=0,t$=(l=/[^.]+$/.exec(tO&&tO.keys&&tO.keys.IE_PROTO||""))?"Symbol(src)_1."+l:"",tB=tR.toString,tD=tT.call(tx),tj=t6._,tL=tk("^"+tT.call(tN).replace(e1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),tF=t9?c.Buffer:et,tU=c.Symbol,tz=c.Uint8Array,tq=tF?tF.allocUnsafe:et,tV=Rs(tx.getPrototypeOf,tx),tK=tx.create,t0=tR.propertyIsEnumerable,t3=tI.splice,t5=tU?tU.isConcatSpreadable:et,t4=tU?tU.iterator:et,t8=tU?tU.toStringTag:et,t7=function(){try{var c=mt(tx,"defineProperty");return c({},"",{}),c}catch{}}(),re=c.clearTimeout!==t6.clearTimeout&&c.clearTimeout,rd=t_&&t_.now!==t6.Date.now&&t_.now,rb=c.setTimeout!==t6.setTimeout&&c.setTimeout,ry=tS.ceil,r_=tS.floor,rw=tx.getOwnPropertySymbols,rE=tF?tF.isBuffer:et,rS=c.isFinite,rx=tI.join,rk=Rs(tx.keys,tx),rC=tS.max,rA=tS.min,rI=t_.now,rP=c.parseInt,rR=tS.random,rO=tI.reverse,rT=mt(c,"DataView"),rN=mt(c,"Map"),rM=mt(c,"Promise"),r$=mt(c,"Set"),rB=mt(c,"WeakMap"),rD=mt(tx,"create"),rj=rB&&new rB,rL={},rF=wt(rT),rU=wt(rN),rz=wt(rM),rq=wt(r$),rH=wt(rB),rW=tU?tU.prototype:et,rV=rW?rW.valueOf:et,rG=rW?rW.toString:et;function a(c){if(Y(c)&&!nG(c)&&!(c instanceof H)){if(c instanceof Pn)return c;if(tN.call(c,"__wrapped__"))return Fu(c)}return new Pn(c)}var rK=function(){function n(){}return function(c){if(!K(c))return{};if(tK)return tK(c);n.prototype=c;var l=new n;return n.prototype=et,l}}();function qe(){}function Pn(c,l){this.__wrapped__=c,this.__actions__=[],this.__chain__=!!l,this.__index__=0,this.__values__=et}function H(c){this.__wrapped__=c,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function dt(c){var l=-1,et=null==c?0:c.length;for(this.clear();++l=l?c:l)),c}function An(c,l,eo,es,ec,el){var ed,eh=1&l,ep=2&l,eb=4&l;if(eo&&(ed=ec?eo(c,es,ec,el):eo(c)),ed!==et)return ed;if(!K(c))return c;var ex=nG(c);if(ex){if(eP=c.length,eU=new c.constructor(eP),eP&&"string"==typeof c[0]&&tN.call(c,"index")&&(eU.index=c.index,eU.input=c.input),ed=eU,!eh)return un(c,ed)}else{var eP,eU,ez,eH,eW,eV=r4(c),eG=eV==ey||eV==e_;if(nJ(c))return hu(c,eh);if(eV==eS||eV==ef||eG&&!ec){if(ed=ep||eG?{}:bu(c),!eh)return ep?(ez=(eW=ed)&&Un(c,on(c),eW),Un(c,r6(c),ez)):(eH=qs(ed,c),Un(c,r5(c),eH))}else{if(!tX[eV])return ec?c:{};ed=function(c,l,et){var eo,es,ec=c.constructor;switch(l){case eR:return fi(c);case eg:case em:return new ec(+c);case eO:return eo=et?fi(c.buffer):c.buffer,new c.constructor(eo,c.byteOffset,c.byteLength);case eT:case eN:case eM:case e$:case eB:case eD:case ej:case eL:case eF:return lu(c,et);case ew:return new ec;case eE:case eA:return new ec(c);case ek:return(es=new c.constructor(c.source,ts.exec(c))).lastIndex=c.lastIndex,es;case eC:return new ec;case eI:return rV?tx(rV.call(c)):{}}}(c,eV,eh)}}el||(el=new Rn);var eK=el.get(c);if(eK)return eK;el.set(c,ed),nX(c)?c.forEach(function(et){ed.add(An(et,l,eo,et,c,el))}):nY(c)&&c.forEach(function(et,es){ed.set(es,An(et,l,eo,es,c,el))});var eJ=eb?ep?pi:li:ep?on:V,eQ=ex?et:eJ(c);return mn(eQ||c,function(et,es){eQ&&(et=c[es=et]),se(ed,es,An(et,l,eo,es,c,el))}),ed}function Bs(c,l,eo){var es=eo.length;if(null==c)return!es;for(c=tx(c);es--;){var ec=eo[es],el=l[ec],ed=c[ec];if(ed===et&&!(ec in c)||!el(ed))return!1}return!0}function Gs(c,l,es){if("function"!=typeof c)throw new tA(eo);return r7(function(){c.apply(et,es)},l)}function ue(c,l,et,eo){var es=-1,ec=Ee,el=!0,ed=c.length,eh=[],ef=l.length;if(!ed)return eh;et&&(l=G(l,hn(et))),eo?(ec=Dr,el=!1):l.length>=200&&(ec=jt,el=!1,l=new gt(l));t:for(;++es-1},Bn.prototype.set=function(c,l){var et=this.__data__,eo=Be(et,c);return eo<0?(++this.size,et.push([c,l])):et[eo][1]=l,this},Gn.prototype.clear=function(){this.size=0,this.__data__={hash:new dt,map:new(rN||Bn),string:new dt}},Gn.prototype.delete=function(c){var l=nr(this,c).delete(c);return this.size-=l?1:0,l},Gn.prototype.get=function(c){return nr(this,c).get(c)},Gn.prototype.has=function(c){return nr(this,c).has(c)},Gn.prototype.set=function(c,l){var et=nr(this,c),eo=et.size;return et.set(c,l),this.size+=et.size==eo?0:1,this},gt.prototype.add=gt.prototype.push=function(c){return this.__data__.set(c,es),this},gt.prototype.has=function(c){return this.__data__.has(c)},Rn.prototype.clear=function(){this.__data__=new Bn,this.size=0},Rn.prototype.delete=function(c){var l=this.__data__,et=l.delete(c);return this.size=l.size,et},Rn.prototype.get=function(c){return this.__data__.get(c)},Rn.prototype.has=function(c){return this.__data__.has(c)},Rn.prototype.set=function(c,l){var et=this.__data__;if(et instanceof Bn){var eo=et.__data__;if(!rN||eo.length<199)return eo.push([c,l]),this.size=++et.size,this;et=this.__data__=new Gn(eo)}return et.set(c,l),this.size=et.size,this};var rJ=vu($n),rQ=vu(Xr,!0);function mc(c,l){var et=!0;return rJ(c,function(c,eo,es){return et=!!l(c,eo,es)}),et}function Ge(c,l,eo){for(var es=-1,ec=c.length;++es0&&et(ed)?l>1?j(ed,l-1,et,eo,es):nt(es,ed):eo||(es[es.length]=ed)}return es}var rY=_u(),rZ=_u(!0);function $n(c,l){return c&&rY(c,l,V)}function Xr(c,l){return c&&rZ(c,l,V)}function ze(c,l){return jn(l,function(l){return Jn(c[l])})}function _t(c,l){l=st(l,c);for(var eo=0,es=l.length;null!=c&&eol}function Pc(c,l){return null!=c&&tN.call(c,l)}function Ac(c,l){return null!=c&&l in tx(c)}function Vr(c,l,eo){for(var es=eo?Dr:Ee,ec=c[0].length,el=c.length,ed=el,eh=ty(el),ef=1/0,ep=[];ed--;){var eg=c[ed];ed&&l&&(eg=G(eg,hn(l))),ef=rA(eg.length,ef),eh[ed]=!eo&&(l||ec>=120&&eg.length>=120)?new gt(ed&&eg):et}eg=c[0];var em=-1,eb=eh[0];t:for(;++em=ed)return eh;return eh*("desc"==et[eo]?-1:1)}}return c.index-l.index}(c,l,et)})}function eu(c,l,et){for(var eo=-1,es=l.length,ec={};++eo-1;)ed!==c&&t3.call(ed,eh,1),t3.call(c,eh,1);return c}function ru(c,l){for(var et=c?l.length:0,eo=et-1;et--;){var es=l[et];if(et==eo||es!==ec){var ec=es;Zn(es)?t3.call(c,es,1):si(c,es)}}return c}function ei(c,l){return c+r_(rR()*(l-c+1))}function ri(c,l){var et="";if(!c||l<1||l>9007199254740991)return et;do l%2&&(et+=c),(l=r_(l/2))&&(c+=c);while(l);return et}function L(c,l){return nn(Du(c,l,fn),c+"")}function fe(c,l,eo,es){if(!K(c))return c;l=st(l,c);for(var ec=-1,el=l.length,ed=el-1,eh=c;null!=eh&&++eces?0:es+l),(et=et>es?es:et)<0&&(et+=es),es=l>et?0:et-l>>>0,l>>>=0;for(var ec=ty(es);++eo>>1,el=c[ec];null!==el&&!pn(el)&&(et?el<=l:el=200){var ef=l?null:r2(c);if(ef)return Se(ef);el=!1,es=jt,eh=new gt}else eh=l?[]:ed;t:for(;++eo=es?c:Cn(c,l,eo)}var r1=re||function(c){return t6.clearTimeout(c)};function hu(c,l){if(l)return c.slice();var et=c.length,eo=tq?tq(et):new c.constructor(et);return c.copy(eo),eo}function fi(c){var l=new c.constructor(c.byteLength);return new tz(l).set(new tz(c)),l}function lu(c,l){var et=l?fi(c.buffer):c.buffer;return new c.constructor(et,c.byteOffset,c.length)}function pu(c,l){if(c!==l){var eo=c!==et,es=null===c,ec=c==c,el=pn(c),ed=l!==et,eh=null===l,ef=l==l,ep=pn(l);if(!eh&&!ep&&!el&&c>l||el&&ed&&ef&&!eh&&!ep||es&&ed&&ef||!eo&&ef||!ec)return 1;if(!es&&!el&&!ep&&c1?eo[ec-1]:et,ed=ec>2?eo[2]:et;for(el=c.length>3&&"function"==typeof el?(ec--,el):et,ed&&rn(eo[0],eo[1],ed)&&(el=ec<3?et:el,ec=1),l=tx(l);++es-1?ec[el?l[ed]:ed]:et}}function Pu(c){return Yn(function(l){var es=l.length,ec=es,el=Pn.prototype.thru;for(c&&l.reverse();ec--;){var ed=l[ec];if("function"!=typeof ed)throw new tA(eo);if(el&&!eh&&"wrapper"==je(ed))var eh=new Pn([],!0)}for(ec=eh?ec:es;++ec1&&eS.reverse(),eg&&efeh))return!1;var ep=el.get(c),eg=el.get(l);if(ep&&eg)return ep==l&&eg==c;var em=-1,eb=!0,ey=2&eo?new gt:et;for(el.set(c,l),el.set(l,c);++em-1&&c%1==0&&c1?"& ":"")+l[eo],l=l.join(et>2?", ":" "),c.replace(e6,`{ +/* [wrapped with `+l+`] */ +`)}(ec,(eo=(es=ec.match(e4))?es[1].split(e8):[],mn(eh,function(c){var l="_."+c[0];et&c[1]&&!Ee(eo,l)&&eo.push(l)}),eo.sort())))}function Uu(c){var l=0,eo=0;return function(){var es=rI(),ec=16-(es-eo);if(eo=es,ec>0){if(++l>=800)return arguments[0]}else l=0;return c.apply(et,arguments)}}function tr(c,l){var eo=-1,es=c.length,ec=es-1;for(l=l===et?es:l;++eo1?c[l-1]:et;return eo="function"==typeof eo?(c.pop(),eo):et,Ku(c,eo)});function Yu(c){var l=a(c);return l.__chain__=!0,l}function er(c,l){return l(c)}var nC=Yn(function(c){var l=c.length,eo=l?c[0]:0,es=this.__wrapped__,s=function(l){return Zr(l,c)};return!(l>1)&&!this.__actions__.length&&es instanceof H&&Zn(eo)?((es=es.slice(eo,+eo+(l?1:0))).__actions__.push({func:er,args:[s],thisArg:et}),new Pn(es,this.__chain__).thru(function(c){return l&&!c.length&&c.push(et),c})):this.thru(s)}),nA=Je(function(c,l,et){tN.call(c,et)?++c[et]:zn(c,et,1)}),nI=wu(Mu),nP=wu(qu);function Zu(c,l){return(nG(c)?mn:rJ)(c,x(l,3))}function Ju(c,l){return(nG(c)?function(c,l){for(var et=null==c?0:c.length;et--&&!1!==l(c[et],et,c););return c}:rQ)(c,x(l,3))}var nR=Je(function(c,l,et){tN.call(c,et)?c[et].push(l):zn(c,et,[l])}),nO=L(function(c,l,et){var eo=-1,es="function"==typeof l,ec=an(c)?ty(c.length):[];return rJ(c,function(c){ec[++eo]=es?cn(l,c,et):ae(c,l,et)}),ec}),nT=Je(function(c,l,et){zn(c,et,l)});function rr(c,l){return(nG(c)?G:Vs)(c,x(l,3))}var nN=Je(function(c,l,et){c[et?0:1].push(l)},function(){return[[],[]]}),nM=L(function(c,l){if(null==c)return[];var et=l.length;return et>1&&rn(c,l[0],l[1])?l=[]:et>2&&rn(l[0],l[1],l[2])&&(l=[l[0]]),tu(c,j(l,1),[])}),n$=rd||function(){return t6.Date.now()};function Xu(c,l,eo){return l=eo?et:l,l=c&&null==l?c.length:l,Kn(c,128,et,et,et,et,l)}function Qu(c,l){var es;if("function"!=typeof l)throw new tA(eo);return c=R(c),function(){return--c>0&&(es=l.apply(this,arguments)),c<=1&&(l=et),es}}var nB=L(function(c,l,et){var eo=1;if(et.length){var es=tt(et,qt(nB));eo|=32}return Kn(c,eo,l,et,es)}),nD=L(function(c,l,et){var eo=3;if(et.length){var es=tt(et,qt(nD));eo|=32}return Kn(l,eo,c,et,es)});function na(c,l,es){var ec,el,ed,eh,ef,ep,eg=0,em=!1,eb=!1,ey=!0;if("function"!=typeof c)throw new tA(eo);function I(l){var eo=ec,es=el;return ec=el=et,eg=l,eh=c.apply(es,eo)}function y(c){var eo=c-ep,es=c-eg;return ep===et||eo>=l||eo<0||eb&&es>=ed}function D(){var c,et,eo,es=n$();if(y(es))return N(es);ef=r7(D,(c=es-ep,et=es-eg,eo=l-c,eb?rA(eo,ed-et):eo))}function N(c){return ef=et,ey&&ec?I(c):(ec=el=et,eh)}function gn(){var c,eo=n$(),es=y(eo);if(ec=arguments,el=this,ep=eo,es){if(ef===et)return eg=c=ep,ef=r7(D,l),em?I(c):eh;if(eb)return r1(ef),ef=r7(D,l),I(ep)}return ef===et&&(ef=r7(D,l)),eh}return l=xn(l)||0,K(es)&&(em=!!es.leading,ed=(eb="maxWait"in es)?rC(xn(es.maxWait)||0,l):ed,ey="trailing"in es?!!es.trailing:ey),gn.cancel=function(){ef!==et&&r1(ef),eg=0,ec=ep=el=ef=et},gn.flush=function(){return ef===et?eh:N(n$())},gn}var nj=L(function(c,l){return Gs(c,1,l)}),nL=L(function(c,l,et){return Gs(c,xn(l)||0,et)});function sr(c,l){if("function"!=typeof c||null!=l&&"function"!=typeof l)throw new tA(eo);var e=function(){var et=arguments,eo=l?l.apply(this,et):et[0],es=e.cache;if(es.has(eo))return es.get(eo);var ec=c.apply(this,et);return e.cache=es.set(eo,ec)||es,ec};return e.cache=new(sr.Cache||Gn),e}function ur(c){if("function"!=typeof c)throw new tA(eo);return function(){var l=arguments;switch(l.length){case 0:return!c.call(this);case 1:return!c.call(this,l[0]);case 2:return!c.call(this,l[0],l[1]);case 3:return!c.call(this,l[0],l[1],l[2])}return!c.apply(this,l)}}sr.Cache=Gn;var nF=L(function(c,l){var et=(l=1==l.length&&nG(l[0])?G(l[0],hn(x())):G(j(l,1),hn(x()))).length;return L(function(eo){for(var es=-1,ec=rA(eo.length,et);++es=l}),nV=Js(function(){return arguments}())?Js:function(c){return Y(c)&&tN.call(c,"callee")&&!t0.call(c,"callee")},nG=ty.isArray,nK=rt?hn(rt):function(c){return Y(c)&&en(c)==eR};function an(c){return null!=c&&ar(c.length)&&!Jn(c)}function Z(c){return Y(c)&&an(c)}var nJ=rE||Ni,nQ=ro?hn(ro):function(c){return Y(c)&&en(c)==em};function Ei(c){if(!Y(c))return!1;var l=en(c);return l==eb||"[object DOMException]"==l||"string"==typeof c.message&&"string"==typeof c.name&&!pe(c)}function Jn(c){if(!K(c))return!1;var l=en(c);return l==ey||l==e_||"[object AsyncFunction]"==l||"[object Proxy]"==l}function ea(c){return"number"==typeof c&&c==R(c)}function ar(c){return"number"==typeof c&&c>-1&&c%1==0&&c<=9007199254740991}function K(c){var l=typeof c;return null!=c&&("object"==l||"function"==l)}function Y(c){return null!=c&&"object"==typeof c}var nY=rs?hn(rs):function(c){return Y(c)&&r4(c)==ew};function ia(c){return"number"==typeof c||Y(c)&&en(c)==eE}function pe(c){if(!Y(c)||en(c)!=eS)return!1;var l=tV(c);if(null===l)return!0;var et=tN.call(l,"constructor")&&l.constructor;return"function"==typeof et&&et instanceof et&&tT.call(et)==tD}var nZ=ra?hn(ra):function(c){return Y(c)&&en(c)==ek},nX=rc?hn(rc):function(c){return Y(c)&&r4(c)==eC};function or(c){return"string"==typeof c||!nG(c)&&Y(c)&&en(c)==eA}function pn(c){return"symbol"==typeof c||Y(c)&&en(c)==eI}var n0=rl?hn(rl):function(c){return Y(c)&&ar(c.length)&&!!tZ[en(c)]},n1=ke(ni),n2=ke(function(c,l){return c<=l});function ua(c){if(!c)return[];if(an(c))return or(c)?On(c):un(c);if(t4&&c[t4])return function(c){for(var l,et=[];!(l=c.next()).done;)et.push(l.value);return et}(c[t4]());var l=r4(c);return(l==ew?qr:l==eC?Se:Gt)(c)}function Xn(c){return c?(c=xn(c))===el||c===-el?(c<0?-1:1)*17976931348623157e292:c==c?c:0:0===c?c:0}function R(c){var l=Xn(c),et=l%1;return l==l?et?l-et:l:0}function aa(c){return c?vt(R(c),0,4294967295):0}function xn(c){if("number"==typeof c)return c;if(pn(c))return ed;if(K(c)){var l="function"==typeof c.valueOf?c.valueOf():c;c=K(l)?l+"":l}if("string"!=typeof c)return 0===c?c:+c;c=ys(c);var et=tc.test(c);return et||td.test(c)?t2(c.slice(2),et?2:8):ta.test(c)?ed:+c}function oa(c){return Un(c,on(c))}function W(c){return null==c?"":ln(c)}var n3=Ft(function(c,l){if(he(l)||an(l)){Un(l,V(l),c);return}for(var et in l)tN.call(l,et)&&se(c,et,l[et])}),n5=Ft(function(c,l){Un(l,on(l),c)}),n6=Ft(function(c,l,et,eo){Un(l,on(l),c,eo)}),n4=Ft(function(c,l,et,eo){Un(l,V(l),c,eo)}),n8=Yn(Zr),n9=L(function(c,l){c=tx(c);var eo=-1,es=l.length,ec=es>2?l[2]:et;for(ec&&rn(l[0],l[1],ec)&&(es=1);++eo1),l}),Un(c,pi(c),et),eo&&(et=An(et,7,kc));for(var es=l.length;es--;)si(et,l[es]);return et}),ih=Yn(function(c,l){return null==c?{}:eu(c,l,function(l,et){return Oi(c,et)})});function ha(c,l){if(null==c)return{};var et=G(pi(c),function(c){return[c]});return l=x(l),eu(c,et,function(c,et){return l(c,et[0])})}var ip=xu(V),ig=xu(on);function Gt(c){return null==c?[]:Mr(c,V(c))}var im=Mt(function(c,l,et){return l=l.toLowerCase(),c+(et?da(l):l)});function da(c){return ix(W(c).toLowerCase())}function ga(c){return(c=W(c))&&c.replace(tf,rh).replace(tW,"")}var ib=Mt(function(c,l,et){return c+(et?"-":"")+l.toLowerCase()}),iy=Mt(function(c,l,et){return c+(et?" ":"")+l.toLowerCase()}),i_=mu("toLowerCase"),iw=Mt(function(c,l,et){return c+(et?"_":"")+l.toLowerCase()}),iE=Mt(function(c,l,et){return c+(et?" ":"")+ix(l)}),iS=Mt(function(c,l,et){return c+(et?" ":"")+l.toUpperCase()}),ix=mu("toUpperCase");function va(c,l,eo){var es;return c=W(c),(l=eo?et:l)===et?(es=c,tJ.test(es))?c.match(tG)||[]:c.match(e9)||[]:c.match(l)||[]}var ik=L(function(c,l){try{return cn(c,et,l)}catch(c){return Ei(c)?c:new tw(c)}}),iC=Yn(function(c,l){return mn(l,function(l){zn(c,l=Wn(l),nB(c[l],c))}),c});function bi(c){return function(){return c}}var iA=Pu(),iI=Pu(!0);function fn(c){return c}function Ti(c){return Qs("function"==typeof c?c:An(c,1))}var iP=L(function(c,l){return function(et){return ae(et,c,l)}}),iR=L(function(c,l){return function(et){return ae(c,et,l)}});function Li(c,l,et){var eo=V(l),es=ze(l,eo);null!=et||K(l)&&(es.length||!eo.length)||(et=l,l=c,c=this,es=ze(l,V(l)));var ec=!(K(et)&&"chain"in et)||!!et.chain,el=Jn(c);return mn(es,function(et){var eo=l[et];c[et]=eo,el&&(c.prototype[et]=function(){var l=this.__chain__;if(ec||l){var et=c(this.__wrapped__);return(et.__actions__=un(this.__actions__)).push({func:eo,args:arguments,thisArg:c}),et.__chain__=l,et}return eo.apply(c,nt([this.value()],arguments))})}),c}function Di(){}var iO=ci(G),iT=ci(As),iN=ci(Nr);function ma(c){return _i(c)?$r(Wn(c)):function(l){return _t(l,c)}}var iM=Cu(),i$=Cu(!0);function Hi(){return[]}function Ni(){return!1}var iB=Qe(function(c,l){return c+l},0),iD=hi("ceil"),ij=Qe(function(c,l){return c/l},1),iL=hi("floor"),iF=Qe(function(c,l){return c*l},1),iU=hi("round"),iz=Qe(function(c,l){return c-l},0);return a.after=function(c,l){if("function"!=typeof l)throw new tA(eo);return c=R(c),function(){if(--c<1)return l.apply(this,arguments)}},a.ary=Xu,a.assign=n3,a.assignIn=n5,a.assignInWith=n6,a.assignWith=n4,a.at=n8,a.before=Qu,a.bind=nB,a.bindAll=iC,a.bindKey=nD,a.castArray=function(){if(!arguments.length)return[];var c=arguments[0];return nG(c)?c:[c]},a.chain=Yu,a.chunk=function(c,l,eo){l=(eo?rn(c,l,eo):l===et)?1:rC(R(l),0);var es=null==c?0:c.length;if(!es||l<1)return[];for(var ec=0,el=0,ed=ty(ry(es/l));ecec?0:ec+eo),(es=es===et||es>ec?ec:R(es))<0&&(es+=ec),es=eo>es?0:aa(es);eo>>0)?(c=W(c))&&("string"==typeof l||null!=l&&!nZ(l))&&!(l=ln(l))&&Lt(c)?ut(On(c),0,eo):c.split(l,eo):[]},a.spread=function(c,l){if("function"!=typeof c)throw new tA(eo);return l=null==l?0:rC(R(l),0),L(function(et){var eo=et[l],es=ut(et,0,l);return eo&&nt(es,eo),cn(c,this,es)})},a.tail=function(c){var l=null==c?0:c.length;return l?Cn(c,1,l):[]},a.take=function(c,l,eo){return c&&c.length?Cn(c,0,(l=eo||l===et?1:R(l))<0?0:l):[]},a.takeRight=function(c,l,eo){var es=null==c?0:c.length;return es?Cn(c,(l=es-(l=eo||l===et?1:R(l)))<0?0:l,es):[]},a.takeRightWhile=function(c,l){return c&&c.length?Ze(c,x(l,3),!1,!0):[]},a.takeWhile=function(c,l){return c&&c.length?Ze(c,x(l,3)):[]},a.tap=function(c,l){return l(c),c},a.throttle=function(c,l,et){var es=!0,ec=!0;if("function"!=typeof c)throw new tA(eo);return K(et)&&(es="leading"in et?!!et.leading:es,ec="trailing"in et?!!et.trailing:ec),na(c,l,{leading:es,maxWait:l,trailing:ec})},a.thru=er,a.toArray=ua,a.toPairs=ip,a.toPairsIn=ig,a.toPath=function(c){return nG(c)?G(c,Wn):pn(c)?[c]:un(no(W(c)))},a.toPlainObject=oa,a.transform=function(c,l,et){var eo=nG(c),es=eo||nJ(c)||n0(c);if(l=x(l,4),null==et){var ec=c&&c.constructor;et=es?eo?new ec:[]:K(c)&&Jn(ec)?rK(tV(c)):{}}return(es?mn:$n)(c,function(c,eo,es){return l(et,c,eo,es)}),et},a.unary=function(c){return Xu(c,1)},a.union=nm,a.unionBy=nb,a.unionWith=ny,a.uniq=function(c){return c&&c.length?it(c):[]},a.uniqBy=function(c,l){return c&&c.length?it(c,x(l,2)):[]},a.uniqWith=function(c,l){return l="function"==typeof l?l:et,c&&c.length?it(c,et,l):[]},a.unset=function(c,l){return null==c||si(c,l)},a.unzip=Ci,a.unzipWith=Ku,a.update=function(c,l,et){return null==c?c:au(c,l,oi(et))},a.updateWith=function(c,l,eo,es){return es="function"==typeof es?es:et,null==c?c:au(c,l,oi(eo),es)},a.values=Gt,a.valuesIn=function(c){return null==c?[]:Mr(c,on(c))},a.without=n_,a.words=va,a.wrap=function(c,l){return nU(oi(l),c)},a.xor=nw,a.xorBy=nE,a.xorWith=nS,a.zip=nx,a.zipObject=function(c,l){return fu(c||[],l||[],se)},a.zipObjectDeep=function(c,l){return fu(c||[],l||[],fe)},a.zipWith=nk,a.entries=ip,a.entriesIn=ig,a.extend=n5,a.extendWith=n6,Li(a,a),a.add=iB,a.attempt=ik,a.camelCase=im,a.capitalize=da,a.ceil=iD,a.clamp=function(c,l,eo){return eo===et&&(eo=l,l=et),eo!==et&&(eo=(eo=xn(eo))==eo?eo:0),l!==et&&(l=(l=xn(l))==l?l:0),vt(xn(c),l,eo)},a.clone=function(c){return An(c,4)},a.cloneDeep=function(c){return An(c,5)},a.cloneDeepWith=function(c,l){return An(c,5,l="function"==typeof l?l:et)},a.cloneWith=function(c,l){return An(c,4,l="function"==typeof l?l:et)},a.conformsTo=function(c,l){return null==l||Bs(c,l,V(l))},a.deburr=ga,a.defaultTo=function(c,l){return null==c||c!=c?l:c},a.divide=ij,a.endsWith=function(c,l,eo){c=W(c),l=ln(l);var es=c.length,ec=eo=eo===et?es:vt(R(eo),0,es);return(eo-=l.length)>=0&&c.slice(eo,ec)==l},a.eq=bn,a.escape=function(c){return(c=W(c))&&eK.test(c)?c.replace(eV,rp):c},a.escapeRegExp=function(c){return(c=W(c))&&e2.test(c)?c.replace(e1,"\\$&"):c},a.every=function(c,l,eo){var es=nG(c)?As:mc;return eo&&rn(c,l,eo)&&(l=et),es(c,x(l,3))},a.find=nI,a.findIndex=Mu,a.findKey=function(c,l){return Cs(c,x(l,3),$n)},a.findLast=nP,a.findLastIndex=qu,a.findLastKey=function(c,l){return Cs(c,x(l,3),Xr)},a.floor=iL,a.forEach=Zu,a.forEachRight=Ju,a.forIn=function(c,l){return null==c?c:rY(c,x(l,3),on)},a.forInRight=function(c,l){return null==c?c:rZ(c,x(l,3),on)},a.forOwn=function(c,l){return c&&$n(c,x(l,3))},a.forOwnRight=function(c,l){return c&&Xr(c,x(l,3))},a.get=Si,a.gt=nH,a.gte=nW,a.has=function(c,l){return null!=c&&Ru(c,l,Pc)},a.hasIn=Oi,a.head=Gu,a.identity=fn,a.includes=function(c,l,et,eo){c=an(c)?c:Gt(c),et=et&&!eo?R(et):0;var es=c.length;return et<0&&(et=rC(es+et,0)),or(c)?et<=es&&c.indexOf(l,et)>-1:!!es&&Tt(c,l,et)>-1},a.indexOf=function(c,l,et){var eo=null==c?0:c.length;if(!eo)return -1;var es=null==et?0:R(et);return es<0&&(es=rC(eo+es,0)),Tt(c,l,es)},a.inRange=function(c,l,eo){var es,ec,el;return l=Xn(l),eo===et?(eo=l,l=0):eo=Xn(eo),(es=c=xn(c))>=rA(ec=l,el=eo)&&es=-9007199254740991&&c<=9007199254740991},a.isSet=nX,a.isString=or,a.isSymbol=pn,a.isTypedArray=n0,a.isUndefined=function(c){return c===et},a.isWeakMap=function(c){return Y(c)&&r4(c)==eP},a.isWeakSet=function(c){return Y(c)&&"[object WeakSet]"==en(c)},a.join=function(c,l){return null==c?"":rx.call(c,l)},a.kebabCase=ib,a.last=In,a.lastIndexOf=function(c,l,eo){var es=null==c?0:c.length;if(!es)return -1;var ec=es;return eo!==et&&(ec=(ec=R(eo))<0?rC(es+ec,0):rA(ec,es-1)),l==l?function(c,l,et){for(var eo=et+1;eo--&&c[eo]!==l;);return eo}(c,l,ec):ye(c,Is,ec,!0)},a.lowerCase=iy,a.lowerFirst=i_,a.lt=n1,a.lte=n2,a.max=function(c){return c&&c.length?Ge(c,fn,Qr):et},a.maxBy=function(c,l){return c&&c.length?Ge(c,x(l,2),Qr):et},a.mean=function(c){return xs(c,fn)},a.meanBy=function(c,l){return xs(c,x(l,2))},a.min=function(c){return c&&c.length?Ge(c,fn,ni):et},a.minBy=function(c,l){return c&&c.length?Ge(c,x(l,2),ni):et},a.stubArray=Hi,a.stubFalse=Ni,a.stubObject=function(){return{}},a.stubString=function(){return""},a.stubTrue=function(){return!0},a.multiply=iF,a.nth=function(c,l){return c&&c.length?nu(c,R(l)):et},a.noConflict=function(){return t6._===this&&(t6._=tj),this},a.noop=Di,a.now=n$,a.pad=function(c,l,et){c=W(c);var eo=(l=R(l))?Dt(c):0;if(!l||eo>=l)return c;var es=(l-eo)/2;return Ve(r_(es),et)+c+Ve(ry(es),et)},a.padEnd=function(c,l,et){c=W(c);var eo=(l=R(l))?Dt(c):0;return l&&eol){var es=c;c=l,l=es}if(eo||c%1||l%1){var ec=rR();return rA(c+ec*(l-c+t1("1e-"+((ec+"").length-1))),l)}return ei(c,l)},a.reduce=function(c,l,et){var eo=nG(c)?Hr:Es,es=arguments.length<3;return eo(c,x(l,4),et,es,rJ)},a.reduceRight=function(c,l,et){var eo=nG(c)?jo:Es,es=arguments.length<3;return eo(c,x(l,4),et,es,rQ)},a.repeat=function(c,l,eo){return l=(eo?rn(c,l,eo):l===et)?1:R(l),ri(W(c),l)},a.replace=function(){var c=arguments,l=W(c[0]);return c.length<3?l:l.replace(c[1],c[2])},a.result=function(c,l,eo){l=st(l,c);var es=-1,ec=l.length;for(ec||(ec=1,c=et);++es9007199254740991)return[];var et=4294967295,eo=rA(c,4294967295);l=x(l),c-=4294967295;for(var es=Fr(eo,l);++et=el)return c;var eh=eo-Dt(es);if(eh<1)return es;var ef=ed?ut(ed,0,eh).join(""):c.slice(0,eh);if(ec===et)return ef+es;if(ed&&(eh+=ef.length-eh),nZ(ec)){if(c.slice(eh).search(ec)){var ep,eg=ef;for(ec.global||(ec=tk(ec.source,W(ts.exec(ec))+"g")),ec.lastIndex=0;ep=ec.exec(eg);)var em=ep.index;ef=ef.slice(0,em===et?eh:em)}}else if(c.indexOf(ln(ec),eh)!=eh){var eb=ef.lastIndexOf(ec);eb>-1&&(ef=ef.slice(0,eb))}return ef+es},a.unescape=function(c){return(c=W(c))&&eG.test(c)?c.replace(eW,rg):c},a.uniqueId=function(c){var l=++tM;return W(c)+l},a.upperCase=iS,a.upperFirst=ix,a.each=Zu,a.eachRight=Ju,a.first=Gu,Li(a,(tb={},$n(a,function(c,l){tN.call(a.prototype,l)||(tb[l]=c)}),tb),{chain:!1}),a.VERSION="4.17.21",mn(["bind","bindKey","curry","curryRight","partial","partialRight"],function(c){a[c].placeholder=a}),mn(["drop","take"],function(c,l){H.prototype[c]=function(eo){eo=eo===et?1:rC(R(eo),0);var es=this.__filtered__&&!l?new H(this):this.clone();return es.__filtered__?es.__takeCount__=rA(eo,es.__takeCount__):es.__views__.push({size:rA(eo,4294967295),type:c+(es.__dir__<0?"Right":"")}),es},H.prototype[c+"Right"]=function(l){return this.reverse()[c](l).reverse()}}),mn(["filter","map","takeWhile"],function(c,l){var et=l+1,eo=1==et||3==et;H.prototype[c]=function(c){var l=this.clone();return l.__iteratees__.push({iteratee:x(c,3),type:et}),l.__filtered__=l.__filtered__||eo,l}}),mn(["head","last"],function(c,l){var et="take"+(l?"Right":"");H.prototype[c]=function(){return this[et](1).value()[0]}}),mn(["initial","tail"],function(c,l){var et="drop"+(l?"":"Right");H.prototype[c]=function(){return this.__filtered__?new H(this):this[et](1)}}),H.prototype.compact=function(){return this.filter(fn)},H.prototype.find=function(c){return this.filter(c).head()},H.prototype.findLast=function(c){return this.reverse().find(c)},H.prototype.invokeMap=L(function(c,l){return"function"==typeof c?new H(this):this.map(function(et){return ae(et,c,l)})}),H.prototype.reject=function(c){return this.filter(ur(x(c)))},H.prototype.slice=function(c,l){c=R(c);var eo=this;return eo.__filtered__&&(c>0||l<0)?new H(eo):(c<0?eo=eo.takeRight(-c):c&&(eo=eo.drop(c)),l!==et&&(eo=(l=R(l))<0?eo.dropRight(-l):eo.take(l-c)),eo)},H.prototype.takeRightWhile=function(c){return this.reverse().takeWhile(c).reverse()},H.prototype.toArray=function(){return this.take(4294967295)},$n(H.prototype,function(c,l){var eo=/^(?:filter|find|map|reject)|While$/.test(l),es=/^(?:head|last)$/.test(l),ec=a[es?"take"+("last"==l?"Right":""):l],el=es||/^find/.test(l);ec&&(a.prototype[l]=function(){var l=this.__wrapped__,ed=es?[1]:arguments,eh=l instanceof H,ef=ed[0],ep=eh||nG(l),m=function(c){var l=ec.apply(a,nt([c],ed));return es&&eg?l[0]:l};ep&&eo&&"function"==typeof ef&&1!=ef.length&&(eh=ep=!1);var eg=this.__chain__,em=!!this.__actions__.length,eb=el&&!eg,ey=eh&&!em;if(!el&&ep){l=ey?l:new H(this);var e_=c.apply(l,ed);return e_.__actions__.push({func:er,args:[m],thisArg:et}),new Pn(e_,eg)}return eb&&ey?c.apply(this,ed):(e_=this.thru(m),eb?es?e_.value()[0]:e_.value():e_)})}),mn(["pop","push","shift","sort","splice","unshift"],function(c){var l=tI[c],et=/^(?:push|sort|unshift)$/.test(c)?"tap":"thru",eo=/^(?:pop|shift)$/.test(c);a.prototype[c]=function(){var c=arguments;if(eo&&!this.__chain__){var es=this.value();return l.apply(nG(es)?es:[],c)}return this[et](function(et){return l.apply(nG(et)?et:[],c)})}}),$n(H.prototype,function(c,l){var et=a[l];if(et){var eo=et.name+"";tN.call(rL,eo)||(rL[eo]=[]),rL[eo].push({name:l,func:et})}}),rL[Xe(et,2).name]=[{name:"wrapper",func:et}],H.prototype.clone=function(){var c=new H(this.__wrapped__);return c.__actions__=un(this.__actions__),c.__dir__=this.__dir__,c.__filtered__=this.__filtered__,c.__iteratees__=un(this.__iteratees__),c.__takeCount__=this.__takeCount__,c.__views__=un(this.__views__),c},H.prototype.reverse=function(){if(this.__filtered__){var c=new H(this);c.__dir__=-1,c.__filtered__=!0}else c=this.clone(),c.__dir__*=-1;return c},H.prototype.value=function(){var c=this.__wrapped__.value(),l=this.__dir__,et=nG(c),eo=l<0,es=et?c.length:0,ec=function(c,l,et){for(var eo=-1,es=et.length;++eo=this.__values__.length,l=c?et:this.__values__[this.__index__++];return{done:c,value:l}},a.prototype.plant=function(c){for(var l,eo=this;eo instanceof qe;){var es=Fu(eo);es.__index__=0,es.__values__=et,l?ec.__wrapped__=es:l=es;var ec=es;eo=eo.__wrapped__}return ec.__wrapped__=c,l},a.prototype.reverse=function(){var c=this.__wrapped__;if(c instanceof H){var l=c;return this.__actions__.length&&(l=new H(this)),(l=l.reverse()).__actions__.push({func:er,args:[Ai],thisArg:et}),new Pn(l,this.__chain__)}return this.thru(Ai)},a.prototype.toJSON=a.prototype.valueOf=a.prototype.value=function(){return ou(this.__wrapped__,this.__actions__)},a.prototype.first=a.prototype.head,t4&&(a.prototype[t4]=function(){return this}),a}();t8?((t8.exports=rm)._=rm,t4._=rm):t6._=rm}).call(n1)}(n2,n2.exports);var n3=Object.defineProperty,n5=Object.defineProperties,n6=Object.getOwnPropertyDescriptors,n4=Object.getOwnPropertySymbols,n8=Object.prototype.hasOwnProperty,n9=Object.prototype.propertyIsEnumerable,ya=(c,l,et)=>l in c?n3(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,index_es_cr=(c,l)=>{for(var et in l||(l={}))n8.call(l,et)&&ya(c,et,l[et]);if(n4)for(var et of n4(l))n9.call(l,et)&&ya(c,et,l[et]);return c},Yg=(c,l)=>n5(c,n6(l));function universal_provider_dist_index_es_ft(c,l,et){var eo;let es=function(c){let[l,et]=c.split(":");return{namespace:l,reference:et}}(c);return(null==(eo=l.rpcMap)?void 0:eo[es.reference])||`https://rpc.walletconnect.com/v1/?chainId=${es.namespace}:${es.reference}&projectId=${et}`}function universal_provider_dist_index_es_Ct(c){return c.includes(":")?c.split(":")[1]:c}function Sa(c){return c.map(c=>`${c.split(":")[0]}:${c.split(":")[1]}`)}function Oa(c){var l,et,eo,es;let ec={};if(!index_es_B(c))return ec;for(let[el,ed]of Object.entries(c)){let c=index_es_oe(el)?[el]:ed.chains,eh=ed.methods||[],ef=ed.events||[],ep=ed.rpcMap||{},eg=index_es_Xe(el);ec[eg]=Yg(index_es_cr(index_es_cr({},ec[eg]),ed),{chains:dist_index_es_S(c,null==(l=ec[eg])?void 0:l.chains),methods:dist_index_es_S(eh,null==(et=ec[eg])?void 0:et.methods),events:dist_index_es_S(ef,null==(eo=ec[eg])?void 0:eo.events),rpcMap:index_es_cr(index_es_cr({},ep),null==(es=ec[eg])?void 0:es.rpcMap)})}return ec}function Xg(c){return c.includes(":")?c.split(":")[2]:c}function index_es_Wi(c){return"number"==typeof c?c:c.includes("0x")?parseInt(c,16):c.includes(":")?Number(c.split(":")[1]):Number(c)}let n7={},dist_index_es_z=c=>n7[c],Fi=(c,l)=>{n7[c]=l};let Vg=class Vg{constructor(c){this.name="polkadot",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(c,l),this.chainId=c,this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${c}`)}getAccounts(){let c=this.namespace.accounts;return c&&c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2])||[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;let eo=universal_provider_dist_index_es_Ct(l);c[eo]=this.createHttpProvider(eo,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(c,this.namespace,this.client.core.projectId);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};let kg=class kg{constructor(c){this.name="eip155",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.httpProviders=this.createHttpProviders(),this.chainId=parseInt(this.getDefaultChain())}async request(c){switch(c.request.method){case"eth_requestAccounts":case"eth_accounts":return this.getAccounts();case"wallet_switchEthereumChain":return await this.handleSwitchChain(c);case"eth_chainId":return parseInt(this.getDefaultChain())}return this.namespace.methods.includes(c.request.method)?await this.client.request(c):this.getHttpProvider().request(c.request)}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(parseInt(c),l),this.chainId=parseInt(c),this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${c}`)}requestAccounts(){return this.getAccounts()}getDefaultChain(){if(this.chainId)return this.chainId.toString();if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(`${this.name}:${c}`,this.namespace,this.client.core.projectId);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;let eo=parseInt(universal_provider_dist_index_es_Ct(l));c[eo]=this.createHttpProvider(eo,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getAccounts(){let c=this.namespace.accounts;return c?[...new Set(c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2]))]:[]}getHttpProvider(){let c=this.chainId,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}async handleSwitchChain(c){var l,et;let eo=c.request.params?null==(l=c.request.params[0])?void 0:l.chainId:"0x0";eo=eo.startsWith("0x")?eo:`0x${eo}`;let es=parseInt(eo,16);if(this.isChainApproved(es))this.setDefaultChain(`${es}`);else if(this.namespace.methods.includes("wallet_switchEthereumChain"))await this.client.request({topic:c.topic,request:{method:c.request.method,params:[{chainId:eo}]},chainId:null==(et=this.namespace.chains)?void 0:et[0]}),this.setDefaultChain(`${es}`);else throw Error(`Failed to switch to chain 'eip155:${es}'. The chain is not approved or the wallet does not support 'wallet_switchEthereumChain' method.`);return null}isChainApproved(c){return this.namespace.chains.includes(`${this.name}:${c}`)}};let jg=class jg{constructor(c){this.name="solana",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(c,l),this.chainId=c,this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${c}`)}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}getAccounts(){let c=this.namespace.accounts;return c?[...new Set(c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2]))]:[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;let eo=universal_provider_dist_index_es_Ct(l);c[eo]=this.createHttpProvider(eo,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(c,this.namespace,this.client.core.projectId);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};let nv=class nv{constructor(c){this.name="cosmos",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(c,l),this.chainId=c,this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${this.chainId}`)}getAccounts(){let c=this.namespace.accounts;return c?[...new Set(c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2]))]:[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;let eo=universal_provider_dist_index_es_Ct(l);c[eo]=this.createHttpProvider(eo,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(c,this.namespace,this.client.core.projectId);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};let tv=class tv{constructor(c){this.name="cip34",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(c,l),this.chainId=c,this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${this.chainId}`)}getAccounts(){let c=this.namespace.accounts;return c?[...new Set(c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2]))]:[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{let et=this.getCardanoRPCUrl(l),eo=universal_provider_dist_index_es_Ct(l);c[eo]=this.createHttpProvider(eo,et)}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}getCardanoRPCUrl(c){let l=this.namespace.rpcMap;if(l)return l[c]}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||this.getCardanoRPCUrl(c);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};let ev=class ev{constructor(c){this.name="elrond",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(c,l),this.chainId=c,this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${c}`)}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}getAccounts(){let c=this.namespace.accounts;return c?[...new Set(c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2]))]:[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;let eo=universal_provider_dist_index_es_Ct(l);c[eo]=this.createHttpProvider(eo,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(c,this.namespace,this.client.core.projectId);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};let rv=class rv{constructor(c){this.name="multiversx",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){this.httpProviders[c]||this.setHttpProvider(c,l),this.chainId=c,this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${c}`)}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}getAccounts(){let c=this.namespace.accounts;return c?[...new Set(c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2]))]:[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;let eo=universal_provider_dist_index_es_Ct(l);c[eo]=this.createHttpProvider(eo,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(c,this.namespace,this.client.core.projectId);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);return new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};let iv=class iv{constructor(c){this.name="near",this.namespace=c.namespace,this.events=dist_index_es_z("events"),this.client=dist_index_es_z("client"),this.chainId=this.getDefaultChain(),this.httpProviders=this.createHttpProviders()}updateNamespace(c){this.namespace=Object.assign(this.namespace,c)}requestAccounts(){return this.getAccounts()}getDefaultChain(){if(this.chainId)return this.chainId;if(this.namespace.defaultChain)return this.namespace.defaultChain;let c=this.namespace.chains[0];if(!c)throw Error("ChainId not found");return c.split(":")[1]}request(c){return this.namespace.methods.includes(c.request.method)?this.client.request(c):this.getHttpProvider().request(c.request)}setDefaultChain(c,l){if(this.chainId=c,!this.httpProviders[c]){let et=l||universal_provider_dist_index_es_ft(`${this.name}:${c}`,this.namespace);if(!et)throw Error(`No RPC url provided for chainId: ${c}`);this.setHttpProvider(c,et)}this.events.emit(n0.DEFAULT_CHAIN_CHANGED,`${this.name}:${this.chainId}`)}getAccounts(){let c=this.namespace.accounts;return c&&c.filter(c=>c.split(":")[1]===this.chainId.toString()).map(c=>c.split(":")[2])||[]}createHttpProviders(){let c={};return this.namespace.chains.forEach(l=>{var et;c[l]=this.createHttpProvider(l,null==(et=this.namespace.rpcMap)?void 0:et[l])}),c}getHttpProvider(){let c=`${this.name}:${this.chainId}`,l=this.httpProviders[c];if(typeof l>"u")throw Error(`JSON-RPC provider for ${c} not found`);return l}setHttpProvider(c,l){let et=this.createHttpProvider(c,l);et&&(this.httpProviders[c]=et)}createHttpProvider(c,l){let et=l||universal_provider_dist_index_es_ft(c,this.namespace);return typeof et>"u"?void 0:new JsonRpcProvider(new HttpConnection(et,dist_index_es_z("disableProviderPing")))}};var ie=Object.defineProperty,ir=Object.defineProperties,io=Object.getOwnPropertyDescriptors,iu=Object.getOwnPropertySymbols,ic=Object.prototype.hasOwnProperty,il=Object.prototype.propertyIsEnumerable,Ta=(c,l,et)=>l in c?ie(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,index_es_hr=(c,l)=>{for(var et in l||(l={}))ic.call(l,et)&&Ta(c,et,l[et]);if(iu)for(var et of iu(l))il.call(l,et)&&Ta(c,et,l[et]);return c},Mi=(c,l)=>ir(c,io(l));let index_es_lr=class index_es_lr{constructor(c){this.events=new(eS()),this.rpcProviders={},this.shouldAbortPairingAttempt=!1,this.maxPairingAttempts=10,this.disableProviderPing=!1,this.providerOpts=c,this.logger="u">typeof c?.logger&&"string"!=typeof c?.logger?c.logger:(0,tC.pino)((0,tC.getDefaultLoggerOptions)({level:c?.logger||nZ})),this.disableProviderPing=c?.disableProviderPing||!1}static async init(c){let l=new index_es_lr(c);return await l.initialize(),l}async request(c,l){let[et,eo]=this.validateChain(l);if(!this.session)throw Error("Please call connect() before request()");return await this.getProvider(et).request({request:index_es_hr({},c),chainId:`${et}:${eo}`,topic:this.session.topic})}sendAsync(c,l,et){this.request(c,et).then(c=>l(null,c)).catch(c=>l(c,void 0))}async enable(){if(!this.client)throw Error("Sign Client not initialized");return this.session||await this.connect({namespaces:this.namespaces,optionalNamespaces:this.optionalNamespaces,sessionProperties:this.sessionProperties}),await this.requestAccounts()}async disconnect(){var c;if(!this.session)throw Error("Please call connect() before enable()");await this.client.disconnect({topic:null==(c=this.session)?void 0:c.topic,reason:index_es_U("USER_DISCONNECTED")}),await this.cleanup()}async connect(c){if(!this.client)throw Error("Sign Client not initialized");if(this.setNamespaces(c),await this.cleanupPendingPairings(),!c.skipPairing)return await this.pair(c.pairingTopic)}on(c,l){this.events.on(c,l)}once(c,l){this.events.once(c,l)}removeListener(c,l){this.events.removeListener(c,l)}off(c,l){this.events.off(c,l)}get isWalletConnect(){return!0}async pair(c){this.shouldAbortPairingAttempt=!1;let l=0;do{if(this.shouldAbortPairingAttempt)throw Error("Pairing aborted");if(l>=this.maxPairingAttempts)throw Error("Max auto pairing attempts reached");let{uri:et,approval:eo}=await this.client.connect({pairingTopic:c,requiredNamespaces:this.namespaces,optionalNamespaces:this.optionalNamespaces,sessionProperties:this.sessionProperties});et&&(this.uri=et,this.events.emit("display_uri",et)),await eo().then(c=>{this.session=c,this.namespaces||(this.namespaces=function(c){let l={};for(let[et,eo]of Object.entries(c)){let c=eo.methods||[],es=eo.events||[],ec=eo.accounts||[],el=index_es_oe(et)?[et]:eo.chains?eo.chains:Sa(eo.accounts);l[et]={chains:el,methods:c,events:es,accounts:ec}}return l}(c.namespaces),this.persist("namespaces",this.namespaces))}).catch(c=>{if(c.message!==nD)throw c;l++})}while(!this.session);return this.onConnect(),this.session}setDefaultChain(c,l){try{if(!this.session)return;let[et,eo]=this.validateChain(c);this.getProvider(et).setDefaultChain(eo,l)}catch(c){if(!/Please call connect/.test(c.message))throw c}}async cleanupPendingPairings(c={}){this.logger.info("Cleaning up inactive pairings...");let l=this.client.pairing.getAll();if(index_es_D(l)){for(let et of l)c.deletePairings?this.client.core.expirer.set(et.topic,0):await this.client.core.relayer.subscriber.unsubscribe(et.topic);this.logger.info(`Inactive pairings cleared: ${l.length}`)}}abortPairingAttempt(){this.shouldAbortPairingAttempt=!0}async checkStorage(){if(this.namespaces=await this.getFromStore("namespaces"),this.optionalNamespaces=await this.getFromStore("optionalNamespaces")||{},this.client.session.length){let c=this.client.session.keys.length-1;this.session=this.client.session.get(this.client.session.keys[c]),this.createProviders()}}async initialize(){this.logger.trace("Initialized"),await this.createClient(),await this.checkStorage(),this.registerEventListeners()}async createClient(){this.client=this.providerOpts.client||await sign_client_dist_index_es_Q.init({logger:this.providerOpts.logger||nZ,relayUrl:this.providerOpts.relayUrl||"wss://relay.walletconnect.com",projectId:this.providerOpts.projectId,metadata:this.providerOpts.metadata,storageOptions:this.providerOpts.storageOptions,storage:this.providerOpts.storage,name:this.providerOpts.name}),this.logger.trace("SignClient Initialized")}createProviders(){if(!this.client)throw Error("Sign Client not initialized");if(!this.session)throw Error("Session not initialized. Please call connect() before enable()");let c=[...new Set(Object.keys(this.session.namespaces).map(c=>index_es_Xe(c)))];Fi("client",this.client),Fi("events",this.events),Fi("disableProviderPing",this.disableProviderPing),c.forEach(c=>{if(!this.session)return;let l=function(c,l){let et=Object.keys(l.namespaces).filter(l=>l.includes(c));if(!et.length)return[];let eo=[];return et.forEach(c=>{let et=l.namespaces[c].accounts;eo.push(...et)}),eo}(c,this.session),et=Sa(l),eo=function(c={},l={}){let et=Oa(c),eo=Oa(l);return n2.exports.merge(et,eo)}(this.namespaces,this.optionalNamespaces),es=Mi(index_es_hr({},eo[c]),{accounts:l,chains:et});switch(c){case"eip155":this.rpcProviders[c]=new kg({namespace:es});break;case"solana":this.rpcProviders[c]=new jg({namespace:es});break;case"cosmos":this.rpcProviders[c]=new nv({namespace:es});break;case"polkadot":this.rpcProviders[c]=new Vg({namespace:es});break;case"cip34":this.rpcProviders[c]=new tv({namespace:es});break;case"elrond":this.rpcProviders[c]=new ev({namespace:es});break;case"multiversx":this.rpcProviders[c]=new rv({namespace:es});break;case"near":this.rpcProviders[c]=new iv({namespace:es})}})}registerEventListeners(){if(typeof this.client>"u")throw Error("Sign Client is not initialized");this.client.on("session_ping",c=>{this.events.emit("session_ping",c)}),this.client.on("session_event",c=>{let{params:l}=c,{event:et}=l;if("accountsChanged"===et.name){let c=et.data;c&&index_es_D(c)&&this.events.emit("accountsChanged",c.map(Xg))}else if("chainChanged"===et.name){let c=l.chainId,et=l.event.data,eo=index_es_Xe(c),es=index_es_Wi(c)!==index_es_Wi(et)?`${eo}:${index_es_Wi(et)}`:c;this.onChainChanged(es)}else this.events.emit(et.name,et.data);this.events.emit("session_event",c)}),this.client.on("session_update",({topic:c,params:l})=>{var et;let{namespaces:eo}=l,es=null==(et=this.client)?void 0:et.session.get(c);this.session=Mi(index_es_hr({},es),{namespaces:eo}),this.onSessionUpdate(),this.events.emit("session_update",{topic:c,params:l})}),this.client.on("session_delete",async c=>{await this.cleanup(),this.events.emit("session_delete",c),this.events.emit("disconnect",Mi(index_es_hr({},index_es_U("USER_DISCONNECTED")),{data:c.topic}))}),this.on(n0.DEFAULT_CHAIN_CHANGED,c=>{this.onChainChanged(c,!0)})}getProvider(c){if(!this.rpcProviders[c])throw Error(`Provider not found: ${c}`);return this.rpcProviders[c]}onSessionUpdate(){Object.keys(this.rpcProviders).forEach(c=>{var l;this.getProvider(c).updateNamespace(null==(l=this.session)?void 0:l.namespaces[c])})}setNamespaces(c){let{namespaces:l,optionalNamespaces:et,sessionProperties:eo}=c;l&&Object.keys(l).length&&(this.namespaces=l),et&&Object.keys(et).length&&(this.optionalNamespaces=et),this.sessionProperties=eo,this.persist("namespaces",l),this.persist("optionalNamespaces",et)}validateChain(c){let[l,et]=c?.split(":")||["",""];if(!this.namespaces||!Object.keys(this.namespaces).length)return[l,et];if(l&&!Object.keys(this.namespaces||{}).map(c=>index_es_Xe(c)).includes(l))throw Error(`Namespace '${l}' is not configured. Please call connect() first with namespace config.`);if(l&&et)return[l,et];let eo=index_es_Xe(Object.keys(this.namespaces)[0]),es=this.rpcProviders[eo].getDefaultChain();return[eo,es]}async requestAccounts(){let[c]=this.validateChain();return await this.getProvider(c).requestAccounts()}onChainChanged(c,l=!1){var et;if(!this.namespaces)return;let[eo,es]=this.validateChain(c);l||this.getProvider(eo).setDefaultChain(es),(null!=(et=this.namespaces[eo])?et:this.namespaces[`${eo}:${es}`]).defaultChain=es,this.persist("namespaces",this.namespaces),this.events.emit("chainChanged",es)}onConnect(){this.createProviders(),this.events.emit("connect",{session:this.session})}async cleanup(){this.session=void 0,this.namespaces=void 0,this.optionalNamespaces=void 0,this.sessionProperties=void 0,this.persist("namespaces",void 0),this.persist("optionalNamespaces",void 0),this.persist("sessionProperties",void 0),await this.cleanupPendingPairings({deletePairings:!0})}persist(c,l){this.client.core.storage.setItem(`${nX}/${c}`,l)}async getFromStore(c){return await this.client.core.storage.getItem(`${nX}/${c}`)}};let ih=["eth_sendTransaction","personal_sign"],ip=["eth_accounts","eth_requestAccounts","eth_sendRawTransaction","eth_sign","eth_signTransaction","eth_signTypedData","eth_signTypedData_v3","eth_signTypedData_v4","eth_sendTransaction","personal_sign","wallet_switchEthereumChain","wallet_addEthereumChain","wallet_getPermissions","wallet_requestPermissions","wallet_registerOnboarding","wallet_watchAsset","wallet_scanQRCode"],ig=["chainChanged","accountsChanged"],im=["chainChanged","accountsChanged","message","disconnect","connect"];var ib=Object.defineProperty,iy=Object.defineProperties,i_=Object.getOwnPropertyDescriptors,iw=Object.getOwnPropertySymbols,iE=Object.prototype.hasOwnProperty,iS=Object.prototype.propertyIsEnumerable,ethereum_provider_dist_index_es_O=(c,l,et)=>l in c?ib(c,l,{enumerable:!0,configurable:!0,writable:!0,value:et}):c[l]=et,ethereum_provider_dist_index_es_p=(c,l)=>{for(var et in l||(l={}))iE.call(l,et)&ðereum_provider_dist_index_es_O(c,et,l[et]);if(iw)for(var et of iw(l))iS.call(l,et)&ðereum_provider_dist_index_es_O(c,et,l[et]);return c},ethereum_provider_dist_index_es_M=(c,l)=>iy(c,i_(l));function ethereum_provider_dist_index_es_g(c){return Number(c[0].split(":")[1])}function f(c){return`0x${c.toString(16)}`}let dist_index_es_v=class dist_index_es_v{constructor(){this.events=new eE.EventEmitter,this.namespace="eip155",this.accounts=[],this.chainId=1,this.STORAGE_KEY="wc@2:ethereum_provider:",this.on=(c,l)=>(this.events.on(c,l),this),this.once=(c,l)=>(this.events.once(c,l),this),this.removeListener=(c,l)=>(this.events.removeListener(c,l),this),this.off=(c,l)=>(this.events.off(c,l),this),this.parseAccount=c=>this.isCompatibleChainId(c)?this.parseAccountId(c).address:c,this.signer={},this.rpc={}}static async init(c){let l=new dist_index_es_v;return await l.initialize(c),l}async request(c){return await this.signer.request(c,this.formatChainId(this.chainId))}sendAsync(c,l){this.signer.sendAsync(c,l,this.formatChainId(this.chainId))}get connected(){return!!this.signer.client&&this.signer.client.core.relayer.connected}get connecting(){return!!this.signer.client&&this.signer.client.core.relayer.connecting}async enable(){return this.session||await this.connect(),await this.request({method:"eth_requestAccounts"})}async connect(c){if(!this.signer.client)throw Error("Provider not initialized. Call init() first");this.loadConnectOpts(c);let{required:l,optional:et}=function(c){let{chains:l,optionalChains:et,methods:eo,optionalMethods:es,events:ec,optionalEvents:el,rpcMap:ed}=c;if(!D(l))throw Error("Invalid chains");let eh={chains:l,methods:eo||ih,events:ec||ig,rpcMap:ethereum_provider_dist_index_es_p({},l.length?{[ethereum_provider_dist_index_es_g(l)]:ed[ethereum_provider_dist_index_es_g(l)]}:{})},ef=ec?.filter(c=>!ig.includes(c)),ep=eo?.filter(c=>!ih.includes(c));if(!et&&!el&&!es&&!(null!=ef&&ef.length)&&!(null!=ep&&ep.length))return{required:l.length?eh:void 0};let eg=ef?.length&&ep?.length||!et,em={chains:[...new Set(eg?eh.chains.concat(et||[]):et)],methods:[...new Set(eh.methods.concat(null!=es&&es.length?es:ip))],events:[...new Set(eh.events.concat(null!=el&&el.length?el:im))],rpcMap:ed};return{required:l.length?eh:void 0,optional:et.length?em:void 0}}(this.rpc);try{let eo=await new Promise(async(eo,es)=>{var ec;this.rpc.showQrModal&&(null==(ec=this.modal)||ec.subscribeModal(c=>{c.open||this.signer.session||(this.signer.abortPairingAttempt(),es(Error("Connection request reset. Please try again.")))})),await this.signer.connect(ethereum_provider_dist_index_es_M(ethereum_provider_dist_index_es_p({namespaces:ethereum_provider_dist_index_es_p({},l&&{[this.namespace]:l})},et&&{optionalNamespaces:{[this.namespace]:et}}),{pairingTopic:c?.pairingTopic})).then(c=>{eo(c)}).catch(c=>{es(Error(c.message))})});if(!eo)return;let es=function(c,l=[]){let et=[];return Object.keys(c).forEach(eo=>{if(l.length&&!l.includes(eo))return;let es=c[eo];et.push(...es.accounts)}),et}(eo.namespaces,[this.namespace]);this.setChainIds(this.rpc.chains.length?this.rpc.chains:es),this.setAccounts(es),this.events.emit("connect",{chainId:f(this.chainId)})}catch(c){throw this.signer.logger.error(c),c}finally{this.modal&&this.modal.closeModal()}}async disconnect(){this.session&&await this.signer.disconnect(),this.reset()}get isWalletConnect(){return!0}get session(){return this.signer.session}registerEventListeners(){this.signer.on("session_event",c=>{let{params:l}=c,{event:et}=l;"accountsChanged"===et.name?(this.accounts=this.parseAccounts(et.data),this.events.emit("accountsChanged",this.accounts)):"chainChanged"===et.name?this.setChainId(this.formatChainId(et.data)):this.events.emit(et.name,et.data),this.events.emit("session_event",c)}),this.signer.on("chainChanged",c=>{let l=parseInt(c);this.chainId=l,this.events.emit("chainChanged",f(this.chainId)),this.persist()}),this.signer.on("session_update",c=>{this.events.emit("session_update",c)}),this.signer.on("session_delete",c=>{this.reset(),this.events.emit("session_delete",c),this.events.emit("disconnect",ethereum_provider_dist_index_es_M(ethereum_provider_dist_index_es_p({},function(c,l){let{message:et,code:eo}=tS[c];return{message:l?`${et} ${l}`:et,code:eo}}("USER_DISCONNECTED")),{data:c.topic,name:"USER_DISCONNECTED"}))}),this.signer.on("display_uri",c=>{var l,et;this.rpc.showQrModal&&(null==(l=this.modal)||l.closeModal(),null==(et=this.modal)||et.openModal({uri:c})),this.events.emit("display_uri",c)})}switchEthereumChain(c){this.request({method:"wallet_switchEthereumChain",params:[{chainId:c.toString(16)}]})}isCompatibleChainId(c){return"string"==typeof c&&c.startsWith(`${this.namespace}:`)}formatChainId(c){return`${this.namespace}:${c}`}parseChainId(c){return Number(c.split(":")[1])}setChainIds(c){let l=c.filter(c=>this.isCompatibleChainId(c)).map(c=>this.parseChainId(c));l.length&&(this.chainId=l[0],this.events.emit("chainChanged",f(this.chainId)),this.persist())}setChainId(c){if(this.isCompatibleChainId(c)){let l=this.parseChainId(c);this.chainId=l,this.switchEthereumChain(l)}}parseAccountId(c){let[l,et,eo]=c.split(":");return{chainId:`${l}:${et}`,address:eo}}setAccounts(c){this.accounts=c.filter(c=>this.parseChainId(this.parseAccountId(c).chainId)===this.chainId).map(c=>this.parseAccountId(c).address),this.events.emit("accountsChanged",this.accounts)}getRpcConfig(c){var l,et;let eo=null!=(l=c?.chains)?l:[],es=null!=(et=c?.optionalChains)?et:[],ec=eo.concat(es);if(!ec.length)throw Error("No chains specified in either `chains` or `optionalChains`");let el=eo.length?c?.methods||ih:[],ed=eo.length?c?.events||ig:[],eh=c?.optionalMethods||[],ef=c?.optionalEvents||[],ep=c?.rpcMap||this.buildRpcMap(ec,c.projectId),eg=c?.qrModalOptions||void 0;return{chains:eo?.map(c=>this.formatChainId(c)),optionalChains:es.map(c=>this.formatChainId(c)),methods:el,events:ed,optionalMethods:eh,optionalEvents:ef,rpcMap:ep,showQrModal:!!(null!=c&&c.showQrModal),qrModalOptions:eg,projectId:c.projectId,metadata:c.metadata}}buildRpcMap(c,l){let et={};return c.forEach(c=>{et[c]=this.getRpcUrl(c,l)}),et}async initialize(c){if(this.rpc=this.getRpcConfig(c),this.chainId=this.rpc.chains.length?ethereum_provider_dist_index_es_g(this.rpc.chains):ethereum_provider_dist_index_es_g(this.rpc.optionalChains),this.signer=await index_es_lr.init({projectId:this.rpc.projectId,metadata:this.rpc.metadata,disableProviderPing:c.disableProviderPing,relayUrl:c.relayUrl,storageOptions:c.storageOptions}),this.registerEventListeners(),await this.loadPersistedSession(),this.rpc.showQrModal){let c;try{let{WalletConnectModal:l}=await et.e(465).then(et.bind(et,78465));c=l}catch{throw Error("To use QR modal, please install @walletconnect/modal package")}if(c)try{this.modal=new c(ethereum_provider_dist_index_es_p({walletConnectVersion:2,projectId:this.rpc.projectId,standaloneChains:this.rpc.chains},this.rpc.qrModalOptions))}catch(c){throw this.signer.logger.error(c),Error("Could not generate WalletConnectModal Instance")}}}loadConnectOpts(c){if(!c)return;let{chains:l,optionalChains:et,rpcMap:eo}=c;l&&D(l)&&(this.rpc.chains=l.map(c=>this.formatChainId(c)),l.forEach(c=>{this.rpc.rpcMap[c]=eo?.[c]||this.getRpcUrl(c)})),et&&D(et)&&(this.rpc.optionalChains=[],this.rpc.optionalChains=et?.map(c=>this.formatChainId(c)),et.forEach(c=>{this.rpc.rpcMap[c]=eo?.[c]||this.getRpcUrl(c)}))}getRpcUrl(c,l){var et;return(null==(et=this.rpc.rpcMap)?void 0:et[c])||`https://rpc.walletconnect.com/v1/?chainId=eip155:${c}&projectId=${l||this.rpc.projectId}`}async loadPersistedSession(){if(!this.session)return;let c=await this.signer.client.core.storage.getItem(`${this.STORAGE_KEY}/chainId`),l=this.session.namespaces[`${this.namespace}:${c}`]?this.session.namespaces[`${this.namespace}:${c}`]:this.session.namespaces[this.namespace];this.setChainIds(c?[this.formatChainId(c)]:l?.accounts),this.setAccounts(l?.accounts)}reset(){this.chainId=1,this.accounts=[]}persist(){this.session&&this.signer.client.core.storage.setItem(`${this.STORAGE_KEY}/chainId`,this.chainId)}parseAccounts(c){return"string"==typeof c||c instanceof String?[this.parseAccount(c)]:c.map(c=>this.parseAccount(c))}};let ix=dist_index_es_v},16614:function(c,l,et){"use strict";let eo=et(67116),es=et(58005),ec=et(34470),el=et(61820),isNullOrUndefined=c=>null==c,ed=Symbol("encodeFragmentIdentifier");function validateArrayFormatSeparator(c){if("string"!=typeof c||1!==c.length)throw TypeError("arrayFormatSeparator must be single character string")}function encode(c,l){return l.encode?l.strict?eo(c):encodeURIComponent(c):c}function decode(c,l){return l.decode?es(c):c}function removeHash(c){let l=c.indexOf("#");return -1!==l&&(c=c.slice(0,l)),c}function extract(c){c=removeHash(c);let l=c.indexOf("?");return -1===l?"":c.slice(l+1)}function parseValue(c,l){return l.parseNumbers&&!Number.isNaN(Number(c))&&"string"==typeof c&&""!==c.trim()?c=Number(c):l.parseBooleans&&null!==c&&("true"===c.toLowerCase()||"false"===c.toLowerCase())&&(c="true"===c.toLowerCase()),c}function parse(c,l){validateArrayFormatSeparator((l=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},l)).arrayFormatSeparator);let et=function(c){let l;switch(c.arrayFormat){case"index":return(c,et,eo)=>{if(l=/\[(\d*)\]$/.exec(c),c=c.replace(/\[\d*\]$/,""),!l){eo[c]=et;return}void 0===eo[c]&&(eo[c]={}),eo[c][l[1]]=et};case"bracket":return(c,et,eo)=>{if(l=/(\[\])$/.exec(c),c=c.replace(/\[\]$/,""),!l){eo[c]=et;return}if(void 0===eo[c]){eo[c]=[et];return}eo[c]=[].concat(eo[c],et)};case"colon-list-separator":return(c,et,eo)=>{if(l=/(:list)$/.exec(c),c=c.replace(/:list$/,""),!l){eo[c]=et;return}if(void 0===eo[c]){eo[c]=[et];return}eo[c]=[].concat(eo[c],et)};case"comma":case"separator":return(l,et,eo)=>{let es="string"==typeof et&&et.includes(c.arrayFormatSeparator),ec="string"==typeof et&&!es&&decode(et,c).includes(c.arrayFormatSeparator);et=ec?decode(et,c):et;let el=es||ec?et.split(c.arrayFormatSeparator).map(l=>decode(l,c)):null===et?et:decode(et,c);eo[l]=el};case"bracket-separator":return(l,et,eo)=>{let es=/(\[\])$/.test(l);if(l=l.replace(/\[\]$/,""),!es){eo[l]=et?decode(et,c):et;return}let ec=null===et?[]:et.split(c.arrayFormatSeparator).map(l=>decode(l,c));if(void 0===eo[l]){eo[l]=ec;return}eo[l]=[].concat(eo[l],ec)};default:return(c,l,et)=>{if(void 0===et[c]){et[c]=l;return}et[c]=[].concat(et[c],l)}}}(l),eo=Object.create(null);if("string"!=typeof c||!(c=c.trim().replace(/^[?#&]/,"")))return eo;for(let es of c.split("&")){if(""===es)continue;let[c,el]=ec(l.decode?es.replace(/\+/g," "):es,"=");el=void 0===el?null:["comma","separator","bracket-separator"].includes(l.arrayFormat)?el:decode(el,l),et(decode(c,l),el,eo)}for(let c of Object.keys(eo)){let et=eo[c];if("object"==typeof et&&null!==et)for(let c of Object.keys(et))et[c]=parseValue(et[c],l);else eo[c]=parseValue(et,l)}return!1===l.sort?eo:(!0===l.sort?Object.keys(eo).sort():Object.keys(eo).sort(l.sort)).reduce((c,l)=>{let et=eo[l];return et&&"object"==typeof et&&!Array.isArray(et)?c[l]=function keysSorter(c){return Array.isArray(c)?c.sort():"object"==typeof c?keysSorter(Object.keys(c)).sort((c,l)=>Number(c)-Number(l)).map(l=>c[l]):c}(et):c[l]=et,c},Object.create(null))}l.extract=extract,l.parse=parse,l.stringify=(c,l)=>{if(!c)return"";validateArrayFormatSeparator((l=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},l)).arrayFormatSeparator);let shouldFilter=et=>l.skipNull&&isNullOrUndefined(c[et])||l.skipEmptyString&&""===c[et],et=function(c){switch(c.arrayFormat){case"index":return l=>(et,eo)=>{let es=et.length;return void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,[encode(l,c),"[",es,"]"].join("")]:[...et,[encode(l,c),"[",encode(es,c),"]=",encode(eo,c)].join("")]};case"bracket":return l=>(et,eo)=>void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,[encode(l,c),"[]"].join("")]:[...et,[encode(l,c),"[]=",encode(eo,c)].join("")];case"colon-list-separator":return l=>(et,eo)=>void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,[encode(l,c),":list="].join("")]:[...et,[encode(l,c),":list=",encode(eo,c)].join("")];case"comma":case"separator":case"bracket-separator":{let l="bracket-separator"===c.arrayFormat?"[]=":"=";return et=>(eo,es)=>void 0===es||c.skipNull&&null===es||c.skipEmptyString&&""===es?eo:(es=null===es?"":es,0===eo.length)?[[encode(et,c),l,encode(es,c)].join("")]:[[eo,encode(es,c)].join(c.arrayFormatSeparator)]}default:return l=>(et,eo)=>void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,encode(l,c)]:[...et,[encode(l,c),"=",encode(eo,c)].join("")]}}(l),eo={};for(let l of Object.keys(c))shouldFilter(l)||(eo[l]=c[l]);let es=Object.keys(eo);return!1!==l.sort&&es.sort(l.sort),es.map(eo=>{let es=c[eo];return void 0===es?"":null===es?encode(eo,l):Array.isArray(es)?0===es.length&&"bracket-separator"===l.arrayFormat?encode(eo,l)+"[]":es.reduce(et(eo),[]).join("&"):encode(eo,l)+"="+encode(es,l)}).filter(c=>c.length>0).join("&")},l.parseUrl=(c,l)=>{l=Object.assign({decode:!0},l);let[et,eo]=ec(c,"#");return Object.assign({url:et.split("?")[0]||"",query:parse(extract(c),l)},l&&l.parseFragmentIdentifier&&eo?{fragmentIdentifier:decode(eo,l)}:{})},l.stringifyUrl=(c,et)=>{et=Object.assign({encode:!0,strict:!0,[ed]:!0},et);let eo=removeHash(c.url).split("?")[0]||"",es=l.extract(c.url),ec=l.parse(es,{sort:!1}),el=Object.assign(ec,c.query),eh=l.stringify(el,et);eh&&(eh=`?${eh}`);let ef=function(c){let l="",et=c.indexOf("#");return -1!==et&&(l=c.slice(et)),l}(c.url);return c.fragmentIdentifier&&(ef=`#${et[ed]?encode(c.fragmentIdentifier,et):c.fragmentIdentifier}`),`${eo}${eh}${ef}`},l.pick=(c,et,eo)=>{eo=Object.assign({parseFragmentIdentifier:!0,[ed]:!1},eo);let{url:es,query:ec,fragmentIdentifier:eh}=l.parseUrl(c,eo);return l.stringifyUrl({url:es,query:el(ec,et),fragmentIdentifier:eh},eo)},l.exclude=(c,et,eo)=>{let es=Array.isArray(et)?c=>!et.includes(c):(c,l)=>!et(c,l);return l.pick(c,es,eo)}},95097:function(c,l,et){"use strict";et.d(l,{q:function(){return IEvents}});let IEvents=class IEvents{}},13923:function(c,l,et){"use strict";et.r(l),et.d(l,{IEvents:function(){return eo.q}});var eo=et(95097)},3768:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.HEARTBEAT_EVENTS=l.HEARTBEAT_INTERVAL=void 0;let eo=et(58619);l.HEARTBEAT_INTERVAL=eo.FIVE_SECONDS,l.HEARTBEAT_EVENTS={pulse:"heartbeat_pulse"}},7051:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(42182);eo.__exportStar(et(3768),l)},74862:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.HeartBeat=void 0;let eo=et(42182),es=et(512),ec=et(58619),el=et(89219),ed=et(7051);let HeartBeat=class HeartBeat extends el.IHeartBeat{constructor(c){super(c),this.events=new es.EventEmitter,this.interval=ed.HEARTBEAT_INTERVAL,this.interval=(null==c?void 0:c.interval)||ed.HEARTBEAT_INTERVAL}static init(c){return eo.__awaiter(this,void 0,void 0,function*(){let l=new HeartBeat(c);return yield l.init(),l})}init(){return eo.__awaiter(this,void 0,void 0,function*(){yield this.initialize()})}stop(){clearInterval(this.intervalRef)}on(c,l){this.events.on(c,l)}once(c,l){this.events.once(c,l)}off(c,l){this.events.off(c,l)}removeListener(c,l){this.events.removeListener(c,l)}initialize(){return eo.__awaiter(this,void 0,void 0,function*(){this.intervalRef=setInterval(()=>this.pulse(),ec.toMiliseconds(this.interval))})}pulse(){this.events.emit(ed.HEARTBEAT_EVENTS.pulse)}};l.HeartBeat=HeartBeat},63943:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(42182);eo.__exportStar(et(74862),l),eo.__exportStar(et(89219),l),eo.__exportStar(et(7051),l)},74684:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.IHeartBeat=void 0;let eo=et(13923);let IHeartBeat=class IHeartBeat extends eo.IEvents{constructor(c){super()}};l.IHeartBeat=IHeartBeat},89219:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(42182);eo.__exportStar(et(74684),l)},42182:function(c,l,et){"use strict";et.r(l),et.d(l,{__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return __createBinding},__decorate:function(){return __decorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar},__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__read:function(){return __read},__rest:function(){return __rest},__spread:function(){return __spread},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */var extendStatics=function(c,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var et in l)l.hasOwnProperty(et)&&(c[et]=l[et])})(c,l)};function __extends(c,l){function __(){this.constructor=c}extendStatics(c,l),c.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(c){for(var l,et=1,eo=arguments.length;etl.indexOf(eo)&&(et[eo]=c[eo]);if(null!=c&&"function"==typeof Object.getOwnPropertySymbols)for(var es=0,eo=Object.getOwnPropertySymbols(c);esl.indexOf(eo[es])&&Object.prototype.propertyIsEnumerable.call(c,eo[es])&&(et[eo[es]]=c[eo[es]]);return et}function __decorate(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el}function __param(c,l){return function(et,eo){l(et,eo,c)}}function __metadata(c,l){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(c,l)}function __awaiter(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})}function __generator(c,l){var et,eo,es,ec,el={label:0,sent:function(){if(1&es[0])throw es[1];return es[1]},trys:[],ops:[]};return ec={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(ec[Symbol.iterator]=function(){return this}),ec;function verb(ec){return function(ed){return function(ec){if(et)throw TypeError("Generator is already executing.");for(;el;)try{if(et=1,eo&&(es=2&ec[0]?eo.return:ec[0]?eo.throw||((es=eo.return)&&es.call(eo),0):eo.next)&&!(es=es.call(eo,ec[1])).done)return es;switch(eo=0,es&&(ec=[2&ec[0],es.value]),ec[0]){case 0:case 1:es=ec;break;case 4:return el.label++,{value:ec[1],done:!1};case 5:el.label++,eo=ec[1],ec=[0];continue;case 7:ec=el.ops.pop(),el.trys.pop();continue;default:if(!(es=(es=el.trys).length>0&&es[es.length-1])&&(6===ec[0]||2===ec[0])){el=0;continue}if(3===ec[0]&&(!es||ec[1]>es[0]&&ec[1]=c.length&&(c=void 0),{value:c&&c[eo++],done:!c}}};throw TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(c,l){var et="function"==typeof Symbol&&c[Symbol.iterator];if(!et)return c;var eo,es,ec=et.call(c),el=[];try{for(;(void 0===l||l-- >0)&&!(eo=ec.next()).done;)el.push(eo.value)}catch(c){es={error:c}}finally{try{eo&&!eo.done&&(et=ec.return)&&et.call(ec)}finally{if(es)throw es.error}}return el}function __spread(){for(var c=[],l=0;l1||resume(c,l)})})}function resume(c,l){try{var et;(et=es[c](l)).value instanceof __await?Promise.resolve(et.value.v).then(fulfill,reject):settle(ec[0][2],et)}catch(c){settle(ec[0][3],c)}}function fulfill(c){resume("next",c)}function reject(c){resume("throw",c)}function settle(c,l){c(l),ec.shift(),ec.length&&resume(ec[0][0],ec[0][1])}}function __asyncDelegator(c){var l,et;return l={},verb("next"),verb("throw",function(c){throw c}),verb("return"),l[Symbol.iterator]=function(){return this},l;function verb(eo,es){l[eo]=c[eo]?function(l){return(et=!et)?{value:__await(c[eo](l)),done:"return"===eo}:es?es(l):l}:es}}function __asyncValues(c){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var l,et=c[Symbol.asyncIterator];return et?et.call(c):(c=__values(c),l={},verb("next"),verb("throw"),verb("return"),l[Symbol.asyncIterator]=function(){return this},l);function verb(et){l[et]=c[et]&&function(l){return new Promise(function(eo,es){!function(c,l,et,eo){Promise.resolve(eo).then(function(l){c({value:l,done:et})},l)}(eo,es,(l=c[et](l)).done,l.value)})}}}function __makeTemplateObject(c,l){return Object.defineProperty?Object.defineProperty(c,"raw",{value:l}):c.raw=l,c}function __importStar(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)Object.hasOwnProperty.call(c,et)&&(l[et]=c[et]);return l.default=c,l}function __importDefault(c){return c&&c.__esModule?c:{default:c}}function __classPrivateFieldGet(c,l){if(!l.has(c))throw TypeError("attempted to get private field on non-instance");return l.get(c)}function __classPrivateFieldSet(c,l,et){if(!l.has(c))throw TypeError("attempted to set private field on non-instance");return l.set(c,et),et}},1426:function(c,l,et){"use strict";let eo=et(89959),es=et(86050),ec=eo.__importDefault(et(48739)),el=et(35165);l.ZP=class{constructor(){this.localStorage=ec.default}getKeys(){return eo.__awaiter(this,void 0,void 0,function*(){return Object.keys(this.localStorage)})}getEntries(){return eo.__awaiter(this,void 0,void 0,function*(){return Object.entries(this.localStorage).map(el.parseEntry)})}getItem(c){return eo.__awaiter(this,void 0,void 0,function*(){let l=this.localStorage.getItem(c);if(null!==l)return es.safeJsonParse(l)})}setItem(c,l){return eo.__awaiter(this,void 0,void 0,function*(){this.localStorage.setItem(c,es.safeJsonStringify(l))})}removeItem(c){return eo.__awaiter(this,void 0,void 0,function*(){this.localStorage.removeItem(c)})}}},48739:function(c,l,et){"use strict";!function(){function LocalStorage(){}LocalStorage.prototype.getItem=function(c){return this.hasOwnProperty(c)?String(this[c]):null},LocalStorage.prototype.setItem=function(c,l){this[c]=String(l)},LocalStorage.prototype.removeItem=function(c){delete this[c]},LocalStorage.prototype.clear=function(){let c=this;Object.keys(c).forEach(function(l){c[l]=void 0,delete c[l]})},LocalStorage.prototype.key=function(c){return c=c||0,Object.keys(this)[c]},LocalStorage.prototype.__defineGetter__("length",function(){return Object.keys(this).length}),void 0!==et.g&&et.g.localStorage?c.exports=et.g.localStorage:"undefined"!=typeof window&&window.localStorage?c.exports=window.localStorage:c.exports=new LocalStorage}()},35165:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(89959);eo.__exportStar(et(52387),l),eo.__exportStar(et(20217),l)},52387:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.IKeyValueStorage=void 0,l.IKeyValueStorage=class{}},20217:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.parseEntry=void 0;let eo=et(86050);l.parseEntry=function(c){var l;return[c[0],eo.safeJsonParse(null!==(l=c[1])&&void 0!==l?l:"")]}},89959:function(c,l,et){"use strict";et.r(l),et.d(l,{__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return __createBinding},__decorate:function(){return __decorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar},__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__read:function(){return __read},__rest:function(){return __rest},__spread:function(){return __spread},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */var extendStatics=function(c,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var et in l)l.hasOwnProperty(et)&&(c[et]=l[et])})(c,l)};function __extends(c,l){function __(){this.constructor=c}extendStatics(c,l),c.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(c){for(var l,et=1,eo=arguments.length;etl.indexOf(eo)&&(et[eo]=c[eo]);if(null!=c&&"function"==typeof Object.getOwnPropertySymbols)for(var es=0,eo=Object.getOwnPropertySymbols(c);esl.indexOf(eo[es])&&Object.prototype.propertyIsEnumerable.call(c,eo[es])&&(et[eo[es]]=c[eo[es]]);return et}function __decorate(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el}function __param(c,l){return function(et,eo){l(et,eo,c)}}function __metadata(c,l){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(c,l)}function __awaiter(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})}function __generator(c,l){var et,eo,es,ec,el={label:0,sent:function(){if(1&es[0])throw es[1];return es[1]},trys:[],ops:[]};return ec={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(ec[Symbol.iterator]=function(){return this}),ec;function verb(ec){return function(ed){return function(ec){if(et)throw TypeError("Generator is already executing.");for(;el;)try{if(et=1,eo&&(es=2&ec[0]?eo.return:ec[0]?eo.throw||((es=eo.return)&&es.call(eo),0):eo.next)&&!(es=es.call(eo,ec[1])).done)return es;switch(eo=0,es&&(ec=[2&ec[0],es.value]),ec[0]){case 0:case 1:es=ec;break;case 4:return el.label++,{value:ec[1],done:!1};case 5:el.label++,eo=ec[1],ec=[0];continue;case 7:ec=el.ops.pop(),el.trys.pop();continue;default:if(!(es=(es=el.trys).length>0&&es[es.length-1])&&(6===ec[0]||2===ec[0])){el=0;continue}if(3===ec[0]&&(!es||ec[1]>es[0]&&ec[1]=c.length&&(c=void 0),{value:c&&c[eo++],done:!c}}};throw TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(c,l){var et="function"==typeof Symbol&&c[Symbol.iterator];if(!et)return c;var eo,es,ec=et.call(c),el=[];try{for(;(void 0===l||l-- >0)&&!(eo=ec.next()).done;)el.push(eo.value)}catch(c){es={error:c}}finally{try{eo&&!eo.done&&(et=ec.return)&&et.call(ec)}finally{if(es)throw es.error}}return el}function __spread(){for(var c=[],l=0;l1||resume(c,l)})})}function resume(c,l){try{var et;(et=es[c](l)).value instanceof __await?Promise.resolve(et.value.v).then(fulfill,reject):settle(ec[0][2],et)}catch(c){settle(ec[0][3],c)}}function fulfill(c){resume("next",c)}function reject(c){resume("throw",c)}function settle(c,l){c(l),ec.shift(),ec.length&&resume(ec[0][0],ec[0][1])}}function __asyncDelegator(c){var l,et;return l={},verb("next"),verb("throw",function(c){throw c}),verb("return"),l[Symbol.iterator]=function(){return this},l;function verb(eo,es){l[eo]=c[eo]?function(l){return(et=!et)?{value:__await(c[eo](l)),done:"return"===eo}:es?es(l):l}:es}}function __asyncValues(c){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var l,et=c[Symbol.asyncIterator];return et?et.call(c):(c=__values(c),l={},verb("next"),verb("throw"),verb("return"),l[Symbol.asyncIterator]=function(){return this},l);function verb(et){l[et]=c[et]&&function(l){return new Promise(function(eo,es){!function(c,l,et,eo){Promise.resolve(eo).then(function(l){c({value:l,done:et})},l)}(eo,es,(l=c[et](l)).done,l.value)})}}}function __makeTemplateObject(c,l){return Object.defineProperty?Object.defineProperty(c,"raw",{value:l}):c.raw=l,c}function __importStar(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)Object.hasOwnProperty.call(c,et)&&(l[et]=c[et]);return l.default=c,l}function __importDefault(c){return c&&c.__esModule?c:{default:c}}function __classPrivateFieldGet(c,l){if(!l.has(c))throw TypeError("attempted to get private field on non-instance");return l.get(c)}function __classPrivateFieldSet(c,l,et){if(!l.has(c))throw TypeError("attempted to set private field on non-instance");return l.set(c,et),et}},76159:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.PINO_CUSTOM_CONTEXT_KEY=l.PINO_LOGGER_DEFAULTS=void 0,l.PINO_LOGGER_DEFAULTS={level:"info"},l.PINO_CUSTOM_CONTEXT_KEY="custom_context"},72058:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.pino=void 0;let eo=et(60907),es=eo.__importDefault(et(90440));Object.defineProperty(l,"pino",{enumerable:!0,get:function(){return es.default}}),eo.__exportStar(et(76159),l),eo.__exportStar(et(8218),l)},8218:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.generateChildLogger=l.formatChildLoggerContext=l.getLoggerContext=l.setBrowserLoggerContext=l.getBrowserLoggerContext=l.getDefaultLoggerOptions=void 0;let eo=et(76159);function getBrowserLoggerContext(c,l=eo.PINO_CUSTOM_CONTEXT_KEY){return c[l]||""}function setBrowserLoggerContext(c,l,et=eo.PINO_CUSTOM_CONTEXT_KEY){return c[et]=l,c}function getLoggerContext(c,l=eo.PINO_CUSTOM_CONTEXT_KEY){return void 0===c.bindings?getBrowserLoggerContext(c,l):c.bindings().context||""}function formatChildLoggerContext(c,l,et=eo.PINO_CUSTOM_CONTEXT_KEY){let es=getLoggerContext(c,et),ec=es.trim()?`${es}/${l}`:l;return ec}l.getDefaultLoggerOptions=function(c){return Object.assign(Object.assign({},c),{level:(null==c?void 0:c.level)||eo.PINO_LOGGER_DEFAULTS.level})},l.getBrowserLoggerContext=getBrowserLoggerContext,l.setBrowserLoggerContext=setBrowserLoggerContext,l.getLoggerContext=getLoggerContext,l.formatChildLoggerContext=formatChildLoggerContext,l.generateChildLogger=function(c,l,et=eo.PINO_CUSTOM_CONTEXT_KEY){let es=formatChildLoggerContext(c,l,et),ec=c.child({context:es});return setBrowserLoggerContext(ec,es,et)}},60907:function(c,l,et){"use strict";et.r(l),et.d(l,{__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return __createBinding},__decorate:function(){return __decorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar},__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__read:function(){return __read},__rest:function(){return __rest},__spread:function(){return __spread},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */var extendStatics=function(c,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var et in l)l.hasOwnProperty(et)&&(c[et]=l[et])})(c,l)};function __extends(c,l){function __(){this.constructor=c}extendStatics(c,l),c.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(c){for(var l,et=1,eo=arguments.length;etl.indexOf(eo)&&(et[eo]=c[eo]);if(null!=c&&"function"==typeof Object.getOwnPropertySymbols)for(var es=0,eo=Object.getOwnPropertySymbols(c);esl.indexOf(eo[es])&&Object.prototype.propertyIsEnumerable.call(c,eo[es])&&(et[eo[es]]=c[eo[es]]);return et}function __decorate(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el}function __param(c,l){return function(et,eo){l(et,eo,c)}}function __metadata(c,l){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(c,l)}function __awaiter(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})}function __generator(c,l){var et,eo,es,ec,el={label:0,sent:function(){if(1&es[0])throw es[1];return es[1]},trys:[],ops:[]};return ec={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(ec[Symbol.iterator]=function(){return this}),ec;function verb(ec){return function(ed){return function(ec){if(et)throw TypeError("Generator is already executing.");for(;el;)try{if(et=1,eo&&(es=2&ec[0]?eo.return:ec[0]?eo.throw||((es=eo.return)&&es.call(eo),0):eo.next)&&!(es=es.call(eo,ec[1])).done)return es;switch(eo=0,es&&(ec=[2&ec[0],es.value]),ec[0]){case 0:case 1:es=ec;break;case 4:return el.label++,{value:ec[1],done:!1};case 5:el.label++,eo=ec[1],ec=[0];continue;case 7:ec=el.ops.pop(),el.trys.pop();continue;default:if(!(es=(es=el.trys).length>0&&es[es.length-1])&&(6===ec[0]||2===ec[0])){el=0;continue}if(3===ec[0]&&(!es||ec[1]>es[0]&&ec[1]=c.length&&(c=void 0),{value:c&&c[eo++],done:!c}}};throw TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(c,l){var et="function"==typeof Symbol&&c[Symbol.iterator];if(!et)return c;var eo,es,ec=et.call(c),el=[];try{for(;(void 0===l||l-- >0)&&!(eo=ec.next()).done;)el.push(eo.value)}catch(c){es={error:c}}finally{try{eo&&!eo.done&&(et=ec.return)&&et.call(ec)}finally{if(es)throw es.error}}return el}function __spread(){for(var c=[],l=0;l1||resume(c,l)})})}function resume(c,l){try{var et;(et=es[c](l)).value instanceof __await?Promise.resolve(et.value.v).then(fulfill,reject):settle(ec[0][2],et)}catch(c){settle(ec[0][3],c)}}function fulfill(c){resume("next",c)}function reject(c){resume("throw",c)}function settle(c,l){c(l),ec.shift(),ec.length&&resume(ec[0][0],ec[0][1])}}function __asyncDelegator(c){var l,et;return l={},verb("next"),verb("throw",function(c){throw c}),verb("return"),l[Symbol.iterator]=function(){return this},l;function verb(eo,es){l[eo]=c[eo]?function(l){return(et=!et)?{value:__await(c[eo](l)),done:"return"===eo}:es?es(l):l}:es}}function __asyncValues(c){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var l,et=c[Symbol.asyncIterator];return et?et.call(c):(c=__values(c),l={},verb("next"),verb("throw"),verb("return"),l[Symbol.asyncIterator]=function(){return this},l);function verb(et){l[et]=c[et]&&function(l){return new Promise(function(eo,es){!function(c,l,et,eo){Promise.resolve(eo).then(function(l){c({value:l,done:et})},l)}(eo,es,(l=c[et](l)).done,l.value)})}}}function __makeTemplateObject(c,l){return Object.defineProperty?Object.defineProperty(c,"raw",{value:l}):c.raw=l,c}function __importStar(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)Object.hasOwnProperty.call(c,et)&&(l[et]=c[et]);return l.default=c,l}function __importDefault(c){return c&&c.__esModule?c:{default:c}}function __classPrivateFieldGet(c,l){if(!l.has(c))throw TypeError("attempted to get private field on non-instance");return l.get(c)}function __classPrivateFieldSet(c,l,et){if(!l.has(c))throw TypeError("attempted to set private field on non-instance");return l.set(c,et),et}},61986:function(c,l,et){var eo=et(25566);function _interopDefault(c){return c&&"object"==typeof c&&"default"in c?c.default:c}var es=et(90294),ec=_interopDefault(et(13928)),el=_interopDefault(et(2390)),ed=et(44096);"undefined"!=typeof Symbol&&(Symbol.iterator||(Symbol.iterator=Symbol("Symbol.iterator"))),"undefined"!=typeof Symbol&&(Symbol.asyncIterator||(Symbol.asyncIterator=Symbol("Symbol.asyncIterator")));var eh="walletconnect-wrapper",ef="walletconnect-style-sheet",ep="walletconnect-qrcode-modal",eg="walletconnect-qrcode-text";function Header(c){return ed.createElement("div",{className:"walletconnect-modal__header"},ed.createElement("img",{src:"data:image/svg+xml,%3Csvg height='185' viewBox='0 0 300 185' width='300' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='m61.4385429 36.2562612c48.9112241-47.8881663 128.2119871-47.8881663 177.1232091 0l5.886545 5.7634174c2.445561 2.3944081 2.445561 6.2765112 0 8.6709204l-20.136695 19.715503c-1.222781 1.1972051-3.2053 1.1972051-4.428081 0l-8.100584-7.9311479c-34.121692-33.4079817-89.443886-33.4079817-123.5655788 0l-8.6750562 8.4936051c-1.2227816 1.1972041-3.205301 1.1972041-4.4280806 0l-20.1366949-19.7155031c-2.4455612-2.3944092-2.4455612-6.2765122 0-8.6709204zm218.7677961 40.7737449 17.921697 17.546897c2.445549 2.3943969 2.445563 6.2764769.000031 8.6708899l-80.810171 79.121134c-2.445544 2.394426-6.410582 2.394453-8.85616.000062-.00001-.00001-.000022-.000022-.000032-.000032l-57.354143-56.154572c-.61139-.598602-1.60265-.598602-2.21404 0-.000004.000004-.000007.000008-.000011.000011l-57.3529212 56.154531c-2.4455368 2.394432-6.4105755 2.394472-8.8561612.000087-.0000143-.000014-.0000296-.000028-.0000449-.000044l-80.81241943-79.122185c-2.44556021-2.394408-2.44556021-6.2765115 0-8.6709197l17.92172963-17.5468673c2.4455602-2.3944082 6.4105989-2.3944082 8.8561602 0l57.3549775 56.155357c.6113908.598602 1.602649.598602 2.2140398 0 .0000092-.000009.0000174-.000017.0000265-.000024l57.3521031-56.155333c2.445505-2.3944633 6.410544-2.3945531 8.856161-.0002.000034.0000336.000068.0000673.000101.000101l57.354902 56.155432c.61139.598601 1.60265.598601 2.21404 0l57.353975-56.1543249c2.445561-2.3944092 6.410599-2.3944092 8.85616 0z' fill='%233b99fc'/%3E%3C/svg%3E",className:"walletconnect-modal__headerLogo"}),ed.createElement("p",null,"WalletConnect"),ed.createElement("div",{className:"walletconnect-modal__close__wrapper",onClick:c.onClose},ed.createElement("div",{id:"walletconnect-qrcode-close",className:"walletconnect-modal__close__icon"},ed.createElement("div",{className:"walletconnect-modal__close__line1"}),ed.createElement("div",{className:"walletconnect-modal__close__line2"}))))}function ConnectButton(c){return ed.createElement("a",{className:"walletconnect-connect__button",href:c.href,id:"walletconnect-connect-button-"+c.name,onClick:c.onClick,rel:"noopener noreferrer",style:{backgroundColor:c.color},target:"_blank"},c.name)}function WalletButton(c){var l=c.color,et=c.href,eo=c.name,es=c.logo,ec=c.onClick;return ed.createElement("a",{className:"walletconnect-modal__base__row",href:et,onClick:ec,rel:"noopener noreferrer",target:"_blank"},ed.createElement("h3",{className:"walletconnect-modal__base__row__h3"},eo),ed.createElement("div",{className:"walletconnect-modal__base__row__right"},ed.createElement("div",{className:"walletconnect-modal__base__row__right__app-icon",style:{background:"url('"+es+"') "+l,backgroundSize:"100%"}}),ed.createElement("img",{src:"data:image/svg+xml,%3Csvg fill='none' height='18' viewBox='0 0 8 18' width='8' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath clip-rule='evenodd' d='m.586301.213898c-.435947.33907-.5144813.967342-.175411 1.403292l4.87831 6.27212c.28087.36111.28087.86677 0 1.22788l-4.878311 6.27211c-.33907.436-.260536 1.0642.175412 1.4033.435949.3391 1.064219.2605 1.403289-.1754l4.87832-6.2721c.84259-1.08336.84259-2.60034 0-3.68367l-4.87832-6.27212c-.33907-.4359474-.96734-.514482-1.403289-.175412z' fill='%233c4252' fill-rule='evenodd'/%3E%3C/svg%3E",className:"walletconnect-modal__base__row__right__caret"})))}function WalletIcon(c){var l=c.color,et=c.href,eo=c.name,es=c.logo,ec=c.onClick,el=window.innerWidth<768?(eo.length>8?2.5:2.7)+"vw":"inherit";return ed.createElement("a",{className:"walletconnect-connect__button__icon_anchor",href:et,onClick:ec,rel:"noopener noreferrer",target:"_blank"},ed.createElement("div",{className:"walletconnect-connect__button__icon",style:{background:"url('"+es+"') "+l,backgroundSize:"100%"}}),ed.createElement("div",{style:{fontSize:el},className:"walletconnect-connect__button__text"},eo))}function LinkDisplay(c){var l=es.isAndroid(),et=ed.useState(""),eo=et[0],ec=et[1],el=ed.useState(""),eh=el[0],ef=el[1],ep=ed.useState(1),em=ep[0],eb=ep[1],ey=eh?c.links.filter(function(c){return c.name.toLowerCase().includes(eh.toLowerCase())}):c.links,e_=c.errorMessage,ew=eh||ey.length>5,eE=Math.ceil(ey.length/12),eS=[(em-1)*12+1,12*em],ex=ey.length?ey.filter(function(c,l){return l+1>=eS[0]&&l+1<=eS[1]}):[],ek=!!(!l&&eE>1),eC=void 0;return ed.createElement("div",null,ed.createElement("p",{id:eg,className:"walletconnect-qrcode__text"},l?c.text.connect_mobile_wallet:c.text.choose_preferred_wallet),!l&&ed.createElement("input",{className:"walletconnect-search__input",placeholder:"Search",value:eo,onChange:function(c){ec(c.target.value),clearTimeout(eC),c.target.value?eC=setTimeout(function(){ef(c.target.value),eb(1)},1e3):(ec(""),ef(""),eb(1))}}),ed.createElement("div",{className:"walletconnect-connect__buttons__wrapper"+(l?"__android":ew&&ey.length?"__wrap":"")},l?ed.createElement(ConnectButton,{name:c.text.connect,color:"rgb(64, 153, 255)",href:c.uri,onClick:ed.useCallback(function(){es.saveMobileLinkInfo({name:"Unknown",href:c.uri})},[])}):ex.length?ex.map(function(l){var et=l.color,eo=l.name,ec=l.shortName,el=l.logo,eh=es.formatIOSMobile(c.uri,l),ef=ed.useCallback(function(){es.saveMobileLinkInfo({name:eo,href:eh})},[ex]);return ew?ed.createElement(WalletIcon,{color:et,href:eh,name:ec||eo,logo:el,onClick:ef}):ed.createElement(WalletButton,{color:et,href:eh,name:eo,logo:el,onClick:ef})}):ed.createElement(ed.Fragment,null,ed.createElement("p",null,e_.length?c.errorMessage:c.links.length&&!ey.length?c.text.no_wallets_found:c.text.loading))),ek&&ed.createElement("div",{className:"walletconnect-modal__footer"},Array(eE).fill(0).map(function(c,l){var et=l+1,eo=em===et;return ed.createElement("a",{style:{margin:"auto 10px",fontWeight:eo?"bold":"normal"},onClick:function(){return eb(et)}},et)})))}function Notification(c){var l=!!c.message.trim();return ed.createElement("div",{className:"walletconnect-qrcode__notification"+(l?" notification__show":"")},c.message)}var formatQRCodeImage=function(c){try{var l="";return Promise.resolve(ec.toString(c,{margin:0,type:"svg"})).then(function(c){return"string"==typeof c&&(l=c.replace("0||ed.useEffect(function(){!function(){try{if(l)return Promise.resolve();eh(!0);var ec=function(c,l){try{var et=c()}catch(c){return l(c)}return et&&et.then?et.then(void 0,l):et}(function(){var l=c.qrcodeModalOptions&&c.qrcodeModalOptions.registryUrl?c.qrcodeModalOptions.registryUrl:es.getWalletRegistryUrl();return Promise.resolve(fetch(l)).then(function(l){return Promise.resolve(l.json()).then(function(l){var ec=l.listings,el=et?"mobile":"desktop",ed=es.getMobileLinkRegistry(es.formatMobileRegistry(ec,el),eo);eh(!1),em(!0),eN(ed.length?"":c.text.no_supported_wallets),eR(ed);var ef=1===ed.length;ef&&(ex(es.formatIOSMobile(c.uri,ed[0])),e_(!0)),eA(ef)})})},function(l){eh(!1),em(!0),eN(c.text.something_went_wrong),console.error(l)});Promise.resolve(ec&&ec.then?ec.then(function(){}):void 0)}catch(c){return Promise.reject(c)}}()})};getLinksIfNeeded();var eM=et?ey:!ey;return ed.createElement("div",{id:ep,className:"walletconnect-qrcode__base animated fadeIn"},ed.createElement("div",{className:"walletconnect-modal__base"},ed.createElement(Header,{onClose:c.onClose}),eC&&ey?ed.createElement("div",{className:"walletconnect-modal__single_wallet"},ed.createElement("a",{onClick:function(){return es.saveMobileLinkInfo({name:eP[0].name,href:eS})},href:eS,rel:"noopener noreferrer",target:"_blank"},c.text.connect_with+" "+(eC?eP[0].name:"")+" ›")):l||el||!el&&eP.length?ed.createElement("div",{className:"walletconnect-modal__mobile__toggle"+(eM?" right__selected":"")},ed.createElement("div",{className:"walletconnect-modal__mobile__toggle_selector"}),et?ed.createElement(ed.Fragment,null,ed.createElement("a",{onClick:function(){return e_(!1),getLinksIfNeeded()}},c.text.mobile),ed.createElement("a",{onClick:function(){return e_(!0)}},c.text.qrcode)):ed.createElement(ed.Fragment,null,ed.createElement("a",{onClick:function(){return e_(!0)}},c.text.qrcode),ed.createElement("a",{onClick:function(){return e_(!1),getLinksIfNeeded()}},c.text.desktop))):null,ed.createElement("div",null,!ey&&(l||el||eP.length)?ed.createElement(LinkDisplay,Object.assign({},ew,{links:eP,errorMessage:eT})):ed.createElement(QRCodeDisplay,Object.assign({},ew)))))}var em={de:{choose_preferred_wallet:"W\xe4hle bevorzugte Wallet",connect_mobile_wallet:"Verbinde mit Mobile Wallet",scan_qrcode_with_wallet:"Scanne den QR-code mit einer WalletConnect kompatiblen Wallet",connect:"Verbinden",qrcode:"QR-Code",mobile:"Mobile",desktop:"Desktop",copy_to_clipboard:"In die Zwischenablage kopieren",copied_to_clipboard:"In die Zwischenablage kopiert!",connect_with:"Verbinden mit Hilfe von",loading:"Laden...",something_went_wrong:"Etwas ist schief gelaufen",no_supported_wallets:"Es gibt noch keine unterst\xfctzten Wallet",no_wallets_found:"keine Wallet gefunden"},en:{choose_preferred_wallet:"Choose your preferred wallet",connect_mobile_wallet:"Connect to Mobile Wallet",scan_qrcode_with_wallet:"Scan QR code with a WalletConnect-compatible wallet",connect:"Connect",qrcode:"QR Code",mobile:"Mobile",desktop:"Desktop",copy_to_clipboard:"Copy to clipboard",copied_to_clipboard:"Copied to clipboard!",connect_with:"Connect with",loading:"Loading...",something_went_wrong:"Something went wrong",no_supported_wallets:"There are no supported wallets yet",no_wallets_found:"No wallets found"},es:{choose_preferred_wallet:"Elige tu billetera preferida",connect_mobile_wallet:"Conectar a billetera m\xf3vil",scan_qrcode_with_wallet:"Escanea el c\xf3digo QR con una billetera compatible con WalletConnect",connect:"Conectar",qrcode:"C\xf3digo QR",mobile:"M\xf3vil",desktop:"Desktop",copy_to_clipboard:"Copiar",copied_to_clipboard:"Copiado!",connect_with:"Conectar mediante",loading:"Cargando...",something_went_wrong:"Algo sali\xf3 mal",no_supported_wallets:"Todav\xeda no hay billeteras compatibles",no_wallets_found:"No se encontraron billeteras"},fr:{choose_preferred_wallet:"Choisissez votre portefeuille pr\xe9f\xe9r\xe9",connect_mobile_wallet:"Se connecter au portefeuille mobile",scan_qrcode_with_wallet:"Scannez le QR code avec un portefeuille compatible WalletConnect",connect:"Se connecter",qrcode:"QR Code",mobile:"Mobile",desktop:"Desktop",copy_to_clipboard:"Copier",copied_to_clipboard:"Copi\xe9!",connect_with:"Connectez-vous \xe0 l'aide de",loading:"Chargement...",something_went_wrong:"Quelque chose a mal tourn\xe9",no_supported_wallets:"Il n'y a pas encore de portefeuilles pris en charge",no_wallets_found:"Aucun portefeuille trouv\xe9"},ko:{choose_preferred_wallet:"원하는 지갑을 선택하세요",connect_mobile_wallet:"모바일 지갑과 연결",scan_qrcode_with_wallet:"WalletConnect 지원 지갑에서 QR코드를 스캔하세요",connect:"연결",qrcode:"QR 코드",mobile:"모바일",desktop:"데스크탑",copy_to_clipboard:"클립보드에 복사",copied_to_clipboard:"클립보드에 복사되었습니다!",connect_with:"와 연결하다",loading:"로드 중...",something_went_wrong:"문제가 발생했습니다.",no_supported_wallets:"아직 지원되는 지갑이 없습니다",no_wallets_found:"지갑을 찾을 수 없습니다"},pt:{choose_preferred_wallet:"Escolha sua carteira preferida",connect_mobile_wallet:"Conectar-se \xe0 carteira m\xf3vel",scan_qrcode_with_wallet:"Ler o c\xf3digo QR com uma carteira compat\xedvel com WalletConnect",connect:"Conectar",qrcode:"C\xf3digo QR",mobile:"M\xf3vel",desktop:"Desktop",copy_to_clipboard:"Copiar",copied_to_clipboard:"Copiado!",connect_with:"Ligar por meio de",loading:"Carregamento...",something_went_wrong:"Algo correu mal",no_supported_wallets:"Ainda n\xe3o h\xe1 carteiras suportadas",no_wallets_found:"Nenhuma carteira encontrada"},zh:{choose_preferred_wallet:"选择你的钱包",connect_mobile_wallet:"连接至移动端钱包",scan_qrcode_with_wallet:"使用兼容 WalletConnect 的钱包扫描二维码",connect:"连接",qrcode:"二维码",mobile:"移动",desktop:"桌面",copy_to_clipboard:"复制到剪贴板",copied_to_clipboard:"复制到剪贴板成功!",connect_with:"通过以下方式连接",loading:"正在加载...",something_went_wrong:"出了问题",no_supported_wallets:"目前还没有支持的钱包",no_wallets_found:"没有找到钱包"},fa:{choose_preferred_wallet:"کیف پول مورد نظر خود را انتخاب کنید",connect_mobile_wallet:"به کیف پول موبایل وصل شوید",scan_qrcode_with_wallet:"کد QR را با یک کیف پول سازگار با WalletConnect اسکن کنید",connect:"اتصال",qrcode:"کد QR",mobile:"سیار",desktop:"دسکتاپ",copy_to_clipboard:"کپی به کلیپ بورد",copied_to_clipboard:"در کلیپ بورد کپی شد!",connect_with:"ارتباط با",loading:"...بارگذاری",something_went_wrong:"مشکلی پیش آمد",no_supported_wallets:"هنوز هیچ کیف پول پشتیبانی شده ای وجود ندارد",no_wallets_found:"هیچ کیف پولی پیدا نشد"}};function triggerCloseAnimation(){var c=es.getDocumentOrThrow(),l=c.getElementById(ep);l&&(l.className=l.className.replace("fadeIn","fadeOut"),setTimeout(function(){var l=c.getElementById(eh);l&&c.body.removeChild(l)},300))}var isNode=function(){return void 0!==eo&&void 0!==eo.versions&&void 0!==eo.versions.node};c.exports={open:function(c,l,et){if(console.log(c),isNode())!function(c){ec.toString(c,{type:"terminal"}).then(console.log)}(c);else{var eo,el,ep,eg,eb;(el=(eo=es.getDocumentOrThrow()).getElementById(ef))&&eo.head.removeChild(el),(ep=eo.createElement("style")).setAttribute("id",ef),ep.innerText=':root {\n --animation-duration: 300ms;\n}\n\n@keyframes fadeIn {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n\n@keyframes fadeOut {\n from {\n opacity: 1;\n }\n to {\n opacity: 0;\n }\n}\n\n.animated {\n animation-duration: var(--animation-duration);\n animation-fill-mode: both;\n}\n\n.fadeIn {\n animation-name: fadeIn;\n}\n\n.fadeOut {\n animation-name: fadeOut;\n}\n\n#walletconnect-wrapper {\n -webkit-user-select: none;\n align-items: center;\n display: flex;\n height: 100%;\n justify-content: center;\n left: 0;\n pointer-events: none;\n position: fixed;\n top: 0;\n user-select: none;\n width: 100%;\n z-index: 99999999999999;\n}\n\n.walletconnect-modal__headerLogo {\n height: 21px;\n}\n\n.walletconnect-modal__header p {\n color: #ffffff;\n font-size: 20px;\n font-weight: 600;\n margin: 0;\n align-items: flex-start;\n display: flex;\n flex: 1;\n margin-left: 5px;\n}\n\n.walletconnect-modal__close__wrapper {\n position: absolute;\n top: 0px;\n right: 0px;\n z-index: 10000;\n background: white;\n border-radius: 26px;\n padding: 6px;\n box-sizing: border-box;\n width: 26px;\n height: 26px;\n cursor: pointer;\n}\n\n.walletconnect-modal__close__icon {\n position: relative;\n top: 7px;\n right: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n transform: rotate(45deg);\n}\n\n.walletconnect-modal__close__line1 {\n position: absolute;\n width: 100%;\n border: 1px solid rgb(48, 52, 59);\n}\n\n.walletconnect-modal__close__line2 {\n position: absolute;\n width: 100%;\n border: 1px solid rgb(48, 52, 59);\n transform: rotate(90deg);\n}\n\n.walletconnect-qrcode__base {\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n background: rgba(37, 41, 46, 0.95);\n height: 100%;\n left: 0;\n pointer-events: auto;\n position: fixed;\n top: 0;\n transition: 0.4s cubic-bezier(0.19, 1, 0.22, 1);\n width: 100%;\n will-change: opacity;\n padding: 40px;\n box-sizing: border-box;\n}\n\n.walletconnect-qrcode__text {\n color: rgba(60, 66, 82, 0.6);\n font-size: 16px;\n font-weight: 600;\n letter-spacing: 0;\n line-height: 1.1875em;\n margin: 10px 0 20px 0;\n text-align: center;\n width: 100%;\n}\n\n@media only screen and (max-width: 768px) {\n .walletconnect-qrcode__text {\n font-size: 4vw;\n }\n}\n\n@media only screen and (max-width: 320px) {\n .walletconnect-qrcode__text {\n font-size: 14px;\n }\n}\n\n.walletconnect-qrcode__image {\n width: calc(100% - 30px);\n box-sizing: border-box;\n cursor: none;\n margin: 0 auto;\n}\n\n.walletconnect-qrcode__notification {\n position: absolute;\n bottom: 0;\n left: 0;\n right: 0;\n font-size: 16px;\n padding: 16px 20px;\n border-radius: 16px;\n text-align: center;\n transition: all 0.1s ease-in-out;\n background: white;\n color: black;\n margin-bottom: -60px;\n opacity: 0;\n}\n\n.walletconnect-qrcode__notification.notification__show {\n opacity: 1;\n}\n\n@media only screen and (max-width: 768px) {\n .walletconnect-modal__header {\n height: 130px;\n }\n .walletconnect-modal__base {\n overflow: auto;\n }\n}\n\n@media only screen and (min-device-width: 415px) and (max-width: 768px) {\n #content {\n max-width: 768px;\n box-sizing: border-box;\n }\n}\n\n@media only screen and (min-width: 375px) and (max-width: 415px) {\n #content {\n max-width: 414px;\n box-sizing: border-box;\n }\n}\n\n@media only screen and (min-width: 320px) and (max-width: 375px) {\n #content {\n max-width: 375px;\n box-sizing: border-box;\n }\n}\n\n@media only screen and (max-width: 320px) {\n #content {\n max-width: 320px;\n box-sizing: border-box;\n }\n}\n\n.walletconnect-modal__base {\n -webkit-font-smoothing: antialiased;\n background: #ffffff;\n border-radius: 24px;\n box-shadow: 0 10px 50px 5px rgba(0, 0, 0, 0.4);\n font-family: ui-rounded, "SF Pro Rounded", "SF Pro Text", medium-content-sans-serif-font,\n -apple-system, BlinkMacSystemFont, ui-sans-serif, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell,\n "Open Sans", "Helvetica Neue", sans-serif;\n margin-top: 41px;\n padding: 24px 24px 22px;\n pointer-events: auto;\n position: relative;\n text-align: center;\n transition: 0.4s cubic-bezier(0.19, 1, 0.22, 1);\n will-change: transform;\n overflow: visible;\n transform: translateY(-50%);\n top: 50%;\n max-width: 500px;\n margin: auto;\n}\n\n@media only screen and (max-width: 320px) {\n .walletconnect-modal__base {\n padding: 24px 12px;\n }\n}\n\n.walletconnect-modal__base .hidden {\n transform: translateY(150%);\n transition: 0.125s cubic-bezier(0.4, 0, 1, 1);\n}\n\n.walletconnect-modal__header {\n align-items: center;\n display: flex;\n height: 26px;\n left: 0;\n justify-content: space-between;\n position: absolute;\n top: -42px;\n width: 100%;\n}\n\n.walletconnect-modal__base .wc-logo {\n align-items: center;\n display: flex;\n height: 26px;\n margin-top: 15px;\n padding-bottom: 15px;\n pointer-events: auto;\n}\n\n.walletconnect-modal__base .wc-logo div {\n background-color: #3399ff;\n height: 21px;\n margin-right: 5px;\n mask-image: url("images/wc-logo.svg") center no-repeat;\n width: 32px;\n}\n\n.walletconnect-modal__base .wc-logo p {\n color: #ffffff;\n font-size: 20px;\n font-weight: 600;\n margin: 0;\n}\n\n.walletconnect-modal__base h2 {\n color: rgba(60, 66, 82, 0.6);\n font-size: 16px;\n font-weight: 600;\n letter-spacing: 0;\n line-height: 1.1875em;\n margin: 0 0 19px 0;\n text-align: center;\n width: 100%;\n}\n\n.walletconnect-modal__base__row {\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n align-items: center;\n border-radius: 20px;\n cursor: pointer;\n display: flex;\n height: 56px;\n justify-content: space-between;\n padding: 0 15px;\n position: relative;\n margin: 0px 0px 8px;\n text-align: left;\n transition: 0.15s cubic-bezier(0.25, 0.46, 0.45, 0.94);\n will-change: transform;\n text-decoration: none;\n}\n\n.walletconnect-modal__base__row:hover {\n background: rgba(60, 66, 82, 0.06);\n}\n\n.walletconnect-modal__base__row:active {\n background: rgba(60, 66, 82, 0.06);\n transform: scale(0.975);\n transition: 0.1s cubic-bezier(0.25, 0.46, 0.45, 0.94);\n}\n\n.walletconnect-modal__base__row__h3 {\n color: #25292e;\n font-size: 20px;\n font-weight: 700;\n margin: 0;\n padding-bottom: 3px;\n}\n\n.walletconnect-modal__base__row__right {\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.walletconnect-modal__base__row__right__app-icon {\n border-radius: 8px;\n height: 34px;\n margin: 0 11px 2px 0;\n width: 34px;\n background-size: 100%;\n box-shadow: 0 4px 12px 0 rgba(37, 41, 46, 0.25);\n}\n\n.walletconnect-modal__base__row__right__caret {\n height: 18px;\n opacity: 0.3;\n transition: 0.1s cubic-bezier(0.25, 0.46, 0.45, 0.94);\n width: 8px;\n will-change: opacity;\n}\n\n.walletconnect-modal__base__row:hover .caret,\n.walletconnect-modal__base__row:active .caret {\n opacity: 0.6;\n}\n\n.walletconnect-modal__mobile__toggle {\n width: 80%;\n display: flex;\n margin: 0 auto;\n position: relative;\n overflow: hidden;\n border-radius: 8px;\n margin-bottom: 18px;\n background: #d4d5d9;\n}\n\n.walletconnect-modal__single_wallet {\n display: flex;\n justify-content: center;\n margin-top: 7px;\n margin-bottom: 18px;\n}\n\n.walletconnect-modal__single_wallet a {\n cursor: pointer;\n color: rgb(64, 153, 255);\n font-size: 21px;\n font-weight: 800;\n text-decoration: none !important;\n margin: 0 auto;\n}\n\n.walletconnect-modal__mobile__toggle_selector {\n width: calc(50% - 8px);\n background: white;\n position: absolute;\n border-radius: 5px;\n height: calc(100% - 8px);\n top: 4px;\n transition: all 0.2s ease-in-out;\n transform: translate3d(4px, 0, 0);\n}\n\n.walletconnect-modal__mobile__toggle.right__selected .walletconnect-modal__mobile__toggle_selector {\n transform: translate3d(calc(100% + 12px), 0, 0);\n}\n\n.walletconnect-modal__mobile__toggle a {\n font-size: 12px;\n width: 50%;\n text-align: center;\n padding: 8px;\n margin: 0;\n font-weight: 600;\n z-index: 1;\n}\n\n.walletconnect-modal__footer {\n display: flex;\n justify-content: center;\n margin-top: 20px;\n}\n\n@media only screen and (max-width: 768px) {\n .walletconnect-modal__footer {\n margin-top: 5vw;\n }\n}\n\n.walletconnect-modal__footer a {\n cursor: pointer;\n color: #898d97;\n font-size: 15px;\n margin: 0 auto;\n}\n\n@media only screen and (max-width: 320px) {\n .walletconnect-modal__footer a {\n font-size: 14px;\n }\n}\n\n.walletconnect-connect__buttons__wrapper {\n max-height: 44vh;\n}\n\n.walletconnect-connect__buttons__wrapper__android {\n margin: 50% 0;\n}\n\n.walletconnect-connect__buttons__wrapper__wrap {\n display: grid;\n grid-template-columns: repeat(4, 1fr);\n margin: 10px 0;\n}\n\n@media only screen and (min-width: 768px) {\n .walletconnect-connect__buttons__wrapper__wrap {\n margin-top: 40px;\n }\n}\n\n.walletconnect-connect__button {\n background-color: rgb(64, 153, 255);\n padding: 12px;\n border-radius: 8px;\n text-decoration: none;\n color: rgb(255, 255, 255);\n font-weight: 500;\n}\n\n.walletconnect-connect__button__icon_anchor {\n cursor: pointer;\n display: flex;\n justify-content: flex-start;\n align-items: center;\n margin: 8px;\n width: 42px;\n justify-self: center;\n flex-direction: column;\n text-decoration: none !important;\n}\n\n@media only screen and (max-width: 320px) {\n .walletconnect-connect__button__icon_anchor {\n margin: 4px;\n }\n}\n\n.walletconnect-connect__button__icon {\n border-radius: 10px;\n height: 42px;\n margin: 0;\n width: 42px;\n background-size: cover !important;\n box-shadow: 0 4px 12px 0 rgba(37, 41, 46, 0.25);\n}\n\n.walletconnect-connect__button__text {\n color: #424952;\n font-size: 2.7vw;\n text-decoration: none !important;\n padding: 0;\n margin-top: 1.8vw;\n font-weight: 600;\n}\n\n@media only screen and (min-width: 768px) {\n .walletconnect-connect__button__text {\n font-size: 16px;\n margin-top: 12px;\n }\n}\n\n.walletconnect-search__input {\n border: none;\n background: #d4d5d9;\n border-style: none;\n padding: 8px 16px;\n outline: none;\n font-style: normal;\n font-stretch: normal;\n font-size: 16px;\n font-style: normal;\n font-stretch: normal;\n line-height: normal;\n letter-spacing: normal;\n text-align: left;\n border-radius: 8px;\n width: calc(100% - 16px);\n margin: 0;\n margin-bottom: 8px;\n}\n',eo.head.appendChild(ep),(eb=(eg=es.getDocumentOrThrow()).createElement("div")).setAttribute("id",eh),eg.body.appendChild(eb),ed.render(ed.createElement(Modal,{text:em[es.getNavigatorOrThrow().language.split("-")[0]||"en"]||em.en,uri:c,onClose:function(){triggerCloseAnimation(),l&&l()},qrcodeModalOptions:et}),eb)}},close:function(){isNode()||triggerCloseAnimation()}}},20235:function(c,l,et){"use strict";/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */var eo=et(34699),es=et(19087),ec="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function createBuffer(c){if(c>2147483647)throw RangeError('The value "'+c+'" is invalid for option "size"');var l=new Uint8Array(c);return Object.setPrototypeOf(l,Buffer.prototype),l}function Buffer(c,l,et){if("number"==typeof c){if("string"==typeof l)throw TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(c)}return from(c,l,et)}function from(c,l,et){if("string"==typeof c)return function(c,l){if(("string"!=typeof l||""===l)&&(l="utf8"),!Buffer.isEncoding(l))throw TypeError("Unknown encoding: "+l);var et=0|byteLength(c,l),eo=createBuffer(et),es=eo.write(c,l);return es!==et&&(eo=eo.slice(0,es)),eo}(c,l);if(ArrayBuffer.isView(c))return function(c){if(isInstance(c,Uint8Array)){var l=new Uint8Array(c);return fromArrayBuffer(l.buffer,l.byteOffset,l.byteLength)}return fromArrayLike(c)}(c);if(null==c)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof c);if(isInstance(c,ArrayBuffer)||c&&isInstance(c.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(isInstance(c,SharedArrayBuffer)||c&&isInstance(c.buffer,SharedArrayBuffer)))return fromArrayBuffer(c,l,et);if("number"==typeof c)throw TypeError('The "value" argument must not be of type number. Received type number');var eo=c.valueOf&&c.valueOf();if(null!=eo&&eo!==c)return Buffer.from(eo,l,et);var es=function(c){if(Buffer.isBuffer(c)){var l,et=0|checked(c.length),eo=createBuffer(et);return 0===eo.length||c.copy(eo,0,0,et),eo}return void 0!==c.length?"number"!=typeof c.length||(l=c.length)!=l?createBuffer(0):fromArrayLike(c):"Buffer"===c.type&&Array.isArray(c.data)?fromArrayLike(c.data):void 0}(c);if(es)return es;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof c[Symbol.toPrimitive])return Buffer.from(c[Symbol.toPrimitive]("string"),l,et);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof c)}function assertSize(c){if("number"!=typeof c)throw TypeError('"size" argument must be of type number');if(c<0)throw RangeError('The value "'+c+'" is invalid for option "size"')}function allocUnsafe(c){return assertSize(c),createBuffer(c<0?0:0|checked(c))}function fromArrayLike(c){for(var l=c.length<0?0:0|checked(c.length),et=createBuffer(l),eo=0;eo=2147483647)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|c}function byteLength(c,l){if(Buffer.isBuffer(c))return c.length;if(ArrayBuffer.isView(c)||isInstance(c,ArrayBuffer))return c.byteLength;if("string"!=typeof c)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof c);var et=c.length,eo=arguments.length>2&&!0===arguments[2];if(!eo&&0===et)return 0;for(var es=!1;;)switch(l){case"ascii":case"latin1":case"binary":return et;case"utf8":case"utf-8":return utf8ToBytes(c).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*et;case"hex":return et>>>1;case"base64":return base64ToBytes(c).length;default:if(es)return eo?-1:utf8ToBytes(c).length;l=(""+l).toLowerCase(),es=!0}}function slowToString(c,l,et){var es,ec,el=!1;if((void 0===l||l<0)&&(l=0),l>this.length||((void 0===et||et>this.length)&&(et=this.length),et<=0||(et>>>=0)<=(l>>>=0)))return"";for(c||(c="utf8");;)switch(c){case"hex":return function(c,l,et){var eo=c.length;(!l||l<0)&&(l=0),(!et||et<0||et>eo)&&(et=eo);for(var es="",ec=l;ec2147483647?et=2147483647:et<-2147483648&&(et=-2147483648),(ec=et=+et)!=ec&&(et=es?0:c.length-1),et<0&&(et=c.length+et),et>=c.length){if(es)return -1;et=c.length-1}else if(et<0){if(!es)return -1;et=0}if("string"==typeof l&&(l=Buffer.from(l,eo)),Buffer.isBuffer(l))return 0===l.length?-1:arrayIndexOf(c,l,et,eo,es);if("number"==typeof l)return(l&=255,"function"==typeof Uint8Array.prototype.indexOf)?es?Uint8Array.prototype.indexOf.call(c,l,et):Uint8Array.prototype.lastIndexOf.call(c,l,et):arrayIndexOf(c,[l],et,eo,es);throw TypeError("val must be string, number or Buffer")}function arrayIndexOf(c,l,et,eo,es){var ec,el=1,ed=c.length,eh=l.length;if(void 0!==eo&&("ucs2"===(eo=String(eo).toLowerCase())||"ucs-2"===eo||"utf16le"===eo||"utf-16le"===eo)){if(c.length<2||l.length<2)return -1;el=2,ed/=2,eh/=2,et/=2}function read(c,l){return 1===el?c[l]:c.readUInt16BE(l*el)}if(es){var ef=-1;for(ec=et;eced&&(et=ed-eh),ec=et;ec>=0;ec--){for(var ep=!0,eg=0;eg239?4:ef>223?3:ef>191?2:1;if(es+eg<=et)switch(eg){case 1:ef<128&&(ep=ef);break;case 2:(192&(ec=c[es+1]))==128&&(eh=(31&ef)<<6|63&ec)>127&&(ep=eh);break;case 3:ec=c[es+1],el=c[es+2],(192&ec)==128&&(192&el)==128&&(eh=(15&ef)<<12|(63&ec)<<6|63&el)>2047&&(eh<55296||eh>57343)&&(ep=eh);break;case 4:ec=c[es+1],el=c[es+2],ed=c[es+3],(192&ec)==128&&(192&el)==128&&(192&ed)==128&&(eh=(15&ef)<<18|(63&ec)<<12|(63&el)<<6|63&ed)>65535&&eh<1114112&&(ep=eh)}null===ep?(ep=65533,eg=1):ep>65535&&(ep-=65536,eo.push(ep>>>10&1023|55296),ep=56320|1023&ep),eo.push(ep),es+=eg}return function(c){var l=c.length;if(l<=4096)return String.fromCharCode.apply(String,c);for(var et="",eo=0;eoet)throw RangeError("Trying to access beyond buffer length")}function checkInt(c,l,et,eo,es,ec){if(!Buffer.isBuffer(c))throw TypeError('"buffer" argument must be a Buffer instance');if(l>es||lc.length)throw RangeError("Index out of range")}function checkIEEE754(c,l,et,eo,es,ec){if(et+eo>c.length||et<0)throw RangeError("Index out of range")}function writeFloat(c,l,et,eo,ec){return l=+l,et>>>=0,ec||checkIEEE754(c,l,et,4,34028234663852886e22,-34028234663852886e22),es.write(c,l,et,eo,23,4),et+4}function writeDouble(c,l,et,eo,ec){return l=+l,et>>>=0,ec||checkIEEE754(c,l,et,8,17976931348623157e292,-17976931348623157e292),es.write(c,l,et,eo,52,8),et+8}l.lW=Buffer,l.h2=50,Buffer.TYPED_ARRAY_SUPPORT=function(){try{var c=new Uint8Array(1),l={foo:function(){return 42}};return Object.setPrototypeOf(l,Uint8Array.prototype),Object.setPrototypeOf(c,l),42===c.foo()}catch(c){return!1}}(),Buffer.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(Buffer.prototype,"parent",{enumerable:!0,get:function(){if(Buffer.isBuffer(this))return this.buffer}}),Object.defineProperty(Buffer.prototype,"offset",{enumerable:!0,get:function(){if(Buffer.isBuffer(this))return this.byteOffset}}),Buffer.poolSize=8192,Buffer.from=function(c,l,et){return from(c,l,et)},Object.setPrototypeOf(Buffer.prototype,Uint8Array.prototype),Object.setPrototypeOf(Buffer,Uint8Array),Buffer.alloc=function(c,l,et){return(assertSize(c),c<=0)?createBuffer(c):void 0!==l?"string"==typeof et?createBuffer(c).fill(l,et):createBuffer(c).fill(l):createBuffer(c)},Buffer.allocUnsafe=function(c){return allocUnsafe(c)},Buffer.allocUnsafeSlow=function(c){return allocUnsafe(c)},Buffer.isBuffer=function(c){return null!=c&&!0===c._isBuffer&&c!==Buffer.prototype},Buffer.compare=function(c,l){if(isInstance(c,Uint8Array)&&(c=Buffer.from(c,c.offset,c.byteLength)),isInstance(l,Uint8Array)&&(l=Buffer.from(l,l.offset,l.byteLength)),!Buffer.isBuffer(c)||!Buffer.isBuffer(l))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(c===l)return 0;for(var et=c.length,eo=l.length,es=0,ec=Math.min(et,eo);eseo.length?Buffer.from(ec).copy(eo,es):Uint8Array.prototype.set.call(eo,ec,es);else if(Buffer.isBuffer(ec))ec.copy(eo,es);else throw TypeError('"list" argument must be an Array of Buffers');es+=ec.length}return eo},Buffer.byteLength=byteLength,Buffer.prototype._isBuffer=!0,Buffer.prototype.swap16=function(){var c=this.length;if(c%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var l=0;let&&(c+=" ... "),""},ec&&(Buffer.prototype[ec]=Buffer.prototype.inspect),Buffer.prototype.compare=function(c,l,et,eo,es){if(isInstance(c,Uint8Array)&&(c=Buffer.from(c,c.offset,c.byteLength)),!Buffer.isBuffer(c))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof c);if(void 0===l&&(l=0),void 0===et&&(et=c?c.length:0),void 0===eo&&(eo=0),void 0===es&&(es=this.length),l<0||et>c.length||eo<0||es>this.length)throw RangeError("out of range index");if(eo>=es&&l>=et)return 0;if(eo>=es)return -1;if(l>=et)return 1;if(l>>>=0,et>>>=0,eo>>>=0,es>>>=0,this===c)return 0;for(var ec=es-eo,el=et-l,ed=Math.min(ec,el),eh=this.slice(eo,es),ef=c.slice(l,et),ep=0;ep>>=0,isFinite(et)?(et>>>=0,void 0===eo&&(eo="utf8")):(eo=et,et=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var es,ec,el,ed,eh,ef,ep,eg,em=this.length-l;if((void 0===et||et>em)&&(et=em),c.length>0&&(et<0||l<0)||l>this.length)throw RangeError("Attempt to write outside buffer bounds");eo||(eo="utf8");for(var eb=!1;;)switch(eo){case"hex":return function(c,l,et,eo){et=Number(et)||0;var es=c.length-et;eo?(eo=Number(eo))>es&&(eo=es):eo=es;var ec=l.length;eo>ec/2&&(eo=ec/2);for(var el=0;el>8,es.push(et%256),es.push(eo);return es}(c,this.length-ep),this,ep,eg);default:if(eb)throw TypeError("Unknown encoding: "+eo);eo=(""+eo).toLowerCase(),eb=!0}},Buffer.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},Buffer.prototype.slice=function(c,l){var et=this.length;c=~~c,l=void 0===l?et:~~l,c<0?(c+=et)<0&&(c=0):c>et&&(c=et),l<0?(l+=et)<0&&(l=0):l>et&&(l=et),l>>=0,l>>>=0,et||checkOffset(c,l,this.length);for(var eo=this[c],es=1,ec=0;++ec>>=0,l>>>=0,et||checkOffset(c,l,this.length);for(var eo=this[c+--l],es=1;l>0&&(es*=256);)eo+=this[c+--l]*es;return eo},Buffer.prototype.readUint8=Buffer.prototype.readUInt8=function(c,l){return c>>>=0,l||checkOffset(c,1,this.length),this[c]},Buffer.prototype.readUint16LE=Buffer.prototype.readUInt16LE=function(c,l){return c>>>=0,l||checkOffset(c,2,this.length),this[c]|this[c+1]<<8},Buffer.prototype.readUint16BE=Buffer.prototype.readUInt16BE=function(c,l){return c>>>=0,l||checkOffset(c,2,this.length),this[c]<<8|this[c+1]},Buffer.prototype.readUint32LE=Buffer.prototype.readUInt32LE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),(this[c]|this[c+1]<<8|this[c+2]<<16)+16777216*this[c+3]},Buffer.prototype.readUint32BE=Buffer.prototype.readUInt32BE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),16777216*this[c]+(this[c+1]<<16|this[c+2]<<8|this[c+3])},Buffer.prototype.readIntLE=function(c,l,et){c>>>=0,l>>>=0,et||checkOffset(c,l,this.length);for(var eo=this[c],es=1,ec=0;++ec=(es*=128)&&(eo-=Math.pow(2,8*l)),eo},Buffer.prototype.readIntBE=function(c,l,et){c>>>=0,l>>>=0,et||checkOffset(c,l,this.length);for(var eo=l,es=1,ec=this[c+--eo];eo>0&&(es*=256);)ec+=this[c+--eo]*es;return ec>=(es*=128)&&(ec-=Math.pow(2,8*l)),ec},Buffer.prototype.readInt8=function(c,l){return(c>>>=0,l||checkOffset(c,1,this.length),128&this[c])?-((255-this[c]+1)*1):this[c]},Buffer.prototype.readInt16LE=function(c,l){c>>>=0,l||checkOffset(c,2,this.length);var et=this[c]|this[c+1]<<8;return 32768&et?4294901760|et:et},Buffer.prototype.readInt16BE=function(c,l){c>>>=0,l||checkOffset(c,2,this.length);var et=this[c+1]|this[c]<<8;return 32768&et?4294901760|et:et},Buffer.prototype.readInt32LE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),this[c]|this[c+1]<<8|this[c+2]<<16|this[c+3]<<24},Buffer.prototype.readInt32BE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),this[c]<<24|this[c+1]<<16|this[c+2]<<8|this[c+3]},Buffer.prototype.readFloatLE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),es.read(this,c,!0,23,4)},Buffer.prototype.readFloatBE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),es.read(this,c,!1,23,4)},Buffer.prototype.readDoubleLE=function(c,l){return c>>>=0,l||checkOffset(c,8,this.length),es.read(this,c,!0,52,8)},Buffer.prototype.readDoubleBE=function(c,l){return c>>>=0,l||checkOffset(c,8,this.length),es.read(this,c,!1,52,8)},Buffer.prototype.writeUintLE=Buffer.prototype.writeUIntLE=function(c,l,et,eo){if(c=+c,l>>>=0,et>>>=0,!eo){var es=Math.pow(2,8*et)-1;checkInt(this,c,l,et,es,0)}var ec=1,el=0;for(this[l]=255&c;++el>>=0,et>>>=0,!eo){var es=Math.pow(2,8*et)-1;checkInt(this,c,l,et,es,0)}var ec=et-1,el=1;for(this[l+ec]=255&c;--ec>=0&&(el*=256);)this[l+ec]=c/el&255;return l+et},Buffer.prototype.writeUint8=Buffer.prototype.writeUInt8=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,1,255,0),this[l]=255&c,l+1},Buffer.prototype.writeUint16LE=Buffer.prototype.writeUInt16LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,65535,0),this[l]=255&c,this[l+1]=c>>>8,l+2},Buffer.prototype.writeUint16BE=Buffer.prototype.writeUInt16BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,65535,0),this[l]=c>>>8,this[l+1]=255&c,l+2},Buffer.prototype.writeUint32LE=Buffer.prototype.writeUInt32LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,4294967295,0),this[l+3]=c>>>24,this[l+2]=c>>>16,this[l+1]=c>>>8,this[l]=255&c,l+4},Buffer.prototype.writeUint32BE=Buffer.prototype.writeUInt32BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,4294967295,0),this[l]=c>>>24,this[l+1]=c>>>16,this[l+2]=c>>>8,this[l+3]=255&c,l+4},Buffer.prototype.writeIntLE=function(c,l,et,eo){if(c=+c,l>>>=0,!eo){var es=Math.pow(2,8*et-1);checkInt(this,c,l,et,es-1,-es)}var ec=0,el=1,ed=0;for(this[l]=255&c;++ec>0)-ed&255;return l+et},Buffer.prototype.writeIntBE=function(c,l,et,eo){if(c=+c,l>>>=0,!eo){var es=Math.pow(2,8*et-1);checkInt(this,c,l,et,es-1,-es)}var ec=et-1,el=1,ed=0;for(this[l+ec]=255&c;--ec>=0&&(el*=256);)c<0&&0===ed&&0!==this[l+ec+1]&&(ed=1),this[l+ec]=(c/el>>0)-ed&255;return l+et},Buffer.prototype.writeInt8=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,1,127,-128),c<0&&(c=255+c+1),this[l]=255&c,l+1},Buffer.prototype.writeInt16LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,32767,-32768),this[l]=255&c,this[l+1]=c>>>8,l+2},Buffer.prototype.writeInt16BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,32767,-32768),this[l]=c>>>8,this[l+1]=255&c,l+2},Buffer.prototype.writeInt32LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,2147483647,-2147483648),this[l]=255&c,this[l+1]=c>>>8,this[l+2]=c>>>16,this[l+3]=c>>>24,l+4},Buffer.prototype.writeInt32BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,2147483647,-2147483648),c<0&&(c=4294967295+c+1),this[l]=c>>>24,this[l+1]=c>>>16,this[l+2]=c>>>8,this[l+3]=255&c,l+4},Buffer.prototype.writeFloatLE=function(c,l,et){return writeFloat(this,c,l,!0,et)},Buffer.prototype.writeFloatBE=function(c,l,et){return writeFloat(this,c,l,!1,et)},Buffer.prototype.writeDoubleLE=function(c,l,et){return writeDouble(this,c,l,!0,et)},Buffer.prototype.writeDoubleBE=function(c,l,et){return writeDouble(this,c,l,!1,et)},Buffer.prototype.copy=function(c,l,et,eo){if(!Buffer.isBuffer(c))throw TypeError("argument should be a Buffer");if(et||(et=0),eo||0===eo||(eo=this.length),l>=c.length&&(l=c.length),l||(l=0),eo>0&&eo=this.length)throw RangeError("Index out of range");if(eo<0)throw RangeError("sourceEnd out of bounds");eo>this.length&&(eo=this.length),c.length-l>>=0,et=void 0===et?this.length:et>>>0,c||(c=0),"number"==typeof c)for(es=l;es55295&&et<57344){if(!es){if(et>56319||el+1===eo){(l-=3)>-1&&ec.push(239,191,189);continue}es=et;continue}if(et<56320){(l-=3)>-1&&ec.push(239,191,189),es=et;continue}et=(es-55296<<10|et-56320)+65536}else es&&(l-=3)>-1&&ec.push(239,191,189);if(es=null,et<128){if((l-=1)<0)break;ec.push(et)}else if(et<2048){if((l-=2)<0)break;ec.push(et>>6|192,63&et|128)}else if(et<65536){if((l-=3)<0)break;ec.push(et>>12|224,et>>6&63|128,63&et|128)}else if(et<1114112){if((l-=4)<0)break;ec.push(et>>18|240,et>>12&63|128,et>>6&63|128,63&et|128)}else throw Error("Invalid code point")}return ec}function base64ToBytes(c){return eo.toByteArray(function(c){if((c=(c=c.split("=")[0]).trim().replace(el,"")).length<2)return"";for(;c.length%4!=0;)c+="=";return c}(c))}function blitBuffer(c,l,et,eo){for(var es=0;es=l.length)&&!(es>=c.length);++es)l[es+et]=c[es];return es}function isInstance(c,l){return c instanceof l||null!=c&&null!=c.constructor&&null!=c.constructor.name&&c.constructor.name===l.name}var ed=function(){for(var c="0123456789abcdef",l=Array(256),et=0;et<16;++et)for(var eo=16*et,es=0;es<16;++es)l[eo+es]=c[et]+c[es];return l}()},44096:function(c,l,et){"use strict";et.r(l),et.d(l,{Children:function(){return eP},Component:function(){return m},Fragment:function(){return d},PureComponent:function(){return eA},Suspense:function(){return U},SuspenseList:function(){return O},cloneElement:function(){return K},createContext:function(){return M},createElement:function(){return h},createFactory:function(){return G},createPortal:function(){return compat_module_z},createRef:function(){return y},default:function(){return ej},findDOMNode:function(){return X},forwardRef:function(){return S},hydrate:function(){return V},isValidElement:function(){return J},lazy:function(){return compat_module_L},memo:function(){return compat_module_},render:function(){return compat_module_T},unmountComponentAtNode:function(){return Q},unstable_batchedUpdates:function(){return Y},useCallback:function(){return hooks_module_T},useContext:function(){return hooks_module_w},useDebugValue:function(){return hooks_module_A},useEffect:function(){return hooks_module_l},useErrorBoundary:function(){return F},useImperativeHandle:function(){return hooks_module_s},useLayoutEffect:function(){return hooks_module_y},useMemo:function(){return hooks_module_h},useReducer:function(){return hooks_module_p},useRef:function(){return hooks_module_d},useState:function(){return hooks_module_m},version:function(){return eD}});var eo,es,ec,el,ed,eh,ef,ep={},eg=[],em=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord/i;function a(c,l){for(var et in l)c[et]=l[et];return c}function v(c){var l=c.parentNode;l&&l.removeChild(c)}function h(c,l,et){var eo,es=arguments,ec={};for(eo in l)"key"!==eo&&"ref"!==eo&&(ec[eo]=l[eo]);if(arguments.length>3)for(et=[et],eo=3;eo2&&(l.children=eg.slice.call(arguments,2)),et={},l)"key"!==eo&&"ref"!==eo&&(et[eo]=l[eo]);return p(c.type,et,l.key||c.key,l.ref||c.ref,null)}function M(c){var l={},et={__c:"__cC"+ef++,__:c,Consumer:function(c,l){return c.children(l)},Provider:function(c){var eo,es=this;return this.getChildContext||(eo=[],this.getChildContext=function(){return l[et.__c]=es,l},this.shouldComponentUpdate=function(c){es.props.value!==c.value&&eo.some(function(l){l.context=c.value,g(l)})},this.sub=function(c){eo.push(c);var l=c.componentWillUnmount;c.componentWillUnmount=function(){eo.splice(eo.indexOf(c),1),l&&l.call(c)}}),c.children}};return et.Consumer.contextType=et,et.Provider.__=et,et}eo={__e:function(c,l){for(var et,eo;l=l.__;)if((et=l.__c)&&!et.__)try{if(et.constructor&&null!=et.constructor.getDerivedStateFromError&&(eo=!0,et.setState(et.constructor.getDerivedStateFromError(c))),null!=et.componentDidCatch&&(eo=!0,et.componentDidCatch(c)),eo)return g(et.__E=et)}catch(l){c=l}throw c}},m.prototype.setState=function(c,l){var et;et=this.__s!==this.state?this.__s:this.__s=a({},this.state),"function"==typeof c&&(c=c(et,this.props)),c&&a(et,c),null!=c&&this.__v&&(l&&this.__h.push(l),g(this))},m.prototype.forceUpdate=function(c){this.__v&&(this.__e=!0,c&&this.__h.push(c),g(this))},m.prototype.render=d,es=[],ec=0,el="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,eh=ep,ef=0;var eb,ey,e_,ew=0,eE=[],eS=eo.__r,ex=eo.diffed,ek=eo.__c,eC=eo.unmount;function hooks_module_v(c,l){eo.__h&&eo.__h(ey,c,ew||l),ew=0;var et=ey.__H||(ey.__H={__:[],__h:[]});return c>=et.__.length&&et.__.push({}),et.__[c]}function hooks_module_m(c){return ew=1,hooks_module_p(hooks_module_E,c)}function hooks_module_p(c,l,et){var eo=hooks_module_v(eb++,2);return eo.__c||(eo.__c=ey,eo.__=[et?et(l):hooks_module_E(void 0,l),function(l){var et=c(eo.__[0],l);eo.__[0]!==et&&(eo.__[0]=et,eo.__c.setState({}))}]),eo.__}function hooks_module_l(c,l){var et=hooks_module_v(eb++,3);!eo.__s&&hooks_module_x(et.__H,l)&&(et.__=c,et.__H=l,ey.__H.__h.push(et))}function hooks_module_y(c,l){var et=hooks_module_v(eb++,4);!eo.__s&&hooks_module_x(et.__H,l)&&(et.__=c,et.__H=l,ey.__h.push(et))}function hooks_module_d(c){return ew=5,hooks_module_h(function(){return{current:c}},[])}function hooks_module_s(c,l,et){ew=6,hooks_module_y(function(){"function"==typeof c?c(l()):c&&(c.current=l())},null==et?et:et.concat(c))}function hooks_module_h(c,l){var et=hooks_module_v(eb++,7);return hooks_module_x(et.__H,l)?(et.__H=l,et.__h=c,et.__=c()):et.__}function hooks_module_T(c,l){return ew=8,hooks_module_h(function(){return c},l)}function hooks_module_w(c){var l=ey.context[c.__c],et=hooks_module_v(eb++,9);return et.__c=c,l?(null==et.__&&(et.__=!0,l.sub(ey)),l.props.value):c.__}function hooks_module_A(c,l){eo.useDebugValue&&eo.useDebugValue(l?l(c):c)}function F(c){var l=hooks_module_v(eb++,10),et=hooks_module_m();return l.__=c,ey.componentDidCatch||(ey.componentDidCatch=function(c){l.__&&l.__(c),et[1](c)}),[et[0],function(){et[1](void 0)}]}function hooks_module_(){eE.some(function(c){if(c.__P)try{c.__H.__h.forEach(hooks_module_g),c.__H.__h.forEach(q),c.__H.__h=[]}catch(l){return c.__H.__h=[],eo.__e(l,c.__v),!0}}),eE=[]}function hooks_module_g(c){c.t&&c.t()}function q(c){var l=c.__();"function"==typeof l&&(c.t=l)}function hooks_module_x(c,l){return!c||l.some(function(l,et){return l!==c[et]})}function hooks_module_E(c,l){return"function"==typeof l?l(c):l}function compat_module_E(c,l){for(var et in l)c[et]=l[et];return c}function compat_module_w(c,l){for(var et in c)if("__source"!==et&&!(et in l))return!0;for(var eo in l)if("__source"!==eo&&c[eo]!==l[eo])return!0;return!1}eo.__r=function(c){eS&&eS(c),eb=0,(ey=c.__c).__H&&(ey.__H.__h.forEach(hooks_module_g),ey.__H.__h.forEach(q),ey.__H.__h=[])},eo.diffed=function(c){ex&&ex(c);var l=c.__c;if(l){var et=l.__H;et&&et.__h.length&&(1!==eE.push(l)&&e_===eo.requestAnimationFrame||((e_=eo.requestAnimationFrame)||function(c){var l,u=function(){clearTimeout(et),cancelAnimationFrame(l),setTimeout(c)},et=setTimeout(u,100);"undefined"!=typeof window&&(l=requestAnimationFrame(u))})(hooks_module_))}},eo.__c=function(c,l){l.some(function(c){try{c.__h.forEach(hooks_module_g),c.__h=c.__h.filter(function(c){return!c.__||q(c)})}catch(et){l.some(function(c){c.__h&&(c.__h=[])}),l=[],eo.__e(et,c.__v)}}),ek&&ek(c,l)},eo.unmount=function(c){eC&&eC(c);var l=c.__c;if(l){var et=l.__H;if(et)try{et.__.forEach(function(c){return c.t&&c.t()})}catch(c){eo.__e(c,l.__v)}}};var eA=function(c){function r(l){var et;return(et=c.call(this,l)||this).isPureReactComponent=!0,et}return r.prototype=Object.create(c.prototype),r.prototype.constructor=r,r.__proto__=c,r.prototype.shouldComponentUpdate=function(c,l){return compat_module_w(this.props,c)||compat_module_w(this.state,l)},r}(m);function compat_module_(c,l){function e(c){var et=this.props.ref,eo=et==c.ref;return!eo&&et&&(et.call?et(null):et.current=null),l?!l(this.props,c)||!eo:compat_module_w(this.props,c)}function r(l){return this.shouldComponentUpdate=e,h(c,compat_module_E({},l))}return r.prototype.isReactComponent=!0,r.displayName="Memo("+(c.displayName||c.name)+")",r.t=!0,r}var eI=eo.__b;function S(c){function t(l){var et=compat_module_E({},l);return delete et.ref,c(et,l.ref)}return t.prototype.isReactComponent=t.t=!0,t.displayName="ForwardRef("+(c.displayName||c.name)+")",t}eo.__b=function(c){c.type&&c.type.t&&c.ref&&(c.props.ref=c.ref,c.ref=null),eI&&eI(c)};var compat_module_k=function(c,l){return c?x(c).reduce(function(c,et,eo){return c.concat(l(et,eo))},[]):null},eP={map:compat_module_k,forEach:compat_module_k,count:function(c){return c?x(c).length:0},only:function(c){if(1!==(c=x(c)).length)throw Error("Children.only() expects only one child.");return c[0]},toArray:x},eR=eo.__e;function U(){this.__u=0,this.o=null,this.__b=null}function compat_module_M(c){var l=c.__.__c;return l&&l.u&&l.u(c)}function compat_module_L(c){var l,et,eo;function o(es){if(l||(l=c()).then(function(c){et=c.default||c},function(c){eo=c}),eo)throw eo;if(!et)throw l;return h(et,es)}return o.displayName="Lazy",o.t=!0,o}function O(){this.i=null,this.l=null}eo.__e=function(c,l,et){if(c.then){for(var eo,es=l;es=es.__;)if((eo=es.__c)&&eo.__c)return eo.__c(c,l.__c)}eR(c,l,et)},(U.prototype=new m).__c=function(c,l){var et=this;null==et.o&&(et.o=[]),et.o.push(l);var eo=compat_module_M(et.__v),es=!1,u=function(){es||(es=!0,eo?eo(i):i())};l.__c=l.componentWillUnmount,l.componentWillUnmount=function(){u(),l.__c&&l.__c()};var i=function(){var c;if(!--et.__u)for(et.__v.__k[0]=et.state.u,et.setState({u:et.__b=null});c=et.o.pop();)c.forceUpdate()};et.__u++||et.setState({u:et.__b=et.__v.__k[0]}),c.then(u,u)},U.prototype.render=function(c,l){return this.__b&&(this.__v.__k[0]=function compat_module_N(c){return c&&((c=compat_module_E({},c)).__c=null,c.__k=c.__k&&c.__k.map(compat_module_N)),c}(this.__b),this.__b=null),[h(m,null,l.u?null:c.children),l.u&&c.fallback]};var compat_module_P=function(c,l,et){if(++et[1]===et[0]&&c.l.delete(l),c.props.revealOrder&&("t"!==c.props.revealOrder[0]||!c.l.size))for(et=c.i;et;){for(;et.length>3;)et.pop()();if(et[1]>>7-c%8&1)==1},put:function(c,l){for(var et=0;et>>l-et-1&1)==1)},getLengthInBits:function(){return this.length},putBit:function(c){var l=Math.floor(this.length/8);this.buffer.length<=l&&this.buffer.push(0),c&&(this.buffer[l]|=128>>>this.length%8),this.length++}},c.exports=BitBuffer},81102:function(c,l,et){var eo=et(8506);function BitMatrix(c){if(!c||c<1)throw Error("BitMatrix size must be defined and greater than 0");this.size=c,this.data=eo.alloc(c*c),this.reservedBit=eo.alloc(c*c)}BitMatrix.prototype.set=function(c,l,et,eo){var es=c*this.size+l;this.data[es]=et,eo&&(this.reservedBit[es]=!0)},BitMatrix.prototype.get=function(c,l){return this.data[c*this.size+l]},BitMatrix.prototype.xor=function(c,l,et){this.data[c*this.size+l]^=et},BitMatrix.prototype.isReserved=function(c,l){return this.reservedBit[c*this.size+l]},c.exports=BitMatrix},7843:function(c,l,et){var eo=et(8506),es=et(75750);function ByteData(c){this.mode=es.BYTE,this.data=eo.from(c)}ByteData.getBitsLength=function(c){return 8*c},ByteData.prototype.getLength=function(){return this.data.length},ByteData.prototype.getBitsLength=function(){return ByteData.getBitsLength(this.data.length)},ByteData.prototype.write=function(c){for(var l=0,et=this.data.length;l=0&&c.bit<4},l.from=function(c,et){if(l.isValid(c))return c;try{return function(c){if("string"!=typeof c)throw Error("Param is not a string");switch(c.toLowerCase()){case"l":case"low":return l.L;case"m":case"medium":return l.M;case"q":case"quartile":return l.Q;case"h":case"high":return l.H;default:throw Error("Unknown EC Level: "+c)}}(c)}catch(c){return et}}},91336:function(c,l,et){var eo=et(49310).getSymbolSize;l.getPositions=function(c){var l=eo(c);return[[0,0],[l-7,0],[0,l-7]]}},64184:function(c,l,et){var eo=et(49310),es=eo.getBCHDigit(1335);l.getEncodedBits=function(c,l){for(var et=c.bit<<3|l,ec=et<<10;eo.getBCHDigit(ec)-es>=0;)ec^=1335<=33088&&et<=40956)et-=33088;else if(et>=57408&&et<=60351)et-=49472;else throw Error("Invalid SJIS character: "+this.data[l]+"\nMake sure your charset is UTF-8");et=(et>>>8&255)*192+(255&et),c.put(et,13)}},c.exports=KanjiData},19123:function(c,l){l.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};var et={N1:3,N2:3,N3:40,N4:10};l.isValid=function(c){return null!=c&&""!==c&&!isNaN(c)&&c>=0&&c<=7},l.from=function(c){return l.isValid(c)?parseInt(c,10):void 0},l.getPenaltyN1=function(c){for(var l=c.size,eo=0,es=0,ec=0,el=null,ed=null,eh=0;eh=5&&(eo+=et.N1+(es-5)),el=ep,es=1),(ep=c.get(ef,eh))===ed?ec++:(ec>=5&&(eo+=et.N1+(ec-5)),ed=ep,ec=1)}es>=5&&(eo+=et.N1+(es-5)),ec>=5&&(eo+=et.N1+(ec-5))}return eo},l.getPenaltyN2=function(c){for(var l=c.size,eo=0,es=0;es=10&&(1488===es||93===es)&&eo++,ec=ec<<1&2047|c.get(ed,el),ed>=10&&(1488===ec||93===ec)&&eo++}return eo*et.N3},l.getPenaltyN4=function(c){for(var l=0,eo=c.data.length,es=0;es=1&&l<10?c.ccBits[0]:l<27?c.ccBits[1]:c.ccBits[2]},l.getBestModeForData=function(c){return es.testNumeric(c)?l.NUMERIC:es.testAlphanumeric(c)?l.ALPHANUMERIC:es.testKanji(c)?l.KANJI:l.BYTE},l.toString=function(c){if(c&&c.id)return c.id;throw Error("Invalid mode")},l.isValid=function(c){return c&&c.bit&&c.ccBits},l.from=function(c,et){if(l.isValid(c))return c;try{return function(c){if("string"!=typeof c)throw Error("Param is not a string");switch(c.toLowerCase()){case"numeric":return l.NUMERIC;case"alphanumeric":return l.ALPHANUMERIC;case"kanji":return l.KANJI;case"byte":return l.BYTE;default:throw Error("Unknown mode: "+c)}}(c)}catch(c){return et}}},87129:function(c,l,et){var eo=et(75750);function NumericData(c){this.mode=eo.NUMERIC,this.data=c.toString()}NumericData.getBitsLength=function(c){return 10*Math.floor(c/3)+(c%3?c%3*3+1:0)},NumericData.prototype.getLength=function(){return this.data.length},NumericData.prototype.getBitsLength=function(){return NumericData.getBitsLength(this.data.length)},NumericData.prototype.write=function(c){for(l=0;l+3<=this.data.length;l+=3)et=parseInt(this.data.substr(l,3),10),c.put(et,10);var l,et,eo=this.data.length-l;eo>0&&(et=parseInt(this.data.substr(l),10),c.put(et,3*eo+1))},c.exports=NumericData},39603:function(c,l,et){var eo=et(8506),es=et(59478);l.mul=function(c,l){for(var et=eo.alloc(c.length+l.length-1),ec=0;ec=0;){for(var ec=et[0],el=0;el>eo&1)==1,eo<6?c.set(eo,8,es,!0):eo<8?c.set(eo+1,8,es,!0):c.set(ec-15+eo,8,es,!0),eo<8?c.set(8,ec-eo-1,es,!0):eo<9?c.set(8,15-eo-1+1,es,!0):c.set(8,15-eo-1,es,!0);c.set(ec-8,8,1,!0)}l.create=function(c,l){if(void 0===c||""===c)throw Error("No input text");var et,ey,eS=ec.M;return void 0!==l&&(eS=ec.from(l.errorCorrectionLevel,ec.M),et=eb.from(l.version),ey=ep.from(l.maskPattern),l.toSJISFunc&&es.setToSJISFunction(l.toSJISFunc)),function(c,l,et,ec){if(eE(c))ey=ew.fromArray(c);else if("string"==typeof c){var ey,eS=l;if(!eS){var ex=ew.rawSplit(c);eS=eb.getBestVersionForData(ex,et)}ey=ew.fromString(c,eS||40)}else throw Error("Invalid data");var ek=eb.getBestVersionForData(ey,et);if(!ek)throw Error("The amount of data is too big to be stored in a QR Code");if(l){if(l=0&&ed<=6&&(0===eh||6===eh)||eh>=0&&eh<=6&&(0===ed||6===ed)||ed>=2&&ed<=4&&eh>=2&&eh<=4?c.set(ec+ed,el+eh,!0,!0):c.set(ec+ed,el+eh,!1,!0))}(eI,l),function(c){for(var l=c.size,et=8;et=7&&function(c,l){for(var et,eo,es,ec=c.size,el=eb.getEncodedBits(l),ed=0;ed<18;ed++)et=Math.floor(ed/3),eo=ed%3+ec-8-3,es=(el>>ed&1)==1,c.set(et,eo,es,!0),c.set(eo,et,es,!0)}(eI,l),function(c,l){for(var et=c.size,eo=-1,es=et-1,ec=7,el=0,ed=et-1;ed>0;ed-=2)for(6===ed&&ed--;;){for(var eh=0;eh<2;eh++)if(!c.isReserved(es,ed-eh)){var ef=!1;el>>ec&1)==1),c.set(es,ed-eh,ef),-1==--ec&&(el++,ec=7)}if((es+=eo)<0||et<=es){es-=eo,eo=-eo;break}}}(eI,eC),isNaN(ec)&&(ec=ep.getBestMask(eI,setupFormatInfo.bind(null,eI,et))),ep.applyMask(ec,eI),setupFormatInfo(eI,et,ec),{modules:eI,version:l,errorCorrectionLevel:et,maskPattern:ec,segments:ey}}(c,et,eS,ey)}},69447:function(c,l,et){var eo=et(8506),es=et(39603),ec=et(20235).lW;function ReedSolomonEncoder(c){this.genPoly=void 0,this.degree=c,this.degree&&this.initialize(this.degree)}ReedSolomonEncoder.prototype.initialize=function(c){this.degree=c,this.genPoly=es.generateECPolynomial(this.degree)},ReedSolomonEncoder.prototype.encode=function(c){if(!this.genPoly)throw Error("Encoder not initialized");var l=eo.alloc(this.degree),et=ec.concat([c,l],c.length+this.degree),el=es.mod(et,this.genPoly),ed=this.degree-el.length;if(ed>0){var eh=eo.alloc(this.degree);return el.copy(eh,ed),eh}return el},c.exports=ReedSolomonEncoder},1597:function(c,l){var et="[0-9]+",eo="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+",es="(?:(?![A-Z0-9 $%*+\\-./:]|"+(eo=eo.replace(/u/g,"\\u"))+")(?:.|[\r\n]))+";l.KANJI=RegExp(eo,"g"),l.BYTE_KANJI=RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),l.BYTE=RegExp(es,"g"),l.NUMERIC=RegExp(et,"g"),l.ALPHANUMERIC=RegExp("[A-Z $%*+\\-./:]+","g");var ec=RegExp("^"+eo+"$"),el=RegExp("^"+et+"$"),ed=RegExp("^[A-Z0-9 $%*+\\-./:]+$");l.testKanji=function(c){return ec.test(c)},l.testNumeric=function(c){return el.test(c)},l.testAlphanumeric=function(c){return ed.test(c)}},76199:function(c,l,et){var eo=et(75750),es=et(87129),ec=et(2679),el=et(7843),ed=et(37162),eh=et(1597),ef=et(49310),ep=et(78343);function getStringByteLength(c){return unescape(encodeURIComponent(c)).length}function getSegments(c,l,et){for(var eo,es=[];null!==(eo=c.exec(et));)es.push({data:eo[0],index:eo.index,mode:l,length:eo[0].length});return es}function getSegmentsFromString(c){var l,et,es=getSegments(eh.NUMERIC,eo.NUMERIC,c),ec=getSegments(eh.ALPHANUMERIC,eo.ALPHANUMERIC,c);return ef.isKanjiModeEnabled()?(l=getSegments(eh.BYTE,eo.BYTE,c),et=getSegments(eh.KANJI,eo.KANJI,c)):(l=getSegments(eh.BYTE_KANJI,eo.BYTE,c),et=[]),es.concat(ec,l,et).sort(function(c,l){return c.index-l.index}).map(function(c){return{data:c.data,mode:c.mode,length:c.length}})}function getSegmentBitsLength(c,l){switch(l){case eo.NUMERIC:return es.getBitsLength(c);case eo.ALPHANUMERIC:return ec.getBitsLength(c);case eo.KANJI:return ed.getBitsLength(c);case eo.BYTE:return el.getBitsLength(c)}}function buildSingleSegment(c,l){var et,eh=eo.getBestModeForData(c);if((et=eo.from(l,eh))!==eo.BYTE&&et.bit=0?c[c.length-1]:null;return et&&et.mode===l.mode?c[c.length-1].data+=l.data:c.push(l),c},[]))},l.rawSplit=function(c){return l.fromArray(getSegmentsFromString(c,ef.isKanjiModeEnabled()))}},49310:function(c,l){var et,eo=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];l.getSymbolSize=function(c){if(!c)throw Error('"version" cannot be null or undefined');if(c<1||c>40)throw Error('"version" should be in range from 1 to 40');return 4*c+17},l.getSymbolTotalCodewords=function(c){return eo[c]},l.getBCHDigit=function(c){for(var l=0;0!==c;)l++,c>>>=1;return l},l.setToSJISFunction=function(c){if("function"!=typeof c)throw Error('"toSJISFunc" is not a valid function.');et=c},l.isKanjiModeEnabled=function(){return void 0!==et},l.toSJIS=function(c){return et(c)}},59021:function(c,l){l.isValid=function(c){return!isNaN(c)&&c>=1&&c<=40}},71569:function(c,l,et){var eo=et(49310),es=et(65499),ec=et(6215),el=et(75750),ed=et(59021),eh=et(82333),ef=eo.getBCHDigit(7973);function getReservedBitsCount(c,l){return el.getCharCountIndicator(c,l)+4}l.from=function(c,l){return ed.isValid(c)?parseInt(c,10):l},l.getCapacity=function(c,l,et){if(!ed.isValid(c))throw Error("Invalid QR Code version");void 0===et&&(et=el.BYTE);var ec=(eo.getSymbolTotalCodewords(c)-es.getTotalCodewordsCount(c,l))*8;if(et===el.MIXED)return ec;var eh=ec-getReservedBitsCount(et,c);switch(et){case el.NUMERIC:return Math.floor(eh/10*3);case el.ALPHANUMERIC:return Math.floor(eh/11*2);case el.KANJI:return Math.floor(eh/13);case el.BYTE:default:return Math.floor(eh/8)}},l.getBestVersionForData=function(c,et){var eo,es=ec.from(et,ec.M);if(eh(c)){if(c.length>1)return function(c,et){for(var eo=1;eo<=40;eo++)if(function(c,l){var et=0;return c.forEach(function(c){var eo=getReservedBitsCount(c.mode,l);et+=eo+c.getBitsLength()}),et}(c,eo)<=l.getCapacity(eo,et,el.MIXED))return eo}(c,es);if(0===c.length)return 1;eo=c[0]}else eo=c;return function(c,et,eo){for(var es=1;es<=40;es++)if(et<=l.getCapacity(es,eo,c))return es}(eo.mode,eo.getLength(),es)},l.getEncodedBits=function(c){if(!ed.isValid(c)||c<7)throw Error("Invalid QR Code version");for(var l=c<<12;eo.getBCHDigit(l)-ef>=0;)l^=7973<':"",ef="0&&eh>0&&c[ed-1]||(eo+=ec?svgCmd("M",eh+et,.5+ef+et):svgCmd("m",es,0),es=0,ec=!1),eh+1',ep=''+eh+ef+"\n";return"function"==typeof et&&et(null,ep),ep}},45452:function(c,l){function hex2rgba(c){if("number"==typeof c&&(c=c.toString()),"string"!=typeof c)throw Error("Color should be defined as hex string");var l=c.slice().replace("#","").split("");if(l.length<3||5===l.length||l.length>8)throw Error("Invalid hex color: "+c);(3===l.length||4===l.length)&&(l=Array.prototype.concat.apply([],l.map(function(c){return[c,c]}))),6===l.length&&l.push("F","F");var et=parseInt(l.join(""),16);return{r:et>>24&255,g:et>>16&255,b:et>>8&255,a:255&et,hex:"#"+l.slice(0,6).join("")}}l.getOptions=function(c){c||(c={}),c.color||(c.color={});var l=void 0===c.margin||null===c.margin||c.margin<0?4:c.margin,et=c.width&&c.width>=21?c.width:void 0,eo=c.scale||4;return{width:et,scale:et?4:eo,margin:l,color:{dark:hex2rgba(c.color.dark||"#000000ff"),light:hex2rgba(c.color.light||"#ffffffff")},type:c.type,rendererOpts:c.rendererOpts||{}}},l.getScale=function(c,l){return l.width&&l.width>=c+2*l.margin?l.width/(c+2*l.margin):l.scale},l.getImageWidth=function(c,et){var eo=l.getScale(c,et);return Math.floor((c+2*et.margin)*eo)},l.qrToImageData=function(c,et,eo){for(var es=et.modules.size,ec=et.modules.data,el=l.getScale(es,eo),ed=Math.floor((es+2*eo.margin)*el),eh=eo.margin*el,ef=[eo.color.light,eo.color.dark],ep=0;ep=eh&&eg>=eh&&ep=es)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+es.toString(16)+" bytes");return 0|c}function createBuffer(c,l){var et;return Buffer.TYPED_ARRAY_SUPPORT?(et=new Uint8Array(l)).__proto__=Buffer.prototype:(null===(et=c)&&(et=new Buffer(l)),et.length=l),et}function allocUnsafe(c,l){var et=createBuffer(c,l<0?0:0|checked(l));if(!Buffer.TYPED_ARRAY_SUPPORT)for(var eo=0;eo55295&&et<57344){if(!es){if(et>56319||el+1===eo){(l-=3)>-1&&ec.push(239,191,189);continue}es=et;continue}if(et<56320){(l-=3)>-1&&ec.push(239,191,189),es=et;continue}et=(es-55296<<10|et-56320)+65536}else es&&(l-=3)>-1&&ec.push(239,191,189);if(es=null,et<128){if((l-=1)<0)break;ec.push(et)}else if(et<2048){if((l-=2)<0)break;ec.push(et>>6|192,63&et|128)}else if(et<65536){if((l-=3)<0)break;ec.push(et>>12|224,et>>6&63|128,63&et|128)}else if(et<1114112){if((l-=4)<0)break;ec.push(et>>18|240,et>>12&63|128,et>>6&63|128,63&et|128)}else throw Error("Invalid code point")}return ec}function byteLength(c){return Buffer.isBuffer(c)?c.length:"undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(c)||c instanceof ArrayBuffer)?c.byteLength:("string"!=typeof c&&(c=""+c),0===c.length)?0:utf8ToBytes(c).length}Buffer.TYPED_ARRAY_SUPPORT&&(Buffer.prototype.__proto__=Uint8Array.prototype,Buffer.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&Buffer[Symbol.species]===Buffer&&Object.defineProperty(Buffer,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1})),Buffer.prototype.write=function(c,l,et){void 0===l?(et=this.length,l=0):void 0===et&&"string"==typeof l?(et=this.length,l=0):isFinite(l)&&(l|=0,isFinite(et)?et|=0:et=void 0);var eo,es,ec=this.length-l;if((void 0===et||et>ec)&&(et=ec),c.length>0&&(et<0||l<0)||l>this.length)throw RangeError("Attempt to write outside buffer bounds");return eo=l,es=et,function(c,l,et,eo){for(var es=0;es=l.length)&&!(es>=c.length);++es)l[es+et]=c[es];return es}(utf8ToBytes(c,this.length-eo),this,eo,es)},Buffer.prototype.slice=function(c,l){var et,eo=this.length;if(c=~~c,l=void 0===l?eo:~~l,c<0?(c+=eo)<0&&(c=0):c>eo&&(c=eo),l<0?(l+=eo)<0&&(l=0):l>eo&&(l=eo),l=c.length&&(l=c.length),l||(l=0),eo>0&&eo=this.length)throw RangeError("sourceStart out of bounds");if(eo<0)throw RangeError("sourceEnd out of bounds");eo>this.length&&(eo=this.length),c.length-l=0;--es)c[es+l]=this[es+et];else if(ec<1e3||!Buffer.TYPED_ARRAY_SUPPORT)for(es=0;es>>=0,et=void 0===et?this.length:et>>>0,c||(c=0),"number"==typeof c)for(eo=l;eo{setTimeout(()=>{l(!0)},c)})}},6954:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});let eo=et(1812);eo.__exportStar(et(18995),l),eo.__exportStar(et(24810),l)},91895:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.Watch=void 0;let Watch=class Watch{constructor(){this.timestamps=new Map}start(c){if(this.timestamps.has(c))throw Error(`Watch already started for label: ${c}`);this.timestamps.set(c,{started:Date.now()})}stop(c){let l=this.get(c);if(void 0!==l.elapsed)throw Error(`Watch already stopped for label: ${c}`);let et=Date.now()-l.started;this.timestamps.set(c,{started:l.started,elapsed:et})}get(c){let l=this.timestamps.get(c);if(void 0===l)throw Error(`No timestamp found for label: ${c}`);return l}elapsed(c){let l=this.get(c),et=l.elapsed||Date.now()-l.started;return et}};l.Watch=Watch,l.default=Watch},1812:function(c,l,et){"use strict";et.r(l),et.d(l,{__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return __createBinding},__decorate:function(){return __decorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar},__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__read:function(){return __read},__rest:function(){return __rest},__spread:function(){return __spread},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});/*! ***************************************************************************** +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. +***************************************************************************** */var extendStatics=function(c,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var et in l)l.hasOwnProperty(et)&&(c[et]=l[et])})(c,l)};function __extends(c,l){function __(){this.constructor=c}extendStatics(c,l),c.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(c){for(var l,et=1,eo=arguments.length;etl.indexOf(eo)&&(et[eo]=c[eo]);if(null!=c&&"function"==typeof Object.getOwnPropertySymbols)for(var es=0,eo=Object.getOwnPropertySymbols(c);esl.indexOf(eo[es])&&Object.prototype.propertyIsEnumerable.call(c,eo[es])&&(et[eo[es]]=c[eo[es]]);return et}function __decorate(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el}function __param(c,l){return function(et,eo){l(et,eo,c)}}function __metadata(c,l){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(c,l)}function __awaiter(c,l,et,eo){return new(et||(et=Promise))(function(es,ec){function fulfilled(c){try{step(eo.next(c))}catch(c){ec(c)}}function rejected(c){try{step(eo.throw(c))}catch(c){ec(c)}}function step(c){var l;c.done?es(c.value):((l=c.value)instanceof et?l:new et(function(c){c(l)})).then(fulfilled,rejected)}step((eo=eo.apply(c,l||[])).next())})}function __generator(c,l){var et,eo,es,ec,el={label:0,sent:function(){if(1&es[0])throw es[1];return es[1]},trys:[],ops:[]};return ec={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(ec[Symbol.iterator]=function(){return this}),ec;function verb(ec){return function(ed){return function(ec){if(et)throw TypeError("Generator is already executing.");for(;el;)try{if(et=1,eo&&(es=2&ec[0]?eo.return:ec[0]?eo.throw||((es=eo.return)&&es.call(eo),0):eo.next)&&!(es=es.call(eo,ec[1])).done)return es;switch(eo=0,es&&(ec=[2&ec[0],es.value]),ec[0]){case 0:case 1:es=ec;break;case 4:return el.label++,{value:ec[1],done:!1};case 5:el.label++,eo=ec[1],ec=[0];continue;case 7:ec=el.ops.pop(),el.trys.pop();continue;default:if(!(es=(es=el.trys).length>0&&es[es.length-1])&&(6===ec[0]||2===ec[0])){el=0;continue}if(3===ec[0]&&(!es||ec[1]>es[0]&&ec[1]=c.length&&(c=void 0),{value:c&&c[eo++],done:!c}}};throw TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(c,l){var et="function"==typeof Symbol&&c[Symbol.iterator];if(!et)return c;var eo,es,ec=et.call(c),el=[];try{for(;(void 0===l||l-- >0)&&!(eo=ec.next()).done;)el.push(eo.value)}catch(c){es={error:c}}finally{try{eo&&!eo.done&&(et=ec.return)&&et.call(ec)}finally{if(es)throw es.error}}return el}function __spread(){for(var c=[],l=0;l1||resume(c,l)})})}function resume(c,l){try{var et;(et=es[c](l)).value instanceof __await?Promise.resolve(et.value.v).then(fulfill,reject):settle(ec[0][2],et)}catch(c){settle(ec[0][3],c)}}function fulfill(c){resume("next",c)}function reject(c){resume("throw",c)}function settle(c,l){c(l),ec.shift(),ec.length&&resume(ec[0][0],ec[0][1])}}function __asyncDelegator(c){var l,et;return l={},verb("next"),verb("throw",function(c){throw c}),verb("return"),l[Symbol.iterator]=function(){return this},l;function verb(eo,es){l[eo]=c[eo]?function(l){return(et=!et)?{value:__await(c[eo](l)),done:"return"===eo}:es?es(l):l}:es}}function __asyncValues(c){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var l,et=c[Symbol.asyncIterator];return et?et.call(c):(c=__values(c),l={},verb("next"),verb("throw"),verb("return"),l[Symbol.asyncIterator]=function(){return this},l);function verb(et){l[et]=c[et]&&function(l){return new Promise(function(eo,es){!function(c,l,et,eo){Promise.resolve(eo).then(function(l){c({value:l,done:et})},l)}(eo,es,(l=c[et](l)).done,l.value)})}}}function __makeTemplateObject(c,l){return Object.defineProperty?Object.defineProperty(c,"raw",{value:l}):c.raw=l,c}function __importStar(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)Object.hasOwnProperty.call(c,et)&&(l[et]=c[et]);return l.default=c,l}function __importDefault(c){return c&&c.__esModule?c:{default:c}}function __classPrivateFieldGet(c,l){if(!l.has(c))throw TypeError("attempted to get private field on non-instance");return l.get(c)}function __classPrivateFieldSet(c,l,et){if(!l.has(c))throw TypeError("attempted to set private field on non-instance");return l.set(c,et),et}},39125:function(c,l,et){"use strict";let eo=et(67116),es=et(58005),ec=et(34470),el=et(61820),isNullOrUndefined=c=>null==c,ed=Symbol("encodeFragmentIdentifier");function validateArrayFormatSeparator(c){if("string"!=typeof c||1!==c.length)throw TypeError("arrayFormatSeparator must be single character string")}function encode(c,l){return l.encode?l.strict?eo(c):encodeURIComponent(c):c}function decode(c,l){return l.decode?es(c):c}function removeHash(c){let l=c.indexOf("#");return -1!==l&&(c=c.slice(0,l)),c}function extract(c){c=removeHash(c);let l=c.indexOf("?");return -1===l?"":c.slice(l+1)}function parseValue(c,l){return l.parseNumbers&&!Number.isNaN(Number(c))&&"string"==typeof c&&""!==c.trim()?c=Number(c):l.parseBooleans&&null!==c&&("true"===c.toLowerCase()||"false"===c.toLowerCase())&&(c="true"===c.toLowerCase()),c}function parse(c,l){validateArrayFormatSeparator((l=Object.assign({decode:!0,sort:!0,arrayFormat:"none",arrayFormatSeparator:",",parseNumbers:!1,parseBooleans:!1},l)).arrayFormatSeparator);let et=function(c){let l;switch(c.arrayFormat){case"index":return(c,et,eo)=>{if(l=/\[(\d*)\]$/.exec(c),c=c.replace(/\[\d*\]$/,""),!l){eo[c]=et;return}void 0===eo[c]&&(eo[c]={}),eo[c][l[1]]=et};case"bracket":return(c,et,eo)=>{if(l=/(\[\])$/.exec(c),c=c.replace(/\[\]$/,""),!l){eo[c]=et;return}if(void 0===eo[c]){eo[c]=[et];return}eo[c]=[].concat(eo[c],et)};case"colon-list-separator":return(c,et,eo)=>{if(l=/(:list)$/.exec(c),c=c.replace(/:list$/,""),!l){eo[c]=et;return}if(void 0===eo[c]){eo[c]=[et];return}eo[c]=[].concat(eo[c],et)};case"comma":case"separator":return(l,et,eo)=>{let es="string"==typeof et&&et.includes(c.arrayFormatSeparator),ec="string"==typeof et&&!es&&decode(et,c).includes(c.arrayFormatSeparator);et=ec?decode(et,c):et;let el=es||ec?et.split(c.arrayFormatSeparator).map(l=>decode(l,c)):null===et?et:decode(et,c);eo[l]=el};case"bracket-separator":return(l,et,eo)=>{let es=/(\[\])$/.test(l);if(l=l.replace(/\[\]$/,""),!es){eo[l]=et?decode(et,c):et;return}let ec=null===et?[]:et.split(c.arrayFormatSeparator).map(l=>decode(l,c));if(void 0===eo[l]){eo[l]=ec;return}eo[l]=[].concat(eo[l],ec)};default:return(c,l,et)=>{if(void 0===et[c]){et[c]=l;return}et[c]=[].concat(et[c],l)}}}(l),eo=Object.create(null);if("string"!=typeof c||!(c=c.trim().replace(/^[?#&]/,"")))return eo;for(let es of c.split("&")){if(""===es)continue;let[c,el]=ec(l.decode?es.replace(/\+/g," "):es,"=");el=void 0===el?null:["comma","separator","bracket-separator"].includes(l.arrayFormat)?el:decode(el,l),et(decode(c,l),el,eo)}for(let c of Object.keys(eo)){let et=eo[c];if("object"==typeof et&&null!==et)for(let c of Object.keys(et))et[c]=parseValue(et[c],l);else eo[c]=parseValue(et,l)}return!1===l.sort?eo:(!0===l.sort?Object.keys(eo).sort():Object.keys(eo).sort(l.sort)).reduce((c,l)=>{let et=eo[l];return et&&"object"==typeof et&&!Array.isArray(et)?c[l]=function keysSorter(c){return Array.isArray(c)?c.sort():"object"==typeof c?keysSorter(Object.keys(c)).sort((c,l)=>Number(c)-Number(l)).map(l=>c[l]):c}(et):c[l]=et,c},Object.create(null))}l.extract=extract,l.parse=parse,l.stringify=(c,l)=>{if(!c)return"";validateArrayFormatSeparator((l=Object.assign({encode:!0,strict:!0,arrayFormat:"none",arrayFormatSeparator:","},l)).arrayFormatSeparator);let shouldFilter=et=>l.skipNull&&isNullOrUndefined(c[et])||l.skipEmptyString&&""===c[et],et=function(c){switch(c.arrayFormat){case"index":return l=>(et,eo)=>{let es=et.length;return void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,[encode(l,c),"[",es,"]"].join("")]:[...et,[encode(l,c),"[",encode(es,c),"]=",encode(eo,c)].join("")]};case"bracket":return l=>(et,eo)=>void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,[encode(l,c),"[]"].join("")]:[...et,[encode(l,c),"[]=",encode(eo,c)].join("")];case"colon-list-separator":return l=>(et,eo)=>void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,[encode(l,c),":list="].join("")]:[...et,[encode(l,c),":list=",encode(eo,c)].join("")];case"comma":case"separator":case"bracket-separator":{let l="bracket-separator"===c.arrayFormat?"[]=":"=";return et=>(eo,es)=>void 0===es||c.skipNull&&null===es||c.skipEmptyString&&""===es?eo:(es=null===es?"":es,0===eo.length)?[[encode(et,c),l,encode(es,c)].join("")]:[[eo,encode(es,c)].join(c.arrayFormatSeparator)]}default:return l=>(et,eo)=>void 0===eo||c.skipNull&&null===eo||c.skipEmptyString&&""===eo?et:null===eo?[...et,encode(l,c)]:[...et,[encode(l,c),"=",encode(eo,c)].join("")]}}(l),eo={};for(let l of Object.keys(c))shouldFilter(l)||(eo[l]=c[l]);let es=Object.keys(eo);return!1!==l.sort&&es.sort(l.sort),es.map(eo=>{let es=c[eo];return void 0===es?"":null===es?encode(eo,l):Array.isArray(es)?0===es.length&&"bracket-separator"===l.arrayFormat?encode(eo,l)+"[]":es.reduce(et(eo),[]).join("&"):encode(eo,l)+"="+encode(es,l)}).filter(c=>c.length>0).join("&")},l.parseUrl=(c,l)=>{l=Object.assign({decode:!0},l);let[et,eo]=ec(c,"#");return Object.assign({url:et.split("?")[0]||"",query:parse(extract(c),l)},l&&l.parseFragmentIdentifier&&eo?{fragmentIdentifier:decode(eo,l)}:{})},l.stringifyUrl=(c,et)=>{et=Object.assign({encode:!0,strict:!0,[ed]:!0},et);let eo=removeHash(c.url).split("?")[0]||"",es=l.extract(c.url),ec=l.parse(es,{sort:!1}),el=Object.assign(ec,c.query),eh=l.stringify(el,et);eh&&(eh=`?${eh}`);let ef=function(c){let l="",et=c.indexOf("#");return -1!==et&&(l=c.slice(et)),l}(c.url);return c.fragmentIdentifier&&(ef=`#${et[ed]?encode(c.fragmentIdentifier,et):c.fragmentIdentifier}`),`${eo}${eh}${ef}`},l.pick=(c,et,eo)=>{eo=Object.assign({parseFragmentIdentifier:!0,[ed]:!1},eo);let{url:es,query:ec,fragmentIdentifier:eh}=l.parseUrl(c,eo);return l.stringifyUrl({url:es,query:el(ec,et),fragmentIdentifier:eh},eo)},l.exclude=(c,et,eo)=>{let es=Array.isArray(et)?c=>!et.includes(c):(c,l)=>!et(c,l);return l.pick(c,es,eo)}},849:function(c,l){"use strict";function getFromWindow(c){let l;return"undefined"!=typeof window&&void 0!==window[c]&&(l=window[c]),l}function getFromWindowOrThrow(c){let l=getFromWindow(c);if(!l)throw Error(`${c} is not defined in Window`);return l}Object.defineProperty(l,"__esModule",{value:!0}),l.getLocalStorage=l.getLocalStorageOrThrow=l.getCrypto=l.getCryptoOrThrow=l.getLocation=l.getLocationOrThrow=l.getNavigator=l.getNavigatorOrThrow=l.getDocument=l.getDocumentOrThrow=l.getFromWindowOrThrow=l.getFromWindow=void 0,l.getFromWindow=getFromWindow,l.getFromWindowOrThrow=getFromWindowOrThrow,l.getDocumentOrThrow=function(){return getFromWindowOrThrow("document")},l.getDocument=function(){return getFromWindow("document")},l.getNavigatorOrThrow=function(){return getFromWindowOrThrow("navigator")},l.getNavigator=function(){return getFromWindow("navigator")},l.getLocationOrThrow=function(){return getFromWindowOrThrow("location")},l.getLocation=function(){return getFromWindow("location")},l.getCryptoOrThrow=function(){return getFromWindowOrThrow("crypto")},l.getCrypto=function(){return getFromWindow("crypto")},l.getLocalStorageOrThrow=function(){return getFromWindowOrThrow("localStorage")},l.getLocalStorage=function(){return getFromWindow("localStorage")}},36073:function(c,l,et){"use strict";l.D=void 0;let eo=et(849);l.D=function(){let c,l,et;try{c=eo.getDocumentOrThrow(),l=eo.getLocationOrThrow()}catch(c){return null}function getWindowMetadataOfAny(...l){let et=c.getElementsByTagName("meta");for(let c=0;ceo.getAttribute(c)).filter(c=>!!c&&l.includes(c));if(es.length&&es){let c=eo.getAttribute("content");if(c)return c}}return""}let es=((et=getWindowMetadataOfAny("name","og:site_name","og:title","twitter:title"))||(et=c.title),et),ec=function(){let c=getWindowMetadataOfAny("description","og:description","twitter:description","keywords");return c}(),el=l.origin,ed=function(){let et=c.getElementsByTagName("link"),eo=[];for(let c=0;c-1){let c=es.getAttribute("href");if(c){if(-1===c.toLowerCase().indexOf("https:")&&-1===c.toLowerCase().indexOf("http:")&&0!==c.indexOf("//")){let et=l.protocol+"//"+l.host;if(0===c.indexOf("/"))et+=c;else{let eo=l.pathname.split("/");eo.pop();let es=eo.join("/");et+=es+"/"+c}eo.push(et)}else if(0===c.indexOf("//")){let et=l.protocol+c;eo.push(et)}else eo.push(c)}}}return eo}();return{description:ec,url:el,icons:ed,name:es}}},65816:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});var eo=et(50044),es=et(71236),ec=function(){function Mutex(){this._semaphore=new es.default(1)}return Mutex.prototype.acquire=function(){return eo.__awaiter(this,void 0,void 0,function(){return eo.__generator(this,function(c){switch(c.label){case 0:return[4,this._semaphore.acquire()];case 1:return[2,c.sent()[1]]}})})},Mutex.prototype.runExclusive=function(c){return this._semaphore.runExclusive(function(){return c()})},Mutex.prototype.isLocked=function(){return this._semaphore.isLocked()},Mutex.prototype.release=function(){this._semaphore.release()},Mutex}();l.default=ec},71236:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0});var eo=et(50044),es=function(){function Semaphore(c){if(this._maxConcurrency=c,this._queue=[],c<=0)throw Error("semaphore must be initialized to a positive value");this._value=c}return Semaphore.prototype.acquire=function(){var c=this,l=this.isLocked(),et=new Promise(function(l){return c._queue.push(l)});return l||this._dispatch(),et},Semaphore.prototype.runExclusive=function(c){return eo.__awaiter(this,void 0,void 0,function(){var l,et,es;return eo.__generator(this,function(eo){switch(eo.label){case 0:return[4,this.acquire()];case 1:et=(l=eo.sent())[0],es=l[1],eo.label=2;case 2:return eo.trys.push([2,,4,5]),[4,c(et)];case 3:return[2,eo.sent()];case 4:return es(),[7];case 5:return[2]}})})},Semaphore.prototype.isLocked=function(){return this._value<=0},Semaphore.prototype.release=function(){if(this._maxConcurrency>1)throw Error("this method is unavailabel on semaphores with concurrency > 1; use the scoped release returned by acquire instead");if(this._currentReleaser){var c=this._currentReleaser;this._currentReleaser=void 0,c()}},Semaphore.prototype._dispatch=function(){var c=this,l=this._queue.shift();if(l){var et=!1;this._currentReleaser=function(){et||(et=!0,c._value++,c._dispatch())},l([this._value--,this._currentReleaser])}},Semaphore}();l.default=es},72140:function(c,l,et){"use strict";l.WU=void 0;var eo=et(65816);Object.defineProperty(l,"WU",{enumerable:!0,get:function(){return eo.default}}),et(71236),et(41335)},41335:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.withTimeout=void 0;var eo=et(50044);l.withTimeout=function(c,l,et){var es=this;return void 0===et&&(et=Error("timeout")),{acquire:function(){return new Promise(function(ec,el){return eo.__awaiter(es,void 0,void 0,function(){var es,ed;return eo.__generator(this,function(eo){switch(eo.label){case 0:return es=!1,setTimeout(function(){es=!0,el(et)},l),[4,c.acquire()];case 1:return ed=eo.sent(),es?(Array.isArray(ed)?ed[1]:ed)():ec(ed),[2]}})})})},runExclusive:function(c){return eo.__awaiter(this,void 0,void 0,function(){var l,et;return eo.__generator(this,function(eo){switch(eo.label){case 0:l=function(){},eo.label=1;case 1:return eo.trys.push([1,,7,8]),[4,this.acquire()];case 2:if(!Array.isArray(et=eo.sent()))return[3,4];return l=et[1],[4,c(et[0])];case 3:case 5:return[2,eo.sent()];case 4:return l=et,[4,c()];case 6:return[3,8];case 7:return l(),[7];case 8:return[2]}})})},release:function(){c.release()},isLocked:function(){return c.isLocked()}}}},34699:function(c,l){"use strict";l.byteLength=function(c){var l=getLens(c),et=l[0],eo=l[1];return(et+eo)*3/4-eo},l.toByteArray=function(c){var l,et,ec=getLens(c),el=ec[0],ed=ec[1],eh=new es((el+ed)*3/4-ed),ef=0,ep=ed>0?el-4:el;for(et=0;et>16&255,eh[ef++]=l>>8&255,eh[ef++]=255&l;return 2===ed&&(l=eo[c.charCodeAt(et)]<<2|eo[c.charCodeAt(et+1)]>>4,eh[ef++]=255&l),1===ed&&(l=eo[c.charCodeAt(et)]<<10|eo[c.charCodeAt(et+1)]<<4|eo[c.charCodeAt(et+2)]>>2,eh[ef++]=l>>8&255,eh[ef++]=255&l),eh},l.fromByteArray=function(c){for(var l,eo=c.length,es=eo%3,ec=[],el=0,ed=eo-es;el>18&63]+et[es>>12&63]+et[es>>6&63]+et[63&es]);return ec.join("")}(c,el,el+16383>ed?ed:el+16383));return 1===es?ec.push(et[(l=c[eo-1])>>2]+et[l<<4&63]+"=="):2===es&&ec.push(et[(l=(c[eo-2]<<8)+c[eo-1])>>10]+et[l>>4&63]+et[l<<2&63]+"="),ec.join("")};for(var et=[],eo=[],es="undefined"!=typeof Uint8Array?Uint8Array:Array,ec="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",el=0,ed=ec.length;el0)throw Error("Invalid string. Length must be a multiple of 4");var et=c.indexOf("=");-1===et&&(et=l);var eo=et===l?0:4-et%4;return[et,eo]}eo["-".charCodeAt(0)]=62,eo["_".charCodeAt(0)]=63},76942:function(c){"use strict";for(var l="qpzry9x8gf2tvdw0s3jn54khce6mua7l",et={},eo=0;eo>25;return(33554431&c)<<5^996825010&-(l>>0&1)^642813549&-(l>>1&1)^513874426&-(l>>2&1)^1027748829&-(l>>3&1)^705979059&-(l>>4&1)}function prefixChk(c){for(var l=1,et=0;et126)return"Invalid prefix ("+c+")";l=polymodStep(l)^eo>>5}for(et=0,l=polymodStep(l);etl)return"Exceeds length limit";var eo=c.toLowerCase(),es=c.toUpperCase();if(c!==eo&&c!==es)return"Mixed-case string "+c;var ec=(c=eo).lastIndexOf("1");if(-1===ec)return"No separator character for "+c;if(0===ec)return"Missing prefix for "+c;var el=c.slice(0,ec),ed=c.slice(ec+1);if(ed.length<6)return"Data too short";var eh=prefixChk(el);if("string"==typeof eh)return eh;for(var ef=[],ep=0;ep=ed.length||ef.push(em)}return 1!==eh?"Invalid checksum for "+c:{prefix:el,words:ef}}function convert(c,l,et,eo){for(var es=0,ec=0,el=(1<=et;)ed.push(es>>(ec-=et)&el);if(eo)ec>0&&ed.push(es<=l)return"Excess padding";if(es<eo)throw TypeError("Exceeds length limit");var es=prefixChk(c=c.toLowerCase());if("string"==typeof es)throw Error(es);for(var ec=c+"1",el=0;el>5!=0)throw Error("Non 5-bit word");es=polymodStep(es)^ed,ec+=l.charAt(ed)}for(el=0;el<6;++el)es=polymodStep(es);for(es^=1,el=0;el<6;++el){var eh=es>>(5-el)*5&31;ec+=l.charAt(eh)}return ec},toWordsUnsafe:function(c){var l=convert(c,8,5,!0);if(Array.isArray(l))return l},toWords:function(c){var l=convert(c,8,5,!0);if(Array.isArray(l))return l;throw Error(l)},fromWordsUnsafe:function(c){var l=convert(c,5,8,!1);if(Array.isArray(l))return l},fromWords:function(c){var l=convert(c,5,8,!1);if(Array.isArray(l))return l;throw Error(l)}}},18714:function(c,l){"use strict";var et,eo;function bind(c,l,eo){if(!eo||typeof eo.value!==et.typeOfFunction)throw TypeError("Only methods can be decorated with @bind. <"+l+"> is not a method!");return{configurable:et.boolTrue,get:function(){var c=eo.value.bind(this);return Object.defineProperty(this,l,{value:c,configurable:et.boolTrue,writable:et.boolTrue}),c}}}Object.defineProperty(l,"__esModule",{value:!0}),(eo=et||(et={})).typeOfFunction="function",eo.boolTrue=!0,l.bind=bind,l.default=bind},56662:function(c,l,et){!function(c,l){"use strict";function assert(c,l){if(!c)throw Error(l||"Assertion failed")}function inherits(c,l){c.super_=l;var TempCtor=function(){};TempCtor.prototype=l.prototype,c.prototype=new TempCtor,c.prototype.constructor=c}function BN(c,l,et){if(BN.isBN(c))return c;this.negative=0,this.words=null,this.length=0,this.red=null,null!==c&&(("le"===l||"be"===l)&&(et=l,l=10),this._init(c||0,l||10,et||"be"))}"object"==typeof c?c.exports=BN:l.BN=BN,BN.BN=BN,BN.wordSize=26;try{eo="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:et(46601).Buffer}catch(c){}function parseHex4Bits(c,l){var et=c.charCodeAt(l);return et>=48&&et<=57?et-48:et>=65&&et<=70?et-55:et>=97&&et<=102?et-87:void assert(!1,"Invalid character in "+c)}function parseHexByte(c,l,et){var eo=parseHex4Bits(c,et);return et-1>=l&&(eo|=parseHex4Bits(c,et-1)<<4),eo}function parseBase(c,l,et,eo){for(var es=0,ec=0,el=Math.min(c.length,et),ed=l;ed=49?eh-49+10:eh>=17?eh-17+10:eh,assert(eh>=0&&ec0?c:l},BN.min=function(c,l){return 0>c.cmp(l)?c:l},BN.prototype._init=function(c,l,et){if("number"==typeof c)return this._initNumber(c,l,et);if("object"==typeof c)return this._initArray(c,l,et);"hex"===l&&(l=16),assert(l===(0|l)&&l>=2&&l<=36);var eo=0;"-"===(c=c.toString().replace(/\s+/g,""))[0]&&(eo++,this.negative=1),eo=0;ec-=3)es=c[ec]|c[ec-1]<<8|c[ec-2]<<16,this.words[eo]|=es<>>26-el&67108863,(el+=24)>=26&&(el-=26,eo++);else if("le"===et)for(ec=0,eo=0;ec>>26-el&67108863,(el+=24)>=26&&(el-=26,eo++);return this._strip()},BN.prototype._parseHex=function(c,l,et){this.length=Math.ceil((c.length-l)/6),this.words=Array(this.length);for(var eo,es=0;es=l;es-=2)eo=parseHexByte(c,l,es)<=18?(ec-=18,el+=1,this.words[el]|=eo>>>26):ec+=8;else for(es=(c.length-l)%2==0?l+1:l;es=18?(ec-=18,el+=1,this.words[el]|=eo>>>26):ec+=8;this._strip()},BN.prototype._parseBase=function(c,l,et){this.words=[0],this.length=1;for(var eo=0,es=1;es<=67108863;es*=l)eo++;eo--,es=es/l|0;for(var ec=c.length-et,el=ec%eo,ed=Math.min(ec,ec-el)+et,eh=0,ef=et;ef1&&0===this.words[this.length-1];)this.length--;return this._normSign()},BN.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{BN.prototype[Symbol.for("nodejs.util.inspect.custom")]=inspect}catch(c){BN.prototype.inspect=inspect}else BN.prototype.inspect=inspect;function inspect(){return(this.red?""}var eo,es=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],ec=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],el=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function smallMulTo(c,l,et){et.negative=l.negative^c.negative;var eo=c.length+l.length|0;et.length=eo,eo=eo-1|0;var es=0|c.words[0],ec=0|l.words[0],el=es*ec,ed=67108863&el,eh=el/67108864|0;et.words[0]=ed;for(var ef=1;ef>>26,eg=67108863&eh,em=Math.min(ef,l.length-1),eb=Math.max(0,ef-c.length+1);eb<=em;eb++){var ey=ef-eb|0;ep+=(el=(es=0|c.words[ey])*(ec=0|l.words[eb])+eg)/67108864|0,eg=67108863&el}et.words[ef]=0|eg,eh=0|ep}return 0!==eh?et.words[ef]=0|eh:et.length--,et._strip()}BN.prototype.toString=function(c,l){if(l=0|l||1,16===(c=c||10)||"hex"===c){et="";for(var et,eo=0,ed=0,eh=0;eh>>24-eo&16777215,(eo+=2)>=26&&(eo-=26,eh--),et=0!==ed||eh!==this.length-1?es[6-ep.length]+ep+et:ep+et}for(0!==ed&&(et=ed.toString(16)+et);et.length%l!=0;)et="0"+et;return 0!==this.negative&&(et="-"+et),et}if(c===(0|c)&&c>=2&&c<=36){var eg=ec[c],em=el[c];et="";var eb=this.clone();for(eb.negative=0;!eb.isZero();){var ey=eb.modrn(em).toString(c);et=(eb=eb.idivn(em)).isZero()?ey+et:es[eg-ey.length]+ey+et}for(this.isZero()&&(et="0"+et);et.length%l!=0;)et="0"+et;return 0!==this.negative&&(et="-"+et),et}assert(!1,"Base should be between 2 and 36")},BN.prototype.toNumber=function(){var c=this.words[0];return 2===this.length?c+=67108864*this.words[1]:3===this.length&&1===this.words[2]?c+=4503599627370496+67108864*this.words[1]:this.length>2&&assert(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-c:c},BN.prototype.toJSON=function(){return this.toString(16,2)},eo&&(BN.prototype.toBuffer=function(c,l){return this.toArrayLike(eo,c,l)}),BN.prototype.toArray=function(c,l){return this.toArrayLike(Array,c,l)},BN.prototype.toArrayLike=function(c,l,et){this._strip();var eo=this.byteLength(),es=et||Math.max(1,eo);assert(eo<=es,"byte array longer than desired length"),assert(es>0,"Requested array length <= 0");var ec=c.allocUnsafe?c.allocUnsafe(es):new c(es);return this["_toArrayLike"+("le"===l?"LE":"BE")](ec,eo),ec},BN.prototype._toArrayLikeLE=function(c,l){for(var et=0,eo=0,es=0,ec=0;es>8&255),et>16&255),6===ec?(et>24&255),eo=0,ec=0):(eo=el>>>24,ec+=2)}if(et=0&&(c[et--]=el>>8&255),et>=0&&(c[et--]=el>>16&255),6===ec?(et>=0&&(c[et--]=el>>24&255),eo=0,ec=0):(eo=el>>>24,ec+=2)}if(et>=0)for(c[et--]=eo;et>=0;)c[et--]=0},Math.clz32?BN.prototype._countBits=function(c){return 32-Math.clz32(c)}:BN.prototype._countBits=function(c){var l=c,et=0;return l>=4096&&(et+=13,l>>>=13),l>=64&&(et+=7,l>>>=7),l>=8&&(et+=4,l>>>=4),l>=2&&(et+=2,l>>>=2),et+l},BN.prototype._zeroBits=function(c){if(0===c)return 26;var l=c,et=0;return(8191&l)==0&&(et+=13,l>>>=13),(127&l)==0&&(et+=7,l>>>=7),(15&l)==0&&(et+=4,l>>>=4),(3&l)==0&&(et+=2,l>>>=2),(1&l)==0&&et++,et},BN.prototype.bitLength=function(){var c=this.words[this.length-1],l=this._countBits(c);return(this.length-1)*26+l},BN.prototype.zeroBits=function(){if(this.isZero())return 0;for(var c=0,l=0;lc.length?this.clone().ior(c):c.clone().ior(this)},BN.prototype.uor=function(c){return this.length>c.length?this.clone().iuor(c):c.clone().iuor(this)},BN.prototype.iuand=function(c){var l;l=this.length>c.length?c:this;for(var et=0;etc.length?this.clone().iand(c):c.clone().iand(this)},BN.prototype.uand=function(c){return this.length>c.length?this.clone().iuand(c):c.clone().iuand(this)},BN.prototype.iuxor=function(c){this.length>c.length?(l=this,et=c):(l=c,et=this);for(var l,et,eo=0;eoc.length?this.clone().ixor(c):c.clone().ixor(this)},BN.prototype.uxor=function(c){return this.length>c.length?this.clone().iuxor(c):c.clone().iuxor(this)},BN.prototype.inotn=function(c){assert("number"==typeof c&&c>=0);var l=0|Math.ceil(c/26),et=c%26;this._expand(l),et>0&&l--;for(var eo=0;eo0&&(this.words[eo]=~this.words[eo]&67108863>>26-et),this._strip()},BN.prototype.notn=function(c){return this.clone().inotn(c)},BN.prototype.setn=function(c,l){assert("number"==typeof c&&c>=0);var et=c/26|0,eo=c%26;return this._expand(et+1),l?this.words[et]=this.words[et]|1<c.length?(et=this,eo=c):(et=c,eo=this);for(var l,et,eo,es=0,ec=0;ec>>26;for(;0!==es&&ec>>26;if(this.length=et.length,0!==es)this.words[this.length]=es,this.length++;else if(et!==this)for(;ecc.length?this.clone().iadd(c):c.clone().iadd(this)},BN.prototype.isub=function(c){if(0!==c.negative){c.negative=0;var l,et,eo=this.iadd(c);return c.negative=1,eo._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(c),this.negative=1,this._normSign();var es=this.cmp(c);if(0===es)return this.negative=0,this.length=1,this.words[0]=0,this;es>0?(l=this,et=c):(l=c,et=this);for(var ec=0,el=0;el>26,this.words[el]=67108863&eo;for(;0!==ec&&el>26,this.words[el]=67108863&eo;if(0===ec&&el>>13,eb=0|el[1],ey=8191&eb,e_=eb>>>13,ew=0|el[2],eE=8191&ew,eS=ew>>>13,ex=0|el[3],ek=8191&ex,eC=ex>>>13,eA=0|el[4],eI=8191&eA,eP=eA>>>13,eR=0|el[5],eO=8191&eR,eT=eR>>>13,eN=0|el[6],eM=8191&eN,e$=eN>>>13,eB=0|el[7],eD=8191&eB,ej=eB>>>13,eL=0|el[8],eF=8191&eL,eU=eL>>>13,ez=0|el[9],eH=8191&ez,eW=ez>>>13,eV=0|ed[0],eG=8191&eV,eK=eV>>>13,eJ=0|ed[1],eQ=8191&eJ,eY=eJ>>>13,eZ=0|ed[2],eX=8191&eZ,e0=eZ>>>13,e1=0|ed[3],e2=8191&e1,e3=e1>>>13,e5=0|ed[4],e6=8191&e5,e4=e5>>>13,e8=0|ed[5],e9=8191&e8,e7=e8>>>13,tn=0|ed[6],to=8191&tn,ts=tn>>>13,ta=0|ed[7],tc=8191&ta,tl=ta>>>13,td=0|ed[8],th=8191&td,tf=td>>>13,tp=0|ed[9],tg=8191&tp,tm=tp>>>13;et.negative=c.negative^l.negative,et.length=19;var tb=(ef+(eo=Math.imul(eg,eG))|0)+((8191&(es=(es=Math.imul(eg,eK))+Math.imul(em,eG)|0))<<13)|0;ef=((ec=Math.imul(em,eK))+(es>>>13)|0)+(tb>>>26)|0,tb&=67108863,eo=Math.imul(ey,eG),es=(es=Math.imul(ey,eK))+Math.imul(e_,eG)|0,ec=Math.imul(e_,eK);var ty=(ef+(eo=eo+Math.imul(eg,eQ)|0)|0)+((8191&(es=(es=es+Math.imul(eg,eY)|0)+Math.imul(em,eQ)|0))<<13)|0;ef=((ec=ec+Math.imul(em,eY)|0)+(es>>>13)|0)+(ty>>>26)|0,ty&=67108863,eo=Math.imul(eE,eG),es=(es=Math.imul(eE,eK))+Math.imul(eS,eG)|0,ec=Math.imul(eS,eK),eo=eo+Math.imul(ey,eQ)|0,es=(es=es+Math.imul(ey,eY)|0)+Math.imul(e_,eQ)|0,ec=ec+Math.imul(e_,eY)|0;var t_=(ef+(eo=eo+Math.imul(eg,eX)|0)|0)+((8191&(es=(es=es+Math.imul(eg,e0)|0)+Math.imul(em,eX)|0))<<13)|0;ef=((ec=ec+Math.imul(em,e0)|0)+(es>>>13)|0)+(t_>>>26)|0,t_&=67108863,eo=Math.imul(ek,eG),es=(es=Math.imul(ek,eK))+Math.imul(eC,eG)|0,ec=Math.imul(eC,eK),eo=eo+Math.imul(eE,eQ)|0,es=(es=es+Math.imul(eE,eY)|0)+Math.imul(eS,eQ)|0,ec=ec+Math.imul(eS,eY)|0,eo=eo+Math.imul(ey,eX)|0,es=(es=es+Math.imul(ey,e0)|0)+Math.imul(e_,eX)|0,ec=ec+Math.imul(e_,e0)|0;var tw=(ef+(eo=eo+Math.imul(eg,e2)|0)|0)+((8191&(es=(es=es+Math.imul(eg,e3)|0)+Math.imul(em,e2)|0))<<13)|0;ef=((ec=ec+Math.imul(em,e3)|0)+(es>>>13)|0)+(tw>>>26)|0,tw&=67108863,eo=Math.imul(eI,eG),es=(es=Math.imul(eI,eK))+Math.imul(eP,eG)|0,ec=Math.imul(eP,eK),eo=eo+Math.imul(ek,eQ)|0,es=(es=es+Math.imul(ek,eY)|0)+Math.imul(eC,eQ)|0,ec=ec+Math.imul(eC,eY)|0,eo=eo+Math.imul(eE,eX)|0,es=(es=es+Math.imul(eE,e0)|0)+Math.imul(eS,eX)|0,ec=ec+Math.imul(eS,e0)|0,eo=eo+Math.imul(ey,e2)|0,es=(es=es+Math.imul(ey,e3)|0)+Math.imul(e_,e2)|0,ec=ec+Math.imul(e_,e3)|0;var tE=(ef+(eo=eo+Math.imul(eg,e6)|0)|0)+((8191&(es=(es=es+Math.imul(eg,e4)|0)+Math.imul(em,e6)|0))<<13)|0;ef=((ec=ec+Math.imul(em,e4)|0)+(es>>>13)|0)+(tE>>>26)|0,tE&=67108863,eo=Math.imul(eO,eG),es=(es=Math.imul(eO,eK))+Math.imul(eT,eG)|0,ec=Math.imul(eT,eK),eo=eo+Math.imul(eI,eQ)|0,es=(es=es+Math.imul(eI,eY)|0)+Math.imul(eP,eQ)|0,ec=ec+Math.imul(eP,eY)|0,eo=eo+Math.imul(ek,eX)|0,es=(es=es+Math.imul(ek,e0)|0)+Math.imul(eC,eX)|0,ec=ec+Math.imul(eC,e0)|0,eo=eo+Math.imul(eE,e2)|0,es=(es=es+Math.imul(eE,e3)|0)+Math.imul(eS,e2)|0,ec=ec+Math.imul(eS,e3)|0,eo=eo+Math.imul(ey,e6)|0,es=(es=es+Math.imul(ey,e4)|0)+Math.imul(e_,e6)|0,ec=ec+Math.imul(e_,e4)|0;var tS=(ef+(eo=eo+Math.imul(eg,e9)|0)|0)+((8191&(es=(es=es+Math.imul(eg,e7)|0)+Math.imul(em,e9)|0))<<13)|0;ef=((ec=ec+Math.imul(em,e7)|0)+(es>>>13)|0)+(tS>>>26)|0,tS&=67108863,eo=Math.imul(eM,eG),es=(es=Math.imul(eM,eK))+Math.imul(e$,eG)|0,ec=Math.imul(e$,eK),eo=eo+Math.imul(eO,eQ)|0,es=(es=es+Math.imul(eO,eY)|0)+Math.imul(eT,eQ)|0,ec=ec+Math.imul(eT,eY)|0,eo=eo+Math.imul(eI,eX)|0,es=(es=es+Math.imul(eI,e0)|0)+Math.imul(eP,eX)|0,ec=ec+Math.imul(eP,e0)|0,eo=eo+Math.imul(ek,e2)|0,es=(es=es+Math.imul(ek,e3)|0)+Math.imul(eC,e2)|0,ec=ec+Math.imul(eC,e3)|0,eo=eo+Math.imul(eE,e6)|0,es=(es=es+Math.imul(eE,e4)|0)+Math.imul(eS,e6)|0,ec=ec+Math.imul(eS,e4)|0,eo=eo+Math.imul(ey,e9)|0,es=(es=es+Math.imul(ey,e7)|0)+Math.imul(e_,e9)|0,ec=ec+Math.imul(e_,e7)|0;var tx=(ef+(eo=eo+Math.imul(eg,to)|0)|0)+((8191&(es=(es=es+Math.imul(eg,ts)|0)+Math.imul(em,to)|0))<<13)|0;ef=((ec=ec+Math.imul(em,ts)|0)+(es>>>13)|0)+(tx>>>26)|0,tx&=67108863,eo=Math.imul(eD,eG),es=(es=Math.imul(eD,eK))+Math.imul(ej,eG)|0,ec=Math.imul(ej,eK),eo=eo+Math.imul(eM,eQ)|0,es=(es=es+Math.imul(eM,eY)|0)+Math.imul(e$,eQ)|0,ec=ec+Math.imul(e$,eY)|0,eo=eo+Math.imul(eO,eX)|0,es=(es=es+Math.imul(eO,e0)|0)+Math.imul(eT,eX)|0,ec=ec+Math.imul(eT,e0)|0,eo=eo+Math.imul(eI,e2)|0,es=(es=es+Math.imul(eI,e3)|0)+Math.imul(eP,e2)|0,ec=ec+Math.imul(eP,e3)|0,eo=eo+Math.imul(ek,e6)|0,es=(es=es+Math.imul(ek,e4)|0)+Math.imul(eC,e6)|0,ec=ec+Math.imul(eC,e4)|0,eo=eo+Math.imul(eE,e9)|0,es=(es=es+Math.imul(eE,e7)|0)+Math.imul(eS,e9)|0,ec=ec+Math.imul(eS,e7)|0,eo=eo+Math.imul(ey,to)|0,es=(es=es+Math.imul(ey,ts)|0)+Math.imul(e_,to)|0,ec=ec+Math.imul(e_,ts)|0;var tk=(ef+(eo=eo+Math.imul(eg,tc)|0)|0)+((8191&(es=(es=es+Math.imul(eg,tl)|0)+Math.imul(em,tc)|0))<<13)|0;ef=((ec=ec+Math.imul(em,tl)|0)+(es>>>13)|0)+(tk>>>26)|0,tk&=67108863,eo=Math.imul(eF,eG),es=(es=Math.imul(eF,eK))+Math.imul(eU,eG)|0,ec=Math.imul(eU,eK),eo=eo+Math.imul(eD,eQ)|0,es=(es=es+Math.imul(eD,eY)|0)+Math.imul(ej,eQ)|0,ec=ec+Math.imul(ej,eY)|0,eo=eo+Math.imul(eM,eX)|0,es=(es=es+Math.imul(eM,e0)|0)+Math.imul(e$,eX)|0,ec=ec+Math.imul(e$,e0)|0,eo=eo+Math.imul(eO,e2)|0,es=(es=es+Math.imul(eO,e3)|0)+Math.imul(eT,e2)|0,ec=ec+Math.imul(eT,e3)|0,eo=eo+Math.imul(eI,e6)|0,es=(es=es+Math.imul(eI,e4)|0)+Math.imul(eP,e6)|0,ec=ec+Math.imul(eP,e4)|0,eo=eo+Math.imul(ek,e9)|0,es=(es=es+Math.imul(ek,e7)|0)+Math.imul(eC,e9)|0,ec=ec+Math.imul(eC,e7)|0,eo=eo+Math.imul(eE,to)|0,es=(es=es+Math.imul(eE,ts)|0)+Math.imul(eS,to)|0,ec=ec+Math.imul(eS,ts)|0,eo=eo+Math.imul(ey,tc)|0,es=(es=es+Math.imul(ey,tl)|0)+Math.imul(e_,tc)|0,ec=ec+Math.imul(e_,tl)|0;var tC=(ef+(eo=eo+Math.imul(eg,th)|0)|0)+((8191&(es=(es=es+Math.imul(eg,tf)|0)+Math.imul(em,th)|0))<<13)|0;ef=((ec=ec+Math.imul(em,tf)|0)+(es>>>13)|0)+(tC>>>26)|0,tC&=67108863,eo=Math.imul(eH,eG),es=(es=Math.imul(eH,eK))+Math.imul(eW,eG)|0,ec=Math.imul(eW,eK),eo=eo+Math.imul(eF,eQ)|0,es=(es=es+Math.imul(eF,eY)|0)+Math.imul(eU,eQ)|0,ec=ec+Math.imul(eU,eY)|0,eo=eo+Math.imul(eD,eX)|0,es=(es=es+Math.imul(eD,e0)|0)+Math.imul(ej,eX)|0,ec=ec+Math.imul(ej,e0)|0,eo=eo+Math.imul(eM,e2)|0,es=(es=es+Math.imul(eM,e3)|0)+Math.imul(e$,e2)|0,ec=ec+Math.imul(e$,e3)|0,eo=eo+Math.imul(eO,e6)|0,es=(es=es+Math.imul(eO,e4)|0)+Math.imul(eT,e6)|0,ec=ec+Math.imul(eT,e4)|0,eo=eo+Math.imul(eI,e9)|0,es=(es=es+Math.imul(eI,e7)|0)+Math.imul(eP,e9)|0,ec=ec+Math.imul(eP,e7)|0,eo=eo+Math.imul(ek,to)|0,es=(es=es+Math.imul(ek,ts)|0)+Math.imul(eC,to)|0,ec=ec+Math.imul(eC,ts)|0,eo=eo+Math.imul(eE,tc)|0,es=(es=es+Math.imul(eE,tl)|0)+Math.imul(eS,tc)|0,ec=ec+Math.imul(eS,tl)|0,eo=eo+Math.imul(ey,th)|0,es=(es=es+Math.imul(ey,tf)|0)+Math.imul(e_,th)|0,ec=ec+Math.imul(e_,tf)|0;var tA=(ef+(eo=eo+Math.imul(eg,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eg,tm)|0)+Math.imul(em,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(em,tm)|0)+(es>>>13)|0)+(tA>>>26)|0,tA&=67108863,eo=Math.imul(eH,eQ),es=(es=Math.imul(eH,eY))+Math.imul(eW,eQ)|0,ec=Math.imul(eW,eY),eo=eo+Math.imul(eF,eX)|0,es=(es=es+Math.imul(eF,e0)|0)+Math.imul(eU,eX)|0,ec=ec+Math.imul(eU,e0)|0,eo=eo+Math.imul(eD,e2)|0,es=(es=es+Math.imul(eD,e3)|0)+Math.imul(ej,e2)|0,ec=ec+Math.imul(ej,e3)|0,eo=eo+Math.imul(eM,e6)|0,es=(es=es+Math.imul(eM,e4)|0)+Math.imul(e$,e6)|0,ec=ec+Math.imul(e$,e4)|0,eo=eo+Math.imul(eO,e9)|0,es=(es=es+Math.imul(eO,e7)|0)+Math.imul(eT,e9)|0,ec=ec+Math.imul(eT,e7)|0,eo=eo+Math.imul(eI,to)|0,es=(es=es+Math.imul(eI,ts)|0)+Math.imul(eP,to)|0,ec=ec+Math.imul(eP,ts)|0,eo=eo+Math.imul(ek,tc)|0,es=(es=es+Math.imul(ek,tl)|0)+Math.imul(eC,tc)|0,ec=ec+Math.imul(eC,tl)|0,eo=eo+Math.imul(eE,th)|0,es=(es=es+Math.imul(eE,tf)|0)+Math.imul(eS,th)|0,ec=ec+Math.imul(eS,tf)|0;var tI=(ef+(eo=eo+Math.imul(ey,tg)|0)|0)+((8191&(es=(es=es+Math.imul(ey,tm)|0)+Math.imul(e_,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(e_,tm)|0)+(es>>>13)|0)+(tI>>>26)|0,tI&=67108863,eo=Math.imul(eH,eX),es=(es=Math.imul(eH,e0))+Math.imul(eW,eX)|0,ec=Math.imul(eW,e0),eo=eo+Math.imul(eF,e2)|0,es=(es=es+Math.imul(eF,e3)|0)+Math.imul(eU,e2)|0,ec=ec+Math.imul(eU,e3)|0,eo=eo+Math.imul(eD,e6)|0,es=(es=es+Math.imul(eD,e4)|0)+Math.imul(ej,e6)|0,ec=ec+Math.imul(ej,e4)|0,eo=eo+Math.imul(eM,e9)|0,es=(es=es+Math.imul(eM,e7)|0)+Math.imul(e$,e9)|0,ec=ec+Math.imul(e$,e7)|0,eo=eo+Math.imul(eO,to)|0,es=(es=es+Math.imul(eO,ts)|0)+Math.imul(eT,to)|0,ec=ec+Math.imul(eT,ts)|0,eo=eo+Math.imul(eI,tc)|0,es=(es=es+Math.imul(eI,tl)|0)+Math.imul(eP,tc)|0,ec=ec+Math.imul(eP,tl)|0,eo=eo+Math.imul(ek,th)|0,es=(es=es+Math.imul(ek,tf)|0)+Math.imul(eC,th)|0,ec=ec+Math.imul(eC,tf)|0;var tP=(ef+(eo=eo+Math.imul(eE,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eE,tm)|0)+Math.imul(eS,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(eS,tm)|0)+(es>>>13)|0)+(tP>>>26)|0,tP&=67108863,eo=Math.imul(eH,e2),es=(es=Math.imul(eH,e3))+Math.imul(eW,e2)|0,ec=Math.imul(eW,e3),eo=eo+Math.imul(eF,e6)|0,es=(es=es+Math.imul(eF,e4)|0)+Math.imul(eU,e6)|0,ec=ec+Math.imul(eU,e4)|0,eo=eo+Math.imul(eD,e9)|0,es=(es=es+Math.imul(eD,e7)|0)+Math.imul(ej,e9)|0,ec=ec+Math.imul(ej,e7)|0,eo=eo+Math.imul(eM,to)|0,es=(es=es+Math.imul(eM,ts)|0)+Math.imul(e$,to)|0,ec=ec+Math.imul(e$,ts)|0,eo=eo+Math.imul(eO,tc)|0,es=(es=es+Math.imul(eO,tl)|0)+Math.imul(eT,tc)|0,ec=ec+Math.imul(eT,tl)|0,eo=eo+Math.imul(eI,th)|0,es=(es=es+Math.imul(eI,tf)|0)+Math.imul(eP,th)|0,ec=ec+Math.imul(eP,tf)|0;var tR=(ef+(eo=eo+Math.imul(ek,tg)|0)|0)+((8191&(es=(es=es+Math.imul(ek,tm)|0)+Math.imul(eC,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(eC,tm)|0)+(es>>>13)|0)+(tR>>>26)|0,tR&=67108863,eo=Math.imul(eH,e6),es=(es=Math.imul(eH,e4))+Math.imul(eW,e6)|0,ec=Math.imul(eW,e4),eo=eo+Math.imul(eF,e9)|0,es=(es=es+Math.imul(eF,e7)|0)+Math.imul(eU,e9)|0,ec=ec+Math.imul(eU,e7)|0,eo=eo+Math.imul(eD,to)|0,es=(es=es+Math.imul(eD,ts)|0)+Math.imul(ej,to)|0,ec=ec+Math.imul(ej,ts)|0,eo=eo+Math.imul(eM,tc)|0,es=(es=es+Math.imul(eM,tl)|0)+Math.imul(e$,tc)|0,ec=ec+Math.imul(e$,tl)|0,eo=eo+Math.imul(eO,th)|0,es=(es=es+Math.imul(eO,tf)|0)+Math.imul(eT,th)|0,ec=ec+Math.imul(eT,tf)|0;var tO=(ef+(eo=eo+Math.imul(eI,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eI,tm)|0)+Math.imul(eP,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(eP,tm)|0)+(es>>>13)|0)+(tO>>>26)|0,tO&=67108863,eo=Math.imul(eH,e9),es=(es=Math.imul(eH,e7))+Math.imul(eW,e9)|0,ec=Math.imul(eW,e7),eo=eo+Math.imul(eF,to)|0,es=(es=es+Math.imul(eF,ts)|0)+Math.imul(eU,to)|0,ec=ec+Math.imul(eU,ts)|0,eo=eo+Math.imul(eD,tc)|0,es=(es=es+Math.imul(eD,tl)|0)+Math.imul(ej,tc)|0,ec=ec+Math.imul(ej,tl)|0,eo=eo+Math.imul(eM,th)|0,es=(es=es+Math.imul(eM,tf)|0)+Math.imul(e$,th)|0,ec=ec+Math.imul(e$,tf)|0;var tT=(ef+(eo=eo+Math.imul(eO,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eO,tm)|0)+Math.imul(eT,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(eT,tm)|0)+(es>>>13)|0)+(tT>>>26)|0,tT&=67108863,eo=Math.imul(eH,to),es=(es=Math.imul(eH,ts))+Math.imul(eW,to)|0,ec=Math.imul(eW,ts),eo=eo+Math.imul(eF,tc)|0,es=(es=es+Math.imul(eF,tl)|0)+Math.imul(eU,tc)|0,ec=ec+Math.imul(eU,tl)|0,eo=eo+Math.imul(eD,th)|0,es=(es=es+Math.imul(eD,tf)|0)+Math.imul(ej,th)|0,ec=ec+Math.imul(ej,tf)|0;var tN=(ef+(eo=eo+Math.imul(eM,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eM,tm)|0)+Math.imul(e$,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(e$,tm)|0)+(es>>>13)|0)+(tN>>>26)|0,tN&=67108863,eo=Math.imul(eH,tc),es=(es=Math.imul(eH,tl))+Math.imul(eW,tc)|0,ec=Math.imul(eW,tl),eo=eo+Math.imul(eF,th)|0,es=(es=es+Math.imul(eF,tf)|0)+Math.imul(eU,th)|0,ec=ec+Math.imul(eU,tf)|0;var tM=(ef+(eo=eo+Math.imul(eD,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eD,tm)|0)+Math.imul(ej,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(ej,tm)|0)+(es>>>13)|0)+(tM>>>26)|0,tM&=67108863,eo=Math.imul(eH,th),es=(es=Math.imul(eH,tf))+Math.imul(eW,th)|0,ec=Math.imul(eW,tf);var t$=(ef+(eo=eo+Math.imul(eF,tg)|0)|0)+((8191&(es=(es=es+Math.imul(eF,tm)|0)+Math.imul(eU,tg)|0))<<13)|0;ef=((ec=ec+Math.imul(eU,tm)|0)+(es>>>13)|0)+(t$>>>26)|0,t$&=67108863;var tB=(ef+(eo=Math.imul(eH,tg))|0)+((8191&(es=(es=Math.imul(eH,tm))+Math.imul(eW,tg)|0))<<13)|0;return ef=((ec=Math.imul(eW,tm))+(es>>>13)|0)+(tB>>>26)|0,tB&=67108863,eh[0]=tb,eh[1]=ty,eh[2]=t_,eh[3]=tw,eh[4]=tE,eh[5]=tS,eh[6]=tx,eh[7]=tk,eh[8]=tC,eh[9]=tA,eh[10]=tI,eh[11]=tP,eh[12]=tR,eh[13]=tO,eh[14]=tT,eh[15]=tN,eh[16]=tM,eh[17]=t$,eh[18]=tB,0!==ef&&(eh[19]=ef,et.length++),et};function bigMulTo(c,l,et){et.negative=l.negative^c.negative,et.length=c.length+l.length;for(var eo=0,es=0,ec=0;ec>>26)|0)>>>26,el&=67108863}et.words[ec]=ed,eo=el,el=es}return 0!==eo?et.words[ec]=eo:et.length--,et._strip()}function FFTM(c,l){this.x=c,this.y=l}Math.imul||(comb10MulTo=smallMulTo),BN.prototype.mulTo=function(c,l){var et,eo=this.length+c.length;return 10===this.length&&10===c.length?comb10MulTo(this,c,l):eo<63?smallMulTo(this,c,l):bigMulTo(this,c,l)},FFTM.prototype.makeRBT=function(c){for(var l=Array(c),et=BN.prototype._countBits(c)-1,eo=0;eo>=1;return eo},FFTM.prototype.permute=function(c,l,et,eo,es,ec){for(var el=0;el>>=1)es++;return 1<>>=13,et[2*ec+1]=8191&es,es>>>=13;for(ec=2*l;ec>=26,et+=(es/67108864|0)+(ec>>>26),this.words[eo]=67108863&ec}return 0!==et&&(this.words[eo]=et,this.length++),l?this.ineg():this},BN.prototype.muln=function(c){return this.clone().imuln(c)},BN.prototype.sqr=function(){return this.mul(this)},BN.prototype.isqr=function(){return this.imul(this.clone())},BN.prototype.pow=function(c){var l=function(c){for(var l=Array(c.bitLength()),et=0;et>>es&1}return l}(c);if(0===l.length)return new BN(1);for(var et=this,eo=0;eo=0);var l,et=c%26,eo=(c-et)/26,es=67108863>>>26-et<<26-et;if(0!==et){var ec=0;for(l=0;l>>26-et}ec&&(this.words[l]=ec,this.length++)}if(0!==eo){for(l=this.length-1;l>=0;l--)this.words[l+eo]=this.words[l];for(l=0;l=0),eo=l?(l-l%26)/26:0;var eo,es=c%26,ec=Math.min((c-es)/26,this.length),el=67108863^67108863>>>es<ec)for(this.length-=ec,ed=0;ed=0&&(0!==eh||ed>=eo);ed--){var ef=0|this.words[ed];this.words[ed]=eh<<26-es|ef>>>es,eh=ef&el}return et&&0!==eh&&(et.words[et.length++]=eh),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},BN.prototype.ishrn=function(c,l,et){return assert(0===this.negative),this.iushrn(c,l,et)},BN.prototype.shln=function(c){return this.clone().ishln(c)},BN.prototype.ushln=function(c){return this.clone().iushln(c)},BN.prototype.shrn=function(c){return this.clone().ishrn(c)},BN.prototype.ushrn=function(c){return this.clone().iushrn(c)},BN.prototype.testn=function(c){assert("number"==typeof c&&c>=0);var l=c%26,et=(c-l)/26;return!(this.length<=et)&&!!(this.words[et]&1<=0);var l=c%26,et=(c-l)/26;return(assert(0===this.negative,"imaskn works only with positive numbers"),this.length<=et)?this:(0!==l&&et++,this.length=Math.min(et,this.length),0!==l&&(this.words[this.length-1]&=67108863^67108863>>>l<=67108864;l++)this.words[l]-=67108864,l===this.length-1?this.words[l+1]=1:this.words[l+1]++;return this.length=Math.max(this.length,l+1),this},BN.prototype.isubn=function(c){if(assert("number"==typeof c),assert(c<67108864),c<0)return this.iaddn(-c);if(0!==this.negative)return this.negative=0,this.iaddn(c),this.negative=1,this;if(this.words[0]-=c,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var l=0;l>26)-(ed/67108864|0),this.words[eo+et]=67108863&es}for(;eo>26,this.words[eo+et]=67108863&es;if(0===el)return this._strip();for(assert(-1===el),el=0,eo=0;eo>26,this.words[eo]=67108863&es;return this.negative=1,this._strip()},BN.prototype._wordDiv=function(c,l){var et,eo=this.length-c.length,es=this.clone(),ec=c,el=0|ec.words[ec.length-1];0!=(eo=26-this._countBits(el))&&(ec=ec.ushln(eo),es.iushln(eo),el=0|ec.words[ec.length-1]);var ed=es.length-ec.length;if("mod"!==l){(et=new BN(null)).length=ed+1,et.words=Array(et.length);for(var eh=0;eh=0;ep--){var eg=(0|es.words[ec.length+ep])*67108864+(0|es.words[ec.length+ep-1]);for(eg=Math.min(eg/el|0,67108863),es._ishlnsubmul(ec,eg,ep);0!==es.negative;)eg--,es.negative=0,es._ishlnsubmul(ec,1,ep),es.isZero()||(es.negative^=1);et&&(et.words[ep]=eg)}return et&&et._strip(),es._strip(),"div"!==l&&0!==eo&&es.iushrn(eo),{div:et||null,mod:es}},BN.prototype.divmod=function(c,l,et){var eo,es,ec;return(assert(!c.isZero()),this.isZero())?{div:new BN(0),mod:new BN(0)}:0!==this.negative&&0===c.negative?(ec=this.neg().divmod(c,l),"mod"!==l&&(eo=ec.div.neg()),"div"!==l&&(es=ec.mod.neg(),et&&0!==es.negative&&es.iadd(c)),{div:eo,mod:es}):0===this.negative&&0!==c.negative?(ec=this.divmod(c.neg(),l),"mod"!==l&&(eo=ec.div.neg()),{div:eo,mod:ec.mod}):(this.negative&c.negative)!=0?(ec=this.neg().divmod(c.neg(),l),"div"!==l&&(es=ec.mod.neg(),et&&0!==es.negative&&es.isub(c)),{div:ec.div,mod:es}):c.length>this.length||0>this.cmp(c)?{div:new BN(0),mod:this}:1===c.length?"div"===l?{div:this.divn(c.words[0]),mod:null}:"mod"===l?{div:null,mod:new BN(this.modrn(c.words[0]))}:{div:this.divn(c.words[0]),mod:new BN(this.modrn(c.words[0]))}:this._wordDiv(c,l)},BN.prototype.div=function(c){return this.divmod(c,"div",!1).div},BN.prototype.mod=function(c){return this.divmod(c,"mod",!1).mod},BN.prototype.umod=function(c){return this.divmod(c,"mod",!0).mod},BN.prototype.divRound=function(c){var l=this.divmod(c);if(l.mod.isZero())return l.div;var et=0!==l.div.negative?l.mod.isub(c):l.mod,eo=c.ushrn(1),es=c.andln(1),ec=et.cmp(eo);return ec<0||1===es&&0===ec?l.div:0!==l.div.negative?l.div.isubn(1):l.div.iaddn(1)},BN.prototype.modrn=function(c){var l=c<0;l&&(c=-c),assert(c<=67108863);for(var et=67108864%c,eo=0,es=this.length-1;es>=0;es--)eo=(et*eo+(0|this.words[es]))%c;return l?-eo:eo},BN.prototype.modn=function(c){return this.modrn(c)},BN.prototype.idivn=function(c){var l=c<0;l&&(c=-c),assert(c<=67108863);for(var et=0,eo=this.length-1;eo>=0;eo--){var es=(0|this.words[eo])+67108864*et;this.words[eo]=es/c|0,et=es%c}return this._strip(),l?this.ineg():this},BN.prototype.divn=function(c){return this.clone().idivn(c)},BN.prototype.egcd=function(c){assert(0===c.negative),assert(!c.isZero());var l=this,et=c.clone();l=0!==l.negative?l.umod(c):l.clone();for(var eo=new BN(1),es=new BN(0),ec=new BN(0),el=new BN(1),ed=0;l.isEven()&&et.isEven();)l.iushrn(1),et.iushrn(1),++ed;for(var eh=et.clone(),ef=l.clone();!l.isZero();){for(var ep=0,eg=1;(l.words[0]&eg)==0&&ep<26;++ep,eg<<=1);if(ep>0)for(l.iushrn(ep);ep-- >0;)(eo.isOdd()||es.isOdd())&&(eo.iadd(eh),es.isub(ef)),eo.iushrn(1),es.iushrn(1);for(var em=0,eb=1;(et.words[0]&eb)==0&&em<26;++em,eb<<=1);if(em>0)for(et.iushrn(em);em-- >0;)(ec.isOdd()||el.isOdd())&&(ec.iadd(eh),el.isub(ef)),ec.iushrn(1),el.iushrn(1);l.cmp(et)>=0?(l.isub(et),eo.isub(ec),es.isub(el)):(et.isub(l),ec.isub(eo),el.isub(es))}return{a:ec,b:el,gcd:et.iushln(ed)}},BN.prototype._invmp=function(c){assert(0===c.negative),assert(!c.isZero());var l,et=this,eo=c.clone();et=0!==et.negative?et.umod(c):et.clone();for(var es=new BN(1),ec=new BN(0),el=eo.clone();et.cmpn(1)>0&&eo.cmpn(1)>0;){for(var ed=0,eh=1;(et.words[0]&eh)==0&&ed<26;++ed,eh<<=1);if(ed>0)for(et.iushrn(ed);ed-- >0;)es.isOdd()&&es.iadd(el),es.iushrn(1);for(var ef=0,ep=1;(eo.words[0]&ep)==0&&ef<26;++ef,ep<<=1);if(ef>0)for(eo.iushrn(ef);ef-- >0;)ec.isOdd()&&ec.iadd(el),ec.iushrn(1);et.cmp(eo)>=0?(et.isub(eo),es.isub(ec)):(eo.isub(et),ec.isub(es))}return 0>(l=0===et.cmpn(1)?es:ec).cmpn(0)&&l.iadd(c),l},BN.prototype.gcd=function(c){if(this.isZero())return c.abs();if(c.isZero())return this.abs();var l=this.clone(),et=c.clone();l.negative=0,et.negative=0;for(var eo=0;l.isEven()&&et.isEven();eo++)l.iushrn(1),et.iushrn(1);for(;;){for(;l.isEven();)l.iushrn(1);for(;et.isEven();)et.iushrn(1);var es=l.cmp(et);if(es<0){var ec=l;l=et,et=ec}else if(0===es||0===et.cmpn(1))break;l.isub(et)}return et.iushln(eo)},BN.prototype.invm=function(c){return this.egcd(c).a.umod(c)},BN.prototype.isEven=function(){return(1&this.words[0])==0},BN.prototype.isOdd=function(){return(1&this.words[0])==1},BN.prototype.andln=function(c){return this.words[0]&c},BN.prototype.bincn=function(c){assert("number"==typeof c);var l=c%26,et=(c-l)/26,eo=1<>>26,el&=67108863,this.words[ec]=el}return 0!==es&&(this.words[ec]=es,this.length++),this},BN.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},BN.prototype.cmpn=function(c){var l,et=c<0;if(0!==this.negative&&!et)return -1;if(0===this.negative&&et)return 1;if(this._strip(),this.length>1)l=1;else{et&&(c=-c),assert(c<=67108863,"Number is too big");var eo=0|this.words[0];l=eo===c?0:eoc.length)return 1;if(this.length=0;et--){var eo=0|this.words[et],es=0|c.words[et];if(eo!==es){eoes&&(l=1);break}}return l},BN.prototype.gtn=function(c){return 1===this.cmpn(c)},BN.prototype.gt=function(c){return 1===this.cmp(c)},BN.prototype.gten=function(c){return this.cmpn(c)>=0},BN.prototype.gte=function(c){return this.cmp(c)>=0},BN.prototype.ltn=function(c){return -1===this.cmpn(c)},BN.prototype.lt=function(c){return -1===this.cmp(c)},BN.prototype.lten=function(c){return 0>=this.cmpn(c)},BN.prototype.lte=function(c){return 0>=this.cmp(c)},BN.prototype.eqn=function(c){return 0===this.cmpn(c)},BN.prototype.eq=function(c){return 0===this.cmp(c)},BN.red=function(c){return new Red(c)},BN.prototype.toRed=function(c){return assert(!this.red,"Already a number in reduction context"),assert(0===this.negative,"red works only with positives"),c.convertTo(this)._forceRed(c)},BN.prototype.fromRed=function(){return assert(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},BN.prototype._forceRed=function(c){return this.red=c,this},BN.prototype.forceRed=function(c){return assert(!this.red,"Already a number in reduction context"),this._forceRed(c)},BN.prototype.redAdd=function(c){return assert(this.red,"redAdd works only with red numbers"),this.red.add(this,c)},BN.prototype.redIAdd=function(c){return assert(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,c)},BN.prototype.redSub=function(c){return assert(this.red,"redSub works only with red numbers"),this.red.sub(this,c)},BN.prototype.redISub=function(c){return assert(this.red,"redISub works only with red numbers"),this.red.isub(this,c)},BN.prototype.redShl=function(c){return assert(this.red,"redShl works only with red numbers"),this.red.shl(this,c)},BN.prototype.redMul=function(c){return assert(this.red,"redMul works only with red numbers"),this.red._verify2(this,c),this.red.mul(this,c)},BN.prototype.redIMul=function(c){return assert(this.red,"redMul works only with red numbers"),this.red._verify2(this,c),this.red.imul(this,c)},BN.prototype.redSqr=function(){return assert(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},BN.prototype.redISqr=function(){return assert(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},BN.prototype.redSqrt=function(){return assert(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},BN.prototype.redInvm=function(){return assert(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},BN.prototype.redNeg=function(){return assert(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},BN.prototype.redPow=function(c){return assert(this.red&&!c.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,c)};var ed={k256:null,p224:null,p192:null,p25519:null};function MPrime(c,l){this.name=c,this.p=new BN(l,16),this.n=this.p.bitLength(),this.k=new BN(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function K256(){MPrime.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function P224(){MPrime.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function P192(){MPrime.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function P25519(){MPrime.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function Red(c){if("string"==typeof c){var l=BN._prime(c);this.m=l.p,this.prime=l}else assert(c.gtn(1),"modulus must be greater than 1"),this.m=c,this.prime=null}function Mont(c){Red.call(this,c),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new BN(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}MPrime.prototype._tmp=function(){var c=new BN(null);return c.words=Array(Math.ceil(this.n/13)),c},MPrime.prototype.ireduce=function(c){var l,et=c;do this.split(et,this.tmp),l=(et=(et=this.imulK(et)).iadd(this.tmp)).bitLength();while(l>this.n);var eo=l0?et.isub(this.p):void 0!==et.strip?et.strip():et._strip(),et},MPrime.prototype.split=function(c,l){c.iushrn(this.n,0,l)},MPrime.prototype.imulK=function(c){return c.imul(this.k)},inherits(K256,MPrime),K256.prototype.split=function(c,l){for(var et=Math.min(c.length,9),eo=0;eo>>22,es=ec}es>>>=22,c.words[eo-10]=es,0===es&&c.length>10?c.length-=10:c.length-=9},K256.prototype.imulK=function(c){c.words[c.length]=0,c.words[c.length+1]=0,c.length+=2;for(var l=0,et=0;et>>=26,c.words[et]=es,l=eo}return 0!==l&&(c.words[c.length++]=l),c},BN._prime=function(c){var l;if(ed[c])return ed[c];if("k256"===c)l=new K256;else if("p224"===c)l=new P224;else if("p192"===c)l=new P192;else if("p25519"===c)l=new P25519;else throw Error("Unknown prime "+c);return ed[c]=l,l},Red.prototype._verify1=function(c){assert(0===c.negative,"red works only with positives"),assert(c.red,"red works only with red numbers")},Red.prototype._verify2=function(c,l){assert((c.negative|l.negative)==0,"red works only with positives"),assert(c.red&&c.red===l.red,"red works only with red numbers")},Red.prototype.imod=function(c){return this.prime?this.prime.ireduce(c)._forceRed(this):(move(c,c.umod(this.m)._forceRed(this)),c)},Red.prototype.neg=function(c){return c.isZero()?c.clone():this.m.sub(c)._forceRed(this)},Red.prototype.add=function(c,l){this._verify2(c,l);var et=c.add(l);return et.cmp(this.m)>=0&&et.isub(this.m),et._forceRed(this)},Red.prototype.iadd=function(c,l){this._verify2(c,l);var et=c.iadd(l);return et.cmp(this.m)>=0&&et.isub(this.m),et},Red.prototype.sub=function(c,l){this._verify2(c,l);var et=c.sub(l);return 0>et.cmpn(0)&&et.iadd(this.m),et._forceRed(this)},Red.prototype.isub=function(c,l){this._verify2(c,l);var et=c.isub(l);return 0>et.cmpn(0)&&et.iadd(this.m),et},Red.prototype.shl=function(c,l){return this._verify1(c),this.imod(c.ushln(l))},Red.prototype.imul=function(c,l){return this._verify2(c,l),this.imod(c.imul(l))},Red.prototype.mul=function(c,l){return this._verify2(c,l),this.imod(c.mul(l))},Red.prototype.isqr=function(c){return this.imul(c,c.clone())},Red.prototype.sqr=function(c){return this.mul(c,c)},Red.prototype.sqrt=function(c){if(c.isZero())return c.clone();var l=this.m.andln(3);if(assert(l%2==1),3===l){var et=this.m.add(new BN(1)).iushrn(2);return this.pow(c,et)}for(var eo=this.m.subn(1),es=0;!eo.isZero()&&0===eo.andln(1);)es++,eo.iushrn(1);assert(!eo.isZero());var ec=new BN(1).toRed(this),el=ec.redNeg(),ed=this.m.subn(1).iushrn(1),eh=this.m.bitLength();for(eh=new BN(2*eh*eh).toRed(this);0!==this.pow(eh,ed).cmp(el);)eh.redIAdd(el);for(var ef=this.pow(eh,eo),ep=this.pow(c,eo.addn(1).iushrn(1)),eg=this.pow(c,eo),em=es;0!==eg.cmp(ec);){for(var eb=eg,ey=0;0!==eb.cmp(ec);ey++)eb=eb.redSqr();assert(ey=0;eo--){for(var eh=l.words[eo],ef=ed-1;ef>=0;ef--){var ep=eh>>ef&1;if(es!==et[0]&&(es=this.sqr(es)),0===ep&&0===ec){el=0;continue}ec<<=1,ec|=ep,(4==++el||0===eo&&0===ef)&&(es=this.mul(es,et[ec]),el=0,ec=0)}ed=26}return es},Red.prototype.convertTo=function(c){var l=c.umod(this.m);return l===c?l.clone():l},Red.prototype.convertFrom=function(c){var l=c.clone();return l.red=null,l},BN.mont=function(c){return new Mont(c)},inherits(Mont,Red),Mont.prototype.convertTo=function(c){return this.imod(c.ushln(this.shift))},Mont.prototype.convertFrom=function(c){var l=this.imod(c.mul(this.rinv));return l.red=null,l},Mont.prototype.imul=function(c,l){if(c.isZero()||l.isZero())return c.words[0]=0,c.length=1,c;var et=c.imul(l),eo=et.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),es=et.isub(eo).iushrn(this.shift),ec=es;return es.cmp(this.m)>=0?ec=es.isub(this.m):0>es.cmpn(0)&&(ec=es.iadd(this.m)),ec._forceRed(this)},Mont.prototype.mul=function(c,l){if(c.isZero()||l.isZero())return new BN(0)._forceRed(this);var et=c.mul(l),eo=et.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),es=et.isub(eo).iushrn(this.shift),ec=es;return es.cmp(this.m)>=0?ec=es.isub(this.m):0>es.cmpn(0)&&(ec=es.iadd(this.m)),ec._forceRed(this)},Mont.prototype.invm=function(c){return this.imod(c._invmp(this.m).mul(this.r2))._forceRed(this)}}(c=et.nmd(c),this)},71725:function(c,l,et){"use strict";et.d(l,{Qp:function(){return disableBodyScroll},tP:function(){return clearAllBodyScrollLocks}});var eo=!1;if("undefined"!=typeof window){var es={get passive(){eo=!0;return}};window.addEventListener("testPassive",null,es),window.removeEventListener("testPassive",null,es)}var ec="undefined"!=typeof window&&window.navigator&&window.navigator.platform&&(/iP(ad|hone|od)/.test(window.navigator.platform)||"MacIntel"===window.navigator.platform&&window.navigator.maxTouchPoints>1),el=[],ed=!1,eh=-1,ef=void 0,ep=void 0,eg=void 0,allowTouchMove=function(c){return el.some(function(l){return!!(l.options.allowTouchMove&&l.options.allowTouchMove(c))})},preventDefault=function(c){var l=c||window.event;return!!allowTouchMove(l.target)||l.touches.length>1||(l.preventDefault&&l.preventDefault(),!1)},setOverflowHidden=function(c){if(void 0===eg){var l=!!c&&!0===c.reserveScrollBarGap,et=window.innerWidth-document.documentElement.clientWidth;if(l&&et>0){var eo=parseInt(window.getComputedStyle(document.body).getPropertyValue("padding-right"),10);eg=document.body.style.paddingRight,document.body.style.paddingRight=eo+et+"px"}}void 0===ef&&(ef=document.body.style.overflow,document.body.style.overflow="hidden")},restoreOverflowSetting=function(){void 0!==eg&&(document.body.style.paddingRight=eg,eg=void 0),void 0!==ef&&(document.body.style.overflow=ef,ef=void 0)},restorePositionSetting=function(){if(void 0!==ep){var c=-parseInt(document.body.style.top,10),l=-parseInt(document.body.style.left,10);document.body.style.position=ep.position,document.body.style.top=ep.top,document.body.style.left=ep.left,window.scrollTo(l,c),ep=void 0}},handleScroll=function(c,l){var et=c.targetTouches[0].clientY-eh;return!allowTouchMove(c.target)&&(l&&0===l.scrollTop&&et>0?preventDefault(c):l&&l.scrollHeight-l.scrollTop<=l.clientHeight&&et<0?preventDefault(c):(c.stopPropagation(),!0))},disableBodyScroll=function(c,l){if(!c){console.error("disableBodyScroll unsuccessful - targetElement must be provided when calling disableBodyScroll on IOS devices.");return}!el.some(function(l){return l.targetElement===c})&&(el=[].concat(function(c){if(!Array.isArray(c))return Array.from(c);for(var l=0,et=Array(c.length);l=eo&&(document.body.style.top=-(l+c))})},300)}}):setOverflowHidden(l),ec&&(c.ontouchstart=function(c){1===c.targetTouches.length&&(eh=c.targetTouches[0].clientY)},c.ontouchmove=function(l){1===l.targetTouches.length&&handleScroll(l,c)},ed||(document.addEventListener("touchmove",preventDefault,eo?{passive:!1}:void 0),ed=!0)))},clearAllBodyScrollLocks=function(){ec&&(el.forEach(function(c){c.targetElement.ontouchstart=null,c.targetElement.ontouchmove=null}),ed&&(document.removeEventListener("touchmove",preventDefault,eo?{passive:!1}:void 0),ed=!1),eh=-1),ec?restorePositionSetting():restoreOverflowSetting(),el=[]}},67133:function(c,l,et){"use strict";/*! + * The buffer module from node.js, for the browser. + * + * @author Feross Aboukhadijeh + * @license MIT + */let eo=et(34699),es=et(19087),ec="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function createBuffer(c){if(c>2147483647)throw RangeError('The value "'+c+'" is invalid for option "size"');let l=new Uint8Array(c);return Object.setPrototypeOf(l,Buffer.prototype),l}function Buffer(c,l,et){if("number"==typeof c){if("string"==typeof l)throw TypeError('The "string" argument must be of type string. Received type number');return allocUnsafe(c)}return from(c,l,et)}function from(c,l,et){if("string"==typeof c)return function(c,l){if(("string"!=typeof l||""===l)&&(l="utf8"),!Buffer.isEncoding(l))throw TypeError("Unknown encoding: "+l);let et=0|byteLength(c,l),eo=createBuffer(et),es=eo.write(c,l);return es!==et&&(eo=eo.slice(0,es)),eo}(c,l);if(ArrayBuffer.isView(c))return function(c){if(isInstance(c,Uint8Array)){let l=new Uint8Array(c);return fromArrayBuffer(l.buffer,l.byteOffset,l.byteLength)}return fromArrayLike(c)}(c);if(null==c)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof c);if(isInstance(c,ArrayBuffer)||c&&isInstance(c.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(isInstance(c,SharedArrayBuffer)||c&&isInstance(c.buffer,SharedArrayBuffer)))return fromArrayBuffer(c,l,et);if("number"==typeof c)throw TypeError('The "value" argument must not be of type number. Received type number');let eo=c.valueOf&&c.valueOf();if(null!=eo&&eo!==c)return Buffer.from(eo,l,et);let es=function(c){var l;if(Buffer.isBuffer(c)){let l=0|checked(c.length),et=createBuffer(l);return 0===et.length||c.copy(et,0,0,l),et}return void 0!==c.length?"number"!=typeof c.length||(l=c.length)!=l?createBuffer(0):fromArrayLike(c):"Buffer"===c.type&&Array.isArray(c.data)?fromArrayLike(c.data):void 0}(c);if(es)return es;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof c[Symbol.toPrimitive])return Buffer.from(c[Symbol.toPrimitive]("string"),l,et);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof c)}function assertSize(c){if("number"!=typeof c)throw TypeError('"size" argument must be of type number');if(c<0)throw RangeError('The value "'+c+'" is invalid for option "size"')}function allocUnsafe(c){return assertSize(c),createBuffer(c<0?0:0|checked(c))}function fromArrayLike(c){let l=c.length<0?0:0|checked(c.length),et=createBuffer(l);for(let eo=0;eo=2147483647)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|c}function byteLength(c,l){if(Buffer.isBuffer(c))return c.length;if(ArrayBuffer.isView(c)||isInstance(c,ArrayBuffer))return c.byteLength;if("string"!=typeof c)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof c);let et=c.length,eo=arguments.length>2&&!0===arguments[2];if(!eo&&0===et)return 0;let es=!1;for(;;)switch(l){case"ascii":case"latin1":case"binary":return et;case"utf8":case"utf-8":return utf8ToBytes(c).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*et;case"hex":return et>>>1;case"base64":return base64ToBytes(c).length;default:if(es)return eo?-1:utf8ToBytes(c).length;l=(""+l).toLowerCase(),es=!0}}function slowToString(c,l,et){let es=!1;if((void 0===l||l<0)&&(l=0),l>this.length||((void 0===et||et>this.length)&&(et=this.length),et<=0||(et>>>=0)<=(l>>>=0)))return"";for(c||(c="utf8");;)switch(c){case"hex":return function(c,l,et){let eo=c.length;(!l||l<0)&&(l=0),(!et||et<0||et>eo)&&(et=eo);let es="";for(let eo=l;eo2147483647?et=2147483647:et<-2147483648&&(et=-2147483648),(ec=et=+et)!=ec&&(et=es?0:c.length-1),et<0&&(et=c.length+et),et>=c.length){if(es)return -1;et=c.length-1}else if(et<0){if(!es)return -1;et=0}if("string"==typeof l&&(l=Buffer.from(l,eo)),Buffer.isBuffer(l))return 0===l.length?-1:arrayIndexOf(c,l,et,eo,es);if("number"==typeof l)return(l&=255,"function"==typeof Uint8Array.prototype.indexOf)?es?Uint8Array.prototype.indexOf.call(c,l,et):Uint8Array.prototype.lastIndexOf.call(c,l,et):arrayIndexOf(c,[l],et,eo,es);throw TypeError("val must be string, number or Buffer")}function arrayIndexOf(c,l,et,eo,es){let ec,el=1,ed=c.length,eh=l.length;if(void 0!==eo&&("ucs2"===(eo=String(eo).toLowerCase())||"ucs-2"===eo||"utf16le"===eo||"utf-16le"===eo)){if(c.length<2||l.length<2)return -1;el=2,ed/=2,eh/=2,et/=2}function read(c,l){return 1===el?c[l]:c.readUInt16BE(l*el)}if(es){let eo=-1;for(ec=et;eced&&(et=ed-eh),ec=et;ec>=0;ec--){let et=!0;for(let eo=0;eo239?4:l>223?3:l>191?2:1;if(es+el<=et){let et,eo,ed,eh;switch(el){case 1:l<128&&(ec=l);break;case 2:(192&(et=c[es+1]))==128&&(eh=(31&l)<<6|63&et)>127&&(ec=eh);break;case 3:et=c[es+1],eo=c[es+2],(192&et)==128&&(192&eo)==128&&(eh=(15&l)<<12|(63&et)<<6|63&eo)>2047&&(eh<55296||eh>57343)&&(ec=eh);break;case 4:et=c[es+1],eo=c[es+2],ed=c[es+3],(192&et)==128&&(192&eo)==128&&(192&ed)==128&&(eh=(15&l)<<18|(63&et)<<12|(63&eo)<<6|63&ed)>65535&&eh<1114112&&(ec=eh)}}null===ec?(ec=65533,el=1):ec>65535&&(ec-=65536,eo.push(ec>>>10&1023|55296),ec=56320|1023&ec),eo.push(ec),es+=el}return function(c){let l=c.length;if(l<=4096)return String.fromCharCode.apply(String,c);let et="",eo=0;for(;eoet)throw RangeError("Trying to access beyond buffer length")}function checkInt(c,l,et,eo,es,ec){if(!Buffer.isBuffer(c))throw TypeError('"buffer" argument must be a Buffer instance');if(l>es||lc.length)throw RangeError("Index out of range")}function wrtBigUInt64LE(c,l,et,eo,es){checkIntBI(l,eo,es,c,et,7);let ec=Number(l&BigInt(4294967295));c[et++]=ec,ec>>=8,c[et++]=ec,ec>>=8,c[et++]=ec,ec>>=8,c[et++]=ec;let el=Number(l>>BigInt(32)&BigInt(4294967295));return c[et++]=el,el>>=8,c[et++]=el,el>>=8,c[et++]=el,el>>=8,c[et++]=el,et}function wrtBigUInt64BE(c,l,et,eo,es){checkIntBI(l,eo,es,c,et,7);let ec=Number(l&BigInt(4294967295));c[et+7]=ec,ec>>=8,c[et+6]=ec,ec>>=8,c[et+5]=ec,ec>>=8,c[et+4]=ec;let el=Number(l>>BigInt(32)&BigInt(4294967295));return c[et+3]=el,el>>=8,c[et+2]=el,el>>=8,c[et+1]=el,el>>=8,c[et]=el,et+8}function checkIEEE754(c,l,et,eo,es,ec){if(et+eo>c.length||et<0)throw RangeError("Index out of range")}function writeFloat(c,l,et,eo,ec){return l=+l,et>>>=0,ec||checkIEEE754(c,l,et,4,34028234663852886e22,-34028234663852886e22),es.write(c,l,et,eo,23,4),et+4}function writeDouble(c,l,et,eo,ec){return l=+l,et>>>=0,ec||checkIEEE754(c,l,et,8,17976931348623157e292,-17976931348623157e292),es.write(c,l,et,eo,52,8),et+8}l.Buffer=Buffer,l.SlowBuffer=function(c){return+c!=c&&(c=0),Buffer.alloc(+c)},l.INSPECT_MAX_BYTES=50,l.kMaxLength=2147483647,Buffer.TYPED_ARRAY_SUPPORT=function(){try{let c=new Uint8Array(1),l={foo:function(){return 42}};return Object.setPrototypeOf(l,Uint8Array.prototype),Object.setPrototypeOf(c,l),42===c.foo()}catch(c){return!1}}(),Buffer.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(Buffer.prototype,"parent",{enumerable:!0,get:function(){if(Buffer.isBuffer(this))return this.buffer}}),Object.defineProperty(Buffer.prototype,"offset",{enumerable:!0,get:function(){if(Buffer.isBuffer(this))return this.byteOffset}}),Buffer.poolSize=8192,Buffer.from=function(c,l,et){return from(c,l,et)},Object.setPrototypeOf(Buffer.prototype,Uint8Array.prototype),Object.setPrototypeOf(Buffer,Uint8Array),Buffer.alloc=function(c,l,et){return(assertSize(c),c<=0)?createBuffer(c):void 0!==l?"string"==typeof et?createBuffer(c).fill(l,et):createBuffer(c).fill(l):createBuffer(c)},Buffer.allocUnsafe=function(c){return allocUnsafe(c)},Buffer.allocUnsafeSlow=function(c){return allocUnsafe(c)},Buffer.isBuffer=function(c){return null!=c&&!0===c._isBuffer&&c!==Buffer.prototype},Buffer.compare=function(c,l){if(isInstance(c,Uint8Array)&&(c=Buffer.from(c,c.offset,c.byteLength)),isInstance(l,Uint8Array)&&(l=Buffer.from(l,l.offset,l.byteLength)),!Buffer.isBuffer(c)||!Buffer.isBuffer(l))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(c===l)return 0;let et=c.length,eo=l.length;for(let es=0,ec=Math.min(et,eo);eseo.length?(Buffer.isBuffer(l)||(l=Buffer.from(l)),l.copy(eo,es)):Uint8Array.prototype.set.call(eo,l,es);else if(Buffer.isBuffer(l))l.copy(eo,es);else throw TypeError('"list" argument must be an Array of Buffers');es+=l.length}return eo},Buffer.byteLength=byteLength,Buffer.prototype._isBuffer=!0,Buffer.prototype.swap16=function(){let c=this.length;if(c%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let l=0;let&&(c+=" ... "),""},ec&&(Buffer.prototype[ec]=Buffer.prototype.inspect),Buffer.prototype.compare=function(c,l,et,eo,es){if(isInstance(c,Uint8Array)&&(c=Buffer.from(c,c.offset,c.byteLength)),!Buffer.isBuffer(c))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof c);if(void 0===l&&(l=0),void 0===et&&(et=c?c.length:0),void 0===eo&&(eo=0),void 0===es&&(es=this.length),l<0||et>c.length||eo<0||es>this.length)throw RangeError("out of range index");if(eo>=es&&l>=et)return 0;if(eo>=es)return -1;if(l>=et)return 1;if(l>>>=0,et>>>=0,eo>>>=0,es>>>=0,this===c)return 0;let ec=es-eo,el=et-l,ed=Math.min(ec,el),eh=this.slice(eo,es),ef=c.slice(l,et);for(let c=0;c>>=0,isFinite(et)?(et>>>=0,void 0===eo&&(eo="utf8")):(eo=et,et=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let em=this.length-l;if((void 0===et||et>em)&&(et=em),c.length>0&&(et<0||l<0)||l>this.length)throw RangeError("Attempt to write outside buffer bounds");eo||(eo="utf8");let eb=!1;for(;;)switch(eo){case"hex":return function(c,l,et,eo){let es;et=Number(et)||0;let ec=c.length-et;eo?(eo=Number(eo))>ec&&(eo=ec):eo=ec;let el=l.length;for(eo>el/2&&(eo=el/2),es=0;es>8,es.push(et%256),es.push(eo);return es}(c,this.length-ep),this,ep,eg);default:if(eb)throw TypeError("Unknown encoding: "+eo);eo=(""+eo).toLowerCase(),eb=!0}},Buffer.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},Buffer.prototype.slice=function(c,l){let et=this.length;c=~~c,l=void 0===l?et:~~l,c<0?(c+=et)<0&&(c=0):c>et&&(c=et),l<0?(l+=et)<0&&(l=0):l>et&&(l=et),l>>=0,l>>>=0,et||checkOffset(c,l,this.length);let eo=this[c],es=1,ec=0;for(;++ec>>=0,l>>>=0,et||checkOffset(c,l,this.length);let eo=this[c+--l],es=1;for(;l>0&&(es*=256);)eo+=this[c+--l]*es;return eo},Buffer.prototype.readUint8=Buffer.prototype.readUInt8=function(c,l){return c>>>=0,l||checkOffset(c,1,this.length),this[c]},Buffer.prototype.readUint16LE=Buffer.prototype.readUInt16LE=function(c,l){return c>>>=0,l||checkOffset(c,2,this.length),this[c]|this[c+1]<<8},Buffer.prototype.readUint16BE=Buffer.prototype.readUInt16BE=function(c,l){return c>>>=0,l||checkOffset(c,2,this.length),this[c]<<8|this[c+1]},Buffer.prototype.readUint32LE=Buffer.prototype.readUInt32LE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),(this[c]|this[c+1]<<8|this[c+2]<<16)+16777216*this[c+3]},Buffer.prototype.readUint32BE=Buffer.prototype.readUInt32BE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),16777216*this[c]+(this[c+1]<<16|this[c+2]<<8|this[c+3])},Buffer.prototype.readBigUInt64LE=defineBigIntMethod(function(c){validateNumber(c>>>=0,"offset");let l=this[c],et=this[c+7];(void 0===l||void 0===et)&&boundsError(c,this.length-8);let eo=l+256*this[++c]+65536*this[++c]+16777216*this[++c],es=this[++c]+256*this[++c]+65536*this[++c]+16777216*et;return BigInt(eo)+(BigInt(es)<>>=0,"offset");let l=this[c],et=this[c+7];(void 0===l||void 0===et)&&boundsError(c,this.length-8);let eo=16777216*l+65536*this[++c]+256*this[++c]+this[++c],es=16777216*this[++c]+65536*this[++c]+256*this[++c]+et;return(BigInt(eo)<>>=0,l>>>=0,et||checkOffset(c,l,this.length);let eo=this[c],es=1,ec=0;for(;++ec=(es*=128)&&(eo-=Math.pow(2,8*l)),eo},Buffer.prototype.readIntBE=function(c,l,et){c>>>=0,l>>>=0,et||checkOffset(c,l,this.length);let eo=l,es=1,ec=this[c+--eo];for(;eo>0&&(es*=256);)ec+=this[c+--eo]*es;return ec>=(es*=128)&&(ec-=Math.pow(2,8*l)),ec},Buffer.prototype.readInt8=function(c,l){return(c>>>=0,l||checkOffset(c,1,this.length),128&this[c])?-((255-this[c]+1)*1):this[c]},Buffer.prototype.readInt16LE=function(c,l){c>>>=0,l||checkOffset(c,2,this.length);let et=this[c]|this[c+1]<<8;return 32768&et?4294901760|et:et},Buffer.prototype.readInt16BE=function(c,l){c>>>=0,l||checkOffset(c,2,this.length);let et=this[c+1]|this[c]<<8;return 32768&et?4294901760|et:et},Buffer.prototype.readInt32LE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),this[c]|this[c+1]<<8|this[c+2]<<16|this[c+3]<<24},Buffer.prototype.readInt32BE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),this[c]<<24|this[c+1]<<16|this[c+2]<<8|this[c+3]},Buffer.prototype.readBigInt64LE=defineBigIntMethod(function(c){validateNumber(c>>>=0,"offset");let l=this[c],et=this[c+7];(void 0===l||void 0===et)&&boundsError(c,this.length-8);let eo=this[c+4]+256*this[c+5]+65536*this[c+6]+(et<<24);return(BigInt(eo)<>>=0,"offset");let l=this[c],et=this[c+7];(void 0===l||void 0===et)&&boundsError(c,this.length-8);let eo=(l<<24)+65536*this[++c]+256*this[++c]+this[++c];return(BigInt(eo)<>>=0,l||checkOffset(c,4,this.length),es.read(this,c,!0,23,4)},Buffer.prototype.readFloatBE=function(c,l){return c>>>=0,l||checkOffset(c,4,this.length),es.read(this,c,!1,23,4)},Buffer.prototype.readDoubleLE=function(c,l){return c>>>=0,l||checkOffset(c,8,this.length),es.read(this,c,!0,52,8)},Buffer.prototype.readDoubleBE=function(c,l){return c>>>=0,l||checkOffset(c,8,this.length),es.read(this,c,!1,52,8)},Buffer.prototype.writeUintLE=Buffer.prototype.writeUIntLE=function(c,l,et,eo){if(c=+c,l>>>=0,et>>>=0,!eo){let eo=Math.pow(2,8*et)-1;checkInt(this,c,l,et,eo,0)}let es=1,ec=0;for(this[l]=255&c;++ec>>=0,et>>>=0,!eo){let eo=Math.pow(2,8*et)-1;checkInt(this,c,l,et,eo,0)}let es=et-1,ec=1;for(this[l+es]=255&c;--es>=0&&(ec*=256);)this[l+es]=c/ec&255;return l+et},Buffer.prototype.writeUint8=Buffer.prototype.writeUInt8=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,1,255,0),this[l]=255&c,l+1},Buffer.prototype.writeUint16LE=Buffer.prototype.writeUInt16LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,65535,0),this[l]=255&c,this[l+1]=c>>>8,l+2},Buffer.prototype.writeUint16BE=Buffer.prototype.writeUInt16BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,65535,0),this[l]=c>>>8,this[l+1]=255&c,l+2},Buffer.prototype.writeUint32LE=Buffer.prototype.writeUInt32LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,4294967295,0),this[l+3]=c>>>24,this[l+2]=c>>>16,this[l+1]=c>>>8,this[l]=255&c,l+4},Buffer.prototype.writeUint32BE=Buffer.prototype.writeUInt32BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,4294967295,0),this[l]=c>>>24,this[l+1]=c>>>16,this[l+2]=c>>>8,this[l+3]=255&c,l+4},Buffer.prototype.writeBigUInt64LE=defineBigIntMethod(function(c,l=0){return wrtBigUInt64LE(this,c,l,BigInt(0),BigInt("0xffffffffffffffff"))}),Buffer.prototype.writeBigUInt64BE=defineBigIntMethod(function(c,l=0){return wrtBigUInt64BE(this,c,l,BigInt(0),BigInt("0xffffffffffffffff"))}),Buffer.prototype.writeIntLE=function(c,l,et,eo){if(c=+c,l>>>=0,!eo){let eo=Math.pow(2,8*et-1);checkInt(this,c,l,et,eo-1,-eo)}let es=0,ec=1,el=0;for(this[l]=255&c;++es>0)-el&255;return l+et},Buffer.prototype.writeIntBE=function(c,l,et,eo){if(c=+c,l>>>=0,!eo){let eo=Math.pow(2,8*et-1);checkInt(this,c,l,et,eo-1,-eo)}let es=et-1,ec=1,el=0;for(this[l+es]=255&c;--es>=0&&(ec*=256);)c<0&&0===el&&0!==this[l+es+1]&&(el=1),this[l+es]=(c/ec>>0)-el&255;return l+et},Buffer.prototype.writeInt8=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,1,127,-128),c<0&&(c=255+c+1),this[l]=255&c,l+1},Buffer.prototype.writeInt16LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,32767,-32768),this[l]=255&c,this[l+1]=c>>>8,l+2},Buffer.prototype.writeInt16BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,2,32767,-32768),this[l]=c>>>8,this[l+1]=255&c,l+2},Buffer.prototype.writeInt32LE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,2147483647,-2147483648),this[l]=255&c,this[l+1]=c>>>8,this[l+2]=c>>>16,this[l+3]=c>>>24,l+4},Buffer.prototype.writeInt32BE=function(c,l,et){return c=+c,l>>>=0,et||checkInt(this,c,l,4,2147483647,-2147483648),c<0&&(c=4294967295+c+1),this[l]=c>>>24,this[l+1]=c>>>16,this[l+2]=c>>>8,this[l+3]=255&c,l+4},Buffer.prototype.writeBigInt64LE=defineBigIntMethod(function(c,l=0){return wrtBigUInt64LE(this,c,l,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),Buffer.prototype.writeBigInt64BE=defineBigIntMethod(function(c,l=0){return wrtBigUInt64BE(this,c,l,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),Buffer.prototype.writeFloatLE=function(c,l,et){return writeFloat(this,c,l,!0,et)},Buffer.prototype.writeFloatBE=function(c,l,et){return writeFloat(this,c,l,!1,et)},Buffer.prototype.writeDoubleLE=function(c,l,et){return writeDouble(this,c,l,!0,et)},Buffer.prototype.writeDoubleBE=function(c,l,et){return writeDouble(this,c,l,!1,et)},Buffer.prototype.copy=function(c,l,et,eo){if(!Buffer.isBuffer(c))throw TypeError("argument should be a Buffer");if(et||(et=0),eo||0===eo||(eo=this.length),l>=c.length&&(l=c.length),l||(l=0),eo>0&&eo=this.length)throw RangeError("Index out of range");if(eo<0)throw RangeError("sourceEnd out of bounds");eo>this.length&&(eo=this.length),c.length-l>>=0,et=void 0===et?this.length:et>>>0,c||(c=0),"number"==typeof c)for(es=l;es=eo+4;et-=3)l=`_${c.slice(et-3,et)}${l}`;return`${c.slice(0,et)}${l}`}function checkIntBI(c,l,et,eo,es,ec){if(c>et||c3?0===l||l===BigInt(0)?`>= 0${es} and < 2${es} ** ${(ec+1)*8}${es}`:`>= -(2${es} ** ${(ec+1)*8-1}${es}) and < 2 ** ${(ec+1)*8-1}${es}`:`>= ${l}${es} and <= ${et}${es}`,new el.ERR_OUT_OF_RANGE("value",eo,c)}validateNumber(es,"offset"),(void 0===eo[es]||void 0===eo[es+ec])&&boundsError(es,eo.length-(ec+1))}function validateNumber(c,l){if("number"!=typeof c)throw new el.ERR_INVALID_ARG_TYPE(l,"number",c)}function boundsError(c,l,et){if(Math.floor(c)!==c)throw validateNumber(c,et),new el.ERR_OUT_OF_RANGE(et||"offset","an integer",c);if(l<0)throw new el.ERR_BUFFER_OUT_OF_BOUNDS;throw new el.ERR_OUT_OF_RANGE(et||"offset",`>= ${et?1:0} and <= ${l}`,c)}E("ERR_BUFFER_OUT_OF_BOUNDS",function(c){return c?`${c} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),E("ERR_INVALID_ARG_TYPE",function(c,l){return`The "${c}" argument must be of type number. Received type ${typeof l}`},TypeError),E("ERR_OUT_OF_RANGE",function(c,l,et){let eo=`The value of "${c}" is out of range.`,es=et;return Number.isInteger(et)&&Math.abs(et)>4294967296?es=addNumericalSeparator(String(et)):"bigint"==typeof et&&(es=String(et),(et>BigInt(2)**BigInt(32)||et<-(BigInt(2)**BigInt(32)))&&(es=addNumericalSeparator(es)),es+="n"),eo+=` It must be ${l}. Received ${es}`},RangeError);let ed=/[^+/0-9A-Za-z-_]/g;function utf8ToBytes(c,l){let et;l=l||1/0;let eo=c.length,es=null,ec=[];for(let el=0;el55295&&et<57344){if(!es){if(et>56319||el+1===eo){(l-=3)>-1&&ec.push(239,191,189);continue}es=et;continue}if(et<56320){(l-=3)>-1&&ec.push(239,191,189),es=et;continue}et=(es-55296<<10|et-56320)+65536}else es&&(l-=3)>-1&&ec.push(239,191,189);if(es=null,et<128){if((l-=1)<0)break;ec.push(et)}else if(et<2048){if((l-=2)<0)break;ec.push(et>>6|192,63&et|128)}else if(et<65536){if((l-=3)<0)break;ec.push(et>>12|224,et>>6&63|128,63&et|128)}else if(et<1114112){if((l-=4)<0)break;ec.push(et>>18|240,et>>12&63|128,et>>6&63|128,63&et|128)}else throw Error("Invalid code point")}return ec}function base64ToBytes(c){return eo.toByteArray(function(c){if((c=(c=c.split("=")[0]).trim().replace(ed,"")).length<2)return"";for(;c.length%4!=0;)c+="=";return c}(c))}function blitBuffer(c,l,et,eo){let es;for(es=0;es=l.length)&&!(es>=c.length);++es)l[es+et]=c[es];return es}function isInstance(c,l){return c instanceof l||null!=c&&null!=c.constructor&&null!=c.constructor.name&&c.constructor.name===l.name}let eh=function(){let c="0123456789abcdef",l=Array(256);for(let et=0;et<16;++et){let eo=16*et;for(let es=0;es<16;++es)l[eo+es]=c[et]+c[es]}return l}();function defineBigIntMethod(c){return"undefined"==typeof BigInt?BufferBigIntNotDefined:c}function BufferBigIntNotDefined(){throw Error("BigInt not supported")}},50710:function(c,l,et){"use strict";var eo=et(51597),es=et(65775),ec=es(eo("String.prototype.indexOf"));c.exports=function(c,l){var et=eo(c,!!l);return"function"==typeof et&&ec(c,".prototype.")>-1?es(et):et}},65775:function(c,l,et){"use strict";var eo=et(24316),es=et(51597),ec=es("%Function.prototype.apply%"),el=es("%Function.prototype.call%"),ed=es("%Reflect.apply%",!0)||eo.call(el,ec),eh=es("%Object.getOwnPropertyDescriptor%",!0),ef=es("%Object.defineProperty%",!0),ep=es("%Math.max%");if(ef)try{ef({},"a",{value:1})}catch(c){ef=null}c.exports=function(c){var l=ed(eo,el,arguments);return eh&&ef&&eh(l,"length").configurable&&ef(l,"length",{value:1+ep(0,c.length-(arguments.length-1))}),l};var applyBind=function(){return ed(eo,ec,arguments)};ef?ef(c.exports,"apply",{value:applyBind}):c.exports.apply=applyBind},50348:function(c,l,et){"use strict";function clsx(){for(var c,l,et=0,eo="";et-1};function normalizeName(c){if("string"!=typeof c&&(c=String(c)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(c))throw TypeError("Invalid character in header field name");return c.toLowerCase()}function normalizeValue(c){return"string"!=typeof c&&(c=String(c)),c}function iteratorFor(c){var et={next:function(){var l=c.shift();return{done:void 0===l,value:l}}};return l.iterable&&(et[Symbol.iterator]=function(){return et}),et}function Headers(c){this.map={},c instanceof Headers?c.forEach(function(c,l){this.append(l,c)},this):Array.isArray(c)?c.forEach(function(c){this.append(c[0],c[1])},this):c&&Object.getOwnPropertyNames(c).forEach(function(l){this.append(l,c[l])},this)}function consumed(c){if(c.bodyUsed)return Promise.reject(TypeError("Already read"));c.bodyUsed=!0}function fileReaderReady(c){return new Promise(function(l,et){c.onload=function(){l(c.result)},c.onerror=function(){et(c.error)}})}function readBlobAsArrayBuffer(c){var l=new FileReader,et=fileReaderReady(l);return l.readAsArrayBuffer(c),et}function bufferClone(c){if(c.slice)return c.slice(0);var l=new Uint8Array(c.byteLength);return l.set(new Uint8Array(c)),l.buffer}function Body(){return this.bodyUsed=!1,this._initBody=function(c){if(this._bodyInit=c,c){if("string"==typeof c)this._bodyText=c;else if(l.blob&&Blob.prototype.isPrototypeOf(c))this._bodyBlob=c;else if(l.formData&&FormData.prototype.isPrototypeOf(c))this._bodyFormData=c;else if(l.searchParams&&URLSearchParams.prototype.isPrototypeOf(c))this._bodyText=c.toString();else{var et;l.arrayBuffer&&l.blob&&(et=c)&&DataView.prototype.isPrototypeOf(et)?(this._bodyArrayBuffer=bufferClone(c.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):l.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(c)||es(c))?this._bodyArrayBuffer=bufferClone(c):this._bodyText=c=Object.prototype.toString.call(c)}}else this._bodyText="";!this.headers.get("content-type")&&("string"==typeof c?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):l.searchParams&&URLSearchParams.prototype.isPrototypeOf(c)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},l.blob&&(this.blob=function(){var c=consumed(this);if(c)return c;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(!this._bodyFormData)return Promise.resolve(new Blob([this._bodyText]));throw Error("could not read FormData body as blob")},this.arrayBuffer=function(){return this._bodyArrayBuffer?consumed(this)||Promise.resolve(this._bodyArrayBuffer):this.blob().then(readBlobAsArrayBuffer)}),this.text=function(){var c,l,et,eo=consumed(this);if(eo)return eo;if(this._bodyBlob)return c=this._bodyBlob,et=fileReaderReady(l=new FileReader),l.readAsText(c),et;if(this._bodyArrayBuffer)return Promise.resolve(function(c){for(var l=new Uint8Array(c),et=Array(l.length),eo=0;eo-1?eo:et),this.mode=l.mode||this.mode||null,this.signal=l.signal||this.signal,this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&es)throw TypeError("Body not allowed for GET or HEAD requests");this._initBody(es)}function decode(c){var l=new FormData;return c.trim().split("&").forEach(function(c){if(c){var et=c.split("="),eo=et.shift().replace(/\+/g," "),es=et.join("=").replace(/\+/g," ");l.append(decodeURIComponent(eo),decodeURIComponent(es))}}),l}function Response(c,l){l||(l={}),this.type="default",this.status=void 0===l.status?200:l.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in l?l.statusText:"OK",this.headers=new Headers(l.headers),this.url=l.url||"",this._initBody(c)}Request.prototype.clone=function(){return new Request(this,{body:this._bodyInit})},Body.call(Request.prototype),Body.call(Response.prototype),Response.prototype.clone=function(){return new Response(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new Headers(this.headers),url:this.url})},Response.error=function(){var c=new Response(null,{status:0,statusText:""});return c.type="error",c};var el=[301,302,303,307,308];Response.redirect=function(c,l){if(-1===el.indexOf(l))throw RangeError("Invalid status code");return new Response(null,{status:l,headers:{location:c}})},c.DOMException=eo.DOMException;try{new c.DOMException}catch(l){c.DOMException=function(c,l){this.message=c,this.name=l;var et=Error(c);this.stack=et.stack},c.DOMException.prototype=Object.create(Error.prototype),c.DOMException.prototype.constructor=c.DOMException}function fetch(et,eo){return new Promise(function(es,ec){var el=new Request(et,eo);if(el.signal&&el.signal.aborted)return ec(new c.DOMException("Aborted","AbortError"));var ed=new XMLHttpRequest;function abortXhr(){ed.abort()}ed.onload=function(){var c,l,et={status:ed.status,statusText:ed.statusText,headers:(c=ed.getAllResponseHeaders()||"",l=new Headers,c.replace(/\r?\n[\t ]+/g," ").split(/\r?\n/).forEach(function(c){var et=c.split(":"),eo=et.shift().trim();if(eo){var es=et.join(":").trim();l.append(eo,es)}}),l)};et.url="responseURL"in ed?ed.responseURL:et.headers.get("X-Request-URL");var eo="response"in ed?ed.response:ed.responseText;es(new Response(eo,et))},ed.onerror=function(){ec(TypeError("Network request failed"))},ed.ontimeout=function(){ec(TypeError("Network request failed"))},ed.onabort=function(){ec(new c.DOMException("Aborted","AbortError"))},ed.open(el.method,el.url,!0),"include"===el.credentials?ed.withCredentials=!0:"omit"===el.credentials&&(ed.withCredentials=!1),"responseType"in ed&&l.blob&&(ed.responseType="blob"),el.headers.forEach(function(c,l){ed.setRequestHeader(l,c)}),el.signal&&(el.signal.addEventListener("abort",abortXhr),ed.onreadystatechange=function(){4===ed.readyState&&el.signal.removeEventListener("abort",abortXhr)}),ed.send(void 0===el._bodyInit?null:el._bodyInit)})}fetch.polyfill=!0,eo.fetch||(eo.fetch=fetch,eo.Headers=Headers,eo.Request=Request,eo.Response=Response),c.Headers=Headers,c.Request=Request,c.Response=Response,c.fetch=fetch,Object.defineProperty(c,"__esModule",{value:!0})})({}),eo.fetch.ponyfill=!0,delete eo.fetch.polyfill,(l=eo.fetch).default=eo.fetch,l.fetch=eo.fetch,l.Headers=eo.Headers,l.Request=eo.Request,l.Response=eo.Response,c.exports=l},26822:function(c){function plural(c,l,et,eo){return Math.round(c/et)+" "+eo+(l>=1.5*et?"s":"")}c.exports=function(c,l){l=l||{};var et,eo,es=typeof c;if("string"===es&&c.length>0)return function(c){if(!((c=String(c)).length>100)){var l=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(c);if(l){var et=parseFloat(l[1]);switch((l[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*et;case"weeks":case"week":case"w":return 6048e5*et;case"days":case"day":case"d":return 864e5*et;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*et;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*et;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*et;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return et;default:return}}}}(c);if("number"===es&&isFinite(c))return l.long?(et=Math.abs(c))>=864e5?plural(c,et,864e5,"day"):et>=36e5?plural(c,et,36e5,"hour"):et>=6e4?plural(c,et,6e4,"minute"):et>=1e3?plural(c,et,1e3,"second"):c+" ms":(eo=Math.abs(c))>=864e5?Math.round(c/864e5)+"d":eo>=36e5?Math.round(c/36e5)+"h":eo>=6e4?Math.round(c/6e4)+"m":eo>=1e3?Math.round(c/1e3)+"s":c+"ms";throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(c))}},4461:function(c,l,et){let eo;var es=et(25566);l.formatArgs=function(l){if(l[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+l[0]+(this.useColors?"%c ":" ")+"+"+c.exports.humanize(this.diff),!this.useColors)return;let et="color: "+this.color;l.splice(1,0,et,"color: inherit");let eo=0,es=0;l[0].replace(/%[a-zA-Z%]/g,c=>{"%%"!==c&&(eo++,"%c"===c&&(es=eo))}),l.splice(es,0,et)},l.save=function(c){try{c?l.storage.setItem("debug",c):l.storage.removeItem("debug")}catch(c){}},l.load=function(){let c;try{c=l.storage.getItem("debug")}catch(c){}return!c&&void 0!==es&&"env"in es&&(c=es.env.DEBUG),c},l.useColors=function(){return"undefined"!=typeof window&&!!window.process&&("renderer"===window.process.type||!!window.process.__nwjs)||!("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},l.storage=function(){try{return localStorage}catch(c){}}(),l.destroy=(eo=!1,()=>{eo||(eo=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}),l.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],l.log=console.debug||console.log||(()=>{}),c.exports=et(84239)(l);let{formatters:ec}=c.exports;ec.j=function(c){try{return JSON.stringify(c)}catch(c){return"[UnexpectedJSONParseError]: "+c.message}}},84239:function(c,l,et){c.exports=function(c){function createDebug(c){let l,et,eo;let es=null;function debug(...c){if(!debug.enabled)return;let et=Number(new Date),eo=et-(l||et);debug.diff=eo,debug.prev=l,debug.curr=et,l=et,c[0]=createDebug.coerce(c[0]),"string"!=typeof c[0]&&c.unshift("%O");let es=0;c[0]=c[0].replace(/%([a-zA-Z%])/g,(l,et)=>{if("%%"===l)return"%";es++;let eo=createDebug.formatters[et];if("function"==typeof eo){let et=c[es];l=eo.call(debug,et),c.splice(es,1),es--}return l}),createDebug.formatArgs.call(debug,c);let ec=debug.log||createDebug.log;ec.apply(debug,c)}return debug.namespace=c,debug.useColors=createDebug.useColors(),debug.color=createDebug.selectColor(c),debug.extend=extend,debug.destroy=createDebug.destroy,Object.defineProperty(debug,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==es?es:(et!==createDebug.namespaces&&(et=createDebug.namespaces,eo=createDebug.enabled(c)),eo),set:c=>{es=c}}),"function"==typeof createDebug.init&&createDebug.init(debug),debug}function extend(c,l){let et=createDebug(this.namespace+(void 0===l?":":l)+c);return et.log=this.log,et}function toNamespace(c){return c.toString().substring(2,c.toString().length-2).replace(/\.\*\?$/,"*")}return createDebug.debug=createDebug,createDebug.default=createDebug,createDebug.coerce=function(c){return c instanceof Error?c.stack||c.message:c},createDebug.disable=function(){let c=[...createDebug.names.map(toNamespace),...createDebug.skips.map(toNamespace).map(c=>"-"+c)].join(",");return createDebug.enable(""),c},createDebug.enable=function(c){let l;createDebug.save(c),createDebug.namespaces=c,createDebug.names=[],createDebug.skips=[];let et=("string"==typeof c?c:"").split(/[\s,]+/),eo=et.length;for(l=0;l{createDebug[l]=c[l]}),createDebug.names=[],createDebug.skips=[],createDebug.formatters={},createDebug.selectColor=function(c){let l=0;for(let et=0;etef)&&(em[el]=ef,eb.push(el,ef),eg[el]=ec));if(void 0!==eo&&void 0===em[eo])throw Error(["Could not find a path from ",et," to ",eo,"."].join(""));return eg},extract_shortest_path_from_predecessor_list:function(c,l){for(var et=[],eo=l;eo;)et.push(eo),c[eo],eo=c[eo];return et.reverse(),et},find_path:function(c,et,eo){var es=l.single_source_shortest_paths(c,et,eo);return l.extract_shortest_path_from_predecessor_list(es,eo)},PriorityQueue:{make:function(c){var et,eo=l.PriorityQueue,es={};for(et in c=c||{},eo)eo.hasOwnProperty(et)&&(es[et]=eo[et]);return es.queue=[],es.sorter=c.sorter||eo.default_sorter,es},default_sorter:function(c,l){return c.cost-l.cost},push:function(c,l){this.queue.push({value:c,cost:l}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};c.exports=l},53216:function(c){"use strict";c.exports=function(c){for(var l=[],et=c.length,eo=0;eo=55296&&es<=56319&&et>eo+1){var ec=c.charCodeAt(eo+1);ec>=56320&&ec<=57343&&(es=(es-55296)*1024+ec-56320+65536,eo+=1)}if(es<128){l.push(es);continue}if(es<2048){l.push(es>>6|192),l.push(63&es|128);continue}if(es<55296||es>=57344&&es<65536){l.push(es>>12|224),l.push(es>>6&63|128),l.push(63&es|128);continue}if(es>=65536&&es<=1114111){l.push(es>>18|240),l.push(es>>12&63|128),l.push(es>>6&63|128),l.push(63&es|128);continue}l.push(239,191,189)}return new Uint8Array(l).buffer}},68590:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.BaseBlockTracker=void 0;let es=eo(et(12941)),calculateSum=(c,l)=>c+l,ec=["sync","latest"];let BaseBlockTracker=class BaseBlockTracker extends es.default{constructor(c){super(),this._blockResetDuration=c.blockResetDuration||2e4,this._currentBlock=null,this._isRunning=!1,this._onNewListener=this._onNewListener.bind(this),this._onRemoveListener=this._onRemoveListener.bind(this),this._resetCurrentBlock=this._resetCurrentBlock.bind(this),this._setupInternalEvents()}async destroy(){this._cancelBlockResetTimeout(),await this._maybeEnd(),super.removeAllListeners()}isRunning(){return this._isRunning}getCurrentBlock(){return this._currentBlock}async getLatestBlock(){if(this._currentBlock)return this._currentBlock;let c=await new Promise(c=>this.once("latest",c));return c}removeAllListeners(c){return c?super.removeAllListeners(c):super.removeAllListeners(),this._setupInternalEvents(),this._onRemoveListener(),this}_setupInternalEvents(){this.removeListener("newListener",this._onNewListener),this.removeListener("removeListener",this._onRemoveListener),this.on("newListener",this._onNewListener),this.on("removeListener",this._onRemoveListener)}_onNewListener(c){ec.includes(c)&&this._maybeStart()}_onRemoveListener(){this._getBlockTrackerEventCount()>0||this._maybeEnd()}async _maybeStart(){this._isRunning||(this._isRunning=!0,this._cancelBlockResetTimeout(),await this._start(),this.emit("_started"))}async _maybeEnd(){this._isRunning&&(this._isRunning=!1,this._setupBlockResetTimeout(),await this._end(),this.emit("_ended"))}_getBlockTrackerEventCount(){return ec.map(c=>this.listenerCount(c)).reduce(calculateSum)}_newPotentialLatest(c){let l=this._currentBlock;l&&hexToInt(c)<=hexToInt(l)||this._setCurrentBlock(c)}_setCurrentBlock(c){let l=this._currentBlock;this._currentBlock=c,this.emit("latest",c),this.emit("sync",{oldBlock:l,newBlock:c})}_setupBlockResetTimeout(){this._cancelBlockResetTimeout(),this._blockResetTimeout=setTimeout(this._resetCurrentBlock,this._blockResetDuration),this._blockResetTimeout.unref&&this._blockResetTimeout.unref()}_cancelBlockResetTimeout(){this._blockResetTimeout&&clearTimeout(this._blockResetTimeout)}_resetCurrentBlock(){this._currentBlock=null}};function hexToInt(c){return Number.parseInt(c,16)}l.BaseBlockTracker=BaseBlockTracker},42399:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.PollingBlockTracker=void 0;let es=eo(et(21192)),ec=eo(et(39094)),el=et(68590),ed=et(58378),eh=(0,ed.createModuleLogger)(ed.projectLogger,"polling-block-tracker"),ef=(0,es.default)();let PollingBlockTracker=class PollingBlockTracker extends el.BaseBlockTracker{constructor(c={}){var l;if(!c.provider)throw Error("PollingBlockTracker - no provider specified.");super({blockResetDuration:null!==(l=c.blockResetDuration)&&void 0!==l?l:c.pollingInterval}),this._provider=c.provider,this._pollingInterval=c.pollingInterval||2e4,this._retryTimeout=c.retryTimeout||this._pollingInterval/10,this._keepEventLoopActive=void 0===c.keepEventLoopActive||c.keepEventLoopActive,this._setSkipCacheFlag=c.setSkipCacheFlag||!1}async checkForLatestBlock(){return await this._updateLatestBlock(),await this.getLatestBlock()}async _start(){this._synchronize()}async _end(){}async _synchronize(){for(var c;this._isRunning;)try{await this._updateLatestBlock();let c=timeout(this._pollingInterval,!this._keepEventLoopActive);this.emit("_waitingForNextIteration"),await c}catch(eo){let l=Error(`PollingBlockTracker - encountered an error while attempting to update latest block: +${null!==(c=eo.stack)&&void 0!==c?c:eo}`);try{this.emit("error",l)}catch(c){console.error(l)}let et=timeout(this._retryTimeout,!this._keepEventLoopActive);this.emit("_waitingForNextIteration"),await et}}async _updateLatestBlock(){let c=await this._fetchLatestBlock();this._newPotentialLatest(c)}async _fetchLatestBlock(){let c={jsonrpc:"2.0",id:ef(),method:"eth_blockNumber",params:[]};this._setSkipCacheFlag&&(c.skipCache=!0),eh("Making request",c);let l=await (0,ec.default)(l=>this._provider.sendAsync(c,l))();if(eh("Got response",l),l.error)throw Error(`PollingBlockTracker - encountered error fetching block: +${l.error.message}`);return l.result}};function timeout(c,l){return new Promise(et=>{let eo=setTimeout(et,c);eo.unref&&l&&eo.unref()})}l.PollingBlockTracker=PollingBlockTracker},57826:function(c,l,et){"use strict";var eo=this&&this.__importDefault||function(c){return c&&c.__esModule?c:{default:c}};Object.defineProperty(l,"__esModule",{value:!0}),l.SubscribeBlockTracker=void 0;let es=eo(et(21192)),ec=et(68590),el=(0,es.default)();let SubscribeBlockTracker=class SubscribeBlockTracker extends ec.BaseBlockTracker{constructor(c={}){if(!c.provider)throw Error("SubscribeBlockTracker - no provider specified.");super(c),this._provider=c.provider,this._subscriptionId=null}async checkForLatestBlock(){return await this.getLatestBlock()}async _start(){if(void 0===this._subscriptionId||null===this._subscriptionId)try{let c=await this._call("eth_blockNumber");this._subscriptionId=await this._call("eth_subscribe","newHeads"),this._provider.on("data",this._handleSubData.bind(this)),this._newPotentialLatest(c)}catch(c){this.emit("error",c)}}async _end(){if(null!==this._subscriptionId&&void 0!==this._subscriptionId)try{await this._call("eth_unsubscribe",this._subscriptionId),this._subscriptionId=null}catch(c){this.emit("error",c)}}_call(c,...l){return new Promise((et,eo)=>{this._provider.sendAsync({id:el(),method:c,params:l,jsonrpc:"2.0"},(c,l)=>{c?eo(c):et(l.result)})})}_handleSubData(c,l){var et;"eth_subscription"===l.method&&(null===(et=l.params)||void 0===et?void 0:et.subscription)===this._subscriptionId&&this._newPotentialLatest(l.params.result.number)}};l.SubscribeBlockTracker=SubscribeBlockTracker},2704:function(c,l,et){"use strict";var eo=this&&this.__createBinding||(Object.create?function(c,l,et,eo){void 0===eo&&(eo=et),Object.defineProperty(c,eo,{enumerable:!0,get:function(){return l[et]}})}:function(c,l,et,eo){void 0===eo&&(eo=et),c[eo]=l[et]}),es=this&&this.__exportStar||function(c,l){for(var et in c)"default"===et||Object.prototype.hasOwnProperty.call(l,et)||eo(l,c,et)};Object.defineProperty(l,"__esModule",{value:!0}),es(et(42399),l),es(et(57826),l),es(et(2047),l)},58378:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.createModuleLogger=l.projectLogger=void 0;let eo=et(30377);Object.defineProperty(l,"createModuleLogger",{enumerable:!0,get:function(){return eo.createModuleLogger}}),l.projectLogger=(0,eo.createProjectLogger)("eth-block-tracker")},2047:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0})},44907:function(c,l,et){let eo=et(12928);c.exports=class extends eo{constructor(){super(),this.allResults=[]}async update(){throw Error("BaseFilterWithHistory - no update method specified")}addResults(c){this.allResults=this.allResults.concat(c),super.addResults(c)}addInitialResults(c){this.allResults=this.allResults.concat(c),super.addInitialResults(c)}getAllResults(){return this.allResults}}},12928:function(c,l,et){let eo=et(12941).default;c.exports=class extends eo{constructor(){super(),this.updates=[]}async initialize(){}async update(){throw Error("BaseFilter - no update method specified")}addResults(c){this.updates=this.updates.concat(c),c.forEach(c=>this.emit("update",c))}addInitialResults(c){}getChangesAndClear(){let c=this.updates;return this.updates=[],c}}},28500:function(c,l,et){let eo=et(12928),es=et(53936),{incrementHexInt:ec}=et(19691);c.exports=class extends eo{constructor({provider:c,params:l}){super(),this.type="block",this.provider=c}async update({oldBlock:c,newBlock:l}){let et=ec(c),eo=await es({provider:this.provider,fromBlock:et,toBlock:l}),el=eo.map(c=>c.hash);this.addResults(el)}}},53936:function(c){async function getBlocksForRange({provider:c,fromBlock:l,toBlock:et}){l||(l=et);let eo=hexToInt(l),es=hexToInt(et),ec=es-eo+1,el=Array(ec).fill().map((c,l)=>eo+l).map(intToHex),ed=await Promise.all(el.map(l=>query(c,"eth_getBlockByNumber",[l,!1])));return ed}function hexToInt(c){return null==c?c:Number.parseInt(c,16)}function intToHex(c){if(null==c)return c;let l=c.toString(16);return"0x"+l}async function query(c,l,et){for(let eo=0;eo<3;eo++)try{return await function(c,l){return new Promise((et,eo)=>{c.sendAsync(l,(c,l)=>{c?eo(c):l.error?eo(l.error):l.result?et(l.result):eo(Error("Result was empty"))})})}(c,{id:1,jsonrpc:"2.0",method:l,params:et})}catch(c){console.error(`provider.sendAsync failed: ${c.stack||c.message||c}`)}throw Error(`Block not found for params: ${JSON.stringify(et)}`)}c.exports=getBlocksForRange},19691:function(c){function sortBlockRefs(c){return c.sort((c,l)=>"latest"===c||"earliest"===l?1:"latest"===l||"earliest"===c?-1:hexToInt(c)-hexToInt(l))}function hexToInt(c){return null==c?c:Number.parseInt(c,16)}function intToHex(c){if(null==c)return c;let l=c.toString(16),et=l.length%2;return et&&(l="0"+l),"0x"+l}function unsafeRandomNibble(){return Math.floor(16*Math.random()).toString(16)}c.exports={minBlockRef:function(...c){let l=sortBlockRefs(c);return l[0]},maxBlockRef:function(...c){let l=sortBlockRefs(c);return l[l.length-1]},sortBlockRefs,bnToHex:function(c){return"0x"+c.toString(16)},blockRefIsNumber:function(c){return c&&!["earliest","latest","pending"].includes(c)},hexToInt,incrementHexInt:function(c){if(null==c)return c;let l=hexToInt(c);return intToHex(l+1)},intToHex,unsafeRandomBytes:function(c){let l="0x";for(let et=0;et{let et=await c(...l),eo=ef(et.id);return eo})}function toAsyncRpcMiddleware(c){return es(async(l,et)=>{let eo=await c.apply(null,l.params);et.result=eo})}function objValues(c,l){let et=[];for(let l in c)et.push(c[l]);return et}c.exports=function({blockTracker:c,provider:l}){let et=0,es={},eg=new eo,em=function({mutex:c}){return l=>async(et,eo,es,ec)=>{let el=await c.acquire();el(),l(et,eo,es,ec)}}({mutex:eg}),eb=ec({eth_newFilter:em(toFilterCreationMiddleware(newLogFilter)),eth_newBlockFilter:em(toFilterCreationMiddleware(newBlockFilter)),eth_newPendingTransactionFilter:em(toFilterCreationMiddleware(newPendingTransactionFilter)),eth_uninstallFilter:em(toAsyncRpcMiddleware(uninstallFilterHandler)),eth_getFilterChanges:em(toAsyncRpcMiddleware(getFilterChanges)),eth_getFilterLogs:em(toAsyncRpcMiddleware(getFilterLogs))}),filterUpdater=async({oldBlock:c,newBlock:l})=>{if(0===es.length)return;let et=await eg.acquire();try{await Promise.all(objValues(es).map(async et=>{try{await et.update({oldBlock:c,newBlock:l})}catch(c){console.error(c)}}))}catch(c){console.error(c)}et()};return eb.newLogFilter=newLogFilter,eb.newBlockFilter=newBlockFilter,eb.newPendingTransactionFilter=newPendingTransactionFilter,eb.uninstallFilter=uninstallFilterHandler,eb.getFilterChanges=getFilterChanges,eb.getFilterLogs=getFilterLogs,eb.destroy=()=>{uninstallAllFilters()},eb;async function newLogFilter(c){let et=new el({provider:l,params:c});return await installFilter(et),et}async function newBlockFilter(){let c=new ed({provider:l});return await installFilter(c),c}async function newPendingTransactionFilter(){let c=new eh({provider:l});return await installFilter(c),c}async function getFilterChanges(c){let l=ep(c),et=es[l];if(!et)throw Error(`No filter for index "${l}"`);let eo=et.getChangesAndClear();return eo}async function getFilterLogs(c){let l=ep(c),et=es[l];if(!et)throw Error(`No filter for index "${l}"`);let eo=[];return"log"===et.type&&(eo=et.getAllResults()),eo}async function uninstallFilterHandler(c){let l=ep(c),et=es[l],eo=!!et;return eo&&await uninstallFilter(l),eo}async function installFilter(l){let eo=objValues(es).length,ec=await c.getLatestBlock();await l.initialize({currentBlock:ec}),es[++et]=l,l.id=et,l.idHex=ef(et);let el=objValues(es).length;return updateBlockTrackerSubs({prevFilterCount:eo,newFilterCount:el}),et}async function uninstallFilter(c){let l=objValues(es).length;delete es[c];let et=objValues(es).length;updateBlockTrackerSubs({prevFilterCount:l,newFilterCount:et})}async function uninstallAllFilters(){let c=objValues(es).length;es={},updateBlockTrackerSubs({prevFilterCount:c,newFilterCount:0})}function updateBlockTrackerSubs({prevFilterCount:l,newFilterCount:et}){if(0===l&&et>0){c.on("sync",filterUpdater);return}if(l>0&&0===et){c.removeListener("sync",filterUpdater);return}}}},26723:function(c,l,et){let eo=et(62011),es=et(743),ec=et(44907),{bnToHex:el,hexToInt:ed,incrementHexInt:eh,minBlockRef:ef,blockRefIsNumber:ep}=et(19691);c.exports=class extends ec{constructor({provider:c,params:l}){super(),this.type="log",this.ethQuery=new eo(c),this.params=Object.assign({fromBlock:"latest",toBlock:"latest",address:void 0,topics:[]},l),this.params.address&&(Array.isArray(this.params.address)||(this.params.address=[this.params.address]),this.params.address=this.params.address.map(c=>c.toLowerCase()))}async initialize({currentBlock:c}){let l=this.params.fromBlock;["latest","pending"].includes(l)&&(l=c),"earliest"===l&&(l="0x0"),this.params.fromBlock=l;let et=ef(this.params.toBlock,c),eo=Object.assign({},this.params,{toBlock:et}),es=await this._fetchLogs(eo);this.addInitialResults(es)}async update({oldBlock:c,newBlock:l}){let et;et=c?eh(c):l;let eo=Object.assign({},this.params,{fromBlock:et,toBlock:l}),es=await this._fetchLogs(eo),ec=es.filter(c=>this.matchLog(c));this.addResults(ec)}async _fetchLogs(c){let l=await es(l=>this.ethQuery.getLogs(c,l))();return l}matchLog(c){if(ed(this.params.fromBlock)>=ed(c.blockNumber)||ep(this.params.toBlock)&&ed(this.params.toBlock)<=ed(c.blockNumber))return!1;let l=c.address&&c.address.toLowerCase();if(this.params.address&&l&&!this.params.address.includes(l))return!1;let et=this.params.topics.every((l,et)=>{let eo=c.topics[et];if(!eo)return!1;eo=eo.toLowerCase();let es=Array.isArray(l)?l:[l],ec=es.includes(null);if(ec)return!0;es=es.map(c=>c.toLowerCase());let el=es.includes(eo);return el});return et}}},743:function(c){"use strict";let processFn=(c,l,et,eo)=>function(...es){let ec=l.promiseModule;return new ec((ec,el)=>{l.multiArgs?es.push((...c)=>{l.errorFirst?c[0]?el(c):(c.shift(),ec(c)):ec(c)}):l.errorFirst?es.push((c,l)=>{c?el(c):ec(l)}):es.push(ec);let ed=this===et?eo:this;Reflect.apply(c,ed,es)})},l=new WeakMap;c.exports=(c,et)=>{et={exclude:[/.+(?:Sync|Stream)$/],errorFirst:!0,promiseModule:Promise,...et};let eo=typeof c;if(!(null!==c&&("object"===eo||"function"===eo)))throw TypeError(`Expected \`input\` to be a \`Function\` or \`Object\`, got \`${null===c?"null":eo}\``);let filter=(c,eo)=>{let es=l.get(c);if(es||(es={},l.set(c,es)),eo in es)return es[eo];let match=c=>"string"==typeof c||"symbol"==typeof eo?eo===c:c.test(eo),ec=Reflect.getOwnPropertyDescriptor(c,eo),el=void 0===ec||ec.writable||ec.configurable,ed=et.include?et.include.some(match):!et.exclude.some(match),eh=ed&⪙return es[eo]=eh,eh},es=new WeakMap,ec=new Proxy(c,{apply(c,l,eo){let el=es.get(c);if(el)return Reflect.apply(el,l,eo);let ed=et.excludeMain?c:processFn(c,et,ec,c);return es.set(c,ed),Reflect.apply(ed,l,eo)},get(c,l){let eo=c[l];if(!filter(c,l)||eo===Function.prototype[l])return eo;let el=es.get(eo);if(el)return el;if("function"==typeof eo){let l=processFn(eo,et,ec,c);return es.set(eo,l),l}return eo}});return ec}},55117:function(c,l,et){let eo=et(12941).default,{createAsyncMiddleware:es,createScaffoldMiddleware:ec}=et(49116),el=et(51018),{unsafeRandomBytes:ed,incrementHexInt:eh}=et(19691),ef=et(53936);function normalizeBlock(c){return null==c?null:{hash:c.hash,parentHash:c.parentHash,sha3Uncles:c.sha3Uncles,miner:c.miner,stateRoot:c.stateRoot,transactionsRoot:c.transactionsRoot,receiptsRoot:c.receiptsRoot,logsBloom:c.logsBloom,difficulty:c.difficulty,number:c.number,gasLimit:c.gasLimit,gasUsed:c.gasUsed,nonce:c.nonce,mixHash:c.mixHash,timestamp:c.timestamp,extraData:c.extraData}}c.exports=function({blockTracker:c,provider:l}){let et={},ep=el({blockTracker:c,provider:l}),eg=!1,em=new eo,eb=ec({eth_subscribe:es(subscribe),eth_unsubscribe:es(unsubscribe)});return eb.destroy=function(){for(let c in em.removeAllListeners(),et)et[c].destroy(),delete et[c];eg=!0},{events:em,middleware:eb};async function subscribe(eo,es){let ec;if(eg)throw Error("SubscriptionManager - attempting to use after destroying");let el=eo.params[0],em=ed(16);switch(el){case"newHeads":ec=function({subId:et}){let eo={type:el,destroy:async()=>{c.removeListener("sync",eo.update)},update:async({oldBlock:c,newBlock:eo})=>{let es=eh(c),ec=await ef({provider:l,fromBlock:es,toBlock:eo}),el=ec.map(normalizeBlock).filter(c=>null!==c);el.forEach(c=>{_emitSubscriptionResult(et,c)})}};return c.on("sync",eo.update),eo}({subId:em});break;case"logs":let eb=eo.params[1],ey=await ep.newLogFilter(eb);ec=function({subId:c,filter:l}){return l.on("update",l=>_emitSubscriptionResult(c,l)),{type:el,destroy:async()=>await ep.uninstallFilter(l.idHex)}}({subId:em,filter:ey});break;default:throw Error(`SubscriptionManager - unsupported subscription type "${el}"`)}et[em]=ec,es.result=em}async function unsubscribe(c,l){if(eg)throw Error("SubscriptionManager - attempting to use after destroying");let eo=c.params[0],es=et[eo];if(!es){l.result=!1;return}delete et[eo],await es.destroy(),l.result=!0}function _emitSubscriptionResult(c,l){em.emit("notification",{jsonrpc:"2.0",method:"eth_subscription",params:{subscription:c,result:l}})}}},78575:function(c,l,et){let eo=et(12928),es=et(53936),{incrementHexInt:ec}=et(19691);c.exports=class extends eo{constructor({provider:c}){super(),this.type="tx",this.provider=c}async update({oldBlock:c}){let l=ec(c),et=await es({provider:this.provider,fromBlock:l,toBlock:c}),eo=[];for(let c of et)eo.push(...c.transactions);this.addResults(eo)}}},62011:function(c,l,et){let eo=et(49820),es=et(21192)();function EthQuery(c){this.currentProvider=c}function generateFnFor(c){return function(){var l=[].slice.call(arguments),et=l.pop();this.sendAsync({method:c,params:l},et)}}function generateFnWithDefaultBlockFor(c,l){return function(){var et=[].slice.call(arguments),eo=et.pop();et.length=1e3&&c<=4999))throw Error('"code" must be an integer such that: 1000 <= code <= 4999');super(c,l,et)}}},58519:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.errorValues=l.errorCodes=void 0,l.errorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901}},l.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."}}},71984:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.ethErrors=void 0;let eo=et(62096),es=et(81199),ec=et(58519);function getEthJsonRpcError(c,l){let[et,ec]=parseOpts(l);return new eo.EthereumRpcError(c,et||es.getMessageFromCode(c),ec)}function getEthProviderError(c,l){let[et,ec]=parseOpts(l);return new eo.EthereumProviderError(c,et||es.getMessageFromCode(c),ec)}function parseOpts(c){if(c){if("string"==typeof c)return[c];if("object"==typeof c&&!Array.isArray(c)){let{message:l,data:et}=c;if(l&&"string"!=typeof l)throw Error("Must specify string message.");return[l||void 0,et]}}return[]}l.ethErrors={rpc:{parse:c=>getEthJsonRpcError(ec.errorCodes.rpc.parse,c),invalidRequest:c=>getEthJsonRpcError(ec.errorCodes.rpc.invalidRequest,c),invalidParams:c=>getEthJsonRpcError(ec.errorCodes.rpc.invalidParams,c),methodNotFound:c=>getEthJsonRpcError(ec.errorCodes.rpc.methodNotFound,c),internal:c=>getEthJsonRpcError(ec.errorCodes.rpc.internal,c),server:c=>{if(!c||"object"!=typeof c||Array.isArray(c))throw Error("Ethereum RPC Server errors must provide single object argument.");let{code:l}=c;if(!Number.isInteger(l)||l>-32005||l<-32099)throw Error('"code" must be an integer such that: -32099 <= code <= -32005');return getEthJsonRpcError(l,c)},invalidInput:c=>getEthJsonRpcError(ec.errorCodes.rpc.invalidInput,c),resourceNotFound:c=>getEthJsonRpcError(ec.errorCodes.rpc.resourceNotFound,c),resourceUnavailable:c=>getEthJsonRpcError(ec.errorCodes.rpc.resourceUnavailable,c),transactionRejected:c=>getEthJsonRpcError(ec.errorCodes.rpc.transactionRejected,c),methodNotSupported:c=>getEthJsonRpcError(ec.errorCodes.rpc.methodNotSupported,c),limitExceeded:c=>getEthJsonRpcError(ec.errorCodes.rpc.limitExceeded,c)},provider:{userRejectedRequest:c=>getEthProviderError(ec.errorCodes.provider.userRejectedRequest,c),unauthorized:c=>getEthProviderError(ec.errorCodes.provider.unauthorized,c),unsupportedMethod:c=>getEthProviderError(ec.errorCodes.provider.unsupportedMethod,c),disconnected:c=>getEthProviderError(ec.errorCodes.provider.disconnected,c),chainDisconnected:c=>getEthProviderError(ec.errorCodes.provider.chainDisconnected,c),custom:c=>{if(!c||"object"!=typeof c||Array.isArray(c))throw Error("Ethereum Provider custom errors must provide single object argument.");let{code:l,message:et,data:es}=c;if(!et||"string"!=typeof et)throw Error('"message" must be a nonempty string');return new eo.EthereumProviderError(l,et,es)}}}},46281:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.getMessageFromCode=l.serializeError=l.EthereumProviderError=l.EthereumRpcError=l.ethErrors=l.errorCodes=void 0;let eo=et(62096);Object.defineProperty(l,"EthereumRpcError",{enumerable:!0,get:function(){return eo.EthereumRpcError}}),Object.defineProperty(l,"EthereumProviderError",{enumerable:!0,get:function(){return eo.EthereumProviderError}});let es=et(81199);Object.defineProperty(l,"serializeError",{enumerable:!0,get:function(){return es.serializeError}}),Object.defineProperty(l,"getMessageFromCode",{enumerable:!0,get:function(){return es.getMessageFromCode}});let ec=et(71984);Object.defineProperty(l,"ethErrors",{enumerable:!0,get:function(){return ec.ethErrors}});let el=et(58519);Object.defineProperty(l,"errorCodes",{enumerable:!0,get:function(){return el.errorCodes}})},81199:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.serializeError=l.isValidCode=l.getMessageFromCode=l.JSON_RPC_SERVER_ERROR_MESSAGE=void 0;let eo=et(58519),es=et(62096),ec=eo.errorCodes.rpc.internal,el={code:ec,message:getMessageFromCode(ec)};function getMessageFromCode(c,et="Unspecified error message. This is a bug, please report it."){if(Number.isInteger(c)){let et=c.toString();if(hasKey(eo.errorValues,et))return eo.errorValues[et].message;if(c>=-32099&&c<=-32e3)return l.JSON_RPC_SERVER_ERROR_MESSAGE}return et}function isValidCode(c){if(!Number.isInteger(c))return!1;let l=c.toString();return!!(eo.errorValues[l]||c>=-32099&&c<=-32e3)}function assignOriginalError(c){return c&&"object"==typeof c&&!Array.isArray(c)?Object.assign({},c):c}function hasKey(c,l){return Object.prototype.hasOwnProperty.call(c,l)}l.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.",l.getMessageFromCode=getMessageFromCode,l.isValidCode=isValidCode,l.serializeError=function(c,{fallbackError:l=el,shouldIncludeStack:et=!1}={}){if(!l||!Number.isInteger(l.code)||"string"!=typeof l.message)throw Error("Must provide fallback error with integer number code and string message.");if(c instanceof es.EthereumRpcError)return c.serialize();let eo={};if(c&&"object"==typeof c&&!Array.isArray(c)&&hasKey(c,"code")&&isValidCode(c.code))eo.code=c.code,c.message&&"string"==typeof c.message?(eo.message=c.message,hasKey(c,"data")&&(eo.data=c.data)):(eo.message=getMessageFromCode(eo.code),eo.data={originalError:assignOriginalError(c)});else{eo.code=l.code;let et=null==c?void 0:c.message;eo.message=et&&"string"==typeof et?et:l.message,eo.data={originalError:assignOriginalError(c)}}let ec=null==c?void 0:c.stack;return et&&c&&ec&&"string"==typeof ec&&(eo.stack=ec),eo}},512:function(c){"use strict";var l,et="object"==typeof Reflect?Reflect:null,eo=et&&"function"==typeof et.apply?et.apply:function(c,l,et){return Function.prototype.apply.call(c,l,et)};l=et&&"function"==typeof et.ownKeys?et.ownKeys:Object.getOwnPropertySymbols?function(c){return Object.getOwnPropertyNames(c).concat(Object.getOwnPropertySymbols(c))}:function(c){return Object.getOwnPropertyNames(c)};var es=Number.isNaN||function(c){return c!=c};function EventEmitter(){EventEmitter.init.call(this)}c.exports=EventEmitter,c.exports.once=function(c,l){return new Promise(function(et,eo){function errorListener(et){c.removeListener(l,resolver),eo(et)}function resolver(){"function"==typeof c.removeListener&&c.removeListener("error",errorListener),et([].slice.call(arguments))}eventTargetAgnosticAddListener(c,l,resolver,{once:!0}),"error"!==l&&"function"==typeof c.on&&eventTargetAgnosticAddListener(c,"error",errorListener,{once:!0})})},EventEmitter.EventEmitter=EventEmitter,EventEmitter.prototype._events=void 0,EventEmitter.prototype._eventsCount=0,EventEmitter.prototype._maxListeners=void 0;var ec=10;function checkListener(c){if("function"!=typeof c)throw TypeError('The "listener" argument must be of type Function. Received type '+typeof c)}function _getMaxListeners(c){return void 0===c._maxListeners?EventEmitter.defaultMaxListeners:c._maxListeners}function _addListener(c,l,et,eo){if(checkListener(et),void 0===(ec=c._events)?(ec=c._events=Object.create(null),c._eventsCount=0):(void 0!==ec.newListener&&(c.emit("newListener",l,et.listener?et.listener:et),ec=c._events),el=ec[l]),void 0===el)el=ec[l]=et,++c._eventsCount;else if("function"==typeof el?el=ec[l]=eo?[et,el]:[el,et]:eo?el.unshift(et):el.push(et),(es=_getMaxListeners(c))>0&&el.length>es&&!el.warned){el.warned=!0;var es,ec,el,ed=Error("Possible EventEmitter memory leak detected. "+el.length+" "+String(l)+" listeners added. Use emitter.setMaxListeners() to increase limit");ed.name="MaxListenersExceededWarning",ed.emitter=c,ed.type=l,ed.count=el.length,console&&console.warn&&console.warn(ed)}return c}function onceWrapper(){if(!this.fired)return(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0==arguments.length)?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function _onceWrap(c,l,et){var eo={fired:!1,wrapFn:void 0,target:c,type:l,listener:et},es=onceWrapper.bind(eo);return es.listener=et,eo.wrapFn=es,es}function _listeners(c,l,et){var eo=c._events;if(void 0===eo)return[];var es=eo[l];return void 0===es?[]:"function"==typeof es?et?[es.listener||es]:[es]:et?function(c){for(var l=Array(c.length),et=0;et0&&(el=l[0]),el instanceof Error)throw el;var el,ed=Error("Unhandled error."+(el?" ("+el.message+")":""));throw ed.context=el,ed}var eh=ec[c];if(void 0===eh)return!1;if("function"==typeof eh)eo(eh,this,l);else for(var ef=eh.length,ep=arrayClone(eh,ef),et=0;et=0;ec--)if(et[ec]===l||et[ec].listener===l){el=et[ec].listener,es=ec;break}if(es<0)return this;0===es?et.shift():function(c,l){for(;l+1=0;eo--)this.removeListener(c,l[eo]);return this},EventEmitter.prototype.listeners=function(c){return _listeners(this,c,!0)},EventEmitter.prototype.rawListeners=function(c){return _listeners(this,c,!1)},EventEmitter.listenerCount=function(c,l){return"function"==typeof c.listenerCount?c.listenerCount(l):listenerCount.call(c,l)},EventEmitter.prototype.listenerCount=listenerCount,EventEmitter.prototype.eventNames=function(){return this._eventsCount>0?l(this._events):[]}},83179:function(c){"use strict";var l,et=(l=[{name:"lowercase",re:/[a-z]/,length:26},{name:"uppercase",re:/[A-Z]/,length:26},{name:"numbers",re:/[0-9]/,length:10},{name:"symbols",re:/[^a-zA-Z0-9]/,length:33}],function(c){return l.reduce(function(l,et){return l+(et.re.test(c)?et.length:0)},0)});c.exports=function(c){var l;return c?(l=et(c),Math.round(c.length*Math.log(l)/Math.LN2)):0}},28534:function(c){c.exports=stringify,stringify.default=stringify,stringify.stable=deterministicStringify,stringify.stableStringify=deterministicStringify;var l="[...]",et="[Circular]",eo=[],es=[];function defaultOptions(){return{depthLimit:Number.MAX_SAFE_INTEGER,edgesLimit:Number.MAX_SAFE_INTEGER}}function stringify(c,ec,el,ed){void 0===ed&&(ed=defaultOptions()),function decirc(c,eo,es,ec,el,ed,eh){if(ed+=1,"object"==typeof c&&null!==c){for(ef=0;efeh.depthLimit||void 0!==eh.edgesLimit&&es+1>eh.edgesLimit){setReplace(l,c,eo,el);return}if(ec.push(c),Array.isArray(c))for(ef=0;efl?1:0}function deterministicStringify(c,ec,el,ed){void 0===ed&&(ed=defaultOptions());var eh,ef=function deterministicDecirc(c,es,ec,el,ed,eh,ef){if(eh+=1,"object"==typeof c&&null!==c){for(ep=0;epef.depthLimit||void 0!==ef.edgesLimit&&ec+1>ef.edgesLimit){setReplace(l,c,es,ed);return}if(el.push(c),Array.isArray(c))for(ep=0;ep0)for(var eo=0;eo1&&"boolean"!=typeof l)throw new el('"allowMissing" argument must be a boolean');if(null===eI(/^%?[^%]*%?$/,c))throw new es("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var et=stringToPath(c),eo=et.length>0?et[0]:"",ec=getBaseIntrinsic("%"+eo+"%",l),eh=ec.name,ef=ec.value,ep=!1,eg=ec.alias;eg&&(eo=eg[0],ek(et,ex([0,1],eg)));for(var em=1,eb=!0;em=et.length){var eC=ed(ef,e_);ef=(eb=!!eC)&&"get"in eC&&!("originalValue"in eC.get)?eC.get:ef[e_]}else eb=eS(ef,e_),ef=ef[e_];eb&&!ep&&(ey[eh]=ef)}}return ef}},85118:function(c){"use strict";var l={foo:{}},et=Object;c.exports=function(){return({__proto__:l}).foo===l.foo&&!(({__proto__:null})instanceof et)}},79633:function(c,l,et){"use strict";var eo="undefined"!=typeof Symbol&&Symbol,es=et(76500);c.exports=function(){return"function"==typeof eo&&"function"==typeof Symbol&&"symbol"==typeof eo("foo")&&"symbol"==typeof Symbol("bar")&&es()}},76500:function(c){"use strict";c.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var c={},l=Symbol("test"),et=Object(l);if("string"==typeof l||"[object Symbol]"!==Object.prototype.toString.call(l)||"[object Symbol]"!==Object.prototype.toString.call(et))return!1;for(l in c[l]=42,c)return!1;if("function"==typeof Object.keys&&0!==Object.keys(c).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(c).length)return!1;var eo=Object.getOwnPropertySymbols(c);if(1!==eo.length||eo[0]!==l||!Object.prototype.propertyIsEnumerable.call(c,l))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var es=Object.getOwnPropertyDescriptor(c,l);if(42!==es.value||!0!==es.enumerable)return!1}return!0}},95427:function(c){"use strict";var l={}.hasOwnProperty,et=Function.prototype.call;c.exports=et.bind?et.bind(l):function(c,eo){return et.call(l,c,eo)}},55336:function(c,l,et){l.utils=et(65794),l.common=et(49619),l.sha=et(53610),l.ripemd=et(17721),l.hmac=et(56432),l.sha1=l.sha.sha1,l.sha256=l.sha.sha256,l.sha224=l.sha.sha224,l.sha384=l.sha.sha384,l.sha512=l.sha.sha512,l.ripemd160=l.ripemd.ripemd160},49619:function(c,l,et){"use strict";var eo=et(65794),es=et(8786);function BlockHash(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}l.BlockHash=BlockHash,BlockHash.prototype.update=function(c,l){if(c=eo.toArray(c,l),this.pending?this.pending=this.pending.concat(c):this.pending=c,this.pendingTotal+=c.length,this.pending.length>=this._delta8){var et=(c=this.pending).length%this._delta8;this.pending=c.slice(c.length-et,c.length),0===this.pending.length&&(this.pending=null),c=eo.join32(c,0,c.length-et,this.endian);for(var es=0;es>>24&255,eo[es++]=c>>>16&255,eo[es++]=c>>>8&255,eo[es++]=255&c}else for(ec=8,eo[es++]=255&c,eo[es++]=c>>>8&255,eo[es++]=c>>>16&255,eo[es++]=c>>>24&255,eo[es++]=0,eo[es++]=0,eo[es++]=0,eo[es++]=0;ecthis.blockSize&&(c=new this.Hash().update(c).digest()),es(c.length<=this.blockSize);for(var l=c.length;l>>3},l.g1_256=function(c){return eo(c,17)^eo(c,19)^c>>>10}},65794:function(c,l,et){"use strict";var eo=et(8786),es=et(75335);function htonl(c){return(c>>>24|c>>>8&65280|c<<8&16711680|(255&c)<<24)>>>0}function zero2(c){return 1===c.length?"0"+c:c}function zero8(c){if(7===c.length)return"0"+c;if(6===c.length)return"00"+c;if(5===c.length)return"000"+c;if(4===c.length)return"0000"+c;if(3===c.length)return"00000"+c;if(2===c.length)return"000000"+c;if(1===c.length)return"0000000"+c;else return c}l.inherits=es,l.toArray=function(c,l){if(Array.isArray(c))return c.slice();if(!c)return[];var et=[];if("string"==typeof c){if(l){if("hex"===l)for((c=c.replace(/[^a-z0-9]+/ig,"")).length%2!=0&&(c="0"+c),es=0;es>6|192:((ec=c,el=es,(64512&ec.charCodeAt(el))!=55296||el<0||el+1>=ec.length?1:(64512&ec.charCodeAt(el+1))!=56320)?et[eo++]=ed>>12|224:(ed=65536+((1023&ed)<<10)+(1023&c.charCodeAt(++es)),et[eo++]=ed>>18|240,et[eo++]=ed>>12&63|128),et[eo++]=ed>>6&63|128),et[eo++]=63&ed|128)}}else for(es=0;es>>0;return ed},l.split32=function(c,l){for(var et=Array(4*c.length),eo=0,es=0;eo>>24,et[es+1]=ec>>>16&255,et[es+2]=ec>>>8&255,et[es+3]=255&ec):(et[es+3]=ec>>>24,et[es+2]=ec>>>16&255,et[es+1]=ec>>>8&255,et[es]=255&ec)}return et},l.rotr32=function(c,l){return c>>>l|c<<32-l},l.rotl32=function(c,l){return c<>>32-l},l.sum32=function(c,l){return c+l>>>0},l.sum32_3=function(c,l,et){return c+l+et>>>0},l.sum32_4=function(c,l,et,eo){return c+l+et+eo>>>0},l.sum32_5=function(c,l,et,eo,es){return c+l+et+eo+es>>>0},l.sum64=function(c,l,et,eo){var es=c[l],ec=eo+c[l+1]>>>0;c[l]=(ec>>0,c[l+1]=ec},l.sum64_hi=function(c,l,et,eo){return(l+eo>>>0>>0},l.sum64_lo=function(c,l,et,eo){return l+eo>>>0},l.sum64_4_hi=function(c,l,et,eo,es,ec,el,ed){var eh,ef=l;return c+et+es+el+(0+((ef=ef+eo>>>0)>>0)>>0)>>0},l.sum64_4_lo=function(c,l,et,eo,es,ec,el,ed){return l+eo+ec+ed>>>0},l.sum64_5_hi=function(c,l,et,eo,es,ec,el,ed,eh,ef){var ep,eg=l;return c+et+es+el+eh+(0+((eg=eg+eo>>>0)>>0)>>0)>>0)>>0},l.sum64_5_lo=function(c,l,et,eo,es,ec,el,ed,eh,ef){return l+eo+ec+ed+ef>>>0},l.rotr64_hi=function(c,l,et){return(l<<32-et|c>>>et)>>>0},l.rotr64_lo=function(c,l,et){return(c<<32-et|l>>>et)>>>0},l.shr64_hi=function(c,l,et){return c>>>et},l.shr64_lo=function(c,l,et){return(c<<32-et|l>>>et)>>>0}},55487:function(c,l,et){"use strict";var eo=et(9176),es={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},ec={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},el={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},ed={};function getStatics(c){return eo.isMemo(c)?el:ed[c.$$typeof]||es}ed[eo.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},ed[eo.Memo]=el;var eh=Object.defineProperty,ef=Object.getOwnPropertyNames,ep=Object.getOwnPropertySymbols,eg=Object.getOwnPropertyDescriptor,em=Object.getPrototypeOf,eb=Object.prototype;c.exports=function hoistNonReactStatics(c,l,et){if("string"!=typeof l){if(eb){var eo=em(l);eo&&eo!==eb&&hoistNonReactStatics(c,eo,et)}var es=ef(l);ep&&(es=es.concat(ep(l)));for(var el=getStatics(c),ed=getStatics(l),ey=0;ey */l.read=function(c,l,et,eo,es){var ec,el,ed=8*es-eo-1,eh=(1<>1,ep=-7,eg=et?es-1:0,em=et?-1:1,eb=c[l+eg];for(eg+=em,ec=eb&(1<<-ep)-1,eb>>=-ep,ep+=ed;ep>0;ec=256*ec+c[l+eg],eg+=em,ep-=8);for(el=ec&(1<<-ep)-1,ec>>=-ep,ep+=eo;ep>0;el=256*el+c[l+eg],eg+=em,ep-=8);if(0===ec)ec=1-ef;else{if(ec===eh)return el?NaN:(eb?-1:1)*(1/0);el+=Math.pow(2,eo),ec-=ef}return(eb?-1:1)*el*Math.pow(2,ec-eo)},l.write=function(c,l,et,eo,es,ec){var el,ed,eh,ef=8*ec-es-1,ep=(1<>1,em=23===es?5960464477539062e-23:0,eb=eo?0:ec-1,ey=eo?1:-1,e_=l<0||0===l&&1/l<0?1:0;for(isNaN(l=Math.abs(l))||l===1/0?(ed=isNaN(l)?1:0,el=ep):(el=Math.floor(Math.log(l)/Math.LN2),l*(eh=Math.pow(2,-el))<1&&(el--,eh*=2),el+eg>=1?l+=em/eh:l+=em*Math.pow(2,1-eg),l*eh>=2&&(el++,eh/=2),el+eg>=ep?(ed=0,el=ep):el+eg>=1?(ed=(l*eh-1)*Math.pow(2,es),el+=eg):(ed=l*Math.pow(2,eg-1)*Math.pow(2,es),el=0));es>=8;c[et+eb]=255&ed,eb+=ey,ed/=256,es-=8);for(el=el<0;c[et+eb]=255&el,eb+=ey,el/=256,ef-=8);c[et+eb-ey]|=128*e_}},75335:function(c){"function"==typeof Object.create?c.exports=function(c,l){l&&(c.super_=l,c.prototype=Object.create(l.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}))}:c.exports=function(c,l){if(l){c.super_=l;var TempCtor=function(){};TempCtor.prototype=l.prototype,c.prototype=new TempCtor,c.prototype.constructor=c}}},82333:function(c){var l={}.toString;c.exports=Array.isArray||function(c){return"[object Array]"==l.call(c)}},26398:function(c,l,et){var eo,es=et(25566);!function(){"use strict";var ec="input is invalid type",el="object"==typeof window,ed=el?window:{};ed.JS_SHA3_NO_WINDOW&&(el=!1);var eh=!el&&"object"==typeof self;!ed.JS_SHA3_NO_NODE_JS&&"object"==typeof es&&es.versions&&es.versions.node?ed=et.g:eh&&(ed=self);var ef=!ed.JS_SHA3_NO_COMMON_JS&&c.exports,ep=et.amdO,eg=!ed.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,em="0123456789abcdef".split(""),eb=[4,1024,262144,67108864],ey=[0,8,16,24],e_=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],ew=[224,256,384,512],eE=[128,256],eS=["hex","buffer","arrayBuffer","array","digest"],ex={128:168,256:136};(ed.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(c){return"[object Array]"===Object.prototype.toString.call(c)}),eg&&(ed.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(c){return"object"==typeof c&&c.buffer&&c.buffer.constructor===ArrayBuffer});for(var createOutputMethod=function(c,l,et){return function(eo){return new Keccak(c,l,c).update(eo)[et]()}},createShakeOutputMethod=function(c,l,et){return function(eo,es){return new Keccak(c,l,es).update(eo)[et]()}},createCshakeOutputMethod=function(c,l,et){return function(l,eo,es,ec){return eC["cshake"+c].update(l,eo,es,ec)[et]()}},createKmacOutputMethod=function(c,l,et){return function(l,eo,es,ec){return eC["kmac"+c].update(l,eo,es,ec)[et]()}},createOutputMethods=function(c,l,et,eo){for(var es=0;es>5,this.byteCount=this.blockCount<<2,this.outputBlocks=et>>5,this.extraBytes=(31&et)>>3;for(var eo=0;eo<50;++eo)this.s[eo]=0}function Kmac(c,l,et){Keccak.call(this,c,l,et)}Keccak.prototype.update=function(c){if(this.finalized)throw Error("finalize already called");var l,et=typeof c;if("string"!==et){if("object"===et){if(null===c)throw Error(ec);if(eg&&c.constructor===ArrayBuffer)c=new Uint8Array(c);else if(!Array.isArray(c)&&(!eg||!ArrayBuffer.isView(c)))throw Error(ec)}else throw Error(ec);l=!0}for(var eo,es,el=this.blocks,ed=this.byteCount,eh=c.length,ef=this.blockCount,ep=0,em=this.s;ep>2]|=c[ep]<>2]|=es<>2]|=(192|es>>6)<=57344?el[eo>>2]|=(224|es>>12)<>2]|=(240|es>>18)<>2]|=(128|es>>12&63)<>2]|=(128|es>>6&63)<>2]|=(128|63&es)<=ed){for(this.start=eo-ed,this.block=el[ef],eo=0;eo>=8,et=255&c;et>0;)es.unshift(et),c>>=8,et=255&c,++eo;return l?es.push(eo):es.unshift(eo),this.update(es),es.length},Keccak.prototype.encodeString=function(c){var l,et=typeof c;if("string"!==et){if("object"===et){if(null===c)throw Error(ec);if(eg&&c.constructor===ArrayBuffer)c=new Uint8Array(c);else if(!Array.isArray(c)&&(!eg||!ArrayBuffer.isView(c)))throw Error(ec)}else throw Error(ec);l=!0}var eo=0,es=c.length;if(l)eo=es;else for(var el=0;el=57344?eo+=3:(ed=65536+((1023&ed)<<10|1023&c.charCodeAt(++el)),eo+=4)}return eo+=this.encode(8*eo),this.update(c),eo},Keccak.prototype.bytepad=function(c,l){for(var et=this.encode(l),eo=0;eo>2]|=this.padding[3&l],this.lastByteIndex===this.byteCount)for(l=1,c[0]=c[et];l>4&15]+em[15&c]+em[c>>12&15]+em[c>>8&15]+em[c>>20&15]+em[c>>16&15]+em[c>>28&15]+em[c>>24&15];el%l==0&&(f(et),ec=0)}return es&&(ed+=em[(c=et[ec])>>4&15]+em[15&c],es>1&&(ed+=em[c>>12&15]+em[c>>8&15]),es>2&&(ed+=em[c>>20&15]+em[c>>16&15])),ed},Keccak.prototype.arrayBuffer=function(){this.finalize();var c,l=this.blockCount,et=this.s,eo=this.outputBlocks,es=this.extraBytes,ec=0,el=0,ed=this.outputBits>>3;c=new ArrayBuffer(es?eo+1<<2:ed);for(var eh=new Uint32Array(c);el>8&255,eh[c+2]=l>>16&255,eh[c+3]=l>>24&255;ed%et==0&&f(eo)}return ec&&(c=ed<<2,l=eo[el],eh[c]=255&l,ec>1&&(eh[c+1]=l>>8&255),ec>2&&(eh[c+2]=l>>16&255)),eh},Kmac.prototype=new Keccak,Kmac.prototype.finalize=function(){return this.encode(this.outputBits,!0),Keccak.prototype.finalize.call(this)};var f=function(c){var l,et,eo,es,ec,el,ed,eh,ef,ep,eg,em,eb,ey,ew,eE,eS,ex,ek,eC,eA,eI,eP,eR,eO,eT,eN,eM,e$,eB,eD,ej,eL,eF,eU,ez,eH,eW,eV,eG,eK,eJ,eQ,eY,eZ,eX,e0,e1,e2,e3,e5,e6,e4,e8,e9,e7,tn,to,ts,ta,tc,tl,td;for(eo=0;eo<48;eo+=2)es=c[0]^c[10]^c[20]^c[30]^c[40],ec=c[1]^c[11]^c[21]^c[31]^c[41],el=c[2]^c[12]^c[22]^c[32]^c[42],ed=c[3]^c[13]^c[23]^c[33]^c[43],eh=c[4]^c[14]^c[24]^c[34]^c[44],ef=c[5]^c[15]^c[25]^c[35]^c[45],ep=c[6]^c[16]^c[26]^c[36]^c[46],eg=c[7]^c[17]^c[27]^c[37]^c[47],em=c[8]^c[18]^c[28]^c[38]^c[48],eb=c[9]^c[19]^c[29]^c[39]^c[49],l=em^(el<<1|ed>>>31),et=eb^(ed<<1|el>>>31),c[0]^=l,c[1]^=et,c[10]^=l,c[11]^=et,c[20]^=l,c[21]^=et,c[30]^=l,c[31]^=et,c[40]^=l,c[41]^=et,l=es^(eh<<1|ef>>>31),et=ec^(ef<<1|eh>>>31),c[2]^=l,c[3]^=et,c[12]^=l,c[13]^=et,c[22]^=l,c[23]^=et,c[32]^=l,c[33]^=et,c[42]^=l,c[43]^=et,l=el^(ep<<1|eg>>>31),et=ed^(eg<<1|ep>>>31),c[4]^=l,c[5]^=et,c[14]^=l,c[15]^=et,c[24]^=l,c[25]^=et,c[34]^=l,c[35]^=et,c[44]^=l,c[45]^=et,l=eh^(em<<1|eb>>>31),et=ef^(eb<<1|em>>>31),c[6]^=l,c[7]^=et,c[16]^=l,c[17]^=et,c[26]^=l,c[27]^=et,c[36]^=l,c[37]^=et,c[46]^=l,c[47]^=et,l=ep^(es<<1|ec>>>31),et=eg^(ec<<1|es>>>31),c[8]^=l,c[9]^=et,c[18]^=l,c[19]^=et,c[28]^=l,c[29]^=et,c[38]^=l,c[39]^=et,c[48]^=l,c[49]^=et,ey=c[0],ew=c[1],eX=c[11]<<4|c[10]>>>28,e0=c[10]<<4|c[11]>>>28,eM=c[20]<<3|c[21]>>>29,e$=c[21]<<3|c[20]>>>29,ta=c[31]<<9|c[30]>>>23,tc=c[30]<<9|c[31]>>>23,eJ=c[40]<<18|c[41]>>>14,eQ=c[41]<<18|c[40]>>>14,eF=c[2]<<1|c[3]>>>31,eU=c[3]<<1|c[2]>>>31,eE=c[13]<<12|c[12]>>>20,eS=c[12]<<12|c[13]>>>20,e1=c[22]<<10|c[23]>>>22,e2=c[23]<<10|c[22]>>>22,eB=c[33]<<13|c[32]>>>19,eD=c[32]<<13|c[33]>>>19,tl=c[42]<<2|c[43]>>>30,td=c[43]<<2|c[42]>>>30,e8=c[5]<<30|c[4]>>>2,e9=c[4]<<30|c[5]>>>2,ez=c[14]<<6|c[15]>>>26,eH=c[15]<<6|c[14]>>>26,ex=c[25]<<11|c[24]>>>21,ek=c[24]<<11|c[25]>>>21,e3=c[34]<<15|c[35]>>>17,e5=c[35]<<15|c[34]>>>17,ej=c[45]<<29|c[44]>>>3,eL=c[44]<<29|c[45]>>>3,eR=c[6]<<28|c[7]>>>4,eO=c[7]<<28|c[6]>>>4,e7=c[17]<<23|c[16]>>>9,tn=c[16]<<23|c[17]>>>9,eW=c[26]<<25|c[27]>>>7,eV=c[27]<<25|c[26]>>>7,eC=c[36]<<21|c[37]>>>11,eA=c[37]<<21|c[36]>>>11,e6=c[47]<<24|c[46]>>>8,e4=c[46]<<24|c[47]>>>8,eY=c[8]<<27|c[9]>>>5,eZ=c[9]<<27|c[8]>>>5,eT=c[18]<<20|c[19]>>>12,eN=c[19]<<20|c[18]>>>12,to=c[29]<<7|c[28]>>>25,ts=c[28]<<7|c[29]>>>25,eG=c[38]<<8|c[39]>>>24,eK=c[39]<<8|c[38]>>>24,eI=c[48]<<14|c[49]>>>18,eP=c[49]<<14|c[48]>>>18,c[0]=ey^~eE&ex,c[1]=ew^~eS&ek,c[10]=eR^~eT&eM,c[11]=eO^~eN&e$,c[20]=eF^~ez&eW,c[21]=eU^~eH&eV,c[30]=eY^~eX&e1,c[31]=eZ^~e0&e2,c[40]=e8^~e7&to,c[41]=e9^~tn&ts,c[2]=eE^~ex&eC,c[3]=eS^~ek&eA,c[12]=eT^~eM&eB,c[13]=eN^~e$&eD,c[22]=ez^~eW&eG,c[23]=eH^~eV&eK,c[32]=eX^~e1&e3,c[33]=e0^~e2&e5,c[42]=e7^~to&ta,c[43]=tn^~ts&tc,c[4]=ex^~eC&eI,c[5]=ek^~eA&eP,c[14]=eM^~eB&ej,c[15]=e$^~eD&eL,c[24]=eW^~eG&eJ,c[25]=eV^~eK&eQ,c[34]=e1^~e3&e6,c[35]=e2^~e5&e4,c[44]=to^~ta&tl,c[45]=ts^~tc&td,c[6]=eC^~eI&ey,c[7]=eA^~eP&ew,c[16]=eB^~ej&eR,c[17]=eD^~eL&eO,c[26]=eG^~eJ&eF,c[27]=eK^~eQ&eU,c[36]=e3^~e6&eY,c[37]=e5^~e4&eZ,c[46]=ta^~tl&e8,c[47]=tc^~td&e9,c[8]=eI^~ey&eE,c[9]=eP^~ew&eS,c[18]=ej^~eR&eT,c[19]=eL^~eO&eN,c[28]=eJ^~eF&ez,c[29]=eQ^~eU&eH,c[38]=e6^~eY&eX,c[39]=e4^~eZ&e0,c[48]=tl^~e8&e7,c[49]=td^~e9&tn,c[0]^=e_[eo],c[1]^=e_[eo+1]};if(ef)c.exports=eC;else{for(eI=0;eI{try{let[es,ec,el]=await JsonRpcEngine._runAllMiddleware(c,l,this._middleware);if(ec)return await JsonRpcEngine._runReturnHandlers(el),eo(es);return et(async c=>{try{await JsonRpcEngine._runReturnHandlers(el)}catch(l){return c(l)}return c()})}catch(c){return eo(c)}}}async _handleBatch(c,l){try{let et=await Promise.all(c.map(this._promiseHandle.bind(this)));if(l)return l(null,et);return et}catch(c){if(l)return l(c);throw c}}_promiseHandle(c){return new Promise(l=>{this._handle(c,(c,et)=>{l(et)})})}async _handle(c,l){if(!c||Array.isArray(c)||"object"!=typeof c){let et=new ec.EthereumRpcError(ec.errorCodes.rpc.invalidRequest,`Requests must be plain objects. Received: ${typeof c}`,{request:c});return l(et,{id:void 0,jsonrpc:"2.0",error:et})}if("string"!=typeof c.method){let et=new ec.EthereumRpcError(ec.errorCodes.rpc.invalidRequest,`Must specify a string method. Received: ${typeof c.method}`,{request:c});return l(et,{id:c.id,jsonrpc:"2.0",error:et})}let et=Object.assign({},c),eo={id:et.id,jsonrpc:et.jsonrpc},es=null;try{await this._processRequest(et,eo)}catch(c){es=c}return es&&(delete eo.result,eo.error||(eo.error=ec.serializeError(es))),l(es,eo)}async _processRequest(c,l){let[et,eo,es]=await JsonRpcEngine._runAllMiddleware(c,l,this._middleware);if(JsonRpcEngine._checkForCompletion(c,l,eo),await JsonRpcEngine._runReturnHandlers(es),et)throw et}static async _runAllMiddleware(c,l,et){let eo=[],es=null,ec=!1;for(let el of et)if([es,ec]=await JsonRpcEngine._runMiddleware(c,l,el,eo),ec)break;return[es,ec,eo.reverse()]}static _runMiddleware(c,l,et,eo){return new Promise(es=>{let end=c=>{let et=c||l.error;et&&(l.error=ec.serializeError(et)),es([et,!0])};try{et(c,l,et=>{l.error?end(l.error):(et&&("function"!=typeof et&&end(new ec.EthereumRpcError(ec.errorCodes.rpc.internal,`JsonRpcEngine: "next" return handlers must be functions. Received "${typeof et}" for request: +${jsonify(c)}`,{request:c})),eo.push(et)),es([null,!1]))},end)}catch(c){end(c)}})}static async _runReturnHandlers(c){for(let l of c)await new Promise((c,et)=>{l(l=>l?et(l):c())})}static _checkForCompletion(c,l,et){if(!("result"in l)&&!("error"in l))throw new ec.EthereumRpcError(ec.errorCodes.rpc.internal,`JsonRpcEngine: Response has no error or result for request: +${jsonify(c)}`,{request:c});if(!et)throw new ec.EthereumRpcError(ec.errorCodes.rpc.internal,`JsonRpcEngine: Nothing ended request: +${jsonify(c)}`,{request:c})}};function jsonify(c){return JSON.stringify(c,null,2)}l.JsonRpcEngine=JsonRpcEngine},4029:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.createAsyncMiddleware=void 0,l.createAsyncMiddleware=function(c){return async(l,et,eo,es)=>{let ec;let el=new Promise(c=>{ec=c}),ed=null,eh=!1,asyncNext=async()=>{eh=!0,eo(c=>{ed=c,ec()}),await el};try{await c(l,et,asyncNext),eh?(await el,ed(null)):es(null)}catch(c){ed?ed(c):es(c)}}}},74386:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.createScaffoldMiddleware=void 0,l.createScaffoldMiddleware=function(c){return(l,et,eo,es)=>{let ec=c[l.method];return void 0===ec?eo():"function"==typeof ec?ec(l,et,eo,es):(et.result=ec,es())}}},74719:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.getUniqueId=void 0;let et=Math.floor(4294967295*Math.random());l.getUniqueId=function(){return et=(et+1)%4294967295}},94449:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.createIdRemapMiddleware=void 0;let eo=et(74719);l.createIdRemapMiddleware=function(){return(c,l,et,es)=>{let ec=c.id,el=eo.getUniqueId();c.id=el,l.id=el,et(et=>{c.id=ec,l.id=ec,et()})}}},49116:function(c,l,et){"use strict";var eo=this&&this.__createBinding||(Object.create?function(c,l,et,eo){void 0===eo&&(eo=et),Object.defineProperty(c,eo,{enumerable:!0,get:function(){return l[et]}})}:function(c,l,et,eo){void 0===eo&&(eo=et),c[eo]=l[et]}),es=this&&this.__exportStar||function(c,l){for(var et in c)"default"===et||Object.prototype.hasOwnProperty.call(l,et)||eo(l,c,et)};Object.defineProperty(l,"__esModule",{value:!0}),es(et(94449),l),es(et(4029),l),es(et(74386),l),es(et(74719),l),es(et(8566),l),es(et(13592),l)},13592:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.mergeMiddleware=void 0;let eo=et(8566);l.mergeMiddleware=function(c){let l=new eo.JsonRpcEngine;return c.forEach(c=>l.push(c)),l.asMiddleware()}},53559:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.EthereumProviderError=l.EthereumRpcError=void 0;let eo=et(28534);let EthereumRpcError=class EthereumRpcError extends Error{constructor(c,l,et){if(!Number.isInteger(c))throw Error('"code" must be an integer.');if(!l||"string"!=typeof l)throw Error('"message" must be a nonempty string.');super(l),this.code=c,void 0!==et&&(this.data=et)}serialize(){let c={code:this.code,message:this.message};return void 0!==this.data&&(c.data=this.data),this.stack&&(c.stack=this.stack),c}toString(){return eo.default(this.serialize(),stringifyReplacer,2)}};function stringifyReplacer(c,l){if("[Circular]"!==l)return l}l.EthereumRpcError=EthereumRpcError,l.EthereumProviderError=class extends EthereumRpcError{constructor(c,l,et){if(!(Number.isInteger(c)&&c>=1e3&&c<=4999))throw Error('"code" must be an integer such that: 1000 <= code <= 4999');super(c,l,et)}}},70357:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.errorValues=l.errorCodes=void 0,l.errorCodes={rpc:{invalidInput:-32e3,resourceNotFound:-32001,resourceUnavailable:-32002,transactionRejected:-32003,methodNotSupported:-32004,limitExceeded:-32005,parse:-32700,invalidRequest:-32600,methodNotFound:-32601,invalidParams:-32602,internal:-32603},provider:{userRejectedRequest:4001,unauthorized:4100,unsupportedMethod:4200,disconnected:4900,chainDisconnected:4901}},l.errorValues={"-32700":{standard:"JSON RPC 2.0",message:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."},"-32600":{standard:"JSON RPC 2.0",message:"The JSON sent is not a valid Request object."},"-32601":{standard:"JSON RPC 2.0",message:"The method does not exist / is not available."},"-32602":{standard:"JSON RPC 2.0",message:"Invalid method parameter(s)."},"-32603":{standard:"JSON RPC 2.0",message:"Internal JSON-RPC error."},"-32000":{standard:"EIP-1474",message:"Invalid input."},"-32001":{standard:"EIP-1474",message:"Resource not found."},"-32002":{standard:"EIP-1474",message:"Resource unavailable."},"-32003":{standard:"EIP-1474",message:"Transaction rejected."},"-32004":{standard:"EIP-1474",message:"Method not supported."},"-32005":{standard:"EIP-1474",message:"Request limit exceeded."},4001:{standard:"EIP-1193",message:"User rejected the request."},4100:{standard:"EIP-1193",message:"The requested account and/or method has not been authorized by the user."},4200:{standard:"EIP-1193",message:"The requested method is not supported by this Ethereum provider."},4900:{standard:"EIP-1193",message:"The provider is disconnected from all chains."},4901:{standard:"EIP-1193",message:"The provider is disconnected from the specified chain."}}},70010:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.ethErrors=void 0;let eo=et(53559),es=et(70394),ec=et(70357);function getEthJsonRpcError(c,l){let[et,ec]=parseOpts(l);return new eo.EthereumRpcError(c,et||es.getMessageFromCode(c),ec)}function getEthProviderError(c,l){let[et,ec]=parseOpts(l);return new eo.EthereumProviderError(c,et||es.getMessageFromCode(c),ec)}function parseOpts(c){if(c){if("string"==typeof c)return[c];if("object"==typeof c&&!Array.isArray(c)){let{message:l,data:et}=c;if(l&&"string"!=typeof l)throw Error("Must specify string message.");return[l||void 0,et]}}return[]}l.ethErrors={rpc:{parse:c=>getEthJsonRpcError(ec.errorCodes.rpc.parse,c),invalidRequest:c=>getEthJsonRpcError(ec.errorCodes.rpc.invalidRequest,c),invalidParams:c=>getEthJsonRpcError(ec.errorCodes.rpc.invalidParams,c),methodNotFound:c=>getEthJsonRpcError(ec.errorCodes.rpc.methodNotFound,c),internal:c=>getEthJsonRpcError(ec.errorCodes.rpc.internal,c),server:c=>{if(!c||"object"!=typeof c||Array.isArray(c))throw Error("Ethereum RPC Server errors must provide single object argument.");let{code:l}=c;if(!Number.isInteger(l)||l>-32005||l<-32099)throw Error('"code" must be an integer such that: -32099 <= code <= -32005');return getEthJsonRpcError(l,c)},invalidInput:c=>getEthJsonRpcError(ec.errorCodes.rpc.invalidInput,c),resourceNotFound:c=>getEthJsonRpcError(ec.errorCodes.rpc.resourceNotFound,c),resourceUnavailable:c=>getEthJsonRpcError(ec.errorCodes.rpc.resourceUnavailable,c),transactionRejected:c=>getEthJsonRpcError(ec.errorCodes.rpc.transactionRejected,c),methodNotSupported:c=>getEthJsonRpcError(ec.errorCodes.rpc.methodNotSupported,c),limitExceeded:c=>getEthJsonRpcError(ec.errorCodes.rpc.limitExceeded,c)},provider:{userRejectedRequest:c=>getEthProviderError(ec.errorCodes.provider.userRejectedRequest,c),unauthorized:c=>getEthProviderError(ec.errorCodes.provider.unauthorized,c),unsupportedMethod:c=>getEthProviderError(ec.errorCodes.provider.unsupportedMethod,c),disconnected:c=>getEthProviderError(ec.errorCodes.provider.disconnected,c),chainDisconnected:c=>getEthProviderError(ec.errorCodes.provider.chainDisconnected,c),custom:c=>{if(!c||"object"!=typeof c||Array.isArray(c))throw Error("Ethereum Provider custom errors must provide single object argument.");let{code:l,message:et,data:es}=c;if(!et||"string"!=typeof et)throw Error('"message" must be a nonempty string');return new eo.EthereumProviderError(l,et,es)}}}},89248:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.getMessageFromCode=l.serializeError=l.EthereumProviderError=l.EthereumRpcError=l.ethErrors=l.errorCodes=void 0;let eo=et(53559);Object.defineProperty(l,"EthereumRpcError",{enumerable:!0,get:function(){return eo.EthereumRpcError}}),Object.defineProperty(l,"EthereumProviderError",{enumerable:!0,get:function(){return eo.EthereumProviderError}});let es=et(70394);Object.defineProperty(l,"serializeError",{enumerable:!0,get:function(){return es.serializeError}}),Object.defineProperty(l,"getMessageFromCode",{enumerable:!0,get:function(){return es.getMessageFromCode}});let ec=et(70010);Object.defineProperty(l,"ethErrors",{enumerable:!0,get:function(){return ec.ethErrors}});let el=et(70357);Object.defineProperty(l,"errorCodes",{enumerable:!0,get:function(){return el.errorCodes}})},70394:function(c,l,et){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.serializeError=l.isValidCode=l.getMessageFromCode=l.JSON_RPC_SERVER_ERROR_MESSAGE=void 0;let eo=et(70357),es=et(53559),ec=eo.errorCodes.rpc.internal,el={code:ec,message:getMessageFromCode(ec)};function getMessageFromCode(c,et="Unspecified error message. This is a bug, please report it."){if(Number.isInteger(c)){let et=c.toString();if(hasKey(eo.errorValues,et))return eo.errorValues[et].message;if(c>=-32099&&c<=-32e3)return l.JSON_RPC_SERVER_ERROR_MESSAGE}return et}function isValidCode(c){if(!Number.isInteger(c))return!1;let l=c.toString();return!!(eo.errorValues[l]||c>=-32099&&c<=-32e3)}function assignOriginalError(c){return c&&"object"==typeof c&&!Array.isArray(c)?Object.assign({},c):c}function hasKey(c,l){return Object.prototype.hasOwnProperty.call(c,l)}l.JSON_RPC_SERVER_ERROR_MESSAGE="Unspecified server error.",l.getMessageFromCode=getMessageFromCode,l.isValidCode=isValidCode,l.serializeError=function(c,{fallbackError:l=el,shouldIncludeStack:et=!1}={}){if(!l||!Number.isInteger(l.code)||"string"!=typeof l.message)throw Error("Must provide fallback error with integer number code and string message.");if(c instanceof es.EthereumRpcError)return c.serialize();let eo={};if(c&&"object"==typeof c&&!Array.isArray(c)&&hasKey(c,"code")&&isValidCode(c.code))eo.code=c.code,c.message&&"string"==typeof c.message?(eo.message=c.message,hasKey(c,"data")&&(eo.data=c.data)):(eo.message=getMessageFromCode(eo.code),eo.data={originalError:assignOriginalError(c)});else{eo.code=l.code;let et=null==c?void 0:c.message;eo.message=et&&"string"==typeof et?et:l.message,eo.data={originalError:assignOriginalError(c)}}let ec=null==c?void 0:c.stack;return et&&c&&ec&&"string"==typeof ec&&(eo.stack=ec),eo}},21192:function(c){c.exports=function(c){var l=(c=c||{}).max||Number.MAX_SAFE_INTEGER,et=void 0!==c.start?c.start:Math.floor(Math.random()*l);return function(){return et%=l,et++}}},26961:function(c,l,et){c.exports=et(8478)(et(64586))},8478:function(c,l,et){let eo=et(99001),es=et(68013);c.exports=function(c){let l=eo(c),et=es(c);return function(c,eo){let es="string"==typeof c?c.toLowerCase():c;switch(es){case"keccak224":return new l(1152,448,null,224,eo);case"keccak256":return new l(1088,512,null,256,eo);case"keccak384":return new l(832,768,null,384,eo);case"keccak512":return new l(576,1024,null,512,eo);case"sha3-224":return new l(1152,448,6,224,eo);case"sha3-256":return new l(1088,512,6,256,eo);case"sha3-384":return new l(832,768,6,384,eo);case"sha3-512":return new l(576,1024,6,512,eo);case"shake128":return new et(1344,256,31,eo);case"shake256":return new et(1088,512,31,eo);default:throw Error("Invald algorithm: "+c)}}}},99001:function(c,l,et){var eo=et(67133).Buffer;let{Transform:es}=et(21579);c.exports=c=>class Keccak extends es{constructor(l,et,eo,es,ec){super(ec),this._rate=l,this._capacity=et,this._delimitedSuffix=eo,this._hashBitLength=es,this._options=ec,this._state=new c,this._state.initialize(l,et),this._finalized=!1}_transform(c,l,et){let eo=null;try{this.update(c,l)}catch(c){eo=c}et(eo)}_flush(c){let l=null;try{this.push(this.digest())}catch(c){l=c}c(l)}update(c,l){if(!eo.isBuffer(c)&&"string"!=typeof c)throw TypeError("Data must be a string or a buffer");if(this._finalized)throw Error("Digest already called");return eo.isBuffer(c)||(c=eo.from(c,l)),this._state.absorb(c),this}digest(c){if(this._finalized)throw Error("Digest already called");this._finalized=!0,this._delimitedSuffix&&this._state.absorbLastFewBits(this._delimitedSuffix);let l=this._state.squeeze(this._hashBitLength/8);return void 0!==c&&(l=l.toString(c)),this._resetState(),l}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){let c=new Keccak(this._rate,this._capacity,this._delimitedSuffix,this._hashBitLength,this._options);return this._state.copy(c._state),c._finalized=this._finalized,c}}},68013:function(c,l,et){var eo=et(67133).Buffer;let{Transform:es}=et(21579);c.exports=c=>class Shake extends es{constructor(l,et,eo,es){super(es),this._rate=l,this._capacity=et,this._delimitedSuffix=eo,this._options=es,this._state=new c,this._state.initialize(l,et),this._finalized=!1}_transform(c,l,et){let eo=null;try{this.update(c,l)}catch(c){eo=c}et(eo)}_flush(){}_read(c){this.push(this.squeeze(c))}update(c,l){if(!eo.isBuffer(c)&&"string"!=typeof c)throw TypeError("Data must be a string or a buffer");if(this._finalized)throw Error("Squeeze already called");return eo.isBuffer(c)||(c=eo.from(c,l)),this._state.absorb(c),this}squeeze(c,l){this._finalized||(this._finalized=!0,this._state.absorbLastFewBits(this._delimitedSuffix));let et=this._state.squeeze(c);return void 0!==l&&(et=et.toString(l)),et}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){let c=new Shake(this._rate,this._capacity,this._delimitedSuffix,this._options);return this._state.copy(c._state),c._finalized=this._finalized,c}}},89773:function(c,l){let et=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648];l.p1600=function(c){for(let l=0;l<24;++l){let eo=c[0]^c[10]^c[20]^c[30]^c[40],es=c[1]^c[11]^c[21]^c[31]^c[41],ec=c[2]^c[12]^c[22]^c[32]^c[42],el=c[3]^c[13]^c[23]^c[33]^c[43],ed=c[4]^c[14]^c[24]^c[34]^c[44],eh=c[5]^c[15]^c[25]^c[35]^c[45],ef=c[6]^c[16]^c[26]^c[36]^c[46],ep=c[7]^c[17]^c[27]^c[37]^c[47],eg=c[8]^c[18]^c[28]^c[38]^c[48],em=c[9]^c[19]^c[29]^c[39]^c[49],eb=eg^(ec<<1|el>>>31),ey=em^(el<<1|ec>>>31),e_=c[0]^eb,ew=c[1]^ey,eE=c[10]^eb,eS=c[11]^ey,ex=c[20]^eb,ek=c[21]^ey,eC=c[30]^eb,eA=c[31]^ey,eI=c[40]^eb,eP=c[41]^ey;eb=eo^(ed<<1|eh>>>31),ey=es^(eh<<1|ed>>>31);let eR=c[2]^eb,eO=c[3]^ey,eT=c[12]^eb,eN=c[13]^ey,eM=c[22]^eb,e$=c[23]^ey,eB=c[32]^eb,eD=c[33]^ey,ej=c[42]^eb,eL=c[43]^ey;eb=ec^(ef<<1|ep>>>31),ey=el^(ep<<1|ef>>>31);let eF=c[4]^eb,eU=c[5]^ey,ez=c[14]^eb,eH=c[15]^ey,eW=c[24]^eb,eV=c[25]^ey,eG=c[34]^eb,eK=c[35]^ey,eJ=c[44]^eb,eQ=c[45]^ey;eb=ed^(eg<<1|em>>>31),ey=eh^(em<<1|eg>>>31);let eY=c[6]^eb,eZ=c[7]^ey,eX=c[16]^eb,e0=c[17]^ey,e1=c[26]^eb,e2=c[27]^ey,e3=c[36]^eb,e5=c[37]^ey,e6=c[46]^eb,e4=c[47]^ey;eb=ef^(eo<<1|es>>>31),ey=ep^(es<<1|eo>>>31);let e8=c[8]^eb,e9=c[9]^ey,e7=c[18]^eb,tn=c[19]^ey,to=c[28]^eb,ts=c[29]^ey,ta=c[38]^eb,tc=c[39]^ey,tl=c[48]^eb,td=c[49]^ey,th=eS<<4|eE>>>28,tf=eE<<4|eS>>>28,tp=ex<<3|ek>>>29,tg=ek<<3|ex>>>29,tm=eA<<9|eC>>>23,tb=eC<<9|eA>>>23,ty=eI<<18|eP>>>14,t_=eP<<18|eI>>>14,tw=eR<<1|eO>>>31,tE=eO<<1|eR>>>31,tS=eN<<12|eT>>>20,tx=eT<<12|eN>>>20,tk=eM<<10|e$>>>22,tC=e$<<10|eM>>>22,tA=eD<<13|eB>>>19,tI=eB<<13|eD>>>19,tP=ej<<2|eL>>>30,tR=eL<<2|ej>>>30,tO=eU<<30|eF>>>2,tT=eF<<30|eU>>>2,tN=ez<<6|eH>>>26,tM=eH<<6|ez>>>26,t$=eV<<11|eW>>>21,tB=eW<<11|eV>>>21,tD=eG<<15|eK>>>17,tj=eK<<15|eG>>>17,tL=eQ<<29|eJ>>>3,tF=eJ<<29|eQ>>>3,tU=eY<<28|eZ>>>4,tz=eZ<<28|eY>>>4,tq=e0<<23|eX>>>9,tH=eX<<23|e0>>>9,tW=e1<<25|e2>>>7,tV=e2<<25|e1>>>7,tG=e3<<21|e5>>>11,tK=e5<<21|e3>>>11,tJ=e4<<24|e6>>>8,tQ=e6<<24|e4>>>8,tY=e8<<27|e9>>>5,tZ=e9<<27|e8>>>5,tX=e7<<20|tn>>>12,t0=tn<<20|e7>>>12,t1=ts<<7|to>>>25,t2=to<<7|ts>>>25,t3=ta<<8|tc>>>24,t5=tc<<8|ta>>>24,t6=tl<<14|td>>>18,t4=td<<14|tl>>>18;c[0]=e_^~tS&t$,c[1]=ew^~tx&tB,c[10]=tU^~tX&tp,c[11]=tz^~t0&tg,c[20]=tw^~tN&tW,c[21]=tE^~tM&tV,c[30]=tY^~th&tk,c[31]=tZ^~tf&tC,c[40]=tO^~tq&t1,c[41]=tT^~tH&t2,c[2]=tS^~t$&tG,c[3]=tx^~tB&tK,c[12]=tX^~tp&tA,c[13]=t0^~tg&tI,c[22]=tN^~tW&t3,c[23]=tM^~tV&t5,c[32]=th^~tk&tD,c[33]=tf^~tC&tj,c[42]=tq^~t1&tm,c[43]=tH^~t2&tb,c[4]=t$^~tG&t6,c[5]=tB^~tK&t4,c[14]=tp^~tA&tL,c[15]=tg^~tI&tF,c[24]=tW^~t3&ty,c[25]=tV^~t5&t_,c[34]=tk^~tD&tJ,c[35]=tC^~tj&tQ,c[44]=t1^~tm&tP,c[45]=t2^~tb&tR,c[6]=tG^~t6&e_,c[7]=tK^~t4&ew,c[16]=tA^~tL&tU,c[17]=tI^~tF&tz,c[26]=t3^~ty&tw,c[27]=t5^~t_&tE,c[36]=tD^~tJ&tY,c[37]=tj^~tQ&tZ,c[46]=tm^~tP&tO,c[47]=tb^~tR&tT,c[8]=t6^~e_&tS,c[9]=t4^~ew&tx,c[18]=tL^~tU&tX,c[19]=tF^~tz&t0,c[28]=ty^~tw&tN,c[29]=t_^~tE&tM,c[38]=tJ^~tY&th,c[39]=tQ^~tZ&tf,c[48]=tP^~tO&tq,c[49]=tR^~tT&tH,c[0]^=et[2*l],c[1]^=et[2*l+1]}}},64586:function(c,l,et){var eo=et(67133).Buffer;let es=et(89773);function Keccak(){this.state=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],this.blockSize=null,this.count=0,this.squeezing=!1}Keccak.prototype.initialize=function(c,l){for(let c=0;c<50;++c)this.state[c]=0;this.blockSize=c/8,this.count=0,this.squeezing=!1},Keccak.prototype.absorb=function(c){for(let l=0;l>>8*(this.count%4)&255,this.count+=1,this.count===this.blockSize&&(es.p1600(this.state),this.count=0);return l},Keccak.prototype.copy=function(c){for(let l=0;l<50;++l)c.state[l]=this.state[l];c.blockSize=this.blockSize,c.count=this.count,c.squeezing=this.squeezing},c.exports=Keccak},99780:function(c,l,et){c=et.nmd(c);var eo,es,ec,el="__lodash_hash_undefined__",ed="[object Arguments]",eh="[object Array]",ef="[object Boolean]",ep="[object Date]",eg="[object Error]",em="[object Function]",eb="[object Map]",ey="[object Number]",e_="[object Object]",ew="[object Promise]",eE="[object RegExp]",eS="[object Set]",ex="[object String]",ek="[object WeakMap]",eC="[object ArrayBuffer]",eA="[object DataView]",eI=/^\[object .+?Constructor\]$/,eP=/^(?:0|[1-9]\d*)$/,eR={};eR["[object Float32Array]"]=eR["[object Float64Array]"]=eR["[object Int8Array]"]=eR["[object Int16Array]"]=eR["[object Int32Array]"]=eR["[object Uint8Array]"]=eR["[object Uint8ClampedArray]"]=eR["[object Uint16Array]"]=eR["[object Uint32Array]"]=!0,eR[ed]=eR[eh]=eR[eC]=eR[ef]=eR[eA]=eR[ep]=eR[eg]=eR[em]=eR[eb]=eR[ey]=eR[e_]=eR[eE]=eR[eS]=eR[ex]=eR[ek]=!1;var eO="object"==typeof et.g&&et.g&&et.g.Object===Object&&et.g,eT="object"==typeof self&&self&&self.Object===Object&&self,eN=eO||eT||Function("return this")(),eM=l&&!l.nodeType&&l,e$=eM&&c&&!c.nodeType&&c,eB=e$&&e$.exports===eM,eD=eB&&eO.process,ej=function(){try{return eD&&eD.binding&&eD.binding("util")}catch(c){}}(),eL=ej&&ej.isTypedArray;function mapToArray(c){var l=-1,et=Array(c.size);return c.forEach(function(c,eo){et[++l]=[eo,c]}),et}function setToArray(c){var l=-1,et=Array(c.size);return c.forEach(function(c){et[++l]=c}),et}var eF=Array.prototype,eU=Function.prototype,ez=Object.prototype,eH=eN["__core-js_shared__"],eW=eU.toString,eV=ez.hasOwnProperty,eG=(eo=/[^.]+$/.exec(eH&&eH.keys&&eH.keys.IE_PROTO||""))?"Symbol(src)_1."+eo:"",eK=ez.toString,eJ=RegExp("^"+eW.call(eV).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),eQ=eB?eN.Buffer:void 0,eY=eN.Symbol,eZ=eN.Uint8Array,eX=ez.propertyIsEnumerable,e0=eF.splice,e1=eY?eY.toStringTag:void 0,e2=Object.getOwnPropertySymbols,e3=eQ?eQ.isBuffer:void 0,e5=(es=Object.keys,ec=Object,function(c){return es(ec(c))}),e6=getNative(eN,"DataView"),e4=getNative(eN,"Map"),e8=getNative(eN,"Promise"),e9=getNative(eN,"Set"),e7=getNative(eN,"WeakMap"),tn=getNative(Object,"create"),to=toSource(e6),ts=toSource(e4),ta=toSource(e8),tc=toSource(e9),tl=toSource(e7),td=eY?eY.prototype:void 0,th=td?td.valueOf:void 0;function Hash(c){var l=-1,et=null==c?0:c.length;for(this.clear();++led))return!1;var ef=ec.get(c);if(ef&&ec.get(l))return ef==l;var ep=-1,eg=!0,em=2&et?new SetCache:void 0;for(ec.set(c,l),ec.set(l,c);++ep-1&&ep%1==0&&ep-1},ListCache.prototype.set=function(c,l){var et=this.__data__,eo=assocIndexOf(et,c);return eo<0?(++this.size,et.push([c,l])):et[eo][1]=l,this},MapCache.prototype.clear=function(){this.size=0,this.__data__={hash:new Hash,map:new(e4||ListCache),string:new Hash}},MapCache.prototype.delete=function(c){var l=getMapData(this,c).delete(c);return this.size-=l?1:0,l},MapCache.prototype.get=function(c){return getMapData(this,c).get(c)},MapCache.prototype.has=function(c){return getMapData(this,c).has(c)},MapCache.prototype.set=function(c,l){var et=getMapData(this,c),eo=et.size;return et.set(c,l),this.size+=et.size==eo?0:1,this},SetCache.prototype.add=SetCache.prototype.push=function(c){return this.__data__.set(c,el),this},SetCache.prototype.has=function(c){return this.__data__.has(c)},Stack.prototype.clear=function(){this.__data__=new ListCache,this.size=0},Stack.prototype.delete=function(c){var l=this.__data__,et=l.delete(c);return this.size=l.size,et},Stack.prototype.get=function(c){return this.__data__.get(c)},Stack.prototype.has=function(c){return this.__data__.has(c)},Stack.prototype.set=function(c,l){var et=this.__data__;if(et instanceof ListCache){var eo=et.__data__;if(!e4||eo.length<199)return eo.push([c,l]),this.size=++et.size,this;et=this.__data__=new MapCache(eo)}return et.set(c,l),this.size=et.size,this};var tf=e2?function(c){return null==c?[]:function(c,l){for(var et=-1,eo=null==c?0:c.length,es=0,ec=[];++et-1&&c%1==0&&c<=9007199254740991}function isObject(c){var l=typeof c;return null!=c&&("object"==l||"function"==l)}function isObjectLike(c){return null!=c&&"object"==typeof c}var ty=eL?function(c){return eL(c)}:function(c){return isObjectLike(c)&&isLength(c.length)&&!!eR[baseGetTag(c)]};c.exports=function(c,l){return function baseIsEqual(c,l,et,eo,es){return c===l||(null!=c&&null!=l&&(isObjectLike(c)||isObjectLike(l))?function(c,l,et,eo,es,ec){var el=tm(c),em=tm(l),ew=el?eh:tp(c),ek=em?eh:tp(l);ew=ew==ed?e_:ew,ek=ek==ed?e_:ek;var eI=ew==e_,eP=ek==e_,eR=ew==ek;if(eR&&tb(c)){if(!tb(l))return!1;el=!0,eI=!1}if(eR&&!eI)return ec||(ec=new Stack),el||ty(c)?equalArrays(c,l,et,eo,es,ec):function(c,l,et,eo,es,ec,el){switch(et){case eA:if(c.byteLength!=l.byteLength||c.byteOffset!=l.byteOffset)break;c=c.buffer,l=l.buffer;case eC:if(c.byteLength!=l.byteLength||!ec(new eZ(c),new eZ(l)))break;return!0;case ef:case ep:case ey:return eq(+c,+l);case eg:return c.name==l.name&&c.message==l.message;case eE:case ex:return c==l+"";case eb:var ed=mapToArray;case eS:var eh=1&eo;if(ed||(ed=setToArray),c.size!=l.size&&!eh)break;var em=el.get(c);if(em)return em==l;eo|=2,el.set(c,l);var e_=equalArrays(ed(c),ed(l),eo,es,ec,el);return el.delete(c),e_;case"[object Symbol]":if(th)return th.call(c)==th.call(l)}return!1}(c,l,ew,et,eo,es,ec);if(!(1&et)){var eO=eI&&eV.call(c,"__wrapped__"),eT=eP&&eV.call(l,"__wrapped__");if(eO||eT){var eN=eO?c.value():c,eM=eT?l.value():l;return ec||(ec=new Stack),es(eN,eM,et,eo,ec)}}return!!eR&&(ec||(ec=new Stack),function(c,l,et,eo,es,ec){var el=1&et,ed=getAllKeys(c),eh=ed.length;if(eh!=getAllKeys(l).length&&!el)return!1;for(var ef=eh;ef--;){var ep=ed[ef];if(!(el?ep in l:eV.call(l,ep)))return!1}var eg=ec.get(c);if(eg&&ec.get(l))return eg==l;var em=!0;ec.set(c,l),ec.set(l,c);for(var eb=el;++ef-1},ListCache.prototype.set=function(c,l){var et=this.__data__,eo=assocIndexOf(et,c);return eo<0?(++this.size,et.push([c,l])):et[eo][1]=l,this},MapCache.prototype.clear=function(){this.size=0,this.__data__={hash:new Hash,map:new(e5||ListCache),string:new Hash}},MapCache.prototype.delete=function(c){var l=getMapData(this,c).delete(c);return this.size-=l?1:0,l},MapCache.prototype.get=function(c){return getMapData(this,c).get(c)},MapCache.prototype.has=function(c){return getMapData(this,c).has(c)},MapCache.prototype.set=function(c,l){var et=getMapData(this,c),eo=et.size;return et.set(c,l),this.size+=et.size==eo?0:1,this},Stack.prototype.clear=function(){this.__data__=new ListCache,this.size=0},Stack.prototype.delete=function(c){var l=this.__data__,et=l.delete(c);return this.size=l.size,et},Stack.prototype.get=function(c){return this.__data__.get(c)},Stack.prototype.has=function(c){return this.__data__.has(c)},Stack.prototype.set=function(c,l){var et=this.__data__;if(et instanceof ListCache){var eo=et.__data__;if(!e5||eo.length<199)return eo.push([c,l]),this.size=++et.size,this;et=this.__data__=new MapCache(eo)}return et.set(c,l),this.size=et.size,this};var baseFor=function(c,l,et){for(var eo=-1,es=Object(c),ec=et(c),el=ec.length;el--;){var ed=ec[++eo];if(!1===l(es[ed],ed,es))break}return c};function baseGetTag(c){return null==c?void 0===c?"[object Undefined]":"[object Null]":eX&&eX in Object(c)?function(c){var l=eL.call(c,eX),et=c[eX];try{c[eX]=void 0;var eo=!0}catch(c){}var es=eU.call(c);return eo&&(l?c[eX]=et:delete c[eX]),es}(c):eU.call(c)}function baseIsArguments(c){return isObjectLike(c)&&baseGetTag(c)==ey}function getMapData(c,l){var et,eo=c.__data__;return("string"==(et=typeof l)||"number"==et||"symbol"==et||"boolean"==et?"__proto__"!==l:null===l)?eo["string"==typeof l?"string":"hash"]:eo.map}function getNative(c,l){var et=null==c?void 0:c[l];return!(!isObject(et)||eF&&eF in et)&&(isFunction(et)?eH:eE).test(function(c){if(null!=c){try{return ej.call(c)}catch(c){}try{return c+""}catch(c){}}return""}(et))?et:void 0}function isIndex(c,l){var et=typeof c;return!!(l=null==l?9007199254740991:l)&&("number"==et||"symbol"!=et&&eS.test(c))&&c>-1&&c%1==0&&c0){if(++es>=800)return arguments[0]}else es=0;return eo.apply(void 0,arguments)});function eq(c,l){return c===l||c!=c&&l!=l}var e9=baseIsArguments(function(){return arguments}())?baseIsArguments:function(c){return isObjectLike(c)&&eL.call(c,"callee")&&!eY.call(c,"callee")},e7=Array.isArray;function isArrayLike(c){return null!=c&&isLength(c.length)&&!isFunction(c)}var tn=e1||function(){return!1};function isFunction(c){if(!isObject(c))return!1;var l=baseGetTag(c);return l==e_||"[object GeneratorFunction]"==l||"[object AsyncFunction]"==l||"[object Proxy]"==l}function isLength(c){return"number"==typeof c&&c>-1&&c%1==0&&c<=9007199254740991}function isObject(c){var l=typeof c;return null!=c&&("object"==l||"function"==l)}function isObjectLike(c){return null!=c&&"object"==typeof c}var to=eN?function(c){return eN(c)}:function(c){return isObjectLike(c)&&isLength(c.length)&&!!ex[baseGetTag(c)]};function keysIn(c){return isArrayLike(c)?function(c,l){var et=e7(c),eo=!et&&e9(c),es=!et&&!eo&&tn(c),ec=!et&&!eo&&!es&&to(c),el=et||eo||es||ec,ed=el?function(c,l){for(var et=-1,eo=Array(c);++et1?l[eo-1]:void 0,ec=eo>2?l[2]:void 0;for(es=eg.length>3&&"function"==typeof es?(eo--,es):void 0,ec&&function(c,l,et){if(!isObject(et))return!1;var eo=typeof l;return("number"==eo?!!(isArrayLike(et)&&isIndex(l,et.length)):"string"==eo&&(l in et))&&eq(et[l],c)}(l[0],l[1],ec)&&(es=eo<3?void 0:es,eo=1),c=Object(c);++et1,get=(c,l,et)=>{let eo=c[em].get(l);if(eo){let l=eo.value;if(isStale(c,l)){if(del(c,eo),!c[ed])return}else et&&(c[eb]&&(eo.value.now=Date.now()),c[eg].unshiftNode(eo));return l.value}},isStale=(c,l)=>{if(!l||!l.maxAge&&!c[eh])return!1;let et=Date.now()-l.now;return l.maxAge?et>l.maxAge:c[eh]&&et>c[eh]},trim=c=>{if(c[ec]>c[es])for(let l=c[eg].tail;c[ec]>c[es]&&null!==l;){let et=l.prev;del(c,l),l=et}},del=(c,l)=>{if(l){let et=l.value;c[ef]&&c[ef](et.key,et.value),c[ec]-=et.length,c[em].delete(et.key),c[eg].removeNode(l)}};let Entry=class Entry{constructor(c,l,et,eo,es){this.key=c,this.value=l,this.length=et,this.now=eo,this.maxAge=es||0}};let forEachStep=(c,l,et,eo)=>{let es=et.value;isStale(c,es)&&(del(c,et),c[ed]||(es=void 0)),es&&l.call(eo,es.value,es.key,c)};c.exports=class{constructor(c){if("number"==typeof c&&(c={max:c}),c||(c={}),c.max&&("number"!=typeof c.max||c.max<0))throw TypeError("max must be a non-negative number");this[es]=c.max||1/0;let l=c.length||naiveLength;if(this[el]="function"!=typeof l?naiveLength:l,this[ed]=c.stale||!1,c.maxAge&&"number"!=typeof c.maxAge)throw TypeError("maxAge must be a number");this[eh]=c.maxAge||0,this[ef]=c.dispose,this[ep]=c.noDisposeOnSet||!1,this[eb]=c.updateAgeOnGet||!1,this.reset()}set max(c){if("number"!=typeof c||c<0)throw TypeError("max must be a non-negative number");this[es]=c||1/0,trim(this)}get max(){return this[es]}set allowStale(c){this[ed]=!!c}get allowStale(){return this[ed]}set maxAge(c){if("number"!=typeof c)throw TypeError("maxAge must be a non-negative number");this[eh]=c,trim(this)}get maxAge(){return this[eh]}set lengthCalculator(c){"function"!=typeof c&&(c=naiveLength),c!==this[el]&&(this[el]=c,this[ec]=0,this[eg].forEach(c=>{c.length=this[el](c.value,c.key),this[ec]+=c.length})),trim(this)}get lengthCalculator(){return this[el]}get length(){return this[ec]}get itemCount(){return this[eg].length}rforEach(c,l){l=l||this;for(let et=this[eg].tail;null!==et;){let eo=et.prev;forEachStep(this,c,et,l),et=eo}}forEach(c,l){l=l||this;for(let et=this[eg].head;null!==et;){let eo=et.next;forEachStep(this,c,et,l),et=eo}}keys(){return this[eg].toArray().map(c=>c.key)}values(){return this[eg].toArray().map(c=>c.value)}reset(){this[ef]&&this[eg]&&this[eg].length&&this[eg].forEach(c=>this[ef](c.key,c.value)),this[em]=new Map,this[eg]=new eo,this[ec]=0}dump(){return this[eg].map(c=>!isStale(this,c)&&{k:c.key,v:c.value,e:c.now+(c.maxAge||0)}).toArray().filter(c=>c)}dumpLru(){return this[eg]}set(c,l,et){if((et=et||this[eh])&&"number"!=typeof et)throw TypeError("maxAge must be a number");let eo=et?Date.now():0,ed=this[el](l,c);if(this[em].has(c)){if(ed>this[es])return del(this,this[em].get(c)),!1;let el=this[em].get(c),eh=el.value;return this[ef]&&!this[ep]&&this[ef](c,eh.value),eh.now=eo,eh.maxAge=et,eh.value=l,this[ec]+=ed-eh.length,eh.length=ed,this.get(c),trim(this),!0}let eb=new Entry(c,l,ed,eo,et);return eb.length>this[es]?(this[ef]&&this[ef](c,l),!1):(this[ec]+=eb.length,this[eg].unshift(eb),this[em].set(c,this[eg].head),trim(this),!0)}has(c){if(!this[em].has(c))return!1;let l=this[em].get(c).value;return!isStale(this,l)}get(c){return get(this,c,!0)}peek(c){return get(this,c,!1)}pop(){let c=this[eg].tail;return c?(del(this,c),c.value):null}del(c){del(this,this[em].get(c))}load(c){this.reset();let l=Date.now();for(let et=c.length-1;et>=0;et--){let eo=c[et],es=eo.e||0;if(0===es)this.set(eo.k,eo.v);else{let c=es-l;c>0&&this.set(eo.k,eo.v,c)}}}prune(){this[em].forEach((c,l)=>get(this,l,!1))}}},8786:function(c){function assert(c,l){if(!c)throw Error(l||"Assertion failed")}c.exports=assert,assert.equal=function(c,l,et){if(c!=l)throw Error(et||"Assertion failed: "+c+" != "+l)}},30622:function(c,l,et){"use strict";/** + * @license React + * react-jsx-runtime.production.min.js + * + * Copyright (c) Meta Platforms, Inc. and affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var eo=et(2265),es=Symbol.for("react.element"),ec=Symbol.for("react.fragment"),el=Object.prototype.hasOwnProperty,ed=eo.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,eh={key:!0,ref:!0,__self:!0,__source:!0};function q(c,l,et){var eo,ec={},ef=null,ep=null;for(eo in void 0!==et&&(ef=""+et),void 0!==l.key&&(ef=""+l.key),void 0!==l.ref&&(ep=l.ref),l)el.call(l,eo)&&!eh.hasOwnProperty(eo)&&(ec[eo]=l[eo]);if(c&&c.defaultProps)for(eo in l=c.defaultProps)void 0===ec[eo]&&(ec[eo]=l[eo]);return{$$typeof:es,type:c,key:ef,ref:ep,props:ec,_owner:ed.current}}l.Fragment=ec,l.jsx=q,l.jsxs=q},57437:function(c,l,et){"use strict";c.exports=et(30622)},19063:function(c,l,et){var eo="function"==typeof Map&&Map.prototype,es=Object.getOwnPropertyDescriptor&&eo?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,ec=eo&&es&&"function"==typeof es.get?es.get:null,el=eo&&Map.prototype.forEach,ed="function"==typeof Set&&Set.prototype,eh=Object.getOwnPropertyDescriptor&&ed?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,ef=ed&&eh&&"function"==typeof eh.get?eh.get:null,ep=ed&&Set.prototype.forEach,eg="function"==typeof WeakMap&&WeakMap.prototype?WeakMap.prototype.has:null,em="function"==typeof WeakSet&&WeakSet.prototype?WeakSet.prototype.has:null,eb="function"==typeof WeakRef&&WeakRef.prototype?WeakRef.prototype.deref:null,ey=Boolean.prototype.valueOf,e_=Object.prototype.toString,ew=Function.prototype.toString,eE=String.prototype.match,eS=String.prototype.slice,ex=String.prototype.replace,ek=String.prototype.toUpperCase,eC=String.prototype.toLowerCase,eA=RegExp.prototype.test,eI=Array.prototype.concat,eP=Array.prototype.join,eR=Array.prototype.slice,eO=Math.floor,eT="function"==typeof BigInt?BigInt.prototype.valueOf:null,eN=Object.getOwnPropertySymbols,eM="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?Symbol.prototype.toString:null,e$="function"==typeof Symbol&&"object"==typeof Symbol.iterator,eB="function"==typeof Symbol&&Symbol.toStringTag&&(typeof Symbol.toStringTag===e$?"object":"symbol")?Symbol.toStringTag:null,eD=Object.prototype.propertyIsEnumerable,ej=("function"==typeof Reflect?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(c){return c.__proto__}:null);function addNumericSeparator(c,l){if(c===1/0||c===-1/0||c!=c||c&&c>-1e3&&c<1e3||eA.call(/e/,l))return l;var et=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if("number"==typeof c){var eo=c<0?-eO(-c):eO(c);if(eo!==c){var es=String(eo),ec=eS.call(l,es.length+1);return ex.call(es,et,"$&_")+"."+ex.call(ex.call(ec,/([0-9]{3})/g,"$&_"),/_$/,"")}}return ex.call(l,et,"$&_")}var eL=et(24654),eF=eL.custom,eU=isSymbol(eF)?eF:null;function wrapQuotes(c,l,et){var eo="double"===(et.quoteStyle||l)?'"':"'";return eo+c+eo}function isArray(c){return"[object Array]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c))}function isRegExp(c){return"[object RegExp]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c))}function isSymbol(c){if(e$)return c&&"object"==typeof c&&c instanceof Symbol;if("symbol"==typeof c)return!0;if(!c||"object"!=typeof c||!eM)return!1;try{return eM.call(c),!0}catch(c){}return!1}c.exports=function inspect_(c,l,et,eo){var es=l||{};if(has(es,"quoteStyle")&&"single"!==es.quoteStyle&&"double"!==es.quoteStyle)throw TypeError('option "quoteStyle" must be "single" or "double"');if(has(es,"maxStringLength")&&("number"==typeof es.maxStringLength?es.maxStringLength<0&&es.maxStringLength!==1/0:null!==es.maxStringLength))throw TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var ed=!has(es,"customInspect")||es.customInspect;if("boolean"!=typeof ed&&"symbol"!==ed)throw TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(has(es,"indent")&&null!==es.indent&&" "!==es.indent&&!(parseInt(es.indent,10)===es.indent&&es.indent>0))throw TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(has(es,"numericSeparator")&&"boolean"!=typeof es.numericSeparator)throw TypeError('option "numericSeparator", if provided, must be `true` or `false`');var eh=es.numericSeparator;if(void 0===c)return"undefined";if(null===c)return"null";if("boolean"==typeof c)return c?"true":"false";if("string"==typeof c)return function inspectString(c,l){if(c.length>l.maxStringLength){var et=c.length-l.maxStringLength;return inspectString(eS.call(c,0,l.maxStringLength),l)+"... "+et+" more character"+(et>1?"s":"")}return wrapQuotes(ex.call(ex.call(c,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,lowbyte),"single",l)}(c,es);if("number"==typeof c){if(0===c)return 1/0/c>0?"0":"-0";var e_=String(c);return eh?addNumericSeparator(c,e_):e_}if("bigint"==typeof c){var ek=String(c)+"n";return eh?addNumericSeparator(c,ek):ek}var eA=void 0===es.depth?5:es.depth;if(void 0===et&&(et=0),et>=eA&&eA>0&&"object"==typeof c)return isArray(c)?"[Array]":"[Object]";var eO=function(c,l){var et;if(" "===c.indent)et=" ";else{if("number"!=typeof c.indent||!(c.indent>0))return null;et=eP.call(Array(c.indent+1)," ")}return{base:et,prev:eP.call(Array(l+1),et)}}(es,et);if(void 0===eo)eo=[];else if(indexOf(eo,c)>=0)return"[Circular]";function inspect(c,l,ec){if(l&&(eo=eR.call(eo)).push(l),ec){var el={depth:es.depth};return has(es,"quoteStyle")&&(el.quoteStyle=es.quoteStyle),inspect_(c,el,et+1,eo)}return inspect_(c,es,et+1,eo)}if("function"==typeof c&&!isRegExp(c)){var eN=function(c){if(c.name)return c.name;var l=eE.call(ew.call(c),/^function\s*([\w$]+)/);return l?l[1]:null}(c),eF=arrObjKeys(c,inspect);return"[Function"+(eN?": "+eN:" (anonymous)")+"]"+(eF.length>0?" { "+eP.call(eF,", ")+" }":"")}if(isSymbol(c)){var ez=e$?ex.call(String(c),/^(Symbol\(.*\))_[^)]*$/,"$1"):eM.call(c);return"object"!=typeof c||e$?ez:markBoxed(ez)}if(c&&"object"==typeof c&&("undefined"!=typeof HTMLElement&&c instanceof HTMLElement||"string"==typeof c.nodeName&&"function"==typeof c.getAttribute)){for(var eH,eW="<"+eC.call(String(c.nodeName)),eV=c.attributes||[],eG=0;eG"}if(isArray(c)){if(0===c.length)return"[]";var eK=arrObjKeys(c,inspect);return eO&&!function(c){for(var l=0;l=0)return!1;return!0}(eK)?"["+indentedJoin(eK,eO)+"]":"[ "+eP.call(eK,", ")+" ]"}if("[object Error]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c))){var eJ=arrObjKeys(c,inspect);return"cause"in Error.prototype||!("cause"in c)||eD.call(c,"cause")?0===eJ.length?"["+String(c)+"]":"{ ["+String(c)+"] "+eP.call(eJ,", ")+" }":"{ ["+String(c)+"] "+eP.call(eI.call("[cause]: "+inspect(c.cause),eJ),", ")+" }"}if("object"==typeof c&&ed){if(eU&&"function"==typeof c[eU]&&eL)return eL(c,{depth:eA-et});if("symbol"!==ed&&"function"==typeof c.inspect)return c.inspect()}if(function(c){if(!ec||!c||"object"!=typeof c)return!1;try{ec.call(c);try{ef.call(c)}catch(c){return!0}return c instanceof Map}catch(c){}return!1}(c)){var eQ=[];return el&&el.call(c,function(l,et){eQ.push(inspect(et,c,!0)+" => "+inspect(l,c))}),collectionOf("Map",ec.call(c),eQ,eO)}if(function(c){if(!ef||!c||"object"!=typeof c)return!1;try{ef.call(c);try{ec.call(c)}catch(c){return!0}return c instanceof Set}catch(c){}return!1}(c)){var eY=[];return ep&&ep.call(c,function(l){eY.push(inspect(l,c))}),collectionOf("Set",ef.call(c),eY,eO)}if(function(c){if(!eg||!c||"object"!=typeof c)return!1;try{eg.call(c,eg);try{em.call(c,em)}catch(c){return!0}return c instanceof WeakMap}catch(c){}return!1}(c))return weakCollectionOf("WeakMap");if(function(c){if(!em||!c||"object"!=typeof c)return!1;try{em.call(c,em);try{eg.call(c,eg)}catch(c){return!0}return c instanceof WeakSet}catch(c){}return!1}(c))return weakCollectionOf("WeakSet");if(function(c){if(!eb||!c||"object"!=typeof c)return!1;try{return eb.call(c),!0}catch(c){}return!1}(c))return weakCollectionOf("WeakRef");if("[object Number]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c)))return markBoxed(inspect(Number(c)));if(function(c){if(!c||"object"!=typeof c||!eT)return!1;try{return eT.call(c),!0}catch(c){}return!1}(c))return markBoxed(inspect(eT.call(c)));if("[object Boolean]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c)))return markBoxed(ey.call(c));if("[object String]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c)))return markBoxed(inspect(String(c)));if(!("[object Date]"===toStr(c)&&(!eB||!("object"==typeof c&&eB in c)))&&!isRegExp(c)){var eZ=arrObjKeys(c,inspect),eX=ej?ej(c)===Object.prototype:c instanceof Object||c.constructor===Object,e0=c instanceof Object?"":"null prototype",e1=!eX&&eB&&Object(c)===c&&eB in c?eS.call(toStr(c),8,-1):e0?"Object":"",e2=(eX||"function"!=typeof c.constructor?"":c.constructor.name?c.constructor.name+" ":"")+(e1||e0?"["+eP.call(eI.call([],e1||[],e0||[]),": ")+"] ":"");return 0===eZ.length?e2+"{}":eO?e2+"{"+indentedJoin(eZ,eO)+"}":e2+"{ "+eP.call(eZ,", ")+" }"}return String(c)};var ez=Object.prototype.hasOwnProperty||function(c){return c in this};function has(c,l){return ez.call(c,l)}function toStr(c){return e_.call(c)}function indexOf(c,l){if(c.indexOf)return c.indexOf(l);for(var et=0,eo=c.length;etfunction(){let et=l.promiseModule,eo=Array(arguments.length);for(let c=0;c{l.errorFirst?eo.push(function(c,eo){if(l.multiArgs){let l=Array(arguments.length-1);for(let c=1;c{let et;l=Object.assign({exclude:[/.+(Sync|Stream)$/],errorFirst:!0,promiseModule:Promise},l);let filter=c=>{let match=l=>"string"==typeof l?c===l:l.test(c);return l.include?l.include.some(match):!l.exclude.some(match)};for(let eo in et="function"==typeof c?function(){return l.excludeMain?c.apply(this,arguments):processFn(c,l).apply(this,arguments)}:Object.create(Object.getPrototypeOf(c)),c){let es=c[eo];et[eo]="function"==typeof es&&filter(eo)?processFn(es,l):es}return et}},88049:function(c,l,et){"use strict";et.r(l),et.d(l,{Component:function(){return b},Fragment:function(){return k},cloneElement:function(){return F},createContext:function(){return G},createElement:function(){return y},createRef:function(){return _},h:function(){return y},hydrate:function(){return E},isValidElement:function(){return el},options:function(){return es},render:function(){return B},toChildArray:function(){return function C(c,l){return l=l||[],null==c||"boolean"==typeof c||(e_(c)?c.some(function(c){C(c,l)}):l.push(c)),l}}});var eo,es,ec,el,ed,eh,ef,ep,eg,em={},eb=[],ey=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,e_=Array.isArray;function h(c,l){for(var et in l)c[et]=l[et];return c}function p(c){var l=c.parentNode;l&&l.removeChild(c)}function y(c,l,et){var es,ec,el,ed={};for(el in l)"key"==el?es=l[el]:"ref"==el?ec=l[el]:ed[el]=l[el];if(arguments.length>2&&(ed.children=arguments.length>3?eo.call(arguments,2):et),"function"==typeof c&&null!=c.defaultProps)for(el in c.defaultProps)void 0===ed[el]&&(ed[el]=c.defaultProps[el]);return d(c,ed,es,ec,null)}function d(c,l,et,eo,el){var ed={type:c,props:l,key:et,ref:eo,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:null==el?++ec:el};return null==el&&null!=es.vnode&&es.vnode(ed),ed}function _(){return{current:null}}function k(c){return c.children}function b(c,l){this.props=c,this.context=l}function g(c,l){if(null==l)return c.__?g(c.__,c.__.__k.indexOf(c)+1):null;for(var et;ll&&ed.sort(ep));x.__r=0}function P(c,l,et,eo,es,ec,el,ed,eh,ef,ep){var eg,ey,ew,eE,eS,ex,ek,eC,eA,eI=0,eP=eo&&eo.__k||eb,eR=eP.length,eO=eR,eT=l.length;for(et.__k=[],eg=0;eg0?d(eE.type,eE.props,eE.key,eE.ref?eE.ref:null,eE.__v):eE)?(eE.__=et,eE.__b=et.__b+1,-1===(eC=function(c,l,et,eo){var es=c.key,ec=c.type,el=et-1,ed=et+1,eh=l[et];if(null===eh||eh&&es==eh.key&&ec===eh.type)return et;if(eo>(null!=eh?1:0))for(;el>=0||ed=0){if((eh=l[el])&&es==eh.key&&ec===eh.type)return el;el--}if(edek?eO>eT-ek?eI+=eC-ek:eI--:eI=eC2&&(eh.children=arguments.length>3?eo.call(arguments,2):et),d(c.type,eh,es||c.key,ec||c.ref,null)}function G(c,l){var et={__c:l="__cC"+eg++,__:c,Consumer:function(c,l){return c.children(l)},Provider:function(c){var et,eo;return this.getChildContext||(et=[],(eo={})[l]=this,this.getChildContext=function(){return eo},this.shouldComponentUpdate=function(c){this.props.value!==c.value&&et.some(function(c){c.__e=!0,w(c)})},this.sub=function(c){et.push(c);var l=c.componentWillUnmount;c.componentWillUnmount=function(){et.splice(et.indexOf(c),1),l&&l.call(c)}}),c.children}};return et.Provider.__=et.Consumer.contextType=et}eo=eb.slice,es={__e:function(c,l,et,eo){for(var es,ec,el;l=l.__;)if((es=l.__c)&&!es.__)try{if((ec=es.constructor)&&null!=ec.getDerivedStateFromError&&(es.setState(ec.getDerivedStateFromError(c)),el=es.__d),null!=es.componentDidCatch&&(es.componentDidCatch(c,eo||{}),el=es.__d),el)return es.__E=es}catch(l){c=l}throw c}},ec=0,el=function(c){return null!=c&&void 0===c.constructor},b.prototype.setState=function(c,l){var et;et=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=h({},this.state),"function"==typeof c&&(c=c(h({},et),this.props)),c&&h(et,c),null!=c&&this.__v&&(l&&this._sb.push(l),w(this))},b.prototype.forceUpdate=function(c){this.__v&&(this.__e=!0,c&&this.__h.push(c),w(this))},b.prototype.render=k,ed=[],ef="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,ep=function(c,l){return c.__v.__b-l.__v.__b},x.__r=0,eg=0},87060:function(c,l,et){"use strict";et.r(l),et.d(l,{useCallback:function(){return T},useContext:function(){return q},useDebugValue:function(){return x},useEffect:function(){return p},useErrorBoundary:function(){return P},useId:function(){return V},useImperativeHandle:function(){return A},useLayoutEffect:function(){return y},useMemo:function(){return F},useReducer:function(){return s},useRef:function(){return _},useState:function(){return h}});var eo,es,ec,el,ed=et(88049),eh=0,ef=[],ep=[],eg=ed.options.__b,em=ed.options.__r,eb=ed.options.diffed,ey=ed.options.__c,e_=ed.options.unmount;function d(c,l){ed.options.__h&&ed.options.__h(es,c,eh||l),eh=0;var et=es.__H||(es.__H={__:[],__h:[]});return c>=et.__.length&&et.__.push({__V:ep}),et.__[c]}function h(c){return eh=1,s(B,c)}function s(c,l,et){var ec=d(eo++,2);if(ec.t=c,!ec.__c&&(ec.__=[et?et(l):B(void 0,l),function(c){var l=ec.__N?ec.__N[0]:ec.__[0],et=ec.t(l,c);l!==et&&(ec.__N=[et,ec.__[1]],ec.__c.setState({}))}],ec.__c=es,!es.u)){var f=function(c,l,et){if(!ec.__c.__H)return!0;var eo=ec.__c.__H.__.filter(function(c){return c.__c});if(eo.every(function(c){return!c.__N}))return!el||el.call(this,c,l,et);var es=!1;return eo.forEach(function(c){if(c.__N){var l=c.__[0];c.__=c.__N,c.__N=void 0,l!==c.__[0]&&(es=!0)}}),!(!es&&ec.__c.props===c)&&(!el||el.call(this,c,l,et))};es.u=!0;var el=es.shouldComponentUpdate,ed=es.componentWillUpdate;es.componentWillUpdate=function(c,l,et){if(this.__e){var eo=el;el=void 0,f(c,l,et),el=eo}ed&&ed.call(this,c,l,et)},es.shouldComponentUpdate=f}return ec.__N||ec.__}function p(c,l){var et=d(eo++,3);!ed.options.__s&&z(et.__H,l)&&(et.__=c,et.i=l,es.__H.__h.push(et))}function y(c,l){var et=d(eo++,4);!ed.options.__s&&z(et.__H,l)&&(et.__=c,et.i=l,es.__h.push(et))}function _(c){return eh=5,F(function(){return{current:c}},[])}function A(c,l,et){eh=6,y(function(){return"function"==typeof c?(c(l()),function(){return c(null)}):c?(c.current=l(),function(){return c.current=null}):void 0},null==et?et:et.concat(c))}function F(c,l){var et=d(eo++,7);return z(et.__H,l)?(et.__V=c(),et.i=l,et.__h=c,et.__V):et.__}function T(c,l){return eh=8,F(function(){return c},l)}function q(c){var l=es.context[c.__c],et=d(eo++,9);return et.c=c,l?(null==et.__&&(et.__=!0,l.sub(es)),l.props.value):c.__}function x(c,l){ed.options.useDebugValue&&ed.options.useDebugValue(l?l(c):c)}function P(c){var l=d(eo++,10),et=h();return l.__=c,es.componentDidCatch||(es.componentDidCatch=function(c,eo){l.__&&l.__(c,eo),et[1](c)}),[et[0],function(){et[1](void 0)}]}function V(){var c=d(eo++,11);if(!c.__){for(var l=es.__v;null!==l&&!l.__m&&null!==l.__;)l=l.__;var et=l.__m||(l.__m=[0,0]);c.__="P"+et[0]+"-"+et[1]++}return c.__}function b(){for(var c;c=ef.shift();)if(c.__P&&c.__H)try{c.__H.__h.forEach(k),c.__H.__h.forEach(w),c.__H.__h=[]}catch(l){c.__H.__h=[],ed.options.__e(l,c.__v)}}ed.options.__b=function(c){es=null,eg&&eg(c)},ed.options.__r=function(c){em&&em(c),eo=0;var l=(es=c.__c).__H;l&&(ec===es?(l.__h=[],es.__h=[],l.__.forEach(function(c){c.__N&&(c.__=c.__N),c.__V=ep,c.__N=c.i=void 0})):(l.__h.forEach(k),l.__h.forEach(w),l.__h=[],eo=0)),ec=es},ed.options.diffed=function(c){eb&&eb(c);var l=c.__c;l&&l.__H&&(l.__H.__h.length&&(1!==ef.push(l)&&el===ed.options.requestAnimationFrame||((el=ed.options.requestAnimationFrame)||function(c){var l,r=function(){clearTimeout(et),ew&&cancelAnimationFrame(l),setTimeout(c)},et=setTimeout(r,100);ew&&(l=requestAnimationFrame(r))})(b)),l.__H.__.forEach(function(c){c.i&&(c.__H=c.i),c.__V!==ep&&(c.__=c.__V),c.i=void 0,c.__V=ep})),ec=es=null},ed.options.__c=function(c,l){l.some(function(c){try{c.__h.forEach(k),c.__h=c.__h.filter(function(c){return!c.__||w(c)})}catch(et){l.some(function(c){c.__h&&(c.__h=[])}),l=[],ed.options.__e(et,c.__v)}}),ey&&ey(c,l)},ed.options.unmount=function(c){e_&&e_(c);var l,et=c.__c;et&&et.__H&&(et.__H.__.forEach(function(c){try{k(c)}catch(c){l=c}}),et.__H=void 0,l&&ed.options.__e(l,et.__v))};var ew="function"==typeof requestAnimationFrame;function k(c){var l=es,et=c.__c;"function"==typeof et&&(c.__c=void 0,et()),es=l}function w(c){var l=es;c.__c=c.__(),es=l}function z(c,l){return!c||c.length!==l.length||l.some(function(l,et){return l!==c[et]})}function B(c,l){return"function"==typeof l?l(c):l}},25566:function(c){var l,et,eo,es=c.exports={};function defaultSetTimout(){throw Error("setTimeout has not been defined")}function defaultClearTimeout(){throw Error("clearTimeout has not been defined")}function runTimeout(c){if(l===setTimeout)return setTimeout(c,0);if((l===defaultSetTimout||!l)&&setTimeout)return l=setTimeout,setTimeout(c,0);try{return l(c,0)}catch(et){try{return l.call(null,c,0)}catch(et){return l.call(this,c,0)}}}!function(){try{l="function"==typeof setTimeout?setTimeout:defaultSetTimout}catch(c){l=defaultSetTimout}try{et="function"==typeof clearTimeout?clearTimeout:defaultClearTimeout}catch(c){et=defaultClearTimeout}}();var ec=[],el=!1,ed=-1;function cleanUpNextTick(){el&&eo&&(el=!1,eo.length?ec=eo.concat(ec):ed=-1,ec.length&&drainQueue())}function drainQueue(){if(!el){var c=runTimeout(cleanUpNextTick);el=!0;for(var l=ec.length;l;){for(eo=ec,ec=[];++ed1)for(var et=1;et>>7-c%8&1)==1},put:function(c,l){for(let et=0;et>>l-et-1&1)==1)},getLengthInBits:function(){return this.length},putBit:function(c){let l=Math.floor(this.length/8);this.buffer.length<=l&&this.buffer.push(0),c&&(this.buffer[l]|=128>>>this.length%8),this.length++}},c.exports=BitBuffer},21091:function(c){function BitMatrix(c){if(!c||c<1)throw Error("BitMatrix size must be defined and greater than 0");this.size=c,this.data=new Uint8Array(c*c),this.reservedBit=new Uint8Array(c*c)}BitMatrix.prototype.set=function(c,l,et,eo){let es=c*this.size+l;this.data[es]=et,eo&&(this.reservedBit[es]=!0)},BitMatrix.prototype.get=function(c,l){return this.data[c*this.size+l]},BitMatrix.prototype.xor=function(c,l,et){this.data[c*this.size+l]^=et},BitMatrix.prototype.isReserved=function(c,l){return this.reservedBit[c*this.size+l]},c.exports=BitMatrix},90690:function(c,l,et){let eo=et(53216),es=et(37662);function ByteData(c){this.mode=es.BYTE,"string"==typeof c&&(c=eo(c)),this.data=new Uint8Array(c)}ByteData.getBitsLength=function(c){return 8*c},ByteData.prototype.getLength=function(){return this.data.length},ByteData.prototype.getBitsLength=function(){return ByteData.getBitsLength(this.data.length)},ByteData.prototype.write=function(c){for(let l=0,et=this.data.length;l=0&&c.bit<4},l.from=function(c,et){if(l.isValid(c))return c;try{return function(c){if("string"!=typeof c)throw Error("Param is not a string");let et=c.toLowerCase();switch(et){case"l":case"low":return l.L;case"m":case"medium":return l.M;case"q":case"quartile":return l.Q;case"h":case"high":return l.H;default:throw Error("Unknown EC Level: "+c)}}(c)}catch(c){return et}}},78241:function(c,l,et){let eo=et(13400).getSymbolSize;l.getPositions=function(c){let l=eo(c);return[[0,0],[l-7,0],[0,l-7]]}},50237:function(c,l,et){let eo=et(13400),es=eo.getBCHDigit(1335);l.getEncodedBits=function(c,l){let et=c.bit<<3|l,ec=et<<10;for(;eo.getBCHDigit(ec)-es>=0;)ec^=1335<=33088&&et<=40956)et-=33088;else if(et>=57408&&et<=60351)et-=49472;else throw Error("Invalid SJIS character: "+this.data[l]+"\nMake sure your charset is UTF-8");et=(et>>>8&255)*192+(255&et),c.put(et,13)}},c.exports=KanjiData},62486:function(c,l){l.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};let et={N1:3,N2:3,N3:40,N4:10};l.isValid=function(c){return null!=c&&""!==c&&!isNaN(c)&&c>=0&&c<=7},l.from=function(c){return l.isValid(c)?parseInt(c,10):void 0},l.getPenaltyN1=function(c){let l=c.size,eo=0,es=0,ec=0,el=null,ed=null;for(let eh=0;eh=5&&(eo+=et.N1+(es-5)),el=l,es=1),(l=c.get(ef,eh))===ed?ec++:(ec>=5&&(eo+=et.N1+(ec-5)),ed=l,ec=1)}es>=5&&(eo+=et.N1+(es-5)),ec>=5&&(eo+=et.N1+(ec-5))}return eo},l.getPenaltyN2=function(c){let l=c.size,eo=0;for(let et=0;et=10&&(1488===es||93===es)&&eo++,ec=ec<<1&2047|c.get(el,et),el>=10&&(1488===ec||93===ec)&&eo++}return eo*et.N3},l.getPenaltyN4=function(c){let l=0,eo=c.data.length;for(let et=0;et=1&&l<10?c.ccBits[0]:l<27?c.ccBits[1]:c.ccBits[2]},l.getBestModeForData=function(c){return es.testNumeric(c)?l.NUMERIC:es.testAlphanumeric(c)?l.ALPHANUMERIC:es.testKanji(c)?l.KANJI:l.BYTE},l.toString=function(c){if(c&&c.id)return c.id;throw Error("Invalid mode")},l.isValid=function(c){return c&&c.bit&&c.ccBits},l.from=function(c,et){if(l.isValid(c))return c;try{return function(c){if("string"!=typeof c)throw Error("Param is not a string");let et=c.toLowerCase();switch(et){case"numeric":return l.NUMERIC;case"alphanumeric":return l.ALPHANUMERIC;case"kanji":return l.KANJI;case"byte":return l.BYTE;default:throw Error("Unknown mode: "+c)}}(c)}catch(c){return et}}},10894:function(c,l,et){let eo=et(37662);function NumericData(c){this.mode=eo.NUMERIC,this.data=c.toString()}NumericData.getBitsLength=function(c){return 10*Math.floor(c/3)+(c%3?c%3*3+1:0)},NumericData.prototype.getLength=function(){return this.data.length},NumericData.prototype.getBitsLength=function(){return NumericData.getBitsLength(this.data.length)},NumericData.prototype.write=function(c){let l,et;for(l=0;l+3<=this.data.length;l+=3)et=parseInt(this.data.substr(l,3),10),c.put(et,10);let eo=this.data.length-l;eo>0&&(et=parseInt(this.data.substr(l),10),c.put(et,3*eo+1))},c.exports=NumericData},25153:function(c,l,et){let eo=et(51309);l.mul=function(c,l){let et=new Uint8Array(c.length+l.length-1);for(let es=0;es=0;){let c=et[0];for(let es=0;es>eo&1)==1,eo<6?c.set(eo,8,es,!0):eo<8?c.set(eo+1,8,es,!0):c.set(ec-15+eo,8,es,!0),eo<8?c.set(8,ec-eo-1,es,!0):eo<9?c.set(8,15-eo-1+1,es,!0):c.set(8,15-eo-1,es,!0);c.set(ec-8,8,1,!0)}l.create=function(c,l){let et,eb;if(void 0===c||""===c)throw Error("No input text");let ew=es.M;return void 0!==l&&(ew=es.from(l.errorCorrectionLevel,es.M),et=em.from(l.version),eb=ef.from(l.maskPattern),l.toSJISFunc&&eo.setToSJISFunction(l.toSJISFunc)),function(c,l,et,es){let eb;if(Array.isArray(c))eb=e_.fromArray(c);else if("string"==typeof c){let eo=l;if(!eo){let l=e_.rawSplit(c);eo=em.getBestVersionForData(l,et)}eb=e_.fromString(c,eo||40)}else throw Error("Invalid data");let ew=em.getBestVersionForData(eb,et);if(!ew)throw Error("The amount of data is too big to be stored in a QR Code");if(l){if(l=0&&l<=6&&(0===eo||6===eo)||eo>=0&&eo<=6&&(0===l||6===l)||l>=2&&l<=4&&eo>=2&&eo<=4?c.set(es+l,ec+eo,!0,!0):c.set(es+l,ec+eo,!1,!0))}}(ex,l),function(c){let l=c.size;for(let et=8;et=7&&function(c,l){let et,eo,es;let ec=c.size,el=em.getEncodedBits(l);for(let l=0;l<18;l++)et=Math.floor(l/3),eo=l%3+ec-8-3,es=(el>>l&1)==1,c.set(et,eo,es,!0),c.set(eo,et,es,!0)}(ex,l),function(c,l){let et=c.size,eo=-1,es=et-1,ec=7,el=0;for(let ed=et-1;ed>0;ed-=2)for(6===ed&&ed--;;){for(let et=0;et<2;et++)if(!c.isReserved(es,ed-et)){let eo=!1;el>>ec&1)==1),c.set(es,ed-et,eo),-1==--ec&&(el++,ec=7)}if((es+=eo)<0||et<=es){es-=eo,eo=-eo;break}}}(ex,eE),isNaN(es)&&(es=ef.getBestMask(ex,setupFormatInfo.bind(null,ex,et))),ef.applyMask(es,ex),setupFormatInfo(ex,et,es),{modules:ex,version:l,errorCorrectionLevel:et,maskPattern:es,segments:eb}}(c,et,ew,eb)}},9936:function(c,l,et){let eo=et(25153);function ReedSolomonEncoder(c){this.genPoly=void 0,this.degree=c,this.degree&&this.initialize(this.degree)}ReedSolomonEncoder.prototype.initialize=function(c){this.degree=c,this.genPoly=eo.generateECPolynomial(this.degree)},ReedSolomonEncoder.prototype.encode=function(c){if(!this.genPoly)throw Error("Encoder not initialized");let l=new Uint8Array(c.length+this.degree);l.set(c);let et=eo.mod(l,this.genPoly),es=this.degree-et.length;if(es>0){let c=new Uint8Array(this.degree);return c.set(et,es),c}return et},c.exports=ReedSolomonEncoder},66579:function(c,l){let et="[0-9]+",eo="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";eo=eo.replace(/u/g,"\\u");let es="(?:(?![A-Z0-9 $%*+\\-./:]|"+eo+")(?:.|[\r\n]))+";l.KANJI=RegExp(eo,"g"),l.BYTE_KANJI=RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),l.BYTE=RegExp(es,"g"),l.NUMERIC=RegExp(et,"g"),l.ALPHANUMERIC=RegExp("[A-Z $%*+\\-./:]+","g");let ec=RegExp("^"+eo+"$"),el=RegExp("^"+et+"$"),ed=RegExp("^[A-Z0-9 $%*+\\-./:]+$");l.testKanji=function(c){return ec.test(c)},l.testNumeric=function(c){return el.test(c)},l.testAlphanumeric=function(c){return ed.test(c)}},25082:function(c,l,et){let eo=et(37662),es=et(10894),ec=et(77654),el=et(90690),ed=et(69592),eh=et(66579),ef=et(13400),ep=et(78343);function getStringByteLength(c){return unescape(encodeURIComponent(c)).length}function getSegments(c,l,et){let eo;let es=[];for(;null!==(eo=c.exec(et));)es.push({data:eo[0],index:eo.index,mode:l,length:eo[0].length});return es}function getSegmentsFromString(c){let l,et;let es=getSegments(eh.NUMERIC,eo.NUMERIC,c),ec=getSegments(eh.ALPHANUMERIC,eo.ALPHANUMERIC,c);ef.isKanjiModeEnabled()?(l=getSegments(eh.BYTE,eo.BYTE,c),et=getSegments(eh.KANJI,eo.KANJI,c)):(l=getSegments(eh.BYTE_KANJI,eo.BYTE,c),et=[]);let el=es.concat(ec,l,et);return el.sort(function(c,l){return c.index-l.index}).map(function(c){return{data:c.data,mode:c.mode,length:c.length}})}function getSegmentBitsLength(c,l){switch(l){case eo.NUMERIC:return es.getBitsLength(c);case eo.ALPHANUMERIC:return ec.getBitsLength(c);case eo.KANJI:return ed.getBitsLength(c);case eo.BYTE:return el.getBitsLength(c)}}function buildSingleSegment(c,l){let et;let eh=eo.getBestModeForData(c);if((et=eo.from(l,eh))!==eo.BYTE&&et.bit=0?c[c.length-1]:null;return et&&et.mode===l.mode?c[c.length-1].data+=l.data:c.push(l),c},[]))},l.rawSplit=function(c){return l.fromArray(getSegmentsFromString(c,ef.isKanjiModeEnabled()))}},13400:function(c,l){let et;let eo=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];l.getSymbolSize=function(c){if(!c)throw Error('"version" cannot be null or undefined');if(c<1||c>40)throw Error('"version" should be in range from 1 to 40');return 4*c+17},l.getSymbolTotalCodewords=function(c){return eo[c]},l.getBCHDigit=function(c){let l=0;for(;0!==c;)l++,c>>>=1;return l},l.setToSJISFunction=function(c){if("function"!=typeof c)throw Error('"toSJISFunc" is not a valid function.');et=c},l.isKanjiModeEnabled=function(){return void 0!==et},l.toSJIS=function(c){return et(c)}},64956:function(c,l){l.isValid=function(c){return!isNaN(c)&&c>=1&&c<=40}},48670:function(c,l,et){let eo=et(13400),es=et(37039),ec=et(9406),el=et(37662),ed=et(64956),eh=eo.getBCHDigit(7973);function getReservedBitsCount(c,l){return el.getCharCountIndicator(c,l)+4}l.from=function(c,l){return ed.isValid(c)?parseInt(c,10):l},l.getCapacity=function(c,l,et){if(!ed.isValid(c))throw Error("Invalid QR Code version");void 0===et&&(et=el.BYTE);let ec=eo.getSymbolTotalCodewords(c),eh=es.getTotalCodewordsCount(c,l),ef=(ec-eh)*8;if(et===el.MIXED)return ef;let ep=ef-getReservedBitsCount(et,c);switch(et){case el.NUMERIC:return Math.floor(ep/10*3);case el.ALPHANUMERIC:return Math.floor(ep/11*2);case el.KANJI:return Math.floor(ep/13);case el.BYTE:default:return Math.floor(ep/8)}},l.getBestVersionForData=function(c,et){let eo;let es=ec.from(et,ec.M);if(Array.isArray(c)){if(c.length>1)return function(c,et){for(let eo=1;eo<=40;eo++){let es=function(c,l){let et=0;return c.forEach(function(c){let eo=getReservedBitsCount(c.mode,l);et+=eo+c.getBitsLength()}),et}(c,eo);if(es<=l.getCapacity(eo,et,el.MIXED))return eo}}(c,es);if(0===c.length)return 1;eo=c[0]}else eo=c;return function(c,et,eo){for(let es=1;es<=40;es++)if(et<=l.getCapacity(es,eo,c))return es}(eo.mode,eo.getLength(),es)},l.getEncodedBits=function(c){if(!ed.isValid(c)||c<7)throw Error("Invalid QR Code version");let l=c<<12;for(;eo.getBCHDigit(l)-eh>=0;)l^=7973<':"",ef="0&&eh>0&&c[ed-1]||(eo+=ec?svgCmd("M",eh+et,.5+ef+et):svgCmd("m",es,0),es=0,ec=!1),eh+1',ep=es.width?'width="'+es.width+'" height="'+es.width+'" ':"",eg=''+eh+ef+"\n";return"function"==typeof et&&et(null,eg),eg}},10544:function(c,l){function hex2rgba(c){if("number"==typeof c&&(c=c.toString()),"string"!=typeof c)throw Error("Color should be defined as hex string");let l=c.slice().replace("#","").split("");if(l.length<3||5===l.length||l.length>8)throw Error("Invalid hex color: "+c);(3===l.length||4===l.length)&&(l=Array.prototype.concat.apply([],l.map(function(c){return[c,c]}))),6===l.length&&l.push("F","F");let et=parseInt(l.join(""),16);return{r:et>>24&255,g:et>>16&255,b:et>>8&255,a:255&et,hex:"#"+l.slice(0,6).join("")}}l.getOptions=function(c){c||(c={}),c.color||(c.color={});let l=void 0===c.margin||null===c.margin||c.margin<0?4:c.margin,et=c.width&&c.width>=21?c.width:void 0,eo=c.scale||4;return{width:et,scale:et?4:eo,margin:l,color:{dark:hex2rgba(c.color.dark||"#000000ff"),light:hex2rgba(c.color.light||"#ffffffff")},type:c.type,rendererOpts:c.rendererOpts||{}}},l.getScale=function(c,l){return l.width&&l.width>=c+2*l.margin?l.width/(c+2*l.margin):l.scale},l.getImageWidth=function(c,et){let eo=l.getScale(c,et);return Math.floor((c+2*et.margin)*eo)},l.qrToImageData=function(c,et,eo){let es=et.modules.size,ec=et.modules.data,el=l.getScale(es,eo),ed=Math.floor((es+2*eo.margin)*el),eh=eo.margin*el,ef=[eo.color.light,eo.color.dark];for(let l=0;l=eh&&et>=eh&&l-1?c.split(","):c},parseValues=function(c,l){var et={__proto__:null},ed=l.ignoreQueryPrefix?c.replace(/^\?/,""):c,eh=l.parameterLimit===1/0?void 0:l.parameterLimit,ef=ed.split(l.delimiter,eh),ep=-1,eg=l.charset;if(l.charsetSentinel)for(em=0;em=0&&et.parseArrays&&ef<=et.arrayLimit?(el=[])[ef]=es:"__proto__"!==eh&&(el[eh]=es):el={0:es}}es=el}return es},parseKeys=function(c,l,et,eo){if(c){var ec=et.allowDots?c.replace(/\.([^.[]+)/g,"[$1]"):c,el=/(\[[^[\]]*])/g,ed=et.depth>0&&/(\[[^[\]]*])/.exec(ec),eh=ed?ec.slice(0,ed.index):ec,ef=[];if(eh){if(!et.plainObjects&&es.call(Object.prototype,eh)&&!et.allowPrototypes)return;ef.push(eh)}for(var ep=0;et.depth>0&&null!==(ed=el.exec(ec))&&ep0?eI.join(",")||null:void 0}];else if(eh(ep))eA=ep;else{var eM=Object.keys(eI);eA=eg?eM.sort(eg):eM}for(var e$=ec&&eh(eI)&&1===eI.length?l+"[]":l,eB=0;eB0?ew+e_:""}},19975:function(c,l,et){"use strict";var eo=et(62578),es=Object.prototype.hasOwnProperty,ec=Array.isArray,el=function(){for(var c=[],l=0;l<256;++l)c.push("%"+((l<16?"0":"")+l.toString(16)).toUpperCase());return c}(),compactQueue=function(c){for(;c.length>1;){var l=c.pop(),et=l.obj[l.prop];if(ec(et)){for(var eo=[],es=0;es=48&&ep<=57||ep>=65&&ep<=90||ep>=97&&ep<=122||ec===eo.RFC1738&&(40===ep||41===ep)){eh+=ed.charAt(ef);continue}if(ep<128){eh+=el[ep];continue}if(ep<2048){eh+=el[192|ep>>6]+el[128|63&ep];continue}if(ep<55296||ep>=57344){eh+=el[224|ep>>12]+el[128|ep>>6&63]+el[128|63&ep];continue}ef+=1,eh+=el[240|(ep=65536+((1023&ep)<<10|1023&ed.charCodeAt(ef)))>>18]+el[128|ep>>12&63]+el[128|ep>>6&63]+el[128|63&ep]}return eh},isBuffer:function(c){return!!c&&"object"==typeof c&&!!(c.constructor&&c.constructor.isBuffer&&c.constructor.isBuffer(c))},isRegExp:function(c){return"[object RegExp]"===Object.prototype.toString.call(c)},maybeMap:function(c,l){if(ec(c)){for(var et=[],eo=0;eo-1?ep:0,c.charCodeAt(em+1)){case 100:case 102:if(ef>=ed||null==l[ef])break;ep=ed||null==l[ef])break;ep=ed||void 0===l[ef])break;ep",ep=em+2,em++;break}eh+=eo(l[ef]),ep=em+2,em++;break;case 115:if(ef>=ed)break;ep1&&void 0!==arguments[1]?arguments[1]:"none";return c||l},getNavigatorInstance=function(){return!!("undefined"!=typeof window&&(window.navigator||navigator))&&(window.navigator||navigator)},isIOS13Check=function(c){var l=getNavigatorInstance();return l&&l.platform&&(-1!==l.platform.indexOf(c)||"MacIntel"===l.platform&&l.maxTouchPoints>1&&!window.MSStream)},isBrowserType=function(c){return c.type===eS.Browser},isEdgeType=function(c){return c.name===ex.Edge},isEdgeChromiumType=function(c){return"string"==typeof c&&-1!==c.indexOf("Edg/")},getIPad13=function(){return isIOS13Check("iPad")};ey.type,eS.SmartTv,ey.type,eS.Console,ey.type,eS.Wearable,ey.type,eS.Embedded,em.name===ex.MobileSafari||getIPad13(),em.name,ex.Chromium;var ek=(eo=ey.type)===eS.Mobile||eo===eS.Tablet||getIPad13(),eC=ey.type===eS.Mobile,eA=(ey.type===eS.Tablet||getIPad13(),isBrowserType(ey),isBrowserType(ey)),eI="Android"===ew.name,eP=(ew.name,"iOS"===ew.name||getIPad13()),eR=(em.name,ex.Chrome,em.name===ex.Firefox);(es=em.name)===ex.Safari||ex.MobileSafari,em.name,ex.Opera,(ec=em.name)===ex.InternetExplorer||ex.Ie,setDefaults(ew.version),setDefaults(ew.name),setDefaults(em.version),setDefaults(em.major),setDefaults(em.name),setDefaults(ey.vendor),setDefaults(ey.model),setDefaults(e_.name),setDefaults(e_.version),setDefaults(eE),isEdgeType(em)||isEdgeChromiumType(eE),em.name,ex.Yandex,setDefaults(ey.type,"browser"),(el=getNavigatorInstance())&&(/iPad|iPhone|iPod/.test(el.platform)||"MacIntel"===el.platform&&el.maxTouchPoints>1)&&window.MSStream,getIPad13(),isIOS13Check("iPhone"),isIOS13Check("iPod"),"string"==typeof(eh=(ed=getNavigatorInstance())&&ed.userAgent&&ed.userAgent.toLowerCase())&&/electron/.test(eh),isEdgeChromiumType(eE),isEdgeType(em)&&isEdgeChromiumType(eE),ew.name,ew.name,em.name,ex.MIUI,em.name,ex.SamsungBrowser,l.Dt=eI,l.nI=eA,l.vU=eR,l.gn=eP,l.tq=ek,l.UA=eC},17966:function(c){var l="undefined"!=typeof Element,et="function"==typeof Map,eo="function"==typeof Set,es="function"==typeof ArrayBuffer&&!!ArrayBuffer.isView;c.exports=function(c,ec){try{return function equal(c,ec){if(c===ec)return!0;if(c&&ec&&"object"==typeof c&&"object"==typeof ec){var el,ed,eh,ef;if(c.constructor!==ec.constructor)return!1;if(Array.isArray(c)){if((el=c.length)!=ec.length)return!1;for(ed=el;0!=ed--;)if(!equal(c[ed],ec[ed]))return!1;return!0}if(et&&c instanceof Map&&ec instanceof Map){if(c.size!==ec.size)return!1;for(ef=c.entries();!(ed=ef.next()).done;)if(!ec.has(ed.value[0]))return!1;for(ef=c.entries();!(ed=ef.next()).done;)if(!equal(ed.value[1],ec.get(ed.value[0])))return!1;return!0}if(eo&&c instanceof Set&&ec instanceof Set){if(c.size!==ec.size)return!1;for(ef=c.entries();!(ed=ef.next()).done;)if(!ec.has(ed.value[0]))return!1;return!0}if(es&&ArrayBuffer.isView(c)&&ArrayBuffer.isView(ec)){if((el=c.length)!=ec.length)return!1;for(ed=el;0!=ed--;)if(c[ed]!==ec[ed])return!1;return!0}if(c.constructor===RegExp)return c.source===ec.source&&c.flags===ec.flags;if(c.valueOf!==Object.prototype.valueOf&&"function"==typeof c.valueOf&&"function"==typeof ec.valueOf)return c.valueOf()===ec.valueOf();if(c.toString!==Object.prototype.toString&&"function"==typeof c.toString&&"function"==typeof ec.toString)return c.toString()===ec.toString();if((el=(eh=Object.keys(c)).length)!==Object.keys(ec).length)return!1;for(ed=el;0!=ed--;)if(!Object.prototype.hasOwnProperty.call(ec,eh[ed]))return!1;if(l&&c instanceof Element)return!1;for(ed=el;0!=ed--;)if(("_owner"!==eh[ed]&&"__v"!==eh[ed]&&"__o"!==eh[ed]||!c.$$typeof)&&!equal(c[eh[ed]],ec[eh[ed]]))return!1;return!0}return c!=c&&ec!=ec}(c,ec)}catch(c){if((c.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw c}}},8236:function(c,l){"use strict";/** @license React v16.13.1 + * react-is.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var et="function"==typeof Symbol&&Symbol.for,eo=et?Symbol.for("react.element"):60103,es=et?Symbol.for("react.portal"):60106,ec=et?Symbol.for("react.fragment"):60107,el=et?Symbol.for("react.strict_mode"):60108,ed=et?Symbol.for("react.profiler"):60114,eh=et?Symbol.for("react.provider"):60109,ef=et?Symbol.for("react.context"):60110,ep=et?Symbol.for("react.async_mode"):60111,eg=et?Symbol.for("react.concurrent_mode"):60111,em=et?Symbol.for("react.forward_ref"):60112,eb=et?Symbol.for("react.suspense"):60113,ey=et?Symbol.for("react.suspense_list"):60120,e_=et?Symbol.for("react.memo"):60115,ew=et?Symbol.for("react.lazy"):60116,eE=et?Symbol.for("react.block"):60121,eS=et?Symbol.for("react.fundamental"):60117,ex=et?Symbol.for("react.responder"):60118,ek=et?Symbol.for("react.scope"):60119;function z(c){if("object"==typeof c&&null!==c){var l=c.$$typeof;switch(l){case eo:switch(c=c.type){case ep:case eg:case ec:case ed:case el:case eb:return c;default:switch(c=c&&c.$$typeof){case ef:case em:case ew:case e_:case eh:return c;default:return l}}case es:return l}}}function A(c){return z(c)===eg}l.AsyncMode=ep,l.ConcurrentMode=eg,l.ContextConsumer=ef,l.ContextProvider=eh,l.Element=eo,l.ForwardRef=em,l.Fragment=ec,l.Lazy=ew,l.Memo=e_,l.Portal=es,l.Profiler=ed,l.StrictMode=el,l.Suspense=eb,l.isAsyncMode=function(c){return A(c)||z(c)===ep},l.isConcurrentMode=A,l.isContextConsumer=function(c){return z(c)===ef},l.isContextProvider=function(c){return z(c)===eh},l.isElement=function(c){return"object"==typeof c&&null!==c&&c.$$typeof===eo},l.isForwardRef=function(c){return z(c)===em},l.isFragment=function(c){return z(c)===ec},l.isLazy=function(c){return z(c)===ew},l.isMemo=function(c){return z(c)===e_},l.isPortal=function(c){return z(c)===es},l.isProfiler=function(c){return z(c)===ed},l.isStrictMode=function(c){return z(c)===el},l.isSuspense=function(c){return z(c)===eb},l.isValidElementType=function(c){return"string"==typeof c||"function"==typeof c||c===ec||c===eg||c===ed||c===el||c===eb||c===ey||"object"==typeof c&&null!==c&&(c.$$typeof===ew||c.$$typeof===e_||c.$$typeof===eh||c.$$typeof===ef||c.$$typeof===em||c.$$typeof===eS||c.$$typeof===ex||c.$$typeof===ek||c.$$typeof===eE)},l.typeOf=z},9176:function(c,l,et){"use strict";c.exports=et(8236)},27455:function(c){"use strict";var l={};function createErrorType(c,et,eo){eo||(eo=Error);var es=function(c){function NodeError(l,eo,es){return c.call(this,"string"==typeof et?et:et(l,eo,es))||this}return NodeError.prototype=Object.create(c.prototype),NodeError.prototype.constructor=NodeError,NodeError.__proto__=c,NodeError}(eo);es.prototype.name=eo.name,es.prototype.code=c,l[c]=es}function oneOf(c,l){if(!Array.isArray(c))return"of ".concat(l," ").concat(String(c));var et=c.length;return(c=c.map(function(c){return String(c)}),et>2)?"one of ".concat(l," ").concat(c.slice(0,et-1).join(", "),", or ")+c[et-1]:2===et?"one of ".concat(l," ").concat(c[0]," or ").concat(c[1]):"of ".concat(l," ").concat(c[0])}createErrorType("ERR_INVALID_OPT_VALUE",function(c,l){return'The value "'+l+'" is invalid for option "'+c+'"'},TypeError),createErrorType("ERR_INVALID_ARG_TYPE",function(c,l,et){if("string"==typeof l&&(eo="not ",l.substr(!es||es<0?0:+es,eo.length)===eo)?(eh="must not be",l=l.replace(/^not /,"")):eh="must be",ec=" argument",(void 0===el||el>c.length)&&(el=c.length),c.substring(el-ec.length,el)===ec)ef="The ".concat(c," ").concat(eh," ").concat(oneOf(l,"type"));else{var eo,es,ec,el,ed,eh,ef,ep=("number"!=typeof ed&&(ed=0),ed+1>c.length||-1===c.indexOf(".",ed))?"argument":"property";ef='The "'.concat(c,'" ').concat(ep," ").concat(eh," ").concat(oneOf(l,"type"))}return ef+". Received type ".concat(typeof et)},TypeError),createErrorType("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),createErrorType("ERR_METHOD_NOT_IMPLEMENTED",function(c){return"The "+c+" method is not implemented"}),createErrorType("ERR_STREAM_PREMATURE_CLOSE","Premature close"),createErrorType("ERR_STREAM_DESTROYED",function(c){return"Cannot call "+c+" after a stream was destroyed"}),createErrorType("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),createErrorType("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),createErrorType("ERR_STREAM_WRITE_AFTER_END","write after end"),createErrorType("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),createErrorType("ERR_UNKNOWN_ENCODING",function(c){return"Unknown encoding: "+c},TypeError),createErrorType("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),c.exports.q=l},21105:function(c,l,et){"use strict";var eo=et(25566),es=Object.keys||function(c){var l=[];for(var et in c)l.push(et);return l};c.exports=Duplex;var ec=et(33623),el=et(98424);et(75335)(Duplex,ec);for(var ed=es(el.prototype),eh=0;eh0){if("string"==typeof l||eb.objectMode||Object.getPrototypeOf(l)===ep.prototype||(ef=l,l=ep.from(ef)),eo)eb.endEmitted?eC(c,new ek):addChunk(c,eb,l,!0);else if(eb.ended)eC(c,new eS);else{if(eb.destroyed)return!1;eb.reading=!1,eb.decoder&&!et?(l=eb.decoder.write(l),eb.objectMode||0!==l.length?addChunk(c,eb,l,!1):maybeReadMore(c,eb)):addChunk(c,eb,l,!1)}}else eo||(eb.reading=!1,maybeReadMore(c,eb))}return!eb.ended&&(eb.lengthl.highWaterMark){var et;l.highWaterMark=((et=c)>=1073741824?et=1073741824:(et--,et|=et>>>1,et|=et>>>2,et|=et>>>4,et|=et>>>8,et|=et>>>16,et++),et)}return c<=l.length?c:l.ended?l.length:(l.needReadable=!0,0)}function emitReadable(c){var l=c._readableState;es("emitReadable",l.needReadable,l.emittedReadable),l.needReadable=!1,l.emittedReadable||(es("emitReadable",l.flowing),l.emittedReadable=!0,eh.nextTick(emitReadable_,c))}function emitReadable_(c){var l=c._readableState;es("emitReadable_",l.destroyed,l.length,l.ended),!l.destroyed&&(l.length||l.ended)&&(c.emit("readable"),l.emittedReadable=!1),l.needReadable=!l.flowing&&!l.ended&&l.length<=l.highWaterMark,flow(c)}function maybeReadMore(c,l){l.readingMore||(l.readingMore=!0,eh.nextTick(maybeReadMore_,c,l))}function maybeReadMore_(c,l){for(;!l.reading&&!l.ended&&(l.length0,l.resumeScheduled&&!l.paused?l.flowing=!0:c.listenerCount("data")>0&&c.resume()}function nReadingNextTick(c){es("readable nexttick read 0"),c.read(0)}function resume_(c,l){es("resume",l.reading),l.reading||c.read(0),l.resumeScheduled=!1,c.emit("resume"),flow(c),l.flowing&&!l.reading&&c.read(0)}function flow(c){var l=c._readableState;for(es("flow",l.flowing);l.flowing&&null!==c.read(););}function fromList(c,l){var et;return 0===l.length?null:(l.objectMode?et=l.buffer.shift():!c||c>=l.length?(et=l.decoder?l.buffer.join(""):1===l.buffer.length?l.buffer.first():l.buffer.concat(l.length),l.buffer.clear()):et=l.buffer.consume(c,l.decoder),et)}function endReadable(c){var l=c._readableState;es("endReadable",l.endEmitted),l.endEmitted||(l.ended=!0,eh.nextTick(endReadableNT,l,c))}function endReadableNT(c,l){if(es("endReadableNT",c.endEmitted,c.length),!c.endEmitted&&0===c.length&&(c.endEmitted=!0,l.readable=!1,l.emit("end"),c.autoDestroy)){var et=l._writableState;(!et||et.autoDestroy&&et.finished)&&l.destroy()}}function indexOf(c,l){for(var et=0,eo=c.length;et=et.highWaterMark:et.length>0)||et.ended))return es("read: emitReadable",et.length,et.ended),0===et.length&&et.ended?endReadable(this):emitReadable(this),null;if(0===(c=howMuchToRead(c,et))&&et.ended)return 0===et.length&&endReadable(this),null;var ec=et.needReadable;return es("need readable",ec),(0===et.length||et.length-c0?fromList(c,et):null)?(et.needReadable=et.length<=et.highWaterMark,c=0):(et.length-=c,et.awaitDrain=0),0===et.length&&(et.ended||(et.needReadable=!0),eo!==c&&et.ended&&endReadable(this)),null!==l&&this.emit("data",l),l},Readable.prototype._read=function(c){eC(this,new ex("_read()"))},Readable.prototype.pipe=function(c,l){var et=this,eo=this._readableState;switch(eo.pipesCount){case 0:eo.pipes=c;break;case 1:eo.pipes=[eo.pipes,c];break;default:eo.pipes.push(c)}eo.pipesCount+=1,es("pipe count=%d opts=%j",eo.pipesCount,l);var ec=l&&!1===l.end||c===eh.stdout||c===eh.stderr?unpipe:onend;function onend(){es("onend"),c.end()}eo.endEmitted?eh.nextTick(ec):et.once("end",ec),c.on("unpipe",function onunpipe(l,ec){es("onunpipe"),l===et&&ec&&!1===ec.hasUnpiped&&(ec.hasUnpiped=!0,es("cleanup"),c.removeListener("close",onclose),c.removeListener("finish",onfinish),c.removeListener("drain",ondrain),c.removeListener("error",onerror),c.removeListener("unpipe",onunpipe),et.removeListener("end",onend),et.removeListener("end",unpipe),et.removeListener("data",ondata),el=!0,eo.awaitDrain&&(!c._writableState||c._writableState.needDrain)&&ondrain())});var ondrain=function(){var c=et._readableState;es("pipeOnDrain",c.awaitDrain),c.awaitDrain&&c.awaitDrain--,0===c.awaitDrain&&EElistenerCount(et,"data")&&(c.flowing=!0,flow(et))};c.on("drain",ondrain);var el=!1;function ondata(l){es("ondata");var ec=c.write(l);es("dest.write",ec),!1===ec&&((1===eo.pipesCount&&eo.pipes===c||eo.pipesCount>1&&-1!==indexOf(eo.pipes,c))&&!el&&(es("false write response, pause",eo.awaitDrain),eo.awaitDrain++),et.pause())}function onerror(l){es("onerror",l),unpipe(),c.removeListener("error",onerror),0===EElistenerCount(c,"error")&&eC(c,l)}function onclose(){c.removeListener("finish",onfinish),unpipe()}function onfinish(){es("onfinish"),c.removeListener("close",onclose),unpipe()}function unpipe(){es("unpipe"),et.unpipe(c)}return et.on("data",ondata),function(c,l,et){if("function"==typeof c.prependListener)return c.prependListener(l,et);c._events&&c._events[l]?Array.isArray(c._events[l])?c._events[l].unshift(et):c._events[l]=[et,c._events[l]]:c.on(l,et)}(c,"error",onerror),c.once("close",onclose),c.once("finish",onfinish),c.emit("pipe",et),eo.flowing||(es("pipe resume"),et.resume()),c},Readable.prototype.unpipe=function(c){var l=this._readableState,et={hasUnpiped:!1};if(0===l.pipesCount)return this;if(1===l.pipesCount)return c&&c!==l.pipes||(c||(c=l.pipes),l.pipes=null,l.pipesCount=0,l.flowing=!1,c&&c.emit("unpipe",this,et)),this;if(!c){var eo=l.pipes,es=l.pipesCount;l.pipes=null,l.pipesCount=0,l.flowing=!1;for(var ec=0;ec0,!1!==eo.flowing&&this.resume()):"readable"!==c||eo.endEmitted||eo.readableListening||(eo.readableListening=eo.needReadable=!0,eo.flowing=!1,eo.emittedReadable=!1,es("on readable",eo.length,eo.reading),eo.length?emitReadable(this):eo.reading||eh.nextTick(nReadingNextTick,this)),et},Readable.prototype.addListener=Readable.prototype.on,Readable.prototype.removeListener=function(c,l){var et=ef.prototype.removeListener.call(this,c,l);return"readable"===c&&eh.nextTick(updateReadableListening,this),et},Readable.prototype.removeAllListeners=function(c){var l=ef.prototype.removeAllListeners.apply(this,arguments);return("readable"===c||void 0===c)&&eh.nextTick(updateReadableListening,this),l},Readable.prototype.resume=function(){var c=this._readableState;return c.flowing||(es("resume"),c.flowing=!c.readableListening,c.resumeScheduled||(c.resumeScheduled=!0,eh.nextTick(resume_,this,c))),c.paused=!1,this},Readable.prototype.pause=function(){return es("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(es("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},Readable.prototype.wrap=function(c){var l=this,et=this._readableState,eo=!1;for(var ec in c.on("end",function(){if(es("wrapped end"),et.decoder&&!et.ended){var c=et.decoder.end();c&&c.length&&l.push(c)}l.push(null)}),c.on("data",function(ec){es("wrapped data"),et.decoder&&(ec=et.decoder.write(ec)),(!et.objectMode||null!=ec)&&(et.objectMode||ec&&ec.length)&&(l.push(ec)||(eo=!0,c.pause()))}),c)void 0===this[ec]&&"function"==typeof c[ec]&&(this[ec]=function(l){return function(){return c[l].apply(c,arguments)}}(ec));for(var el=0;el-1))throw new ek(c);return this._writableState.defaultEncoding=c,this},Object.defineProperty(Writable.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(Writable.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Writable.prototype._write=function(c,l,et){et(new ey("_write()"))},Writable.prototype._writev=null,Writable.prototype.end=function(c,l,et){var eo,es=this._writableState;return"function"==typeof c?(et=c,c=null,l=null):"function"==typeof l&&(et=l,l=null),null!=c&&this.write(c,l),es.corked&&(es.corked=1,this.uncork()),es.ending||(eo=et,es.ending=!0,finishMaybe(this,es),eo&&(es.finished?ec.nextTick(eo):this.once("finish",eo)),es.ended=!0,this.writable=!1),this},Object.defineProperty(Writable.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(Writable.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(c){this._writableState&&(this._writableState.destroyed=c)}}),Writable.prototype.destroy=ep.destroy,Writable.prototype._undestroy=ep.undestroy,Writable.prototype._destroy=function(c,l){l(c)}},80157:function(c,l,et){"use strict";var eo,es=et(25566);function _defineProperty(c,l,et){var eo;return(l="symbol"==typeof(eo=function(c,l){if("object"!=typeof c||null===c)return c;var et=c[Symbol.toPrimitive];if(void 0!==et){var eo=et.call(c,l||"default");if("object"!=typeof eo)return eo;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===l?String:Number)(c)}(l,"string"))?eo:String(eo))in c?Object.defineProperty(c,l,{value:et,enumerable:!0,configurable:!0,writable:!0}):c[l]=et,c}var ec=et(32435),el=Symbol("lastResolve"),ed=Symbol("lastReject"),eh=Symbol("error"),ef=Symbol("ended"),ep=Symbol("lastPromise"),eg=Symbol("handlePromise"),em=Symbol("stream");function createIterResult(c,l){return{value:c,done:l}}function readAndResolve(c){var l=c[el];if(null!==l){var et=c[em].read();null!==et&&(c[ep]=null,c[el]=null,c[ed]=null,l(createIterResult(et,!1)))}}function onReadable(c){es.nextTick(readAndResolve,c)}var eb=Object.getPrototypeOf(function(){}),ey=Object.setPrototypeOf((_defineProperty(eo={get stream(){return this[em]},next:function(){var c,l,et=this,eo=this[eh];if(null!==eo)return Promise.reject(eo);if(this[ef])return Promise.resolve(createIterResult(void 0,!0));if(this[em].destroyed)return new Promise(function(c,l){es.nextTick(function(){et[eh]?l(et[eh]):c(createIterResult(void 0,!0))})});var ec=this[ep];if(ec)l=new Promise((c=this,function(l,et){ec.then(function(){if(c[ef]){l(createIterResult(void 0,!0));return}c[eg](l,et)},et)}));else{var el=this[em].read();if(null!==el)return Promise.resolve(createIterResult(el,!1));l=new Promise(this[eg])}return this[ep]=l,l}},Symbol.asyncIterator,function(){return this}),_defineProperty(eo,"return",function(){var c=this;return new Promise(function(l,et){c[em].destroy(null,function(c){if(c){et(c);return}l(createIterResult(void 0,!0))})})}),eo),eb);c.exports=function(c){var l,et=Object.create(ey,(_defineProperty(l={},em,{value:c,writable:!0}),_defineProperty(l,el,{value:null,writable:!0}),_defineProperty(l,ed,{value:null,writable:!0}),_defineProperty(l,eh,{value:null,writable:!0}),_defineProperty(l,ef,{value:c._readableState.endEmitted,writable:!0}),_defineProperty(l,eg,{value:function(c,l){var eo=et[em].read();eo?(et[ep]=null,et[el]=null,et[ed]=null,c(createIterResult(eo,!1))):(et[el]=c,et[ed]=l)},writable:!0}),l));return et[ep]=null,ec(c,function(c){if(c&&"ERR_STREAM_PREMATURE_CLOSE"!==c.code){var l=et[ed];null!==l&&(et[ep]=null,et[el]=null,et[ed]=null,l(c)),et[eh]=c;return}var eo=et[el];null!==eo&&(et[ep]=null,et[el]=null,et[ed]=null,eo(createIterResult(void 0,!0))),et[ef]=!0}),c.on("readable",onReadable.bind(null,et)),et}},27195:function(c,l,et){"use strict";function ownKeys(c,l){var et=Object.keys(c);if(Object.getOwnPropertySymbols){var eo=Object.getOwnPropertySymbols(c);l&&(eo=eo.filter(function(l){return Object.getOwnPropertyDescriptor(c,l).enumerable})),et.push.apply(et,eo)}return et}function _objectSpread(c){for(var l=1;l0?this.tail.next=l:this.head=l,this.tail=l,++this.length}},{key:"unshift",value:function(c){var l={data:c,next:this.head};0===this.length&&(this.tail=l),this.head=l,++this.length}},{key:"shift",value:function(){if(0!==this.length){var c=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,c}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(c){if(0===this.length)return"";for(var l=this.head,et=""+l.data;l=l.next;)et+=c+l.data;return et}},{key:"concat",value:function(c){if(0===this.length)return eo.alloc(0);for(var l,et,es=eo.allocUnsafe(c>>>0),ec=this.head,el=0;ec;)l=ec.data,et=el,eo.prototype.copy.call(l,es,et),el+=ec.data.length,ec=ec.next;return es}},{key:"consume",value:function(c,l){var et;return ces.length?es.length:c;if(ec===es.length?eo+=es:eo+=es.slice(0,c),0==(c-=ec)){ec===es.length?(++et,l.next?this.head=l.next:this.head=this.tail=null):(this.head=l,l.data=es.slice(ec));break}++et}return this.length-=et,eo}},{key:"_getBuffer",value:function(c){var l=eo.allocUnsafe(c),et=this.head,es=1;for(et.data.copy(l),c-=et.data.length;et=et.next;){var ec=et.data,el=c>ec.length?ec.length:c;if(ec.copy(l,l.length-c,0,el),0==(c-=el)){el===ec.length?(++es,et.next?this.head=et.next:this.head=this.tail=null):(this.head=et,et.data=ec.slice(el));break}++es}return this.length-=es,l}},{key:ec,value:function(c,l){return es(this,_objectSpread(_objectSpread({},l),{},{depth:0,customInspect:!1}))}}],_defineProperties(BufferList.prototype,c),l&&_defineProperties(BufferList,l),Object.defineProperty(BufferList,"prototype",{writable:!1}),BufferList}()},22382:function(c,l,et){"use strict";var eo=et(25566);function emitErrorAndCloseNT(c,l){emitErrorNT(c,l),emitCloseNT(c)}function emitCloseNT(c){(!c._writableState||c._writableState.emitClose)&&(!c._readableState||c._readableState.emitClose)&&c.emit("close")}function emitErrorNT(c,l){c.emit("error",l)}c.exports={destroy:function(c,l){var et=this,es=this._readableState&&this._readableState.destroyed,ec=this._writableState&&this._writableState.destroyed;return es||ec?l?l(c):c&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,eo.nextTick(emitErrorNT,this,c)):eo.nextTick(emitErrorNT,this,c)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(c||null,function(c){!l&&c?et._writableState?et._writableState.errorEmitted?eo.nextTick(emitCloseNT,et):(et._writableState.errorEmitted=!0,eo.nextTick(emitErrorAndCloseNT,et,c)):eo.nextTick(emitErrorAndCloseNT,et,c):l?(eo.nextTick(emitCloseNT,et),l(c)):eo.nextTick(emitCloseNT,et)})),this},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(c,l){var et=c._readableState,eo=c._writableState;et&&et.autoDestroy||eo&&eo.autoDestroy?c.destroy(l):c.emit("error",l)}}},32435:function(c,l,et){"use strict";var eo=et(27455).q.ERR_STREAM_PREMATURE_CLOSE;function noop(){}c.exports=function eos(c,l,et){if("function"==typeof l)return eos(c,null,l);l||(l={}),es=et||noop,ec=!1,et=function(){if(!ec){ec=!0;for(var c=arguments.length,l=Array(c),et=0;et0},function(c){if(c)return ec(c);em=!0,ec()}),eb=!1,function(l){if(!em&&!eb){if(eb=!0,c.setHeader&&"function"==typeof c.abort)return c.abort();if("function"==typeof c.destroy)return c.destroy();ec(l||new el("pipe"))}}});return ed.reduce(pipe)}},60072:function(c,l,et){"use strict";var eo=et(27455).q.ERR_INVALID_OPT_VALUE;c.exports={getHighWaterMark:function(c,l,et,es){var ec=null!=l.highWaterMark?l.highWaterMark:es?l[et]:null;if(null!=ec){if(!(isFinite(ec)&&Math.floor(ec)===ec)||ec<0){var el=es?et:"highWaterMark";throw new eo(el,ec)}return Math.floor(ec)}return c.objectMode?16:16384}}},14163:function(c,l,et){c.exports=et(512).EventEmitter},21579:function(c,l,et){(l=c.exports=et(33623)).Stream=l,l.Readable=l,l.Writable=et(98424),l.Duplex=et(21105),l.Transform=et(568),l.PassThrough=et(77359),l.finished=et(32435),l.pipeline=et(87432)},33664:function(c,l,et){"use strict";et.r(l),et.d(l,{ArgumentOutOfRangeError:function(){return eM.W},AsyncSubject:function(){return ep.c},BehaviorSubject:function(){return eh.X},ConnectableObservable:function(){return es.c},EMPTY:function(){return eG.E},EmptyError:function(){return e$.K},GroupedObservable:function(){return ec.T},NEVER:function(){return eX},Notification:function(){return eR.P},NotificationKind:function(){return eR.W},ObjectUnsubscribedError:function(){return eB.N},Observable:function(){return eo.y},ReplaySubject:function(){return ef.t},Scheduler:function(){return eA.b},Subject:function(){return ed.xQ},Subscriber:function(){return eP.L},Subscription:function(){return eI.w},TimeoutError:function(){return ej.W},UnsubscriptionError:function(){return eD.B},VirtualAction:function(){return eC},VirtualTimeScheduler:function(){return ek},animationFrame:function(){return ex},animationFrameScheduler:function(){return eS},asap:function(){return eg.e},asapScheduler:function(){return eg.E},async:function(){return em.P},asyncScheduler:function(){return em.z},bindCallback:function(){return function bindCallback(c,l,et){if(l){if(!(0,ez.K)(l))return function(){for(var eo=[],es=0;es1?eo.next(Array.prototype.slice.call(arguments)):eo.next(c)},eo,et)})}},fromEventPattern:function(){return function fromEventPattern(c,l,et){return et?fromEventPattern(c,l).pipe((0,eL.U)(function(c){return(0,eU.k)(c)?et.apply(void 0,c):et(c)})):new eo.y(function(et){var eo,handler=function(){for(var c=[],l=0;l0)?c.prototype.requestAsyncId.call(this,l,et,eo):(l.actions.push(this),l.scheduled||(l.scheduled=requestAnimationFrame(function(){return l.flush(null)})))},AnimationFrameAction.prototype.recycleAsyncId=function(l,et,eo){if(void 0===eo&&(eo=0),null!==eo&&eo>0||null===eo&&this.delay>0)return c.prototype.recycleAsyncId.call(this,l,et,eo);0===l.actions.length&&(cancelAnimationFrame(et),l.scheduled=void 0)},AnimationFrameAction}(e_.o),eE=et(13995),eS=new(function(c){function AnimationFrameScheduler(){return null!==c&&c.apply(this,arguments)||this}return ey.ZT(AnimationFrameScheduler,c),AnimationFrameScheduler.prototype.flush=function(c){this.active=!0,this.scheduled=void 0;var l,et=this.actions,eo=-1,es=et.length;c=c||et.shift();do if(l=c.execute(c.state,c.delay))break;while(++eol.index?1:-1:c.delay>l.delay?1:-1},VirtualAction}(e_.o),eA=et(70283),eI=et(29659),eP=et(92105),eR=et(73762),eO=et(52996),eT=et(6860),eN=et(18016);function isObservable(c){return!!c&&(c instanceof eo.y||"function"==typeof c.lift&&"function"==typeof c.subscribe)}var eM=et(73197),e$=et(40531),eB=et(72280),eD=et(5156),ej=et(81799),eL=et(45889),eF=et(17087),eU=et(91088),ez=et(56711);function dispatch(c){var l=this,et=c.args,eo=c.subscriber,es=c.params,ec=es.callbackFunc,el=es.context,ed=es.scheduler,eh=es.subject;if(!eh){eh=es.subject=new ep.c;try{ec.apply(el,et.concat([function(){for(var c=[],et=0;et=l){eo.complete();break}if(eo.next(ec++),eo.closed)break}})}function range_dispatch(c){var l=c.start,et=c.index,eo=c.count,es=c.subscriber;if(et>=eo){es.complete();return}es.next(l),es.closed||(c.index=et+1,c.start=l+1,this.schedule(c))}var e6=et(62056),e4=et(51353);function using(c,l){return new eo.y(function(et){try{eo=c()}catch(c){et.error(c);return}try{es=l(eo)}catch(c){et.error(c);return}var eo,es,ec=(es?(0,eJ.D)(es):eG.E).subscribe(et);return function(){ec.unsubscribe(),eo&&eo.unsubscribe()}})}var e8=et(84095),e9=et(37542),e7=et(11297)},27762:function(c,l,et){"use strict";et.d(l,{c:function(){return el}});var eo=et(64619),es=et(75584),ec=et(29659),el=function(c){function AsyncSubject(){var l=null!==c&&c.apply(this,arguments)||this;return l.value=null,l.hasNext=!1,l.hasCompleted=!1,l}return eo.ZT(AsyncSubject,c),AsyncSubject.prototype._subscribe=function(l){return this.hasError?(l.error(this.thrownError),ec.w.EMPTY):this.hasCompleted&&this.hasNext?(l.next(this.value),l.complete(),ec.w.EMPTY):c.prototype._subscribe.call(this,l)},AsyncSubject.prototype.next=function(c){this.hasCompleted||(this.value=c,this.hasNext=!0)},AsyncSubject.prototype.error=function(l){this.hasCompleted||c.prototype.error.call(this,l)},AsyncSubject.prototype.complete=function(){this.hasCompleted=!0,this.hasNext&&c.prototype.next.call(this,this.value),c.prototype.complete.call(this)},AsyncSubject}(es.xQ)},95307:function(c,l,et){"use strict";et.d(l,{X:function(){return el}});var eo=et(64619),es=et(75584),ec=et(72280),el=function(c){function BehaviorSubject(l){var et=c.call(this)||this;return et._value=l,et}return eo.ZT(BehaviorSubject,c),Object.defineProperty(BehaviorSubject.prototype,"value",{get:function(){return this.getValue()},enumerable:!0,configurable:!0}),BehaviorSubject.prototype._subscribe=function(l){var et=c.prototype._subscribe.call(this,l);return et&&!et.closed&&l.next(this._value),et},BehaviorSubject.prototype.getValue=function(){if(this.hasError)throw this.thrownError;if(!this.closed)return this._value;throw new ec.N},BehaviorSubject.prototype.next=function(l){c.prototype.next.call(this,this._value=l)},BehaviorSubject}(es.xQ)},73762:function(c,l,et){"use strict";et.d(l,{P:function(){return ed},W:function(){return eo}});var eo,es=et(42229),ec=et(46304),el=et(62056);eo||(eo={});var ed=function(){function Notification(c,l,et){this.kind=c,this.value=l,this.error=et,this.hasValue="N"===c}return Notification.prototype.observe=function(c){switch(this.kind){case"N":return c.next&&c.next(this.value);case"E":return c.error&&c.error(this.error);case"C":return c.complete&&c.complete()}},Notification.prototype.do=function(c,l,et){switch(this.kind){case"N":return c&&c(this.value);case"E":return l&&l(this.error);case"C":return et&&et()}},Notification.prototype.accept=function(c,l,et){return c&&"function"==typeof c.next?this.observe(c):this.do(c,l,et)},Notification.prototype.toObservable=function(){switch(this.kind){case"N":return(0,ec.of)(this.value);case"E":return(0,el._)(this.error);case"C":return(0,es.c)()}throw Error("unexpected notification kind value")},Notification.createNext=function(c){return void 0!==c?new Notification("N",c):Notification.undefinedValueNotification},Notification.createError=function(c){return new Notification("E",void 0,c)},Notification.createComplete=function(){return Notification.completeNotification},Notification.completeNotification=new Notification("C"),Notification.undefinedValueNotification=new Notification("N",void 0),Notification}()},18547:function(c,l,et){"use strict";et.d(l,{y:function(){return ep}});var eo=et(17087),es=et(92105),ec=et(19538),el=et(36586),ed=et(42655),eh=et(52996),ef=et(11297),ep=function(){function Observable(c){this._isScalar=!1,c&&(this._subscribe=c)}return Observable.prototype.lift=function(c){var l=new Observable;return l.source=this,l.operator=c,l},Observable.prototype.subscribe=function(c,l,et){var eo=this.operator,ed=function(c,l,et){if(c){if(c instanceof es.L)return c;if(c[ec.b])return c[ec.b]()}return c||l||et?new es.L(c,l,et):new es.L(el.c)}(c,l,et);if(eo?ed.add(eo.call(ed,this.source)):ed.add(this.source||ef.v.useDeprecatedSynchronousErrorHandling&&!ed.syncErrorThrowable?this._subscribe(ed):this._trySubscribe(ed)),ef.v.useDeprecatedSynchronousErrorHandling&&ed.syncErrorThrowable&&(ed.syncErrorThrowable=!1,ed.syncErrorThrown))throw ed.syncErrorValue;return ed},Observable.prototype._trySubscribe=function(c){try{return this._subscribe(c)}catch(l){ef.v.useDeprecatedSynchronousErrorHandling&&(c.syncErrorThrown=!0,c.syncErrorValue=l),(0,eo._)(c)?c.error(l):console.warn(l)}},Observable.prototype.forEach=function(c,l){var et=this;return new(l=getPromiseCtor(l))(function(l,eo){var es;es=et.subscribe(function(l){try{c(l)}catch(c){eo(c),es&&es.unsubscribe()}},eo,l)})},Observable.prototype._subscribe=function(c){var l=this.source;return l&&l.subscribe(c)},Observable.prototype[ed.L]=function(){return this},Observable.prototype.pipe=function(){for(var c=[],l=0;lthis._bufferSize&&et.shift()}c.prototype.next.call(this,l)},ReplaySubject.prototype.nextTimeWindow=function(l){this.isStopped||(this._events.push(new ReplayEvent(this._getNow(),l)),this._trimBufferThenGetEvents()),c.prototype.next.call(this,l)},ReplaySubject.prototype._subscribe=function(c){var l,et=this._infiniteTimeWindow,eo=et?this._events:this._trimBufferThenGetEvents(),es=this.scheduler,ec=eo.length;if(this.closed)throw new eh.N;if(this.isStopped||this.hasError?l=el.w.EMPTY:(this.observers.push(c),l=new ef.W(this,c)),es&&c.add(c=new ed.ht(c,es)),et)for(var ep=0;epl&&(ec=Math.max(ec,es-l)),ec>0&&eo.splice(0,ec),eo},ReplaySubject}(es.xQ),ReplayEvent=function(c,l){this.time=c,this.value=l}},70283:function(c,l,et){"use strict";et.d(l,{b:function(){return eo}});var eo=function(){function Scheduler(c,l){void 0===l&&(l=Scheduler.now),this.SchedulerAction=c,this.now=l}return Scheduler.prototype.schedule=function(c,l,et){return void 0===l&&(l=0),new this.SchedulerAction(this,c).schedule(et,l)},Scheduler.now=function(){return Date.now()},Scheduler}()},75584:function(c,l,et){"use strict";et.d(l,{Yc:function(){return ep},xQ:function(){return eg}});var eo=et(64619),es=et(18547),ec=et(92105),el=et(29659),ed=et(72280),eh=et(95862),ef=et(19538),ep=function(c){function SubjectSubscriber(l){var et=c.call(this,l)||this;return et.destination=l,et}return eo.ZT(SubjectSubscriber,c),SubjectSubscriber}(ec.L),eg=function(c){function Subject(){var l=c.call(this)||this;return l.observers=[],l.closed=!1,l.isStopped=!1,l.hasError=!1,l.thrownError=null,l}return eo.ZT(Subject,c),Subject.prototype[ef.b]=function(){return new ep(this)},Subject.prototype.lift=function(c){var l=new em(this,this);return l.operator=c,l},Subject.prototype.next=function(c){if(this.closed)throw new ed.N;if(!this.isStopped)for(var l=this.observers,et=l.length,eo=l.slice(),es=0;es1&&"number"==typeof c[c.length-1]&&(et=c.pop())):"number"==typeof eh&&(et=c.pop()),null===ed&&1===c.length&&c[0]instanceof eo.y)?c[0]:(0,ec.J)(et)((0,el.n)(c,ed))}},46304:function(c,l,et){"use strict";et.d(l,{of:function(){return of}});var eo=et(56711),es=et(22456),ec=et(21350);function of(){for(var c=[],l=0;lNumber(l)&&1||Number(l):(0,el.K)(l)&&(et=l),(0,el.K)(et)||(et=es.P),new eo.y(function(l){var eo=(0,ec.k)(c)?c:+c-et.now();return et.schedule(dispatch,eo,{index:0,period:ed,subscriber:l})})}function dispatch(c){var l=c.index,et=c.period,eo=c.subscriber;if(eo.next(l),!eo.closed){if(-1===et)return eo.complete();c.index=l+1,this.schedule(c,et)}}},84095:function(c,l,et){"use strict";et.d(l,{$R:function(){return zip},mx:function(){return ef}});var eo=et(64619),es=et(22456),ec=et(91088),el=et(92105),ed=et(41705),eh=et(9266);function zip(){for(var c=[],l=0;lthis.index},StaticArrayIterator.prototype.hasCompleted=function(){return this.array.length===this.index},StaticArrayIterator}(),eb=function(c){function ZipBufferIterator(l,et,eo){var es=c.call(this,l)||this;return es.parent=et,es.observable=eo,es.stillUnsubscribed=!0,es.buffer=[],es.isComplete=!1,es}return eo.ZT(ZipBufferIterator,c),ZipBufferIterator.prototype[ed.hZ]=function(){return this},ZipBufferIterator.prototype.next=function(){var c=this.buffer;return 0===c.length&&this.isComplete?{value:null,done:!0}:{value:c.shift(),done:!1}},ZipBufferIterator.prototype.hasValue=function(){return this.buffer.length>0},ZipBufferIterator.prototype.hasCompleted=function(){return 0===this.buffer.length&&this.isComplete},ZipBufferIterator.prototype.notifyComplete=function(){this.buffer.length>0?(this.isComplete=!0,this.parent.notifyInactive()):this.destination.complete()},ZipBufferIterator.prototype.notifyNext=function(c){this.buffer.push(c),this.parent.checkIterators()},ZipBufferIterator.prototype.subscribe=function(){return(0,eh.ft)(this.observable,new eh.IY(this))},ZipBufferIterator}(eh.Ds)},6790:function(c,l,et){"use strict";et.d(l,{u:function(){return concatAll}});var eo=et(74103);function concatAll(){return(0,eo.J)(1)}},25163:function(c,l,et){"use strict";et.d(l,{h:function(){return filter}});var eo=et(64619),es=et(92105);function filter(c,l){return function(et){return et.lift(new ec(c,l))}}var ec=function(){function FilterOperator(c,l){this.predicate=c,this.thisArg=l}return FilterOperator.prototype.call=function(c,l){return l.subscribe(new el(c,this.predicate,this.thisArg))},FilterOperator}(),el=function(c){function FilterSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.predicate=et,es.thisArg=eo,es.count=0,es}return eo.ZT(FilterSubscriber,c),FilterSubscriber.prototype._next=function(c){var l;try{l=this.predicate.call(this.thisArg,c,this.count++)}catch(c){this.destination.error(c);return}l&&this.destination.next(c)},FilterSubscriber}(es.L)},9439:function(c,l,et){"use strict";et.d(l,{T:function(){return eg},v:function(){return groupBy}});var eo=et(64619),es=et(92105),ec=et(29659),el=et(18547),ed=et(75584);function groupBy(c,l,et,eo){return function(es){return es.lift(new eh(c,l,et,eo))}}var eh=function(){function GroupByOperator(c,l,et,eo){this.keySelector=c,this.elementSelector=l,this.durationSelector=et,this.subjectSelector=eo}return GroupByOperator.prototype.call=function(c,l){return l.subscribe(new ef(c,this.keySelector,this.elementSelector,this.durationSelector,this.subjectSelector))},GroupByOperator}(),ef=function(c){function GroupBySubscriber(l,et,eo,es,ec){var el=c.call(this,l)||this;return el.keySelector=et,el.elementSelector=eo,el.durationSelector=es,el.subjectSelector=ec,el.groups=null,el.attemptedToUnsubscribe=!1,el.count=0,el}return eo.ZT(GroupBySubscriber,c),GroupBySubscriber.prototype._next=function(c){var l;try{l=this.keySelector(c)}catch(c){this.error(c);return}this._group(c,l)},GroupBySubscriber.prototype._group=function(c,l){var et,eo=this.groups;eo||(eo=this.groups=new Map);var es=eo.get(l);if(this.elementSelector)try{et=this.elementSelector(c)}catch(c){this.error(c)}else et=c;if(!es){es=this.subjectSelector?this.subjectSelector():new ed.xQ,eo.set(l,es);var ec=new eg(l,es,this);if(this.destination.next(ec),this.durationSelector){var el=void 0;try{el=this.durationSelector(new eg(l,es))}catch(c){this.error(c);return}this.add(el.subscribe(new ep(l,es,this)))}}es.closed||es.next(et)},GroupBySubscriber.prototype._error=function(c){var l=this.groups;l&&(l.forEach(function(l,et){l.error(c)}),l.clear()),this.destination.error(c)},GroupBySubscriber.prototype._complete=function(){var c=this.groups;c&&(c.forEach(function(c,l){c.complete()}),c.clear()),this.destination.complete()},GroupBySubscriber.prototype.removeGroup=function(c){this.groups.delete(c)},GroupBySubscriber.prototype.unsubscribe=function(){this.closed||(this.attemptedToUnsubscribe=!0,0===this.count&&c.prototype.unsubscribe.call(this))},GroupBySubscriber}(es.L),ep=function(c){function GroupDurationSubscriber(l,et,eo){var es=c.call(this,et)||this;return es.key=l,es.group=et,es.parent=eo,es}return eo.ZT(GroupDurationSubscriber,c),GroupDurationSubscriber.prototype._next=function(c){this.complete()},GroupDurationSubscriber.prototype._unsubscribe=function(){var c=this.parent,l=this.key;this.key=this.parent=null,c&&c.removeGroup(l)},GroupDurationSubscriber}(es.L),eg=function(c){function GroupedObservable(l,et,eo){var es=c.call(this)||this;return es.key=l,es.groupSubject=et,es.refCountSubscription=eo,es}return eo.ZT(GroupedObservable,c),GroupedObservable.prototype._subscribe=function(c){var l=new ec.w,et=this.refCountSubscription,eo=this.groupSubject;return et&&!et.closed&&l.add(new em(et)),l.add(eo.subscribe(c)),l},GroupedObservable}(el.y),em=function(c){function InnerRefCountSubscription(l){var et=c.call(this)||this;return et.parent=l,l.count++,et}return eo.ZT(InnerRefCountSubscription,c),InnerRefCountSubscription.prototype.unsubscribe=function(){var l=this.parent;l.closed||this.closed||(c.prototype.unsubscribe.call(this),l.count-=1,0===l.count&&l.attemptedToUnsubscribe&&l.unsubscribe())},InnerRefCountSubscription}(ec.w)},45889:function(c,l,et){"use strict";et.d(l,{U:function(){return map}});var eo=et(64619),es=et(92105);function map(c,l){return function(et){if("function"!=typeof c)throw TypeError("argument is not a function. Are you looking for `mapTo()`?");return et.lift(new ec(c,l))}}var ec=function(){function MapOperator(c,l){this.project=c,this.thisArg=l}return MapOperator.prototype.call=function(c,l){return l.subscribe(new el(c,this.project,this.thisArg))},MapOperator}(),el=function(c){function MapSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.project=et,es.count=0,es.thisArg=eo||es,es}return eo.ZT(MapSubscriber,c),MapSubscriber.prototype._next=function(c){var l;try{l=this.project.call(this.thisArg,c,this.count++)}catch(c){this.destination.error(c);return}this.destination.next(l)},MapSubscriber}(es.L)},74103:function(c,l,et){"use strict";et.d(l,{J:function(){return mergeAll}});var eo=et(20096),es=et(18016);function mergeAll(c){return void 0===c&&(c=Number.POSITIVE_INFINITY),(0,eo.zg)(es.y,c)}},20096:function(c,l,et){"use strict";et.d(l,{VS:function(){return ef},zg:function(){return mergeMap}});var eo=et(64619),es=et(45889),ec=et(57910),el=et(9266);function mergeMap(c,l,et){return(void 0===et&&(et=Number.POSITIVE_INFINITY),"function"==typeof l)?function(eo){return eo.pipe(mergeMap(function(et,eo){return(0,ec.D)(c(et,eo)).pipe((0,es.U)(function(c,es){return l(et,c,eo,es)}))},et))}:("number"==typeof l&&(et=l),function(l){return l.lift(new ed(c,et))})}var ed=function(){function MergeMapOperator(c,l){void 0===l&&(l=Number.POSITIVE_INFINITY),this.project=c,this.concurrent=l}return MergeMapOperator.prototype.call=function(c,l){return l.subscribe(new eh(c,this.project,this.concurrent))},MergeMapOperator}(),eh=function(c){function MergeMapSubscriber(l,et,eo){void 0===eo&&(eo=Number.POSITIVE_INFINITY);var es=c.call(this,l)||this;return es.project=et,es.concurrent=eo,es.hasCompleted=!1,es.buffer=[],es.active=0,es.index=0,es}return eo.ZT(MergeMapSubscriber,c),MergeMapSubscriber.prototype._next=function(c){this.active0?this._next(c.shift()):0===this.active&&this.hasCompleted&&this.destination.complete()},MergeMapSubscriber}(el.Ds),ef=mergeMap},56600:function(c,l,et){"use strict";et.d(l,{QV:function(){return observeOn},ht:function(){return ed}});var eo=et(64619),es=et(92105),ec=et(73762);function observeOn(c,l){return void 0===l&&(l=0),function(et){return et.lift(new el(c,l))}}var el=function(){function ObserveOnOperator(c,l){void 0===l&&(l=0),this.scheduler=c,this.delay=l}return ObserveOnOperator.prototype.call=function(c,l){return l.subscribe(new ed(c,this.scheduler,this.delay))},ObserveOnOperator}(),ed=function(c){function ObserveOnSubscriber(l,et,eo){void 0===eo&&(eo=0);var es=c.call(this,l)||this;return es.scheduler=et,es.delay=eo,es}return eo.ZT(ObserveOnSubscriber,c),ObserveOnSubscriber.dispatch=function(c){var l=c.notification,et=c.destination;l.observe(et),this.unsubscribe()},ObserveOnSubscriber.prototype.scheduleMessage=function(c){this.destination.add(this.scheduler.schedule(ObserveOnSubscriber.dispatch,this.delay,new ObserveOnMessage(c,this.destination)))},ObserveOnSubscriber.prototype._next=function(c){this.scheduleMessage(ec.P.createNext(c))},ObserveOnSubscriber.prototype._error=function(c){this.scheduleMessage(ec.P.createError(c)),this.unsubscribe()},ObserveOnSubscriber.prototype._complete=function(){this.scheduleMessage(ec.P.createComplete()),this.unsubscribe()},ObserveOnSubscriber}(es.L),ObserveOnMessage=function(c,l){this.notification=c,this.destination=l}},16262:function(c,l,et){"use strict";et.d(l,{x:function(){return refCount}});var eo=et(64619),es=et(92105);function refCount(){return function(c){return c.lift(new ec(c))}}var ec=function(){function RefCountOperator(c){this.connectable=c}return RefCountOperator.prototype.call=function(c,l){var et=this.connectable;et._refCount++;var eo=new el(c,et),es=l.subscribe(eo);return eo.closed||(eo.connection=et.connect()),es},RefCountOperator}(),el=function(c){function RefCountSubscriber(l,et){var eo=c.call(this,l)||this;return eo.connectable=et,eo}return eo.ZT(RefCountSubscriber,c),RefCountSubscriber.prototype._unsubscribe=function(){var c=this.connectable;if(!c){this.connection=null;return}this.connectable=null;var l=c._refCount;if(l<=0||(c._refCount=l-1,l>1)){this.connection=null;return}var et=this.connection,eo=c._connection;this.connection=null,eo&&(!et||eo===et)&&eo.unsubscribe()},RefCountSubscriber}(es.L)},21350:function(c,l,et){"use strict";et.d(l,{r:function(){return scheduleArray}});var eo=et(18547),es=et(29659);function scheduleArray(c,l){return new eo.y(function(et){var eo=new es.w,ec=0;return eo.add(l.schedule(function(){if(ec===c.length){et.complete();return}et.next(c[ec++]),et.closed||eo.add(this.schedule())})),eo})}},37542:function(c,l,et){"use strict";et.d(l,{x:function(){return scheduled}});var eo=et(18547),es=et(29659),ec=et(42655),el=et(21350),ed=et(41705),eh=et(86355),ef=et(64404);function scheduled(c,l){if(null!=c){if(c&&"function"==typeof c[ec.L])return new eo.y(function(et){var eo=new es.w;return eo.add(l.schedule(function(){var es=c[ec.L]();eo.add(es.subscribe({next:function(c){eo.add(l.schedule(function(){return et.next(c)}))},error:function(c){eo.add(l.schedule(function(){return et.error(c)}))},complete:function(){eo.add(l.schedule(function(){return et.complete()}))}}))})),eo});if((0,eh.t)(c))return new eo.y(function(et){var eo=new es.w;return eo.add(l.schedule(function(){return c.then(function(c){eo.add(l.schedule(function(){et.next(c),eo.add(l.schedule(function(){return et.complete()}))}))},function(c){eo.add(l.schedule(function(){return et.error(c)}))})})),eo});if((0,ef.z)(c))return(0,el.r)(c,l);if(c&&"function"==typeof c[ed.hZ]||"string"==typeof c)return function(c,l){if(!c)throw Error("Iterable cannot be null");return new eo.y(function(et){var eo,ec=new es.w;return ec.add(function(){eo&&"function"==typeof eo.return&&eo.return()}),ec.add(l.schedule(function(){eo=c[ed.hZ](),ec.add(l.schedule(function(){if(!et.closed){try{var c,l,es=eo.next();c=es.value,l=es.done}catch(c){et.error(c);return}l?et.complete():(et.next(c),this.schedule())}}))})),ec})}(c,l)}throw TypeError((null!==c&&typeof c||c)+" is not observable")}},49424:function(c,l,et){"use strict";et.d(l,{o:function(){return es}});var eo=et(64619),es=function(c){function AsyncAction(l,et){var eo=c.call(this,l,et)||this;return eo.scheduler=l,eo.work=et,eo.pending=!1,eo}return eo.ZT(AsyncAction,c),AsyncAction.prototype.schedule=function(c,l){if(void 0===l&&(l=0),this.closed)return this;this.state=c;var et=this.id,eo=this.scheduler;return null!=et&&(this.id=this.recycleAsyncId(eo,et,l)),this.pending=!0,this.delay=l,this.id=this.id||this.requestAsyncId(eo,this.id,l),this},AsyncAction.prototype.requestAsyncId=function(c,l,et){return void 0===et&&(et=0),setInterval(c.flush.bind(c,this),et)},AsyncAction.prototype.recycleAsyncId=function(c,l,et){if(void 0===et&&(et=0),null!==et&&this.delay===et&&!1===this.pending)return l;clearInterval(l)},AsyncAction.prototype.execute=function(c,l){if(this.closed)return Error("executing a cancelled action");this.pending=!1;var et=this._execute(c,l);if(et)return et;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},AsyncAction.prototype._execute=function(c,l){var et=!1,eo=void 0;try{this.work(c)}catch(c){et=!0,eo=!!c&&c||Error(c)}if(et)return this.unsubscribe(),eo},AsyncAction.prototype._unsubscribe=function(){var c=this.id,l=this.scheduler,et=l.actions,eo=et.indexOf(this);this.work=null,this.state=null,this.pending=!1,this.scheduler=null,-1!==eo&&et.splice(eo,1),null!=c&&(this.id=this.recycleAsyncId(l,c,null)),this.delay=null},AsyncAction}(function(c){function Action(l,et){return c.call(this)||this}return eo.ZT(Action,c),Action.prototype.schedule=function(c,l){return void 0===l&&(l=0),this},Action}(et(29659).w))},13995:function(c,l,et){"use strict";et.d(l,{v:function(){return ec}});var eo=et(64619),es=et(70283),ec=function(c){function AsyncScheduler(l,et){void 0===et&&(et=es.b.now);var eo=c.call(this,l,function(){return AsyncScheduler.delegate&&AsyncScheduler.delegate!==eo?AsyncScheduler.delegate.now():et()})||this;return eo.actions=[],eo.active=!1,eo.scheduled=void 0,eo}return eo.ZT(AsyncScheduler,c),AsyncScheduler.prototype.schedule=function(l,et,eo){return(void 0===et&&(et=0),AsyncScheduler.delegate&&AsyncScheduler.delegate!==this)?AsyncScheduler.delegate.schedule(l,et,eo):c.prototype.schedule.call(this,l,et,eo)},AsyncScheduler.prototype.flush=function(c){var l,et=this.actions;if(this.active){et.push(c);return}this.active=!0;do if(l=c.execute(c.state,c.delay))break;while(c=et.shift());if(this.active=!1,l){for(;c=et.shift();)c.unsubscribe();throw l}},AsyncScheduler}(es.b)},36389:function(c,l,et){"use strict";et.d(l,{e:function(){return ep},E:function(){return ef}});var eo=et(64619),es=1,ec=Promise.resolve(),el={};function findAndClearHandle(c){return c in el&&(delete el[c],!0)}var ed={setImmediate:function(c){var l=es++;return el[l]=!0,ec.then(function(){return findAndClearHandle(l)&&c()}),l},clearImmediate:function(c){findAndClearHandle(c)}},eh=function(c){function AsapAction(l,et){var eo=c.call(this,l,et)||this;return eo.scheduler=l,eo.work=et,eo}return eo.ZT(AsapAction,c),AsapAction.prototype.requestAsyncId=function(l,et,eo){return(void 0===eo&&(eo=0),null!==eo&&eo>0)?c.prototype.requestAsyncId.call(this,l,et,eo):(l.actions.push(this),l.scheduled||(l.scheduled=ed.setImmediate(l.flush.bind(l,null))))},AsapAction.prototype.recycleAsyncId=function(l,et,eo){if(void 0===eo&&(eo=0),null!==eo&&eo>0||null===eo&&this.delay>0)return c.prototype.recycleAsyncId.call(this,l,et,eo);0===l.actions.length&&(ed.clearImmediate(et),l.scheduled=void 0)},AsapAction}(et(49424).o),ef=new(function(c){function AsapScheduler(){return null!==c&&c.apply(this,arguments)||this}return eo.ZT(AsapScheduler,c),AsapScheduler.prototype.flush=function(c){this.active=!0,this.scheduled=void 0;var l,et=this.actions,eo=-1,es=et.length;c=c||et.shift();do if(l=c.execute(c.state,c.delay))break;while(++eo0)?c.prototype.schedule.call(this,l,et):(this.delay=et,this.state=l,this.scheduler.flush(this),this)},QueueAction.prototype.execute=function(l,et){return et>0||this.closed?c.prototype.execute.call(this,l,et):this._execute(l,et)},QueueAction.prototype.requestAsyncId=function(l,et,eo){return(void 0===eo&&(eo=0),null!==eo&&eo>0||null===eo&&this.delay>0)?c.prototype.requestAsyncId.call(this,l,et,eo):l.flush(this)},QueueAction}(et(49424).o),ec=new(function(c){function QueueScheduler(){return null!==c&&c.apply(this,arguments)||this}return eo.ZT(QueueScheduler,c),QueueScheduler}(et(13995).v))(es),el=ec},41705:function(c,l,et){"use strict";et.d(l,{hZ:function(){return eo}});var eo="function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"},42655:function(c,l,et){"use strict";et.d(l,{L:function(){return eo}});var eo="function"==typeof Symbol&&Symbol.observable||"@@observable"},19538:function(c,l,et){"use strict";et.d(l,{b:function(){return eo}});var eo="function"==typeof Symbol?Symbol("rxSubscriber"):"@@rxSubscriber_"+Math.random()},73197:function(c,l,et){"use strict";et.d(l,{W:function(){return eo}});var eo=function(){function ArgumentOutOfRangeErrorImpl(){return Error.call(this),this.message="argument out of range",this.name="ArgumentOutOfRangeError",this}return ArgumentOutOfRangeErrorImpl.prototype=Object.create(Error.prototype),ArgumentOutOfRangeErrorImpl}()},40531:function(c,l,et){"use strict";et.d(l,{K:function(){return eo}});var eo=function(){function EmptyErrorImpl(){return Error.call(this),this.message="no elements in sequence",this.name="EmptyError",this}return EmptyErrorImpl.prototype=Object.create(Error.prototype),EmptyErrorImpl}()},72280:function(c,l,et){"use strict";et.d(l,{N:function(){return eo}});var eo=function(){function ObjectUnsubscribedErrorImpl(){return Error.call(this),this.message="object unsubscribed",this.name="ObjectUnsubscribedError",this}return ObjectUnsubscribedErrorImpl.prototype=Object.create(Error.prototype),ObjectUnsubscribedErrorImpl}()},81799:function(c,l,et){"use strict";et.d(l,{W:function(){return eo}});var eo=function(){function TimeoutErrorImpl(){return Error.call(this),this.message="Timeout has occurred",this.name="TimeoutError",this}return TimeoutErrorImpl.prototype=Object.create(Error.prototype),TimeoutErrorImpl}()},5156:function(c,l,et){"use strict";et.d(l,{B:function(){return eo}});var eo=function(){function UnsubscriptionErrorImpl(c){return Error.call(this),this.message=c?c.length+" errors occurred during unsubscription:\n"+c.map(function(c,l){return l+1+") "+c.toString()}).join("\n "):"",this.name="UnsubscriptionError",this.errors=c,this}return UnsubscriptionErrorImpl.prototype=Object.create(Error.prototype),UnsubscriptionErrorImpl}()},17087:function(c,l,et){"use strict";et.d(l,{_:function(){return canReportError}});var eo=et(92105);function canReportError(c){for(;c;){var l=c,et=l.closed,es=l.destination,ec=l.isStopped;if(et||ec)return!1;c=es&&es instanceof eo.L?es:null}return!0}},74223:function(c,l,et){"use strict";function hostReportError(c){setTimeout(function(){throw c},0)}et.d(l,{z:function(){return hostReportError}})},18016:function(c,l,et){"use strict";function identity(c){return c}et.d(l,{y:function(){return identity}})},91088:function(c,l,et){"use strict";et.d(l,{k:function(){return eo}});var eo=Array.isArray||function(c){return c&&"number"==typeof c.length}},64404:function(c,l,et){"use strict";et.d(l,{z:function(){return isArrayLike}});var isArrayLike=function(c){return c&&"number"==typeof c.length&&"function"!=typeof c}},39259:function(c,l,et){"use strict";function isFunction(c){return"function"==typeof c}et.d(l,{m:function(){return isFunction}})},1738:function(c,l,et){"use strict";et.d(l,{k:function(){return isNumeric}});var eo=et(91088);function isNumeric(c){return!(0,eo.k)(c)&&c-parseFloat(c)+1>=0}},83184:function(c,l,et){"use strict";function isObject(c){return null!==c&&"object"==typeof c}et.d(l,{K:function(){return isObject}})},86355:function(c,l,et){"use strict";function isPromise(c){return!!c&&"function"!=typeof c.subscribe&&"function"==typeof c.then}et.d(l,{t:function(){return isPromise}})},56711:function(c,l,et){"use strict";function isScheduler(c){return c&&"function"==typeof c.schedule}et.d(l,{K:function(){return isScheduler}})},6860:function(c,l,et){"use strict";function noop(){}et.d(l,{Z:function(){return noop}})},9603:function(c,l,et){"use strict";function not(c,l){function notPred(){return!notPred.pred.apply(notPred.thisArg,arguments)}return notPred.pred=c,notPred.thisArg=l,notPred}et.d(l,{f:function(){return not}})},52996:function(c,l,et){"use strict";et.d(l,{U:function(){return pipeFromArray},z:function(){return pipe}});var eo=et(18016);function pipe(){for(var c=[],l=0;l0&&this.destination.next(l),c.prototype._complete.call(this)},BufferCountSubscriber}(eg.L),ey=function(c){function BufferSkipCountSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.bufferSize=et,es.startBufferEvery=eo,es.buffers=[],es.count=0,es}return eo.ZT(BufferSkipCountSubscriber,c),BufferSkipCountSubscriber.prototype._next=function(c){var l=this.bufferSize,et=this.startBufferEvery,eo=this.buffers,es=this.count;this.count++,es%et==0&&eo.push([]);for(var ec=eo.length;ec--;){var el=eo[ec];el.push(c),el.length===l&&(eo.splice(ec,1),this.destination.next(el))}},BufferSkipCountSubscriber.prototype._complete=function(){for(var l=this.buffers,et=this.destination;l.length>0;){var eo=l.shift();eo.length>0&&et.next(eo)}c.prototype._complete.call(this)},BufferSkipCountSubscriber}(eg.L),e_=et(56711);function bufferTime(c){var l=arguments.length,et=ed.P;(0,e_.K)(arguments[arguments.length-1])&&(et=arguments[arguments.length-1],l--);var eo=null;l>=2&&(eo=arguments[1]);var es=Number.POSITIVE_INFINITY;return l>=3&&(es=arguments[2]),function(l){return l.lift(new ew(c,eo,es,et))}}var ew=function(){function BufferTimeOperator(c,l,et,eo){this.bufferTimeSpan=c,this.bufferCreationInterval=l,this.maxBufferSize=et,this.scheduler=eo}return BufferTimeOperator.prototype.call=function(c,l){return l.subscribe(new eE(c,this.bufferTimeSpan,this.bufferCreationInterval,this.maxBufferSize,this.scheduler))},BufferTimeOperator}(),Context=function(){this.buffer=[]},eE=function(c){function BufferTimeSubscriber(l,et,eo,es,ec){var el=c.call(this,l)||this;el.bufferTimeSpan=et,el.bufferCreationInterval=eo,el.maxBufferSize=es,el.scheduler=ec,el.contexts=[];var ed=el.openContext();return el.timespanOnly=null==eo||eo<0,el.timespanOnly?el.add(ed.closeAction=ec.schedule(dispatchBufferTimeSpanOnly,et,{subscriber:el,context:ed,bufferTimeSpan:et})):(el.add(ed.closeAction=ec.schedule(dispatchBufferClose,et,{subscriber:el,context:ed})),el.add(ec.schedule(dispatchBufferCreation,eo,{bufferTimeSpan:et,bufferCreationInterval:eo,subscriber:el,scheduler:ec}))),el}return eo.ZT(BufferTimeSubscriber,c),BufferTimeSubscriber.prototype._next=function(c){for(var l,et=this.contexts,eo=et.length,es=0;es0;){var eo=l.shift();et.next(eo.buffer)}c.prototype._complete.call(this)},BufferTimeSubscriber.prototype._unsubscribe=function(){this.contexts=null},BufferTimeSubscriber.prototype.onBufferFull=function(c){this.closeContext(c);var l=c.closeAction;if(l.unsubscribe(),this.remove(l),!this.closed&&this.timespanOnly){c=this.openContext();var et=this.bufferTimeSpan,eo={subscriber:this,context:c,bufferTimeSpan:et};this.add(c.closeAction=this.scheduler.schedule(dispatchBufferTimeSpanOnly,et,eo))}},BufferTimeSubscriber.prototype.openContext=function(){var c=new Context;return this.contexts.push(c),c},BufferTimeSubscriber.prototype.closeContext=function(c){this.destination.next(c.buffer);var l=this.contexts;(l?l.indexOf(c):-1)>=0&&l.splice(l.indexOf(c),1)},BufferTimeSubscriber}(eg.L);function dispatchBufferTimeSpanOnly(c){var l=c.subscriber,et=c.context;et&&l.closeContext(et),l.closed||(c.context=l.openContext(),c.context.closeAction=this.schedule(c,c.bufferTimeSpan))}function dispatchBufferCreation(c){var l=c.bufferCreationInterval,et=c.bufferTimeSpan,eo=c.subscriber,es=c.scheduler,ec=eo.openContext();eo.closed||(eo.add(ec.closeAction=es.schedule(dispatchBufferClose,et,{subscriber:eo,context:ec})),this.schedule(c,l))}function dispatchBufferClose(c){var l=c.subscriber,et=c.context;l.closeContext(et)}var eS=et(29659),ex=et(36718),ek=et(50240);function bufferToggle(c,l){return function(et){return et.lift(new eC(c,l))}}var eC=function(){function BufferToggleOperator(c,l){this.openings=c,this.closingSelector=l}return BufferToggleOperator.prototype.call=function(c,l){return l.subscribe(new eA(c,this.openings,this.closingSelector))},BufferToggleOperator}(),eA=function(c){function BufferToggleSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.closingSelector=eo,es.contexts=[],es.add((0,ex.D)(es,et)),es}return eo.ZT(BufferToggleSubscriber,c),BufferToggleSubscriber.prototype._next=function(c){for(var l=this.contexts,et=l.length,eo=0;eo0;){var eo=et.shift();eo.subscription.unsubscribe(),eo.buffer=null,eo.subscription=null}this.contexts=null,c.prototype._error.call(this,l)},BufferToggleSubscriber.prototype._complete=function(){for(var l=this.contexts;l.length>0;){var et=l.shift();this.destination.next(et.buffer),et.subscription.unsubscribe(),et.buffer=null,et.subscription=null}this.contexts=null,c.prototype._complete.call(this)},BufferToggleSubscriber.prototype.notifyNext=function(c,l){c?this.closeBuffer(c):this.openBuffer(l)},BufferToggleSubscriber.prototype.notifyComplete=function(c){this.closeBuffer(c.context)},BufferToggleSubscriber.prototype.openBuffer=function(c){try{var l=this.closingSelector.call(this,c);l&&this.trySubscribe(l)}catch(c){this._error(c)}},BufferToggleSubscriber.prototype.closeBuffer=function(c){var l=this.contexts;if(l&&c){var et=c.buffer,eo=c.subscription;this.destination.next(et),l.splice(l.indexOf(c),1),this.remove(eo),eo.unsubscribe()}},BufferToggleSubscriber.prototype.trySubscribe=function(c){var l=this.contexts,et=new eS.w,eo={buffer:[],subscription:et};l.push(eo);var es=(0,ex.D)(this,c,eo);!es||es.closed?this.closeBuffer(eo):(es.context=eo,this.add(es),et.add(es))},BufferToggleSubscriber}(ek.L);function bufferWhen(c){return function(l){return l.lift(new eI(c))}}var eI=function(){function BufferWhenOperator(c){this.closingSelector=c}return BufferWhenOperator.prototype.call=function(c,l){return l.subscribe(new eP(c,this.closingSelector))},BufferWhenOperator}(),eP=function(c){function BufferWhenSubscriber(l,et){var eo=c.call(this,l)||this;return eo.closingSelector=et,eo.subscribing=!1,eo.openBuffer(),eo}return eo.ZT(BufferWhenSubscriber,c),BufferWhenSubscriber.prototype._next=function(c){this.buffer.push(c)},BufferWhenSubscriber.prototype._complete=function(){var l=this.buffer;l&&this.destination.next(l),c.prototype._complete.call(this)},BufferWhenSubscriber.prototype._unsubscribe=function(){this.buffer=void 0,this.subscribing=!1},BufferWhenSubscriber.prototype.notifyNext=function(){this.openBuffer()},BufferWhenSubscriber.prototype.notifyComplete=function(){this.subscribing?this.complete():this.openBuffer()},BufferWhenSubscriber.prototype.openBuffer=function(){var c,l=this.closingSubscription;l&&(this.remove(l),l.unsubscribe());var et=this.buffer;this.buffer&&this.destination.next(et),this.buffer=[];try{c=(0,this.closingSelector)()}catch(c){return this.error(c)}l=new eS.w,this.closingSubscription=l,this.add(l),this.subscribing=!0,l.add((0,es.ft)(c,new es.IY(this))),this.subscribing=!1},BufferWhenSubscriber}(es.Ds);function catchError(c){return function(l){var et=new eR(c),eo=l.lift(et);return et.caught=eo}}var eR=function(){function CatchOperator(c){this.selector=c}return CatchOperator.prototype.call=function(c,l){return l.subscribe(new eO(c,this.selector,this.caught))},CatchOperator}(),eO=function(c){function CatchSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.selector=et,es.caught=eo,es}return eo.ZT(CatchSubscriber,c),CatchSubscriber.prototype.error=function(l){if(!this.isStopped){var et=void 0;try{et=this.selector(l,this.caught)}catch(l){c.prototype.error.call(this,l);return}this._unsubscribeAndRecycle();var eo=new es.IY(this);this.add(eo);var ec=(0,es.ft)(et,eo);ec!==eo&&this.add(ec)}},CatchSubscriber}(es.Ds),eT=et(33797);function combineAll(c){return function(l){return l.lift(new eT.Ms(c))}}var eN=et(91088),eM=et(57910);function combineLatest_combineLatest(){for(var c=[],l=0;l0&&et[0].time-eo.now()<=0;)et.shift().notification.observe(es);if(et.length>0){var ec=Math.max(0,et[0].time-eo.now());this.schedule(c,ec)}else this.unsubscribe(),l.active=!1},DelaySubscriber.prototype._schedule=function(c){this.active=!0,this.destination.add(c.schedule(DelaySubscriber.dispatch,this.delay,{source:this,destination:this.destination,scheduler:c}))},DelaySubscriber.prototype.scheduleNotification=function(c){if(!0!==this.errored){var l=this.scheduler,et=new DelayMessage(l.now()+this.delay,c);this.queue.push(et),!1===this.active&&this._schedule(l)}},DelaySubscriber.prototype._next=function(c){this.scheduleNotification(eG.P.createNext(c))},DelaySubscriber.prototype._error=function(c){this.errored=!0,this.queue=[],this.destination.error(c),this.unsubscribe()},DelaySubscriber.prototype._complete=function(){this.scheduleNotification(eG.P.createComplete()),this.unsubscribe()},DelaySubscriber}(eg.L),DelayMessage=function(c,l){this.time=c,this.notification=l},eQ=et(18547);function delayWhen(c,l){return l?function(et){return new eX(et,l).lift(new eY(c))}:function(l){return l.lift(new eY(c))}}var eY=function(){function DelayWhenOperator(c){this.delayDurationSelector=c}return DelayWhenOperator.prototype.call=function(c,l){return l.subscribe(new eZ(c,this.delayDurationSelector))},DelayWhenOperator}(),eZ=function(c){function DelayWhenSubscriber(l,et){var eo=c.call(this,l)||this;return eo.delayDurationSelector=et,eo.completed=!1,eo.delayNotifierSubscriptions=[],eo.index=0,eo}return eo.ZT(DelayWhenSubscriber,c),DelayWhenSubscriber.prototype.notifyNext=function(c,l,et,eo,es){this.destination.next(c),this.removeSubscription(es),this.tryComplete()},DelayWhenSubscriber.prototype.notifyError=function(c,l){this._error(c)},DelayWhenSubscriber.prototype.notifyComplete=function(c){var l=this.removeSubscription(c);l&&this.destination.next(l),this.tryComplete()},DelayWhenSubscriber.prototype._next=function(c){var l=this.index++;try{var et=this.delayDurationSelector(c,l);et&&this.tryDelay(et,c)}catch(c){this.destination.error(c)}},DelayWhenSubscriber.prototype._complete=function(){this.completed=!0,this.tryComplete(),this.unsubscribe()},DelayWhenSubscriber.prototype.removeSubscription=function(c){c.unsubscribe();var l=this.delayNotifierSubscriptions.indexOf(c);return -1!==l&&this.delayNotifierSubscriptions.splice(l,1),c.outerValue},DelayWhenSubscriber.prototype.tryDelay=function(c,l){var et=(0,ex.D)(this,c,l);et&&!et.closed&&(this.destination.add(et),this.delayNotifierSubscriptions.push(et))},DelayWhenSubscriber.prototype.tryComplete=function(){this.completed&&0===this.delayNotifierSubscriptions.length&&this.destination.complete()},DelayWhenSubscriber}(ek.L),eX=function(c){function SubscriptionDelayObservable(l,et){var eo=c.call(this)||this;return eo.source=l,eo.subscriptionDelay=et,eo}return eo.ZT(SubscriptionDelayObservable,c),SubscriptionDelayObservable.prototype._subscribe=function(c){this.subscriptionDelay.subscribe(new e0(c,this.source))},SubscriptionDelayObservable}(eQ.y),e0=function(c){function SubscriptionDelaySubscriber(l,et){var eo=c.call(this)||this;return eo.parent=l,eo.source=et,eo.sourceSubscribed=!1,eo}return eo.ZT(SubscriptionDelaySubscriber,c),SubscriptionDelaySubscriber.prototype._next=function(c){this.subscribeToSource()},SubscriptionDelaySubscriber.prototype._error=function(c){this.unsubscribe(),this.parent.error(c)},SubscriptionDelaySubscriber.prototype._complete=function(){this.unsubscribe(),this.subscribeToSource()},SubscriptionDelaySubscriber.prototype.subscribeToSource=function(){this.sourceSubscribed||(this.sourceSubscribed=!0,this.unsubscribe(),this.source.subscribe(this.parent))},SubscriptionDelaySubscriber}(eg.L);function dematerialize(){return function(c){return c.lift(new e1)}}var e1=function(){function DeMaterializeOperator(){}return DeMaterializeOperator.prototype.call=function(c,l){return l.subscribe(new e2(c))},DeMaterializeOperator}(),e2=function(c){function DeMaterializeSubscriber(l){return c.call(this,l)||this}return eo.ZT(DeMaterializeSubscriber,c),DeMaterializeSubscriber.prototype._next=function(c){c.observe(this.destination)},DeMaterializeSubscriber}(eg.L);function distinct(c,l){return function(et){return et.lift(new e3(c,l))}}var e3=function(){function DistinctOperator(c,l){this.keySelector=c,this.flushes=l}return DistinctOperator.prototype.call=function(c,l){return l.subscribe(new e5(c,this.keySelector,this.flushes))},DistinctOperator}(),e5=function(c){function DistinctSubscriber(l,et,eo){var ec=c.call(this,l)||this;return ec.keySelector=et,ec.values=new Set,eo&&ec.add((0,es.ft)(eo,new es.IY(ec))),ec}return eo.ZT(DistinctSubscriber,c),DistinctSubscriber.prototype.notifyNext=function(){this.values.clear()},DistinctSubscriber.prototype.notifyError=function(c){this._error(c)},DistinctSubscriber.prototype._next=function(c){this.keySelector?this._useKeySelector(c):this._finalizeNext(c,c)},DistinctSubscriber.prototype._useKeySelector=function(c){var l,et=this.destination;try{l=this.keySelector(c)}catch(c){et.error(c);return}this._finalizeNext(l,c)},DistinctSubscriber.prototype._finalizeNext=function(c,l){var et=this.values;et.has(c)||(et.add(c),this.destination.next(l))},DistinctSubscriber}(es.Ds);function distinctUntilChanged(c,l){return function(et){return et.lift(new e6(c,l))}}var e6=function(){function DistinctUntilChangedOperator(c,l){this.compare=c,this.keySelector=l}return DistinctUntilChangedOperator.prototype.call=function(c,l){return l.subscribe(new e4(c,this.compare,this.keySelector))},DistinctUntilChangedOperator}(),e4=function(c){function DistinctUntilChangedSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.keySelector=eo,es.hasKey=!1,"function"==typeof et&&(es.compare=et),es}return eo.ZT(DistinctUntilChangedSubscriber,c),DistinctUntilChangedSubscriber.prototype.compare=function(c,l){return c===l},DistinctUntilChangedSubscriber.prototype._next=function(c){try{var l,et=this.keySelector;l=et?et(c):c}catch(c){return this.destination.error(c)}var eo=!1;if(this.hasKey)try{eo=(0,this.compare)(this.key,l)}catch(c){return this.destination.error(c)}else this.hasKey=!0;eo||(this.key=l,this.destination.next(c))},DistinctUntilChangedSubscriber}(eg.L);function distinctUntilKeyChanged(c,l){return distinctUntilChanged(function(et,eo){return l?l(et[c],eo[c]):et[c]===eo[c]})}var e8=et(73197),e9=et(25163),e7=et(40531);function throwIfEmpty(c){return void 0===c&&(c=defaultErrorFactory),function(l){return l.lift(new tn(c))}}var tn=function(){function ThrowIfEmptyOperator(c){this.errorFactory=c}return ThrowIfEmptyOperator.prototype.call=function(c,l){return l.subscribe(new to(c,this.errorFactory))},ThrowIfEmptyOperator}(),to=function(c){function ThrowIfEmptySubscriber(l,et){var eo=c.call(this,l)||this;return eo.errorFactory=et,eo.hasValue=!1,eo}return eo.ZT(ThrowIfEmptySubscriber,c),ThrowIfEmptySubscriber.prototype._next=function(c){this.hasValue=!0,this.destination.next(c)},ThrowIfEmptySubscriber.prototype._complete=function(){if(this.hasValue)return this.destination.complete();var c=void 0;try{c=this.errorFactory()}catch(l){c=l}this.destination.error(c)},ThrowIfEmptySubscriber}(eg.L);function defaultErrorFactory(){return new e7.K}var ts=et(42229);function take(c){return function(l){return 0===c?(0,ts.c)():l.lift(new ta(c))}}var ta=function(){function TakeOperator(c){if(this.total=c,this.total<0)throw new e8.W}return TakeOperator.prototype.call=function(c,l){return l.subscribe(new tc(c,this.total))},TakeOperator}(),tc=function(c){function TakeSubscriber(l,et){var eo=c.call(this,l)||this;return eo.total=et,eo.count=0,eo}return eo.ZT(TakeSubscriber,c),TakeSubscriber.prototype._next=function(c){var l=this.total,et=++this.count;et<=l&&(this.destination.next(c),et===l&&(this.destination.complete(),this.unsubscribe()))},TakeSubscriber}(eg.L);function elementAt(c,l){if(c<0)throw new e8.W;var et=arguments.length>=2;return function(eo){return eo.pipe((0,e9.h)(function(l,et){return et===c}),take(1),et?defaultIfEmpty(l):throwIfEmpty(function(){return new e8.W}))}}var tl=et(46304);function endWith(){for(var c=[],l=0;l(l||0)?Number.POSITIVE_INFINITY:l,function(eo){return eo.lift(new ty(c,l,et))}}var ty=function(){function ExpandOperator(c,l,et){this.project=c,this.concurrent=l,this.scheduler=et}return ExpandOperator.prototype.call=function(c,l){return l.subscribe(new t_(c,this.project,this.concurrent,this.scheduler))},ExpandOperator}(),t_=function(c){function ExpandSubscriber(l,et,eo,es){var ec=c.call(this,l)||this;return ec.project=et,ec.concurrent=eo,ec.scheduler=es,ec.index=0,ec.active=0,ec.hasCompleted=!1,eo0&&this._next(c.shift()),this.hasCompleted&&0===this.active&&this.destination.complete()},ExpandSubscriber}(es.Ds);function finalize(c){return function(l){return l.lift(new tw(c))}}var tw=function(){function FinallyOperator(c){this.callback=c}return FinallyOperator.prototype.call=function(c,l){return l.subscribe(new tE(c,this.callback))},FinallyOperator}(),tE=function(c){function FinallySubscriber(l,et){var eo=c.call(this,l)||this;return eo.add(new eS.w(et)),eo}return eo.ZT(FinallySubscriber,c),FinallySubscriber}(eg.L);function find(c,l){if("function"!=typeof c)throw TypeError("predicate is not a function");return function(et){return et.lift(new tS(c,et,!1,l))}}var tS=function(){function FindValueOperator(c,l,et,eo){this.predicate=c,this.source=l,this.yieldIndex=et,this.thisArg=eo}return FindValueOperator.prototype.call=function(c,l){return l.subscribe(new tx(c,this.predicate,this.source,this.yieldIndex,this.thisArg))},FindValueOperator}(),tx=function(c){function FindValueSubscriber(l,et,eo,es,ec){var el=c.call(this,l)||this;return el.predicate=et,el.source=eo,el.yieldIndex=es,el.thisArg=ec,el.index=0,el}return eo.ZT(FindValueSubscriber,c),FindValueSubscriber.prototype.notifyComplete=function(c){var l=this.destination;l.next(c),l.complete(),this.unsubscribe()},FindValueSubscriber.prototype._next=function(c){var l=this.predicate,et=this.thisArg,eo=this.index++;try{l.call(et||this,c,eo,this.source)&&this.notifyComplete(this.yieldIndex?eo:c)}catch(c){this.destination.error(c)}},FindValueSubscriber.prototype._complete=function(){this.notifyComplete(this.yieldIndex?-1:void 0)},FindValueSubscriber}(eg.L);function findIndex(c,l){return function(et){return et.lift(new tS(c,et,!0,l))}}var tk=et(18016);function first(c,l){var et=arguments.length>=2;return function(eo){return eo.pipe(c?(0,e9.h)(function(l,et){return c(l,et,eo)}):tk.y,take(1),et?defaultIfEmpty(l):throwIfEmpty(function(){return new e7.K}))}}var tC=et(9439);function ignoreElements(){return function(c){return c.lift(new tA)}}var tA=function(){function IgnoreElementsOperator(){}return IgnoreElementsOperator.prototype.call=function(c,l){return l.subscribe(new tI(c))},IgnoreElementsOperator}(),tI=function(c){function IgnoreElementsSubscriber(){return null!==c&&c.apply(this,arguments)||this}return eo.ZT(IgnoreElementsSubscriber,c),IgnoreElementsSubscriber.prototype._next=function(c){},IgnoreElementsSubscriber}(eg.L);function isEmpty(){return function(c){return c.lift(new tP)}}var tP=function(){function IsEmptyOperator(){}return IsEmptyOperator.prototype.call=function(c,l){return l.subscribe(new tR(c))},IsEmptyOperator}(),tR=function(c){function IsEmptySubscriber(l){return c.call(this,l)||this}return eo.ZT(IsEmptySubscriber,c),IsEmptySubscriber.prototype.notifyComplete=function(c){var l=this.destination;l.next(c),l.complete()},IsEmptySubscriber.prototype._next=function(c){this.notifyComplete(!1)},IsEmptySubscriber.prototype._complete=function(){this.notifyComplete(!0)},IsEmptySubscriber}(eg.L);function takeLast(c){return function(l){return 0===c?(0,ts.c)():l.lift(new tO(c))}}var tO=function(){function TakeLastOperator(c){if(this.total=c,this.total<0)throw new e8.W}return TakeLastOperator.prototype.call=function(c,l){return l.subscribe(new tT(c,this.total))},TakeLastOperator}(),tT=function(c){function TakeLastSubscriber(l,et){var eo=c.call(this,l)||this;return eo.total=et,eo.ring=[],eo.count=0,eo}return eo.ZT(TakeLastSubscriber,c),TakeLastSubscriber.prototype._next=function(c){var l=this.ring,et=this.total,eo=this.count++;l.length0)for(var et=this.count>=this.total?this.total:this.count,eo=this.ring,es=0;es=2;return function(eo){return eo.pipe(c?(0,e9.h)(function(l,et){return c(l,et,eo)}):tk.y,takeLast(1),et?defaultIfEmpty(l):throwIfEmpty(function(){return new e7.K}))}}function mapTo(c){return function(l){return l.lift(new tN(c))}}var tN=function(){function MapToOperator(c){this.value=c}return MapToOperator.prototype.call=function(c,l){return l.subscribe(new tM(c,this.value))},MapToOperator}(),tM=function(c){function MapToSubscriber(l,et){var eo=c.call(this,l)||this;return eo.value=et,eo}return eo.ZT(MapToSubscriber,c),MapToSubscriber.prototype._next=function(c){this.destination.next(this.value)},MapToSubscriber}(eg.L);function materialize(){return function(c){return c.lift(new t$)}}var t$=function(){function MaterializeOperator(){}return MaterializeOperator.prototype.call=function(c,l){return l.subscribe(new tB(c))},MaterializeOperator}(),tB=function(c){function MaterializeSubscriber(l){return c.call(this,l)||this}return eo.ZT(MaterializeSubscriber,c),MaterializeSubscriber.prototype._next=function(c){this.destination.next(eG.P.createNext(c))},MaterializeSubscriber.prototype._error=function(c){var l=this.destination;l.next(eG.P.createError(c)),l.complete()},MaterializeSubscriber.prototype._complete=function(){var c=this.destination;c.next(eG.P.createComplete()),c.complete()},MaterializeSubscriber}(eg.L);function scan(c,l){var et=!1;return arguments.length>=2&&(et=!0),function(eo){return eo.lift(new tD(c,l,et))}}var tD=function(){function ScanOperator(c,l,et){void 0===et&&(et=!1),this.accumulator=c,this.seed=l,this.hasSeed=et}return ScanOperator.prototype.call=function(c,l){return l.subscribe(new tj(c,this.accumulator,this.seed,this.hasSeed))},ScanOperator}(),tj=function(c){function ScanSubscriber(l,et,eo,es){var ec=c.call(this,l)||this;return ec.accumulator=et,ec._seed=eo,ec.hasSeed=es,ec.index=0,ec}return eo.ZT(ScanSubscriber,c),Object.defineProperty(ScanSubscriber.prototype,"seed",{get:function(){return this._seed},set:function(c){this.hasSeed=!0,this._seed=c},enumerable:!0,configurable:!0}),ScanSubscriber.prototype._next=function(c){if(this.hasSeed)return this._tryNext(c);this.seed=c,this.destination.next(c)},ScanSubscriber.prototype._tryNext=function(c){var l,et=this.index++;try{l=this.accumulator(this.seed,c,et)}catch(c){this.destination.error(c)}this.seed=l,this.destination.next(l)},ScanSubscriber}(eg.L),tL=et(52996);function reduce(c,l){return arguments.length>=2?function(et){return(0,tL.z)(scan(c,l),takeLast(1),defaultIfEmpty(l))(et)}:function(l){return(0,tL.z)(scan(function(l,et,eo){return c(l,et,eo+1)}),takeLast(1))(l)}}function max(c){return reduce("function"==typeof c?function(l,et){return c(l,et)>0?l:et}:function(c,l){return c>l?c:l})}var tF=et(51095);function merge_merge(){for(var c=[],l=0;l0?this._next(c.shift()):0===this.active&&this.hasCompleted&&(!1===this.hasValue&&this.destination.next(this.acc),this.destination.complete())},MergeScanSubscriber}(es.Ds);function min(c){return reduce("function"==typeof c?function(l,et){return 0>c(l,et)?l:et}:function(c,l){return c-1&&(this.count=et-1),l.subscribe(this._unsubscribeAndRecycle())}},RepeatSubscriber}(eg.L);function repeatWhen(c){return function(l){return l.lift(new t6(c))}}var t6=function(){function RepeatWhenOperator(c){this.notifier=c}return RepeatWhenOperator.prototype.call=function(c,l){return l.subscribe(new t4(c,this.notifier,l))},RepeatWhenOperator}(),t4=function(c){function RepeatWhenSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.notifier=et,es.source=eo,es.sourceIsBeingSubscribedTo=!0,es}return eo.ZT(RepeatWhenSubscriber,c),RepeatWhenSubscriber.prototype.notifyNext=function(){this.sourceIsBeingSubscribedTo=!0,this.source.subscribe(this)},RepeatWhenSubscriber.prototype.notifyComplete=function(){if(!1===this.sourceIsBeingSubscribedTo)return c.prototype.complete.call(this)},RepeatWhenSubscriber.prototype.complete=function(){if(this.sourceIsBeingSubscribedTo=!1,!this.isStopped){if(this.retries||this.subscribeToRetries(),!this.retriesSubscription||this.retriesSubscription.closed)return c.prototype.complete.call(this);this._unsubscribeAndRecycle(),this.notifications.next(void 0)}},RepeatWhenSubscriber.prototype._unsubscribe=function(){var c=this.notifications,l=this.retriesSubscription;c&&(c.unsubscribe(),this.notifications=void 0),l&&(l.unsubscribe(),this.retriesSubscription=void 0),this.retries=void 0},RepeatWhenSubscriber.prototype._unsubscribeAndRecycle=function(){var l=this._unsubscribe;return this._unsubscribe=null,c.prototype._unsubscribeAndRecycle.call(this),this._unsubscribe=l,this},RepeatWhenSubscriber.prototype.subscribeToRetries=function(){this.notifications=new tZ.xQ;try{var l;l=(0,this.notifier)(this.notifications)}catch(l){return c.prototype.complete.call(this)}this.retries=l,this.retriesSubscription=(0,es.ft)(l,new es.IY(this))},RepeatWhenSubscriber}(es.Ds);function retry(c){return void 0===c&&(c=-1),function(l){return l.lift(new t8(c,l))}}var t8=function(){function RetryOperator(c,l){this.count=c,this.source=l}return RetryOperator.prototype.call=function(c,l){return l.subscribe(new t9(c,this.count,this.source))},RetryOperator}(),t9=function(c){function RetrySubscriber(l,et,eo){var es=c.call(this,l)||this;return es.count=et,es.source=eo,es}return eo.ZT(RetrySubscriber,c),RetrySubscriber.prototype.error=function(l){if(!this.isStopped){var et=this.source,eo=this.count;if(0===eo)return c.prototype.error.call(this,l);eo>-1&&(this.count=eo-1),et.subscribe(this._unsubscribeAndRecycle())}},RetrySubscriber}(eg.L);function retryWhen(c){return function(l){return l.lift(new t7(c,l))}}var t7=function(){function RetryWhenOperator(c,l){this.notifier=c,this.source=l}return RetryWhenOperator.prototype.call=function(c,l){return l.subscribe(new re(c,this.notifier,this.source))},RetryWhenOperator}(),re=function(c){function RetryWhenSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.notifier=et,es.source=eo,es}return eo.ZT(RetryWhenSubscriber,c),RetryWhenSubscriber.prototype.error=function(l){if(!this.isStopped){var et=this.errors,eo=this.retries,ec=this.retriesSubscription;if(eo)this.errors=void 0,this.retriesSubscription=void 0;else{et=new tZ.xQ;try{eo=(0,this.notifier)(et)}catch(l){return c.prototype.error.call(this,l)}ec=(0,es.ft)(eo,new es.IY(this))}this._unsubscribeAndRecycle(),this.errors=et,this.retries=eo,this.retriesSubscription=ec,et.next(l)}},RetryWhenSubscriber.prototype._unsubscribe=function(){var c=this.errors,l=this.retriesSubscription;c&&(c.unsubscribe(),this.errors=void 0),l&&(l.unsubscribe(),this.retriesSubscription=void 0),this.retries=void 0},RetryWhenSubscriber.prototype.notifyNext=function(){var c=this._unsubscribe;this._unsubscribe=null,this._unsubscribeAndRecycle(),this._unsubscribe=c,this.source.subscribe(this)},RetryWhenSubscriber}(es.Ds),rt=et(16262);function sample(c){return function(l){return l.lift(new ro(c))}}var ro=function(){function SampleOperator(c){this.notifier=c}return SampleOperator.prototype.call=function(c,l){var et=new rs(c),eo=l.subscribe(et);return eo.add((0,es.ft)(this.notifier,new es.IY(et))),eo},SampleOperator}(),rs=function(c){function SampleSubscriber(){var l=null!==c&&c.apply(this,arguments)||this;return l.hasValue=!1,l}return eo.ZT(SampleSubscriber,c),SampleSubscriber.prototype._next=function(c){this.value=c,this.hasValue=!0},SampleSubscriber.prototype.notifyNext=function(){this.emitValue()},SampleSubscriber.prototype.notifyComplete=function(){this.emitValue()},SampleSubscriber.prototype.emitValue=function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.value))},SampleSubscriber}(es.Ds);function sampleTime(c,l){return void 0===l&&(l=ed.P),function(et){return et.lift(new ra(c,l))}}var ra=function(){function SampleTimeOperator(c,l){this.period=c,this.scheduler=l}return SampleTimeOperator.prototype.call=function(c,l){return l.subscribe(new rc(c,this.period,this.scheduler))},SampleTimeOperator}(),rc=function(c){function SampleTimeSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.period=et,es.scheduler=eo,es.hasValue=!1,es.add(eo.schedule(dispatchNotification,et,{subscriber:es,period:et})),es}return eo.ZT(SampleTimeSubscriber,c),SampleTimeSubscriber.prototype._next=function(c){this.lastValue=c,this.hasValue=!0},SampleTimeSubscriber.prototype.notifyNext=function(){this.hasValue&&(this.hasValue=!1,this.destination.next(this.lastValue))},SampleTimeSubscriber}(eg.L);function dispatchNotification(c){var l=c.subscriber,et=c.period;l.notifyNext(),this.schedule(c,et)}function sequenceEqual(c,l){return function(et){return et.lift(new rl(c,l))}}var rl=function(){function SequenceEqualOperator(c,l){this.compareTo=c,this.comparator=l}return SequenceEqualOperator.prototype.call=function(c,l){return l.subscribe(new rd(c,this.compareTo,this.comparator))},SequenceEqualOperator}(),rd=function(c){function SequenceEqualSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.compareTo=et,es.comparator=eo,es._a=[],es._b=[],es._oneComplete=!1,es.destination.add(et.subscribe(new rh(l,es))),es}return eo.ZT(SequenceEqualSubscriber,c),SequenceEqualSubscriber.prototype._next=function(c){this._oneComplete&&0===this._b.length?this.emit(!1):(this._a.push(c),this.checkValues())},SequenceEqualSubscriber.prototype._complete=function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0,this.unsubscribe()},SequenceEqualSubscriber.prototype.checkValues=function(){for(var c=this._a,l=this._b,et=this.comparator;c.length>0&&l.length>0;){var eo=c.shift(),es=l.shift(),ec=!1;try{ec=et?et(eo,es):eo===es}catch(c){this.destination.error(c)}ec||this.emit(!1)}},SequenceEqualSubscriber.prototype.emit=function(c){var l=this.destination;l.next(c),l.complete()},SequenceEqualSubscriber.prototype.nextB=function(c){this._oneComplete&&0===this._a.length?this.emit(!1):(this._b.push(c),this.checkValues())},SequenceEqualSubscriber.prototype.completeB=function(){this._oneComplete?this.emit(0===this._a.length&&0===this._b.length):this._oneComplete=!0},SequenceEqualSubscriber}(eg.L),rh=function(c){function SequenceEqualCompareToSubscriber(l,et){var eo=c.call(this,l)||this;return eo.parent=et,eo}return eo.ZT(SequenceEqualCompareToSubscriber,c),SequenceEqualCompareToSubscriber.prototype._next=function(c){this.parent.nextB(c)},SequenceEqualCompareToSubscriber.prototype._error=function(c){this.parent.error(c),this.unsubscribe()},SequenceEqualCompareToSubscriber.prototype._complete=function(){this.parent.completeB(),this.unsubscribe()},SequenceEqualCompareToSubscriber}(eg.L);function shareSubjectFactory(){return new tZ.xQ}function share(){return function(c){return(0,rt.x)()(multicast(shareSubjectFactory)(c))}}function shareReplay(c,l,et){var eo;return eo=c&&"object"==typeof c?c:{bufferSize:c,windowTime:l,refCount:!1,scheduler:et},function(c){var l,et,es,ec,el,ed,eh,ef,ep,eg,em;return c.lift((ec=void 0===(es=eo.bufferSize)?Number.POSITIVE_INFINITY:es,ed=void 0===(el=eo.windowTime)?Number.POSITIVE_INFINITY:el,eh=eo.refCount,ef=eo.scheduler,ep=0,eg=!1,em=!1,function(c){var eo;ep++,!l||eg?(eg=!1,eo=(l=new t1.t(ec,ed,ef)).subscribe(this),et=c.subscribe({next:function(c){l.next(c)},error:function(c){eg=!0,l.error(c)},complete:function(){em=!0,et=void 0,l.complete()}}),em&&(et=void 0)):eo=l.subscribe(this),this.add(function(){ep--,eo.unsubscribe(),eo=void 0,et&&!em&&eh&&0===ep&&(et.unsubscribe(),et=void 0,l=void 0)})}))}}function single(c){return function(l){return l.lift(new rp(c,l))}}var rp=function(){function SingleOperator(c,l){this.predicate=c,this.source=l}return SingleOperator.prototype.call=function(c,l){return l.subscribe(new rg(c,this.predicate,this.source))},SingleOperator}(),rg=function(c){function SingleSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.predicate=et,es.source=eo,es.seenValue=!1,es.index=0,es}return eo.ZT(SingleSubscriber,c),SingleSubscriber.prototype.applySingleValue=function(c){this.seenValue?this.destination.error("Sequence contains more than one element"):(this.seenValue=!0,this.singleValue=c)},SingleSubscriber.prototype._next=function(c){var l=this.index++;this.predicate?this.tryNext(c,l):this.applySingleValue(c)},SingleSubscriber.prototype.tryNext=function(c,l){try{this.predicate(c,l,this.source)&&this.applySingleValue(c)}catch(c){this.destination.error(c)}},SingleSubscriber.prototype._complete=function(){var c=this.destination;this.index>0?(c.next(this.seenValue?this.singleValue:void 0),c.complete()):c.error(new e7.K)},SingleSubscriber}(eg.L);function skip(c){return function(l){return l.lift(new rm(c))}}var rm=function(){function SkipOperator(c){this.total=c}return SkipOperator.prototype.call=function(c,l){return l.subscribe(new rb(c,this.total))},SkipOperator}(),rb=function(c){function SkipSubscriber(l,et){var eo=c.call(this,l)||this;return eo.total=et,eo.count=0,eo}return eo.ZT(SkipSubscriber,c),SkipSubscriber.prototype._next=function(c){++this.count>this.total&&this.destination.next(c)},SkipSubscriber}(eg.L);function skipLast(c){return function(l){return l.lift(new ry(c))}}var ry=function(){function SkipLastOperator(c){if(this._skipCount=c,this._skipCount<0)throw new e8.W}return SkipLastOperator.prototype.call=function(c,l){return 0===this._skipCount?l.subscribe(new eg.L(c)):l.subscribe(new r_(c,this._skipCount))},SkipLastOperator}(),r_=function(c){function SkipLastSubscriber(l,et){var eo=c.call(this,l)||this;return eo._skipCount=et,eo._count=0,eo._ring=Array(et),eo}return eo.ZT(SkipLastSubscriber,c),SkipLastSubscriber.prototype._next=function(c){var l=this._skipCount,et=this._count++;if(et0?this.startWindowEvery:this.windowSize,et=this.destination,eo=this.windowSize,es=this.windows,ec=es.length,el=0;el=0&&ed%l==0&&!this.closed&&es.shift().complete(),++this.count%l==0&&!this.closed){var eh=new tZ.xQ;es.push(eh),et.next(eh)}},WindowCountSubscriber.prototype._error=function(c){var l=this.windows;if(l)for(;l.length>0&&!this.closed;)l.shift().error(c);this.destination.error(c)},WindowCountSubscriber.prototype._complete=function(){var c=this.windows;if(c)for(;c.length>0&&!this.closed;)c.shift().complete();this.destination.complete()},WindowCountSubscriber.prototype._unsubscribe=function(){this.count=0,this.windows=null},WindowCountSubscriber}(eg.L);function windowTime(c){var l=ed.P,et=null,eo=Number.POSITIVE_INFINITY;return(0,e_.K)(arguments[3])&&(l=arguments[3]),(0,e_.K)(arguments[2])?l=arguments[2]:(0,rC.k)(arguments[2])&&(eo=Number(arguments[2])),(0,e_.K)(arguments[1])?l=arguments[1]:(0,rC.k)(arguments[1])&&(et=Number(arguments[1])),function(es){return es.lift(new rX(c,et,eo,l))}}var rX=function(){function WindowTimeOperator(c,l,et,eo){this.windowTimeSpan=c,this.windowCreationInterval=l,this.maxWindowSize=et,this.scheduler=eo}return WindowTimeOperator.prototype.call=function(c,l){return l.subscribe(new r1(c,this.windowTimeSpan,this.windowCreationInterval,this.maxWindowSize,this.scheduler))},WindowTimeOperator}(),r0=function(c){function CountedSubject(){var l=null!==c&&c.apply(this,arguments)||this;return l._numberOfNextedValues=0,l}return eo.ZT(CountedSubject,c),CountedSubject.prototype.next=function(l){this._numberOfNextedValues++,c.prototype.next.call(this,l)},Object.defineProperty(CountedSubject.prototype,"numberOfNextedValues",{get:function(){return this._numberOfNextedValues},enumerable:!0,configurable:!0}),CountedSubject}(tZ.xQ),r1=function(c){function WindowTimeSubscriber(l,et,eo,es,ec){var el=c.call(this,l)||this;el.destination=l,el.windowTimeSpan=et,el.windowCreationInterval=eo,el.maxWindowSize=es,el.scheduler=ec,el.windows=[];var ed=el.openWindow();return null!==eo&&eo>=0?(el.add(ec.schedule(dispatchWindowClose,et,{subscriber:el,window:ed,context:null})),el.add(ec.schedule(dispatchWindowCreation,eo,{windowTimeSpan:et,windowCreationInterval:eo,subscriber:el,scheduler:ec}))):el.add(ec.schedule(dispatchWindowTimeSpanOnly,et,{subscriber:el,window:ed,windowTimeSpan:et})),el}return eo.ZT(WindowTimeSubscriber,c),WindowTimeSubscriber.prototype._next=function(c){for(var l=this.windows,et=l.length,eo=0;eo=this.maxWindowSize&&this.closeWindow(es))}},WindowTimeSubscriber.prototype._error=function(c){for(var l=this.windows;l.length>0;)l.shift().error(c);this.destination.error(c)},WindowTimeSubscriber.prototype._complete=function(){for(var c=this.windows;c.length>0;){var l=c.shift();l.closed||l.complete()}this.destination.complete()},WindowTimeSubscriber.prototype.openWindow=function(){var c=new r0;return this.windows.push(c),this.destination.next(c),c},WindowTimeSubscriber.prototype.closeWindow=function(c){c.complete();var l=this.windows;l.splice(l.indexOf(c),1)},WindowTimeSubscriber}(eg.L);function dispatchWindowTimeSpanOnly(c){var l=c.subscriber,et=c.windowTimeSpan,eo=c.window;eo&&l.closeWindow(eo),c.window=l.openWindow(),this.schedule(c,et)}function dispatchWindowCreation(c){var l=c.windowTimeSpan,et=c.subscriber,eo=c.scheduler,es=c.windowCreationInterval,ec=et.openWindow(),el={action:this,subscription:null};el.subscription=eo.schedule(dispatchWindowClose,l,{subscriber:et,window:ec,context:el}),this.add(el.subscription),this.schedule(c,es)}function dispatchWindowClose(c){var l=c.subscriber,et=c.window,eo=c.context;eo&&eo.action&&eo.subscription&&eo.action.remove(eo.subscription),l.closeWindow(et)}function windowToggle(c,l){return function(et){return et.lift(new r2(c,l))}}var r2=function(){function WindowToggleOperator(c,l){this.openings=c,this.closingSelector=l}return WindowToggleOperator.prototype.call=function(c,l){return l.subscribe(new r3(c,this.openings,this.closingSelector))},WindowToggleOperator}(),r3=function(c){function WindowToggleSubscriber(l,et,eo){var es=c.call(this,l)||this;return es.openings=et,es.closingSelector=eo,es.contexts=[],es.add(es.openSubscription=(0,ex.D)(es,et,et)),es}return eo.ZT(WindowToggleSubscriber,c),WindowToggleSubscriber.prototype._next=function(c){var l=this.contexts;if(l)for(var et=l.length,eo=0;eo0){var es=eo.indexOf(et);-1!==es&&eo.splice(es,1)}},WithLatestFromSubscriber.prototype.notifyComplete=function(){},WithLatestFromSubscriber.prototype._next=function(c){if(0===this.toRespond.length){var l=[c].concat(this.values);this.project?this._tryProject(l):this.destination.next(l)}},WithLatestFromSubscriber.prototype._tryProject=function(c){var l;try{l=this.project.apply(this,c)}catch(c){this.destination.error(c);return}this.destination.next(l)},WithLatestFromSubscriber}(ek.L),r9=et(84095);function zip_zip(){for(var c=[],l=0;l */var eo=et(67133),es=eo.Buffer;function copyProps(c,l){for(var et in c)l[et]=c[et]}function SafeBuffer(c,l,et){return es(c,l,et)}es.from&&es.alloc&&es.allocUnsafe&&es.allocUnsafeSlow?c.exports=eo:(copyProps(eo,l),l.Buffer=SafeBuffer),SafeBuffer.prototype=Object.create(es.prototype),copyProps(es,SafeBuffer),SafeBuffer.from=function(c,l,et){if("number"==typeof c)throw TypeError("Argument must not be a number");return es(c,l,et)},SafeBuffer.alloc=function(c,l,et){if("number"!=typeof c)throw TypeError("Argument must be a number");var eo=es(c);return void 0!==l?"string"==typeof et?eo.fill(l,et):eo.fill(l):eo.fill(0),eo},SafeBuffer.allocUnsafe=function(c){if("number"!=typeof c)throw TypeError("Argument must be a number");return es(c)},SafeBuffer.allocUnsafeSlow=function(c){if("number"!=typeof c)throw TypeError("Argument must be a number");return eo.SlowBuffer(c)}},86050:function(c,l){"use strict";Object.defineProperty(l,"__esModule",{value:!0}),l.safeJsonParse=function(c){if("string"!=typeof c)throw Error(`Cannot safe json parse value of type ${typeof c}`);try{return JSON.parse(c)}catch(l){return c}},l.safeJsonStringify=function(c){return"string"==typeof c?c:JSON.stringify(c,(c,l)=>void 0===l?null:l)}},95904:function(c,l,et){var eo=et(92336).Buffer;function Hash(c,l){this._block=eo.alloc(c),this._finalSize=l,this._blockSize=c,this._len=0}Hash.prototype.update=function(c,l){"string"==typeof c&&(l=l||"utf8",c=eo.from(c,l));for(var et=this._block,es=this._blockSize,ec=c.length,el=this._len,ed=0;ed=this._finalSize&&(this._update(this._block),this._block.fill(0));var et=8*this._len;if(et<=4294967295)this._block.writeUInt32BE(et,this._blockSize-4);else{var eo=(4294967295&et)>>>0,es=(et-eo)/4294967296;this._block.writeUInt32BE(es,this._blockSize-8),this._block.writeUInt32BE(eo,this._blockSize-4)}this._update(this._block);var ec=this._hash();return c?ec.toString(c):ec},Hash.prototype._update=function(){throw Error("_update must be implemented by subclass")},c.exports=Hash},71114:function(c,l,et){var eo=c.exports=function(c){var l=eo[c=c.toLowerCase()];if(!l)throw Error(c+" is not supported (we accept pull requests)");return new l};eo.sha=et(83358),eo.sha1=et(43652),eo.sha224=et(43212),eo.sha256=et(78194),eo.sha384=et(33681),eo.sha512=et(34270)},83358:function(c,l,et){var eo=et(75335),es=et(95904),ec=et(92336).Buffer,el=[1518500249,1859775393,-1894007588,-899497514],ed=Array(80);function Sha(){this.init(),this._w=ed,es.call(this,64,56)}eo(Sha,es),Sha.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},Sha.prototype._update=function(c){for(var l=this._w,et=0|this._a,eo=0|this._b,es=0|this._c,ec=0|this._d,ed=0|this._e,eh=0;eh<16;++eh)l[eh]=c.readInt32BE(4*eh);for(;eh<80;++eh)l[eh]=l[eh-3]^l[eh-8]^l[eh-14]^l[eh-16];for(var ef=0;ef<80;++ef){var ep,eg,em,eb,ey,e_=~~(ef/20),ew=((ep=et)<<5|ep>>>27)+(eg=eo,em=es,eb=ec,0===e_?eg&em|~eg&eb:2===e_?eg&em|eg&eb|em&eb:eg^em^eb)+ed+l[ef]+el[e_]|0;ed=ec,ec=es,es=(ey=eo)<<30|ey>>>2,eo=et,et=ew}this._a=et+this._a|0,this._b=eo+this._b|0,this._c=es+this._c|0,this._d=ec+this._d|0,this._e=ed+this._e|0},Sha.prototype._hash=function(){var c=ec.allocUnsafe(20);return c.writeInt32BE(0|this._a,0),c.writeInt32BE(0|this._b,4),c.writeInt32BE(0|this._c,8),c.writeInt32BE(0|this._d,12),c.writeInt32BE(0|this._e,16),c},c.exports=Sha},43652:function(c,l,et){var eo=et(75335),es=et(95904),ec=et(92336).Buffer,el=[1518500249,1859775393,-1894007588,-899497514],ed=Array(80);function Sha1(){this.init(),this._w=ed,es.call(this,64,56)}eo(Sha1,es),Sha1.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},Sha1.prototype._update=function(c){for(var l=this._w,et=0|this._a,eo=0|this._b,es=0|this._c,ec=0|this._d,ed=0|this._e,eh=0;eh<16;++eh)l[eh]=c.readInt32BE(4*eh);for(;eh<80;++eh)l[eh]=(ep=l[eh-3]^l[eh-8]^l[eh-14]^l[eh-16])<<1|ep>>>31;for(var ef=0;ef<80;++ef){var ep,eg,em,eb,ey,e_,ew=~~(ef/20),eE=((eg=et)<<5|eg>>>27)+(em=eo,eb=es,ey=ec,0===ew?em&eb|~em&ey:2===ew?em&eb|em&ey|eb&ey:em^eb^ey)+ed+l[ef]+el[ew]|0;ed=ec,ec=es,es=(e_=eo)<<30|e_>>>2,eo=et,et=eE}this._a=et+this._a|0,this._b=eo+this._b|0,this._c=es+this._c|0,this._d=ec+this._d|0,this._e=ed+this._e|0},Sha1.prototype._hash=function(){var c=ec.allocUnsafe(20);return c.writeInt32BE(0|this._a,0),c.writeInt32BE(0|this._b,4),c.writeInt32BE(0|this._c,8),c.writeInt32BE(0|this._d,12),c.writeInt32BE(0|this._e,16),c},c.exports=Sha1},43212:function(c,l,et){var eo=et(75335),es=et(78194),ec=et(95904),el=et(92336).Buffer,ed=Array(64);function Sha224(){this.init(),this._w=ed,ec.call(this,64,56)}eo(Sha224,es),Sha224.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},Sha224.prototype._hash=function(){var c=el.allocUnsafe(28);return c.writeInt32BE(this._a,0),c.writeInt32BE(this._b,4),c.writeInt32BE(this._c,8),c.writeInt32BE(this._d,12),c.writeInt32BE(this._e,16),c.writeInt32BE(this._f,20),c.writeInt32BE(this._g,24),c},c.exports=Sha224},78194:function(c,l,et){var eo=et(75335),es=et(95904),ec=et(92336).Buffer,el=[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],ed=Array(64);function Sha256(){this.init(),this._w=ed,es.call(this,64,56)}eo(Sha256,es),Sha256.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},Sha256.prototype._update=function(c){for(var l=this._w,et=0|this._a,eo=0|this._b,es=0|this._c,ec=0|this._d,ed=0|this._e,eh=0|this._f,ef=0|this._g,ep=0|this._h,eg=0;eg<16;++eg)l[eg]=c.readInt32BE(4*eg);for(;eg<64;++eg)l[eg]=(((eb=l[eg-2])>>>17|eb<<15)^(eb>>>19|eb<<13)^eb>>>10)+l[eg-7]+(((ey=l[eg-15])>>>7|ey<<25)^(ey>>>18|ey<<14)^ey>>>3)+l[eg-16]|0;for(var em=0;em<64;++em){var eb,ey,e_,ew,eE,eS,ex,ek,eC,eA=ep+(((e_=ed)>>>6|e_<<26)^(e_>>>11|e_<<21)^(e_>>>25|e_<<7))+(ew=ed,eE=eh,(eS=ef)^ew&(eE^eS))+el[em]+l[em]|0,eI=(((ex=et)>>>2|ex<<30)^(ex>>>13|ex<<19)^(ex>>>22|ex<<10))+((ek=et)&(eC=eo)|es&(ek|eC))|0;ep=ef,ef=eh,eh=ed,ed=ec+eA|0,ec=es,es=eo,eo=et,et=eA+eI|0}this._a=et+this._a|0,this._b=eo+this._b|0,this._c=es+this._c|0,this._d=ec+this._d|0,this._e=ed+this._e|0,this._f=eh+this._f|0,this._g=ef+this._g|0,this._h=ep+this._h|0},Sha256.prototype._hash=function(){var c=ec.allocUnsafe(32);return c.writeInt32BE(this._a,0),c.writeInt32BE(this._b,4),c.writeInt32BE(this._c,8),c.writeInt32BE(this._d,12),c.writeInt32BE(this._e,16),c.writeInt32BE(this._f,20),c.writeInt32BE(this._g,24),c.writeInt32BE(this._h,28),c},c.exports=Sha256},33681:function(c,l,et){var eo=et(75335),es=et(34270),ec=et(95904),el=et(92336).Buffer,ed=Array(160);function Sha384(){this.init(),this._w=ed,ec.call(this,128,112)}eo(Sha384,es),Sha384.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},Sha384.prototype._hash=function(){var c=el.allocUnsafe(48);function writeInt64BE(l,et,eo){c.writeInt32BE(l,eo),c.writeInt32BE(et,eo+4)}return writeInt64BE(this._ah,this._al,0),writeInt64BE(this._bh,this._bl,8),writeInt64BE(this._ch,this._cl,16),writeInt64BE(this._dh,this._dl,24),writeInt64BE(this._eh,this._el,32),writeInt64BE(this._fh,this._fl,40),c},c.exports=Sha384},34270:function(c,l,et){var eo=et(75335),es=et(95904),ec=et(92336).Buffer,el=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],ed=Array(160);function Sha512(){this.init(),this._w=ed,es.call(this,128,112)}function sigma0(c,l){return(c>>>28|l<<4)^(l>>>2|c<<30)^(l>>>7|c<<25)}function sigma1(c,l){return(c>>>14|l<<18)^(c>>>18|l<<14)^(l>>>9|c<<23)}function getCarry(c,l){return c>>>0>>0?1:0}eo(Sha512,es),Sha512.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},Sha512.prototype._update=function(c){for(var l=this._w,et=0|this._ah,eo=0|this._bh,es=0|this._ch,ec=0|this._dh,ed=0|this._eh,eh=0|this._fh,ef=0|this._gh,ep=0|this._hh,eg=0|this._al,em=0|this._bl,eb=0|this._cl,ey=0|this._dl,e_=0|this._el,ew=0|this._fl,eE=0|this._gl,eS=0|this._hl,ex=0;ex<32;ex+=2)l[ex]=c.readInt32BE(4*ex),l[ex+1]=c.readInt32BE(4*ex+4);for(;ex<160;ex+=2){var ek,eC,eA,eI,eP,eR,eO,eT,eN=l[ex-30],eM=l[ex-30+1],e$=((ek=eN)>>>1|(eC=eM)<<31)^(ek>>>8|eC<<24)^ek>>>7,eB=((eA=eM)>>>1|(eI=eN)<<31)^(eA>>>8|eI<<24)^(eA>>>7|eI<<25);eN=l[ex-4],eM=l[ex-4+1];var eD=((eP=eN)>>>19|(eR=eM)<<13)^(eR>>>29|eP<<3)^eP>>>6,ej=((eO=eM)>>>19|(eT=eN)<<13)^(eT>>>29|eO<<3)^(eO>>>6|eT<<26),eL=l[ex-14],eF=l[ex-14+1],eU=l[ex-32],ez=l[ex-32+1],eH=eB+eF|0,eW=e$+eL+getCarry(eH,eB)|0;eW=(eW=eW+eD+getCarry(eH=eH+ej|0,ej)|0)+eU+getCarry(eH=eH+ez|0,ez)|0,l[ex]=eW,l[ex+1]=eH}for(var eV=0;eV<160;eV+=2){eW=l[eV],eH=l[eV+1];var eG,eK,eJ,eQ,eY,eZ,eX,e0,e1,e2,e3=(eG=et)&(eK=eo)|es&(eG|eK),e5=(eJ=eg)&(eQ=em)|eb&(eJ|eQ),e6=sigma0(et,eg),e4=sigma0(eg,et),e8=sigma1(ed,e_),e9=sigma1(e_,ed),e7=el[eV],tn=el[eV+1],to=(eY=ed,eZ=eh,(eX=ef)^eY&(eZ^eX)),ts=(e0=e_,e1=ew,(e2=eE)^e0&(e1^e2)),ta=eS+e9|0,tc=ep+e8+getCarry(ta,eS)|0;tc=(tc=(tc=tc+to+getCarry(ta=ta+ts|0,ts)|0)+e7+getCarry(ta=ta+tn|0,tn)|0)+eW+getCarry(ta=ta+eH|0,eH)|0;var tl=e4+e5|0,td=e6+e3+getCarry(tl,e4)|0;ep=ef,eS=eE,ef=eh,eE=ew,eh=ed,ew=e_,ed=ec+tc+getCarry(e_=ey+ta|0,ey)|0,ec=es,ey=eb,es=eo,eb=em,eo=et,em=eg,et=tc+td+getCarry(eg=ta+tl|0,ta)|0}this._al=this._al+eg|0,this._bl=this._bl+em|0,this._cl=this._cl+eb|0,this._dl=this._dl+ey|0,this._el=this._el+e_|0,this._fl=this._fl+ew|0,this._gl=this._gl+eE|0,this._hl=this._hl+eS|0,this._ah=this._ah+et+getCarry(this._al,eg)|0,this._bh=this._bh+eo+getCarry(this._bl,em)|0,this._ch=this._ch+es+getCarry(this._cl,eb)|0,this._dh=this._dh+ec+getCarry(this._dl,ey)|0,this._eh=this._eh+ed+getCarry(this._el,e_)|0,this._fh=this._fh+eh+getCarry(this._fl,ew)|0,this._gh=this._gh+ef+getCarry(this._gl,eE)|0,this._hh=this._hh+ep+getCarry(this._hl,eS)|0},Sha512.prototype._hash=function(){var c=ec.allocUnsafe(64);function writeInt64BE(l,et,eo){c.writeInt32BE(l,eo),c.writeInt32BE(et,eo+4)}return writeInt64BE(this._ah,this._al,0),writeInt64BE(this._bh,this._bl,8),writeInt64BE(this._ch,this._cl,16),writeInt64BE(this._dh,this._dl,24),writeInt64BE(this._eh,this._el,32),writeInt64BE(this._fh,this._fl,40),writeInt64BE(this._gh,this._gl,48),writeInt64BE(this._hh,this._hl,56),c},c.exports=Sha512},75733:function(c){c.exports=function(c,l,et,eo){var es=et?et.call(eo,c,l):void 0;if(void 0!==es)return!!es;if(c===l)return!0;if("object"!=typeof c||!c||"object"!=typeof l||!l)return!1;var ec=Object.keys(c),el=Object.keys(l);if(ec.length!==el.length)return!1;for(var ed=Object.prototype.hasOwnProperty.bind(l),eh=0;eh{if(!("string"==typeof c&&"string"==typeof l))throw TypeError("Expected the arguments to be of type `string`");if(""===l)return[c];let et=c.indexOf(l);return -1===et?[c]:[c.slice(0,et),c.slice(et+l.length)]}},67116:function(c){"use strict";c.exports=c=>encodeURIComponent(c).replace(/[!'()*]/g,c=>`%${c.charCodeAt(0).toString(16).toUpperCase()}`)},67171:function(c,l,et){"use strict";var eo=et(92336).Buffer,es=eo.isEncoding||function(c){switch((c=""+c)&&c.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function StringDecoder(c){var l;switch(this.encoding=function(c){var l=function(c){var l;if(!c)return"utf8";for(;;)switch(c){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return c;default:if(l)return;c=(""+c).toLowerCase(),l=!0}}(c);if("string"!=typeof l&&(eo.isEncoding===es||!es(c)))throw Error("Unknown encoding: "+c);return l||c}(c),this.encoding){case"utf16le":this.text=utf16Text,this.end=utf16End,l=4;break;case"utf8":this.fillLast=utf8FillLast,l=4;break;case"base64":this.text=base64Text,this.end=base64End,l=3;break;default:this.write=simpleWrite,this.end=simpleEnd;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=eo.allocUnsafe(l)}function utf8CheckByte(c){return c<=127?0:c>>5==6?2:c>>4==14?3:c>>3==30?4:c>>6==2?-1:-2}function utf8FillLast(c){var l=this.lastTotal-this.lastNeed,et=function(c,l,et){if((192&l[0])!=128)return c.lastNeed=0,"�";if(c.lastNeed>1&&l.length>1){if((192&l[1])!=128)return c.lastNeed=1,"�";if(c.lastNeed>2&&l.length>2&&(192&l[2])!=128)return c.lastNeed=2,"�"}}(this,c,0);return void 0!==et?et:this.lastNeed<=c.length?(c.copy(this.lastChar,l,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(c.copy(this.lastChar,l,0,c.length),this.lastNeed-=c.length)}function utf16Text(c,l){if((c.length-l)%2==0){var et=c.toString("utf16le",l);if(et){var eo=et.charCodeAt(et.length-1);if(eo>=55296&&eo<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1],et.slice(0,-1)}return et}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=c[c.length-1],c.toString("utf16le",l,c.length-1)}function utf16End(c){var l=c&&c.length?this.write(c):"";if(this.lastNeed){var et=this.lastTotal-this.lastNeed;return l+this.lastChar.toString("utf16le",0,et)}return l}function base64Text(c,l){var et=(c.length-l)%3;return 0===et?c.toString("base64",l):(this.lastNeed=3-et,this.lastTotal=3,1===et?this.lastChar[0]=c[c.length-1]:(this.lastChar[0]=c[c.length-2],this.lastChar[1]=c[c.length-1]),c.toString("base64",l,c.length-et))}function base64End(c){var l=c&&c.length?this.write(c):"";return this.lastNeed?l+this.lastChar.toString("base64",0,3-this.lastNeed):l}function simpleWrite(c){return c.toString(this.encoding)}function simpleEnd(c){return c&&c.length?this.write(c):""}l.s=StringDecoder,StringDecoder.prototype.write=function(c){var l,et;if(0===c.length)return"";if(this.lastNeed){if(void 0===(l=this.fillLast(c)))return"";et=this.lastNeed,this.lastNeed=0}else et=0;return et=0?(es>0&&(c.lastNeed=es-1),es):--eo=0?(es>0&&(c.lastNeed=es-2),es):--eo=0?(es>0&&(2===es?es=0:c.lastNeed=es-3),es):0}(this,c,l);if(!this.lastNeed)return c.toString("utf8",l);this.lastTotal=et;var eo=c.length-(et-this.lastNeed);return c.copy(this.lastChar,0,eo),c.toString("utf8",l,eo)},StringDecoder.prototype.fillLast=function(c){if(this.lastNeed<=c.length)return c.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);c.copy(this.lastChar,this.lastTotal-this.lastNeed,0,c.length),this.lastNeed-=c.length}},88208:function(c,l,et){"use strict";et.d(l,{vJ:function(){return $e},iv:function(){return Ae},ZP:function(){return e1}});var eo,es=et(9176),ec=et(2265),el=et(75733),ed=et.n(el),stylis_browser_esm=function(c){function X(c,l,et){var eo=l.trim().split(el);l=eo;var es=eo.length,ec=c.length;switch(ec){case 0:case 1:var ed=0;for(c=0===ec?"":c[0]+" ";edeo&&(eo=(l=l.trim()).charCodeAt(0)),eo){case 38:return l.replace(ed,"$1"+c.trim());case 58:return c.trim()+l.replace(ed,"$1"+c.trim());default:if(0<1*et&&0ef.charCodeAt(8))break;case 115:ed=ed.replace(ef,"-webkit-"+ef)+";"+ed;break;case 207:case 102:ed=ed.replace(ef,"-webkit-"+(102es.charCodeAt(0)&&(es=es.trim()),es=[es],0ed)&&(ej=(eU=eU.replace(" ",":")).length),01?l-1:0),eo=1;eo0?" Args: "+et.join(", "):""))}var ex=function(){function e(c){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=c}var c=e.prototype;return c.indexOfGroup=function(c){for(var l=0,et=0;et=this.groupSizes.length){for(var et=this.groupSizes,eo=et.length,es=eo;c>=es;)(es<<=1)<0&&D(16,""+c);this.groupSizes=new Uint32Array(es),this.groupSizes.set(et),this.length=es;for(var ec=eo;ec=this.length||0===this.groupSizes[c])return l;for(var et=this.groupSizes[c],eo=this.indexOfGroup(c),es=eo+et,ec=eo;ec=eA&&(eA=l+1),ek.set(c,l),eC.set(l,c)},eI="style["+e_+'][data-styled-version="5.3.11"]',eP=RegExp("^"+e_+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),L=function(c,l,et){for(var eo,es=et.split(","),ec=0,el=es.length;ec=0;et--){var eo=l[et];if(eo&&1===eo.nodeType&&eo.hasAttribute(e_))return eo}}(et),ec=void 0!==es?es.nextSibling:null;eo.setAttribute(e_,"active"),eo.setAttribute("data-styled-version","5.3.11");var el=Y();return el&&eo.setAttribute("nonce",el),et.insertBefore(eo,ec),eo},eR=function(){function e(c){var l=this.element=q(c);l.appendChild(document.createTextNode("")),this.sheet=function(c){if(c.sheet)return c.sheet;for(var l=document.styleSheets,et=0,eo=l.length;et=0){var et=document.createTextNode(l),eo=this.nodes[c];return this.element.insertBefore(et,eo||null),this.length++,!0}return!1},c.deleteRule=function(c){this.element.removeChild(this.nodes[c]),this.length--},c.getRule=function(c){return c0&&(ep+=c+",")}),eo+=""+eh+ef+'{content:"'+ep+'"}/*!sc*/\n'}}}return eo}(this)},e}(),eB=/(a)(d)/gi,K=function(c){return String.fromCharCode(c+(c>25?39:97))};function Q(c){var l,et="";for(l=Math.abs(c);l>52;l=l/52|0)et=K(l%52)+et;return(K(l%52)+et).replace(eB,"$1-$2")}var ee=function(c,l){for(var et=l.length;et;)c=33*c^l.charCodeAt(--et);return c},te=function(c){return ee(5381,c)};function ne(c){for(var l=0;l>>0);if(!l.hasNameForId(eo,el)){var ed=et(ec,"."+el,void 0,eo);l.insertRules(eo,el,ed)}es.push(el),this.staticRulesId=el}}else{for(var eh=this.rules.length,ef=ee(this.baseHash,et.hash),ep="",eg=0;eg>>0);if(!l.hasNameForId(eo,e_)){var ew=et(ep,"."+e_,void 0,eo);l.insertRules(eo,e_,ew)}es.push(e_)}}return es.join(" ")},e}(),eL=/^\s*\/\/.*$/gm,eF=[":","[",".","#"];function ae(c){var l,et,eo,es,ec=void 0===c?ey:c,el=ec.options,ed=void 0===el?ey:el,eh=ec.plugins,ef=void 0===eh?eb:eh,ep=new stylis_browser_esm(ed),eg=[],em=function(c){function t(l){if(l)try{c(l+"}")}catch(c){}}return function(l,et,eo,es,ec,el,ed,eh,ef,ep){switch(l){case 1:if(0===ef&&64===et.charCodeAt(0))return c(et+";"),"";break;case 2:if(0===eh)return et+"/*|*/";break;case 3:switch(eh){case 102:case 112:return c(eo[0]+et),"";default:return et+(0===ep?"/*|*/":"")}case -2:et.split("/*|*/}").forEach(t)}}}(function(c){eg.push(c)}),f=function(c,eo,ec){return 0===eo&&-1!==eF.indexOf(ec[et.length])||ec.match(es)?c:"."+l};function m(c,ec,el,ed){void 0===ed&&(ed="&");var eh=c.replace(eL,""),ef=ec&&el?el+" "+ec+" { "+eh+" }":eh;return l=ed,eo=RegExp("\\"+(et=ec)+"\\b","g"),es=RegExp("(\\"+et+"\\b){2,}"),ep(el||!ec?"":ec,ef)}return ep.use([].concat(ef,[function(c,l,es){2===c&&es.length&&es[0].lastIndexOf(et)>0&&(es[0]=es[0].replace(eo,f))},em,function(c){if(-2===c){var l=eg;return eg=[],l}}])),m.hash=ef.length?ef.reduce(function(c,l){return l.name||D(15),ee(c,l.name)},5381).toString():"",m}var eU=ec.createContext(),ez=(eU.Consumer,ec.createContext()),eH=(ez.Consumer,new e$),eW=ae();function pe(){return(0,ec.useContext)(eU)||eH}function fe(){return(0,ec.useContext)(ez)||eW}function me(c){var l=(0,ec.useState)(c.stylisPlugins),et=l[0],eo=l[1],es=pe(),el=(0,ec.useMemo)(function(){var l=es;return c.sheet?l=c.sheet:c.target&&(l=l.reconstructWithOptions({target:c.target},!1)),c.disableCSSOMInjection&&(l=l.reconstructWithOptions({useCSSOMInjection:!1})),l},[c.disableCSSOMInjection,c.sheet,c.target]),eh=(0,ec.useMemo)(function(){return ae({options:{prefix:!c.disableVendorPrefixes},plugins:et})},[c.disableVendorPrefixes,et]);return(0,ec.useEffect)(function(){ed()(et,c.stylisPlugins)||eo(c.stylisPlugins)},[c.stylisPlugins]),ec.createElement(eU.Provider,{value:el},ec.createElement(ez.Provider,{value:eh},c.children))}var eV=function(){function e(c,l){var et=this;this.inject=function(c,l){void 0===l&&(l=eW);var eo=et.name+l.hash;c.hasNameForId(et.id,eo)||c.insertRules(et.id,eo,l(et.rules,eo,"@keyframes"))},this.toString=function(){return D(12,String(et.name))},this.name=c,this.id="sc-keyframes-"+c,this.rules=l}return e.prototype.getName=function(c){return void 0===c&&(c=eW),this.name+c.hash},e}(),eG=/([A-Z])/,eK=/([A-Z])/g,eJ=/^ms-/,we=function(c){return"-"+c.toLowerCase()};function Ee(c){return eG.test(c)?c.replace(eK,we).replace(eJ,"-ms-"):c}var be=function(c){return null==c||!1===c||""===c};function _e(c,l,et,eo){if(Array.isArray(c)){for(var es,ec=[],el=0,ed=c.length;el1?l-1:0),eo=1;eo?@[\\\]^`{|}~-]+/g,eY=/(^-|-$)/g;function je(c){return c.replace(eQ,"-").replace(eY,"")}var Te=function(c){return Q(te(c)>>>0)};function xe(c){return"string"==typeof c}var ke=function(c){return"function"==typeof c||"object"==typeof c&&null!==c&&!Array.isArray(c)},eZ=ec.createContext();eZ.Consumer;var eX={},qe=function(c){return function e(c,l,et){if(void 0===et&&(et=ey),!(0,es.isValidElementType)(l))return D(1,String(l));var s=function(){return c(l,et,Ae.apply(void 0,arguments))};return s.withConfig=function(eo){return e(c,l,y({},et,{},eo))},s.attrs=function(eo){return e(c,l,y({},et,{attrs:Array.prototype.concat(et.attrs,eo).filter(Boolean)}))},s}(function Ye(c,l,et){var eo=_(c),es=!xe(c),el=l.attrs,ed=void 0===el?eb:el,eh=l.componentId,ep=void 0===eh?(ex=l.displayName,ek=l.parentComponentId,eX[eC="string"!=typeof ex?"sc":je(ex)]=(eX[eC]||0)+1,eA=eC+"-"+Te("5.3.11"+eC+eX[eC]),ek?ek+"-"+eA:eA):eh,em=l.displayName,e_=void 0===em?xe(c)?"styled."+c:"Styled("+b(c)+")":em,ew=l.displayName&&l.componentId?je(l.displayName)+"-"+l.componentId:l.componentId||ep,eE=eo&&c.attrs?Array.prototype.concat(c.attrs,ed).filter(Boolean):ed,eS=l.shouldForwardProp;eo&&c.shouldForwardProp&&(eS=l.shouldForwardProp?function(et,eo,es){return c.shouldForwardProp(et,eo,es)&&l.shouldForwardProp(et,eo,es)}:c.shouldForwardProp);var ex,ek,eC,eA,eI,eP=new ej(et,ew,eo?c.componentStyle:void 0),eR=eP.isStatic&&0===ed.length,P=function(c,l){return function(c,l,et,eo){var es,el,ed,eh,ep,eg=c.attrs,em=c.componentStyle,eb=c.defaultProps,e_=c.foldedComponentIds,ew=c.shouldForwardProp,eE=c.styledComponentId,eS=c.target,ex=(void 0===(es=Oe(l,(0,ec.useContext)(eZ),eb)||ey)&&(es=ey),el=y({},l,{theme:es}),ed={},eg.forEach(function(c){var l,et,eo,es=c;for(l in E(es)&&(es=es(el)),es)el[l]=ed[l]="className"===l?(et=ed[l],eo=es[l],et&&eo?et+" "+eo:et||eo):es[l]}),[el,ed]),ek=ex[0],eC=ex[1],eA=(eh=pe(),ep=fe(),eo?em.generateAndInjectStyles(ey,eh,ep):em.generateAndInjectStyles(ek,eh,ep)),eI=eC.$as||l.$as||eC.as||l.as||eS,eP=xe(eI),eR=eC!==l?y({},l,{},eC):l,eO={};for(var eT in eR)"$"!==eT[0]&&"as"!==eT&&("forwardedAs"===eT?eO.as=eR[eT]:(ew?ew(eT,ef.Z,eI):!eP||(0,ef.Z)(eT))&&(eO[eT]=eR[eT]));return l.style&&eC.style!==l.style&&(eO.style=y({},l.style,{},eC.style)),eO.className=Array.prototype.concat(e_,eE,eA!==eE?eA:null,l.className,eC.className).filter(Boolean).join(" "),eO.ref=et,(0,ec.createElement)(eI,eO)}(eI,c,l,eR)};return P.displayName=e_,(eI=ec.forwardRef(P)).attrs=eE,eI.componentStyle=eP,eI.displayName=e_,eI.shouldForwardProp=eS,eI.foldedComponentIds=eo?Array.prototype.concat(c.foldedComponentIds,c.styledComponentId):eb,eI.styledComponentId=ew,eI.target=eo?c.target:c,eI.withComponent=function(c){var eo=l.componentId,es=function(c,l){if(null==c)return{};var et,eo,es={},ec=Object.keys(c);for(eo=0;eo=0||(es[et]=c[et]);return es}(l,["componentId"]),ec=eo&&eo+"-"+(xe(c)?c:je(b(c)));return Ye(c,y({},es,{attrs:eE,componentId:ec}),et)},Object.defineProperty(eI,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(l){this._foldedDefaultProps=eo?function ze(c){for(var l=arguments.length,et=Array(l>1?l-1:0),eo=1;eo2&&e$.registerId(this.componentId+c),this.removeStyles(c,et),this.createStyles(c,l,et,eo)},e}();function $e(c){for(var l=arguments.length,et=Array(l>1?l-1:0),eo=1;eo"+l+""},this.getStyleTags=function(){return c.sealed?D(2):c._emitSheetCSS()},this.getStyleElement=function(){if(c.sealed)return D(2);var l,et=((l={})[e_]="",l["data-styled-version"]="5.3.11",l.dangerouslySetInnerHTML={__html:c.instance.toString()},l),eo=Y();return eo&&(et.nonce=eo),[ec.createElement("style",y({},et,{key:"sc-0-0"}))]},this.seal=function(){c.sealed=!0},this.instance=new e$({isServer:!0}),this.sealed=!1}).prototype).collectStyles=function(c){return this.sealed?D(2):ec.createElement(me,{sheet:this.instance},c)},eo.interleaveWithNodeStream=function(c){return D(3)};var e1=qe},25809:function(c){c.exports=function(){var c=document.getSelection();if(!c.rangeCount)return function(){};for(var l=document.activeElement,et=[],eo=0;eo0?2===ed.length?typeof ed[1]==el?this[ed[0]]=ed[1].call(this,ep):this[ed[0]]=ed[1]:3===ed.length?typeof ed[1]!==el||ed[1].exec&&ed[1].test?this[ed[0]]=ep?ep.replace(ed[1],ed[2]):ec:this[ed[0]]=ep?ed[1].call(this,ep,ed[2]):ec:4===ed.length&&(this[ed[0]]=ep?ed[3].call(this,ep.replace(ed[1],ed[2])):ec):this[ed]=ep||ec;eg+=2}},strMapper=function(c,l){for(var et in l)if(typeof l[et]===eh&&l[et].length>0){for(var eo=0;eo2&&(c[eg]="iPad",c[eb]=ex),c},this.getEngine=function(){var c={};return c[em]=ec,c[e_]=ec,rgxMapper.call(c,eo,ek.engine),c},this.getOS=function(){var c={};return c[em]=ec,c[e_]=ec,rgxMapper.call(c,eo,ek.os),eC&&!c[em]&&eE&&"Unknown"!=eE.platform&&(c[em]=eE.platform.replace(/chrome os/i,eG).replace(/macos/i,eK)),c},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return eo},this.setUA=function(c){return eo=typeof c===ef&&c.length>350?trim(c,350):c,this},this.setUA(eo),this};UAParser.VERSION="1.0.36",UAParser.BROWSER=enumerize([em,e_,ep]),UAParser.CPU=enumerize([ew]),UAParser.DEVICE=enumerize([eg,ey,eb,eE,eS,ek,ex,eC,eA]),UAParser.ENGINE=UAParser.OS=enumerize([em,e_]),typeof l!==ed?(c.exports&&(l=c.exports=UAParser),l.UAParser=UAParser):et.amdO?ec!==(eo=(function(){return UAParser}).call(l,et,l,c))&&(c.exports=eo):typeof es!==ed&&(es.UAParser=UAParser);var eY=typeof es!==ed&&(es.jQuery||es.Zepto);if(eY&&!eY.ua){var eZ=new UAParser;eY.ua=eZ.getResult(),eY.ua.get=function(){return eZ.getUA()},eY.ua.set=function(c){eZ.setUA(c);var l=eZ.getResult();for(var et in l)eY.ua[et]=l[et]}}}("object"==typeof window?window:this)},81853:function(c,l,et){"use strict";/** + * @license React + * use-sync-external-store-shim.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var eo=et(2265),es="function"==typeof Object.is?Object.is:function(c,l){return c===l&&(0!==c||1/c==1/l)||c!=c&&l!=l},ec=eo.useState,el=eo.useEffect,ed=eo.useLayoutEffect,eh=eo.useDebugValue;function r(c){var l=c.getSnapshot;c=c.value;try{var et=l();return!es(c,et)}catch(c){return!0}}var ef="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(c,l){return l()}:function(c,l){var et=l(),eo=ec({inst:{value:et,getSnapshot:l}}),es=eo[0].inst,ef=eo[1];return ed(function(){es.value=et,es.getSnapshot=l,r(es)&&ef({inst:es})},[c,et,l]),el(function(){return r(es)&&ef({inst:es}),c(function(){r(es)&&ef({inst:es})})},[c]),eh(et),et};l.useSyncExternalStore=void 0!==eo.useSyncExternalStore?eo.useSyncExternalStore:ef},78704:function(c,l,et){"use strict";/** + * @license React + * use-sync-external-store-shim/with-selector.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var eo=et(2265),es=et(26272),ec="function"==typeof Object.is?Object.is:function(c,l){return c===l&&(0!==c||1/c==1/l)||c!=c&&l!=l},el=es.useSyncExternalStore,ed=eo.useRef,eh=eo.useEffect,ef=eo.useMemo,ep=eo.useDebugValue;l.useSyncExternalStoreWithSelector=function(c,l,et,eo,es){var eg=ed(null);if(null===eg.current){var em={hasValue:!1,value:null};eg.current=em}else em=eg.current;var eb=el(c,(eg=ef(function(){function a(l){if(!ed){if(ed=!0,c=l,l=eo(l),void 0!==es&&em.hasValue){var et=em.value;if(es(et,l))return el=et}return el=l}if(et=el,ec(c,l))return et;var eh=eo(l);return void 0!==es&&es(et,eh)?et:(c=l,el=eh)}var c,el,ed=!1,eh=void 0===et?null:et;return[function(){return a(l())},null===eh?void 0:function(){return a(eh())}]},[l,et,eo,es]))[0],eg[1]);return eh(function(){em.hasValue=!0,em.value=eb},[eb]),ep(eb),eb}},26272:function(c,l,et){"use strict";c.exports=et(81853)},65401:function(c,l,et){"use strict";c.exports=et(78704)},79026:function(c,l,et){c.exports=function(c,l){if(config("noDeprecation"))return c;var et=!1;return function(){if(!et){if(config("throwDeprecation"))throw Error(l);config("traceDeprecation")?console.trace(l):console.warn(l),et=!0}return c.apply(this,arguments)}};function config(c){try{if(!et.g.localStorage)return!1}catch(c){return!1}var l=et.g.localStorage[c];return null!=l&&"true"===String(l).toLowerCase()}},63895:function(){var c=function(){function defineProperties(c,l){for(var et=0;et0)for(var et=0,eo=arguments.length;et1)et=l;else if(this.head)eo=this.head.next,et=this.head.value;else throw TypeError("Reduce of empty list with no initial value");for(var es=0;null!==eo;es++)et=c(et,eo.value,es),eo=eo.next;return et},Yallist.prototype.reduceReverse=function(c,l){var et,eo=this.tail;if(arguments.length>1)et=l;else if(this.tail)eo=this.tail.prev,et=this.tail.value;else throw TypeError("Reduce of empty list with no initial value");for(var es=this.length-1;null!==eo;es--)et=c(et,eo.value,es),eo=eo.prev;return et},Yallist.prototype.toArray=function(){for(var c=Array(this.length),l=0,et=this.head;null!==et;l++)c[l]=et.value,et=et.next;return c},Yallist.prototype.toArrayReverse=function(){for(var c=Array(this.length),l=0,et=this.tail;null!==et;l++)c[l]=et.value,et=et.prev;return c},Yallist.prototype.slice=function(c,l){(l=l||this.length)<0&&(l+=this.length),(c=c||0)<0&&(c+=this.length);var et=new Yallist;if(lthis.length&&(l=this.length);for(var eo=0,es=this.head;null!==es&&eothis.length&&(l=this.length);for(var eo=this.length,es=this.tail;null!==es&&eo>l;eo--)es=es.prev;for(;null!==es&&eo>c;eo--,es=es.prev)et.push(es.value);return et},Yallist.prototype.splice=function(c,l,...et){c>this.length&&(c=this.length-1),c<0&&(c=this.length+c);for(var eo=0,es=this.head;null!==es&&eo-1&&(ed=!1),"function"==typeof eo&&(eo.error=eo.fatal=eo.warn=eo.info=eo.debug=eo.trace=eo),!1===c.enabled&&(c.level="silent");let eh=c.level||"info",ef=Object.create(eo);ef.log||(ef.log=noop),Object.defineProperty(ef,"levelVal",{get:function(){return"silent"===this.level?1/0:this.levels.values[this.level]}}),Object.defineProperty(ef,"level",{get:function(){return this._level},set:function(c){if("silent"!==c&&!this.levels.values[c])throw Error("unknown level "+c);this._level=c,set(ep,ef,"error","log"),set(ep,ef,"fatal","error"),set(ep,ef,"warn","error"),set(ep,ef,"info","log"),set(ep,ef,"debug","log"),set(ep,ef,"trace","log")}});let ep={transmit:et,serialize:el,asObject:c.browser.asObject,levels:["error","fatal","warn","info","debug","trace"],timestamp:"function"==typeof(l=c).timestamp?l.timestamp:!1===l.timestamp?nullTime:epochTime};return ef.levels=pino.levels,ef.level=eh,ef.setMaxListeners=ef.getMaxListeners=ef.emit=ef.addListener=ef.on=ef.prependListener=ef.once=ef.prependOnceListener=ef.removeListener=ef.removeAllListeners=ef.listeners=ef.listenerCount=ef.eventNames=ef.write=ef.flush=noop,ef.serializers=ec,ef._serialize=el,ef._stdErrSerialize=ed,ef.child=function(l,eo){if(!l)throw Error("missing bindings for child Pino");eo=eo||{},el&&l.serializers&&(eo.serializers=l.serializers);let es=eo.serializers;if(el&&es){var ed=Object.assign({},ec,es),eh=!0===c.browser.serialize?Object.keys(ed):el;delete l.serializers,applySerializers([l],eh,ed,this._stdErrSerialize)}function Child(c){this._childLevel=(0|c._childLevel)+1,this.error=bind(c,l,"error"),this.fatal=bind(c,l,"fatal"),this.warn=bind(c,l,"warn"),this.info=bind(c,l,"info"),this.debug=bind(c,l,"debug"),this.trace=bind(c,l,"trace"),ed&&(this.serializers=ed,this._serialize=eh),et&&(this._logEvent=createLogEventShape([].concat(c._logEvent.bindings,l)))}return Child.prototype=this,new Child(this)},et&&(ef._logEvent=createLogEventShape()),ef}function set(c,l,et,ec){let el=Object.getPrototypeOf(l);l[et]=l.levelVal>l.levels.values[et]?noop:el[et]?el[et]:es[et]||es[ec]||noop,function(c,l,et){if(c.transmit||l[et]!==noop){var ec;l[et]=(ec=l[et],function(){let el=c.timestamp(),ed=Array(arguments.length),eh=Object.getPrototypeOf&&Object.getPrototypeOf(this)===es?es:this;for(var ef=0;ef-1&&eo in et&&(c[es][eo]=et[eo](c[es][eo]))}function bind(c,l,et){return function(){let eo=Array(1+arguments.length);eo[0]=l;for(var es=1;es({display:"flex",alignItems:"center",position:l?"relative":"absolute",[ey]:l?eh:0,fontSize:"1em",lineHeight:"normal",...eg}),[eg,l,ey,eh]);return(0,ed.jsx)(es.chakra.div,{className:eb,...em,__css:e_,children:ef})}ButtonSpinner.displayName="ButtonSpinner"},56663:function(c,l,et){"use strict";et.d(l,{D:function(){return eo},i:function(){return es}});var[eo,es]=(0,et(310).k)({strict:!1,name:"ButtonGroupContext"})},48433:function(c,l,et){"use strict";et.d(l,{z:function(){return eb}});var eo=et(2265),es=et(56663),ec=et(23145),el=et(16465),ed=et(57437);function ButtonIcon(c){let{children:l,className:et,...es}=c,eh=(0,eo.isValidElement)(l)?(0,eo.cloneElement)(l,{"aria-hidden":!0,focusable:!1}):l,ef=(0,el.cx)("chakra-button__icon",et);return(0,ed.jsx)(ec.chakra.span,{display:"inline-flex",alignSelf:"center",flexShrink:0,...es,className:ef,children:eh})}ButtonIcon.displayName="ButtonIcon";var eh=et(35279),ef=et(45663),ep=et(58250),eg=et(92013),em=et(50446),eb=(0,ep.forwardRef)((c,l)=>{let et=(0,es.i)(),ep=(0,eg.useStyleConfig)("Button",{...et,...c}),{isDisabled:eb=null==et?void 0:et.isDisabled,isLoading:ey,isActive:e_,children:ew,leftIcon:eE,rightIcon:eS,loadingText:ex,iconSpacing:ek="0.5rem",type:eC,spinner:eA,spinnerPlacement:eI="start",className:eP,as:eR,...eO}=(0,em.Lr)(c),eT=(0,eo.useMemo)(()=>{let c={...null==ep?void 0:ep._focus,zIndex:1};return{display:"inline-flex",appearance:"none",alignItems:"center",justifyContent:"center",userSelect:"none",position:"relative",whiteSpace:"nowrap",verticalAlign:"middle",outline:"none",...ep,...!!et&&{_focus:c}}},[ep,et]),{ref:eN,type:eM}=function(c){let[l,et]=(0,eo.useState)(!c),es=(0,eo.useCallback)(c=>{c&&et("BUTTON"===c.tagName)},[]);return{ref:es,type:l?"button":void 0}}(eR),e$={rightIcon:eS,leftIcon:eE,iconSpacing:ek,children:ew};return(0,ed.jsxs)(ec.chakra.button,{ref:(0,ef.qq)(l,eN),as:eR,type:null!=eC?eC:eM,"data-active":(0,el.PB)(e_),"data-loading":(0,el.PB)(ey),__css:eT,className:(0,el.cx)("chakra-button",eP),...eO,disabled:eb||ey,children:[ey&&"start"===eI&&(0,ed.jsx)(eh.X,{className:"chakra-button__spinner--start",label:ex,placement:"start",spacing:ek,children:eA}),ey?ex||(0,ed.jsx)(ec.chakra.span,{opacity:0,children:(0,ed.jsx)(ButtonContent,{...e$})}):(0,ed.jsx)(ButtonContent,{...e$}),ey&&"end"===eI&&(0,ed.jsx)(eh.X,{className:"chakra-button__spinner--end",label:ex,placement:"end",spacing:ek,children:eA})]})});function ButtonContent(c){let{leftIcon:l,rightIcon:et,children:eo,iconSpacing:es}=c;return(0,ed.jsxs)(ed.Fragment,{children:[l&&(0,ed.jsx)(ButtonIcon,{marginEnd:es,children:l}),eo,et&&(0,ed.jsx)(ButtonIcon,{marginStart:es,children:et})]})}eb.displayName="Button"},85035:function(c,l,et){"use strict";et.d(l,{If:function(){return useColorMode},ff:function(){return useColorModeValue},kc:function(){return es}});var eo=et(2265),es=(0,eo.createContext)({});function useColorMode(){let c=(0,eo.useContext)(es);if(void 0===c)throw Error("useColorMode must be used within a ColorModeProvider");return c}function useColorModeValue(c,l){let{colorMode:et}=useColorMode();return"dark"===et?l:c}es.displayName="ColorModeContext"},68975:function(c,l,et){"use strict";et.d(l,{NI:function(){return ew},NJ:function(){return e_},Q6:function(){return eE},e:function(){return eb}});var eo=et(310),es=et(45663),ec=et(58250),el=et(92013),ed=et(50446),eh=et(23145),ef=et(16465),ep=et(2265),eg=et(57437),[em,eb]=(0,eo.k)({name:"FormControlStylesContext",errorMessage:"useFormControlStyles returned is 'undefined'. Seems you forgot to wrap the components in \"\" "}),[ey,e_]=(0,eo.k)({strict:!1,name:"FormControlContext"}),ew=(0,ec.forwardRef)(function(c,l){let et=(0,el.useMultiStyleConfig)("Form",c),eo=(0,ed.Lr)(c),{getRootProps:ec,htmlProps:eb,...e_}=function(c){let{id:l,isRequired:et,isInvalid:eo,isDisabled:ec,isReadOnly:el,...ed}=c,eh=(0,ep.useId)(),eg=l||`field-${eh}`,em=`${eg}-label`,eb=`${eg}-feedback`,ey=`${eg}-helptext`,[e_,ew]=(0,ep.useState)(!1),[eE,eS]=(0,ep.useState)(!1),[ex,ek]=(0,ep.useState)(!1),eC=(0,ep.useCallback)((c={},l=null)=>({id:ey,...c,ref:(0,es.lq)(l,c=>{c&&eS(!0)})}),[ey]),eA=(0,ep.useCallback)((c={},l=null)=>({...c,ref:l,"data-focus":(0,ef.PB)(ex),"data-disabled":(0,ef.PB)(ec),"data-invalid":(0,ef.PB)(eo),"data-readonly":(0,ef.PB)(el),id:void 0!==c.id?c.id:em,htmlFor:void 0!==c.htmlFor?c.htmlFor:eg}),[eg,ec,ex,eo,el,em]),eI=(0,ep.useCallback)((c={},l=null)=>({id:eb,...c,ref:(0,es.lq)(l,c=>{c&&ew(!0)}),"aria-live":"polite"}),[eb]),eP=(0,ep.useCallback)((c={},l=null)=>({...c,...ed,ref:l,role:"group"}),[ed]),eR=(0,ep.useCallback)((c={},l=null)=>({...c,ref:l,role:"presentation","aria-hidden":!0,children:c.children||"*"}),[]);return{isRequired:!!et,isInvalid:!!eo,isReadOnly:!!el,isDisabled:!!ec,isFocused:!!ex,onFocus:()=>ek(!0),onBlur:()=>ek(!1),hasFeedbackText:e_,setHasFeedbackText:ew,hasHelpText:eE,setHasHelpText:eS,id:eg,labelId:em,feedbackId:eb,helpTextId:ey,htmlProps:ed,getHelpTextProps:eC,getErrorMessageProps:eI,getRootProps:eP,getLabelProps:eA,getRequiredIndicatorProps:eR}}(eo),ew=(0,ef.cx)("chakra-form-control",c.className);return(0,eg.jsx)(ey,{value:e_,children:(0,eg.jsx)(em,{value:et,children:(0,eg.jsx)(eh.chakra.div,{...ec({},l),className:ew,__css:et.container})})})});ew.displayName="FormControl";var eE=(0,ec.forwardRef)(function(c,l){let et=e_(),eo=eb(),es=(0,ef.cx)("chakra-form__helper-text",c.className);return(0,eg.jsx)(eh.chakra.div,{...null==et?void 0:et.getHelpTextProps(c,l),__css:eo.helperText,className:es})});eE.displayName="FormHelperText"},75992:function(c,l,et){"use strict";et.d(l,{K:function(){return useFormControlProps},Y:function(){return useFormControl}});var eo=et(68975),es=et(16465);function useFormControl(c){let{isDisabled:l,isInvalid:et,isReadOnly:eo,isRequired:ec,...el}=useFormControlProps(c);return{...el,disabled:l,readOnly:eo,required:ec,"aria-invalid":(0,es.Qm)(et),"aria-required":(0,es.Qm)(ec),"aria-readonly":(0,es.Qm)(eo)}}function useFormControlProps(c){var l,et,ec;let el=(0,eo.NJ)(),{id:ed,disabled:eh,readOnly:ef,required:ep,isRequired:eg,isInvalid:em,isReadOnly:eb,isDisabled:ey,onFocus:e_,onBlur:ew,...eE}=c,eS=c["aria-describedby"]?[c["aria-describedby"]]:[];return(null==el?void 0:el.hasFeedbackText)&&(null==el?void 0:el.isInvalid)&&eS.push(el.feedbackId),(null==el?void 0:el.hasHelpText)&&eS.push(el.helpTextId),{...eE,"aria-describedby":eS.join(" ")||void 0,id:null!=ed?ed:null==el?void 0:el.id,isDisabled:null!=(l=null!=eh?eh:ey)?l:null==el?void 0:el.isDisabled,isReadOnly:null!=(et=null!=ef?ef:eb)?et:null==el?void 0:el.isReadOnly,isRequired:null!=(ec=null!=ep?ep:eg)?ec:null==el?void 0:el.isRequired,isInvalid:null!=em?em:null==el?void 0:el.isInvalid,onFocus:(0,es.v0)(null==el?void 0:el.onFocus,e_),onBlur:(0,es.v0)(null==el?void 0:el.onBlur,ew)}}},51091:function(c,l,et){"use strict";et.d(l,{I:function(){return ep}});var eo=et(75992),es=et(58250),ec=et(92013),el=et(50446),ed=et(23145),eh=et(16465),ef=et(57437),ep=(0,es.forwardRef)(function(c,l){let{htmlSize:et,...es}=c,ep=(0,ec.useMultiStyleConfig)("Input",es),eg=(0,el.Lr)(es),em=(0,eo.Y)(eg),eb=(0,eh.cx)("chakra-input",c.className);return(0,ef.jsx)(ed.chakra.input,{size:et,...em,__css:ep.field,ref:l,className:eb})});ep.displayName="Input",ep.id="Input"},79980:function(c,l,et){"use strict";et.d(l,{x:function(){return ep}});var eo=et(58250),es=et(92013),ec=et(50446),el=et(23145),ed=et(16465),eh=et(89565),ef=et(57437),ep=(0,eo.forwardRef)(function(c,l){let et=(0,es.useStyleConfig)("Text",c),{className:eo,align:ep,decoration:eg,casing:em,...eb}=(0,ec.Lr)(c),ey=(0,eh.o)({textAlign:c.align,textDecoration:c.decoration,textTransform:c.casing});return(0,ef.jsx)(el.chakra.p,{ref:l,className:(0,ed.cx)("chakra-text",c.className),...ey,...eb,__css:et})});ep.displayName="Text"},26621:function(c,l,et){"use strict";et.d(l,{k:function(){return el}});var eo=et(58250),es=et(23145),ec=et(57437),el=(0,eo.forwardRef)(function(c,l){let{direction:et,align:eo,justify:el,wrap:ed,basis:eh,grow:ef,shrink:ep,...eg}=c;return(0,ec.jsx)(es.chakra.div,{ref:l,__css:{display:"flex",flexDirection:et,alignItems:eo,justifyContent:el,flexWrap:ed,flexBasis:eh,flexGrow:ef,flexShrink:ep},...eg})});el.displayName="Flex"},89565:function(c,l,et){"use strict";function compact(c){let l=Object.assign({},c);for(let c in l)void 0===l[c]&&delete l[c];return l}et.d(l,{o:function(){return compact}})},310:function(c,l,et){"use strict";et.d(l,{k:function(){return createContext}});var eo=et(2265);function createContext(c={}){let{name:l,strict:et=!0,hookName:es="useContext",providerName:ec="Provider",errorMessage:el,defaultValue:ed}=c,eh=(0,eo.createContext)(ed);return eh.displayName=l,[eh.Provider,function useContext(){var c;let l=(0,eo.useContext)(eh);if(!l&&et){let l=Error(null!=el?el:`${es} returned \`undefined\`. Seems you forgot to wrap component within ${ec}`);throw l.name="ContextError",null==(c=Error.captureStackTrace)||c.call(Error,l,useContext),l}return l},eh]}},45663:function(c,l,et){"use strict";et.d(l,{lq:function(){return mergeRefs},qq:function(){return useMergeRefs}});var eo=et(2265);function mergeRefs(...c){return l=>{c.forEach(c=>{!function(c,l){if(null!=c){if("function"==typeof c){c(l);return}try{c.current=l}catch(et){throw Error(`Cannot assign value '${l}' to ref '${c}'`)}}}(c,l)})}}function useMergeRefs(...c){return(0,eo.useMemo)(()=>mergeRefs(...c),c)}},16465:function(c,l,et){"use strict";et.d(l,{Kn:function(){return isObject},PB:function(){return dataAttr},PP:function(){return callAll},Pu:function(){return runIfFn},Qm:function(){return ariaAttr},ZK:function(){return warn},cx:function(){return cx},v0:function(){return callAllHandlers}});var cx=(...c)=>c.filter(Boolean).join(" ");function isObject(c){let l=typeof c;return null!=c&&("object"===l||"function"===l)&&!Array.isArray(c)}var warn=c=>{let{condition:l,message:et}=c};function runIfFn(c,...l){return isFunction(c)?c(...l):c}var isFunction=c=>"function"==typeof c,dataAttr=c=>c?"":void 0,ariaAttr=c=>!!c||void 0;function callAllHandlers(...c){return function(l){c.some(c=>(null==c||c(l),null==l?void 0:l.defaultPrevented))}}function callAll(...c){return function(l){c.forEach(c=>{null==c||c(l)})}}},83109:function(c,l,et){"use strict";et.d(l,{$:function(){return eg}});var eo=et(99538),es=et(58250),ec=et(92013),el=et(50446),ed=et(23145),eh=et(16465),ef=et(57437),ep=(0,eo.F4)({"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}}),eg=(0,es.forwardRef)((c,l)=>{let et=(0,ec.useStyleConfig)("Spinner",c),{label:eo="Loading...",thickness:es="2px",speed:eg="0.45s",emptyColor:em="transparent",className:eb,...ey}=(0,el.Lr)(c),e_=(0,eh.cx)("chakra-spinner",eb),ew={display:"inline-block",borderColor:"currentColor",borderStyle:"solid",borderRadius:"99999px",borderWidth:es,borderBottomColor:em,borderLeftColor:em,animation:`${ep} ${eg} linear infinite`,...et};return(0,ef.jsx)(ed.chakra.div,{ref:l,__css:ew,className:e_,...ey,children:eo&&(0,ef.jsx)(ed.chakra.span,{srOnly:!0,children:eo})})});eg.displayName="Spinner"},50446:function(c,l,et){"use strict";et.d(l,{D:function(){return createMultiStyleConfigHelpers},K1:function(){return getCSSVar},Lr:function(){return omitThemingProps},Ud:function(){return resolveStyleConfig},ZR:function(){return isStyleProp},_6:function(){return defineCssVars},c0:function(){return toCSSVar},cC:function(){return eK},fj:function(){return defineStyleConfig},gJ:function(){return cssVar},iv:function(){return css},k0:function(){return defineStyle},oE:function(){return eG}});var eo=et(16465),es=et(94216),isImportant=c=>/!(important)?$/.test(c),withoutImportant=c=>"string"==typeof c?c.replace(/!(important)?$/,"").trim():c,tokenToCSSVar=(c,l)=>et=>{let es=String(l),ec=isImportant(es),el=withoutImportant(es),ed=c?`${c}.${el}`:el,eh=(0,eo.Kn)(et.__cssMap)&&ed in et.__cssMap?et.__cssMap[ed].varRef:l;return eh=withoutImportant(eh),ec?`${eh} !important`:eh};function createTransform(c){let{scale:l,transform:et,compose:eo}=c;return(c,es)=>{var ec;let el=tokenToCSSVar(l,c)(es),ed=null!=(ec=null==et?void 0:et(el,es))?ec:el;return eo&&(ed=eo(ed,es)),ed}}var pipe=(...c)=>l=>c.reduce((c,l)=>l(c),l);function toConfig(c,l){return et=>{let eo={property:et,scale:c};return eo.transform=createTransform({scale:c,transform:l}),eo}}var getRtl=({rtl:c,ltr:l})=>et=>"rtl"===et.direction?c:l,ec=["rotate(var(--chakra-rotate, 0))","scaleX(var(--chakra-scale-x, 1))","scaleY(var(--chakra-scale-y, 1))","skewX(var(--chakra-skew-x, 0))","skewY(var(--chakra-skew-y, 0))"],el={"--chakra-blur":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-brightness":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-contrast":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-grayscale":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-hue-rotate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-invert":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-saturate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-sepia":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-drop-shadow":"var(--chakra-empty,/*!*/ /*!*/)",filter:"var(--chakra-blur) var(--chakra-brightness) var(--chakra-contrast) var(--chakra-grayscale) var(--chakra-hue-rotate) var(--chakra-invert) var(--chakra-saturate) var(--chakra-sepia) var(--chakra-drop-shadow)"},ed={backdropFilter:"var(--chakra-backdrop-blur) var(--chakra-backdrop-brightness) var(--chakra-backdrop-contrast) var(--chakra-backdrop-grayscale) var(--chakra-backdrop-hue-rotate) var(--chakra-backdrop-invert) var(--chakra-backdrop-opacity) var(--chakra-backdrop-saturate) var(--chakra-backdrop-sepia)","--chakra-backdrop-blur":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-brightness":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-contrast":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-grayscale":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-hue-rotate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-invert":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-opacity":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-saturate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-sepia":"var(--chakra-empty,/*!*/ /*!*/)"},eh={"row-reverse":{space:"--chakra-space-x-reverse",divide:"--chakra-divide-x-reverse"},"column-reverse":{space:"--chakra-space-y-reverse",divide:"--chakra-divide-y-reverse"}},ef={"to-t":"to top","to-tr":"to top right","to-r":"to right","to-br":"to bottom right","to-b":"to bottom","to-bl":"to bottom left","to-l":"to left","to-tl":"to top left"},ep=new Set(Object.values(ef)),eg=new Set(["none","-moz-initial","inherit","initial","revert","unset"]),trimSpace=c=>c.trim(),isCSSFunction=c=>"string"==typeof c&&c.includes("(")&&c.includes(")"),analyzeCSSValue=c=>{let l=parseFloat(c.toString()),et=c.toString().replace(String(l),"");return{unitless:!et,value:l,unit:et}},wrap=c=>l=>`${c}(${l})`,em={filter:c=>"auto"!==c?c:el,backdropFilter:c=>"auto"!==c?c:ed,ring:c=>({"--chakra-ring-offset-shadow":"var(--chakra-ring-inset) 0 0 0 var(--chakra-ring-offset-width) var(--chakra-ring-offset-color)","--chakra-ring-shadow":"var(--chakra-ring-inset) 0 0 0 calc(var(--chakra-ring-width) + var(--chakra-ring-offset-width)) var(--chakra-ring-color)","--chakra-ring-width":em.px(c),boxShadow:"var(--chakra-ring-offset-shadow), var(--chakra-ring-shadow), var(--chakra-shadow, 0 0 #0000)"}),bgClip:c=>"text"===c?{color:"transparent",backgroundClip:"text"}:{backgroundClip:c},transform:c=>"auto"===c?["translateX(var(--chakra-translate-x, 0))","translateY(var(--chakra-translate-y, 0))",...ec].join(" "):"auto-gpu"===c?["translate3d(var(--chakra-translate-x, 0), var(--chakra-translate-y, 0), 0)",...ec].join(" "):c,vh:c=>"$100vh"===c?"var(--chakra-vh)":c,px(c){if(null==c)return c;let{unitless:l}=analyzeCSSValue(c);return l||"number"==typeof c?`${c}px`:c},fraction:c=>"number"!=typeof c||c>1?c:`${100*c}%`,float:(c,l)=>"rtl"===l.direction?({left:"right",right:"left"})[c]:c,degree(c){if(/^var\(--.+\)$/.test(c)||null==c)return c;let l="string"==typeof c&&!c.endsWith("deg");return"number"==typeof c||l?`${c}deg`:c},gradient:(c,l)=>(function(c,l){if(null==c||eg.has(c))return c;let et=isCSSFunction(c)||eg.has(c);if(!et)return`url('${c}')`;let eo=/(^[a-z-A-Z]+)\((.*)\)/g.exec(c),es=null==eo?void 0:eo[1],ec=null==eo?void 0:eo[2];if(!es||!ec)return c;let el=es.includes("-gradient")?es:`${es}-gradient`,[ed,...eh]=ec.split(",").map(trimSpace).filter(Boolean);if((null==eh?void 0:eh.length)===0)return c;let em=ed in ef?ef[ed]:ed;eh.unshift(em);let eb=eh.map(c=>{if(ep.has(c))return c;let et=c.indexOf(" "),[eo,es]=-1!==et?[c.substr(0,et),c.substr(et+1)]:[c],ec=isCSSFunction(es)?es:es&&es.split(" "),el=`colors.${eo}`,ed=el in l.__cssMap?l.__cssMap[el].varRef:eo;return ec?[ed,...Array.isArray(ec)?ec:[ec]].join(" "):ed});return`${el}(${eb.join(", ")})`})(c,null!=l?l:{}),blur:wrap("blur"),opacity:wrap("opacity"),brightness:wrap("brightness"),contrast:wrap("contrast"),dropShadow:wrap("drop-shadow"),grayscale:wrap("grayscale"),hueRotate:wrap("hue-rotate"),invert:wrap("invert"),saturate:wrap("saturate"),sepia:wrap("sepia"),bgImage(c){if(null==c)return c;let l=isCSSFunction(c)||eg.has(c);return l?c:`url(${c})`},outline(c){let l="0"===String(c)||"none"===String(c);return null!==c&&l?{outline:"2px solid transparent",outlineOffset:"2px"}:{outline:c}},flexDirection(c){var l;let{space:et,divide:eo}=null!=(l=eh[c])?l:{},es={flexDirection:c};return et&&(es[et]=1),eo&&(es[eo]=1),es}},eb={borderWidths:toConfig("borderWidths"),borderStyles:toConfig("borderStyles"),colors:toConfig("colors"),borders:toConfig("borders"),gradients:toConfig("gradients",em.gradient),radii:toConfig("radii",em.px),space:toConfig("space",pipe(em.vh,em.px)),spaceT:toConfig("space",pipe(em.vh,em.px)),degreeT:c=>({property:c,transform:em.degree}),prop:(c,l,et)=>({property:c,scale:l,...l&&{transform:createTransform({scale:l,transform:et})}}),propT:(c,l)=>({property:c,transform:l}),sizes:toConfig("sizes",pipe(em.vh,em.px)),sizesT:toConfig("sizes",pipe(em.vh,em.fraction)),shadows:toConfig("shadows"),logical:function(c){let{property:l,scale:et,transform:eo}=c;return{scale:et,property:getRtl(l),transform:et?createTransform({scale:et,compose:eo}):eo}},blur:toConfig("blur",em.blur)},ey={background:eb.colors("background"),backgroundColor:eb.colors("backgroundColor"),backgroundImage:eb.gradients("backgroundImage"),backgroundSize:!0,backgroundPosition:!0,backgroundRepeat:!0,backgroundAttachment:!0,backgroundClip:{transform:em.bgClip},bgSize:eb.prop("backgroundSize"),bgPosition:eb.prop("backgroundPosition"),bg:eb.colors("background"),bgColor:eb.colors("backgroundColor"),bgPos:eb.prop("backgroundPosition"),bgRepeat:eb.prop("backgroundRepeat"),bgAttachment:eb.prop("backgroundAttachment"),bgGradient:eb.gradients("backgroundImage"),bgClip:{transform:em.bgClip}};Object.assign(ey,{bgImage:ey.backgroundImage,bgImg:ey.backgroundImage});var e_={border:eb.borders("border"),borderWidth:eb.borderWidths("borderWidth"),borderStyle:eb.borderStyles("borderStyle"),borderColor:eb.colors("borderColor"),borderRadius:eb.radii("borderRadius"),borderTop:eb.borders("borderTop"),borderBlockStart:eb.borders("borderBlockStart"),borderTopLeftRadius:eb.radii("borderTopLeftRadius"),borderStartStartRadius:eb.logical({scale:"radii",property:{ltr:"borderTopLeftRadius",rtl:"borderTopRightRadius"}}),borderEndStartRadius:eb.logical({scale:"radii",property:{ltr:"borderBottomLeftRadius",rtl:"borderBottomRightRadius"}}),borderTopRightRadius:eb.radii("borderTopRightRadius"),borderStartEndRadius:eb.logical({scale:"radii",property:{ltr:"borderTopRightRadius",rtl:"borderTopLeftRadius"}}),borderEndEndRadius:eb.logical({scale:"radii",property:{ltr:"borderBottomRightRadius",rtl:"borderBottomLeftRadius"}}),borderRight:eb.borders("borderRight"),borderInlineEnd:eb.borders("borderInlineEnd"),borderBottom:eb.borders("borderBottom"),borderBlockEnd:eb.borders("borderBlockEnd"),borderBottomLeftRadius:eb.radii("borderBottomLeftRadius"),borderBottomRightRadius:eb.radii("borderBottomRightRadius"),borderLeft:eb.borders("borderLeft"),borderInlineStart:{property:"borderInlineStart",scale:"borders"},borderInlineStartRadius:eb.logical({scale:"radii",property:{ltr:["borderTopLeftRadius","borderBottomLeftRadius"],rtl:["borderTopRightRadius","borderBottomRightRadius"]}}),borderInlineEndRadius:eb.logical({scale:"radii",property:{ltr:["borderTopRightRadius","borderBottomRightRadius"],rtl:["borderTopLeftRadius","borderBottomLeftRadius"]}}),borderX:eb.borders(["borderLeft","borderRight"]),borderInline:eb.borders("borderInline"),borderY:eb.borders(["borderTop","borderBottom"]),borderBlock:eb.borders("borderBlock"),borderTopWidth:eb.borderWidths("borderTopWidth"),borderBlockStartWidth:eb.borderWidths("borderBlockStartWidth"),borderTopColor:eb.colors("borderTopColor"),borderBlockStartColor:eb.colors("borderBlockStartColor"),borderTopStyle:eb.borderStyles("borderTopStyle"),borderBlockStartStyle:eb.borderStyles("borderBlockStartStyle"),borderBottomWidth:eb.borderWidths("borderBottomWidth"),borderBlockEndWidth:eb.borderWidths("borderBlockEndWidth"),borderBottomColor:eb.colors("borderBottomColor"),borderBlockEndColor:eb.colors("borderBlockEndColor"),borderBottomStyle:eb.borderStyles("borderBottomStyle"),borderBlockEndStyle:eb.borderStyles("borderBlockEndStyle"),borderLeftWidth:eb.borderWidths("borderLeftWidth"),borderInlineStartWidth:eb.borderWidths("borderInlineStartWidth"),borderLeftColor:eb.colors("borderLeftColor"),borderInlineStartColor:eb.colors("borderInlineStartColor"),borderLeftStyle:eb.borderStyles("borderLeftStyle"),borderInlineStartStyle:eb.borderStyles("borderInlineStartStyle"),borderRightWidth:eb.borderWidths("borderRightWidth"),borderInlineEndWidth:eb.borderWidths("borderInlineEndWidth"),borderRightColor:eb.colors("borderRightColor"),borderInlineEndColor:eb.colors("borderInlineEndColor"),borderRightStyle:eb.borderStyles("borderRightStyle"),borderInlineEndStyle:eb.borderStyles("borderInlineEndStyle"),borderTopRadius:eb.radii(["borderTopLeftRadius","borderTopRightRadius"]),borderBottomRadius:eb.radii(["borderBottomLeftRadius","borderBottomRightRadius"]),borderLeftRadius:eb.radii(["borderTopLeftRadius","borderBottomLeftRadius"]),borderRightRadius:eb.radii(["borderTopRightRadius","borderBottomRightRadius"])};Object.assign(e_,{rounded:e_.borderRadius,roundedTop:e_.borderTopRadius,roundedTopLeft:e_.borderTopLeftRadius,roundedTopRight:e_.borderTopRightRadius,roundedTopStart:e_.borderStartStartRadius,roundedTopEnd:e_.borderStartEndRadius,roundedBottom:e_.borderBottomRadius,roundedBottomLeft:e_.borderBottomLeftRadius,roundedBottomRight:e_.borderBottomRightRadius,roundedBottomStart:e_.borderEndStartRadius,roundedBottomEnd:e_.borderEndEndRadius,roundedLeft:e_.borderLeftRadius,roundedRight:e_.borderRightRadius,roundedStart:e_.borderInlineStartRadius,roundedEnd:e_.borderInlineEndRadius,borderStart:e_.borderInlineStart,borderEnd:e_.borderInlineEnd,borderTopStartRadius:e_.borderStartStartRadius,borderTopEndRadius:e_.borderStartEndRadius,borderBottomStartRadius:e_.borderEndStartRadius,borderBottomEndRadius:e_.borderEndEndRadius,borderStartRadius:e_.borderInlineStartRadius,borderEndRadius:e_.borderInlineEndRadius,borderStartWidth:e_.borderInlineStartWidth,borderEndWidth:e_.borderInlineEndWidth,borderStartColor:e_.borderInlineStartColor,borderEndColor:e_.borderInlineEndColor,borderStartStyle:e_.borderInlineStartStyle,borderEndStyle:e_.borderInlineEndStyle});var ew={color:eb.colors("color"),textColor:eb.colors("color"),fill:eb.colors("fill"),stroke:eb.colors("stroke")},eE={boxShadow:eb.shadows("boxShadow"),mixBlendMode:!0,blendMode:eb.prop("mixBlendMode"),backgroundBlendMode:!0,bgBlendMode:eb.prop("backgroundBlendMode"),opacity:!0};Object.assign(eE,{shadow:eE.boxShadow});var eS={filter:{transform:em.filter},blur:eb.blur("--chakra-blur"),brightness:eb.propT("--chakra-brightness",em.brightness),contrast:eb.propT("--chakra-contrast",em.contrast),hueRotate:eb.degreeT("--chakra-hue-rotate"),invert:eb.propT("--chakra-invert",em.invert),saturate:eb.propT("--chakra-saturate",em.saturate),dropShadow:eb.propT("--chakra-drop-shadow",em.dropShadow),backdropFilter:{transform:em.backdropFilter},backdropBlur:eb.blur("--chakra-backdrop-blur"),backdropBrightness:eb.propT("--chakra-backdrop-brightness",em.brightness),backdropContrast:eb.propT("--chakra-backdrop-contrast",em.contrast),backdropHueRotate:eb.degreeT("--chakra-backdrop-hue-rotate"),backdropInvert:eb.propT("--chakra-backdrop-invert",em.invert),backdropSaturate:eb.propT("--chakra-backdrop-saturate",em.saturate)},ex={alignItems:!0,alignContent:!0,justifyItems:!0,justifyContent:!0,flexWrap:!0,flexDirection:{transform:em.flexDirection},flex:!0,flexFlow:!0,flexGrow:!0,flexShrink:!0,flexBasis:eb.sizes("flexBasis"),justifySelf:!0,alignSelf:!0,order:!0,placeItems:!0,placeContent:!0,placeSelf:!0,gap:eb.space("gap"),rowGap:eb.space("rowGap"),columnGap:eb.space("columnGap")};Object.assign(ex,{flexDir:ex.flexDirection});var ek={gridGap:eb.space("gridGap"),gridColumnGap:eb.space("gridColumnGap"),gridRowGap:eb.space("gridRowGap"),gridColumn:!0,gridRow:!0,gridAutoFlow:!0,gridAutoColumns:!0,gridColumnStart:!0,gridColumnEnd:!0,gridRowStart:!0,gridRowEnd:!0,gridAutoRows:!0,gridTemplate:!0,gridTemplateColumns:!0,gridTemplateRows:!0,gridTemplateAreas:!0,gridArea:!0},eC={appearance:!0,cursor:!0,resize:!0,userSelect:!0,pointerEvents:!0,outline:{transform:em.outline},outlineOffset:!0,outlineColor:eb.colors("outlineColor")},eA={width:eb.sizesT("width"),inlineSize:eb.sizesT("inlineSize"),height:eb.sizes("height"),blockSize:eb.sizes("blockSize"),boxSize:eb.sizes(["width","height"]),minWidth:eb.sizes("minWidth"),minInlineSize:eb.sizes("minInlineSize"),minHeight:eb.sizes("minHeight"),minBlockSize:eb.sizes("minBlockSize"),maxWidth:eb.sizes("maxWidth"),maxInlineSize:eb.sizes("maxInlineSize"),maxHeight:eb.sizes("maxHeight"),maxBlockSize:eb.sizes("maxBlockSize"),overflow:!0,overflowX:!0,overflowY:!0,overscrollBehavior:!0,overscrollBehaviorX:!0,overscrollBehaviorY:!0,display:!0,aspectRatio:!0,hideFrom:{scale:"breakpoints",transform:(c,l)=>{var et,eo,es;let ec=null!=(es=null==(eo=null==(et=l.__breakpoints)?void 0:et.get(c))?void 0:eo.minW)?es:c,el=`@media screen and (min-width: ${ec})`;return{[el]:{display:"none"}}}},hideBelow:{scale:"breakpoints",transform:(c,l)=>{var et,eo,es;let ec=null!=(es=null==(eo=null==(et=l.__breakpoints)?void 0:et.get(c))?void 0:eo._minW)?es:c,el=`@media screen and (max-width: ${ec})`;return{[el]:{display:"none"}}}},verticalAlign:!0,boxSizing:!0,boxDecorationBreak:!0,float:eb.propT("float",em.float),objectFit:!0,objectPosition:!0,visibility:!0,isolation:!0};Object.assign(eA,{w:eA.width,h:eA.height,minW:eA.minWidth,maxW:eA.maxWidth,minH:eA.minHeight,maxH:eA.maxHeight,overscroll:eA.overscrollBehavior,overscrollX:eA.overscrollBehaviorX,overscrollY:eA.overscrollBehaviorY});var eI={listStyleType:!0,listStylePosition:!0,listStylePos:eb.prop("listStylePosition"),listStyleImage:!0,listStyleImg:eb.prop("listStyleImage")},eP=(c=>{let l=new WeakMap;return(et,eo,es,ec)=>{if(void 0===et)return c(et,eo,es);l.has(et)||l.set(et,new Map);let el=l.get(et);if(el.has(eo))return el.get(eo);let ed=c(et,eo,es,ec);return el.set(eo,ed),ed}})(function(c,l,et,eo){let es="string"==typeof l?l.split("."):[l];for(eo=0;eo{let eo={},es=eP(c,l,{});for(let c in es){let l=c in et&&null!=et[c];l||(eo[c]=es[c])}return eo},eT={position:!0,pos:eb.prop("position"),zIndex:eb.prop("zIndex","zIndices"),inset:eb.spaceT("inset"),insetX:eb.spaceT(["left","right"]),insetInline:eb.spaceT("insetInline"),insetY:eb.spaceT(["top","bottom"]),insetBlock:eb.spaceT("insetBlock"),top:eb.spaceT("top"),insetBlockStart:eb.spaceT("insetBlockStart"),bottom:eb.spaceT("bottom"),insetBlockEnd:eb.spaceT("insetBlockEnd"),left:eb.spaceT("left"),insetInlineStart:eb.logical({scale:"space",property:{ltr:"left",rtl:"right"}}),right:eb.spaceT("right"),insetInlineEnd:eb.logical({scale:"space",property:{ltr:"right",rtl:"left"}})};Object.assign(eT,{insetStart:eT.insetInlineStart,insetEnd:eT.insetInlineEnd});var eN={ring:{transform:em.ring},ringColor:eb.colors("--chakra-ring-color"),ringOffset:eb.prop("--chakra-ring-offset-width"),ringOffsetColor:eb.colors("--chakra-ring-offset-color"),ringInset:eb.prop("--chakra-ring-inset")},eM={margin:eb.spaceT("margin"),marginTop:eb.spaceT("marginTop"),marginBlockStart:eb.spaceT("marginBlockStart"),marginRight:eb.spaceT("marginRight"),marginInlineEnd:eb.spaceT("marginInlineEnd"),marginBottom:eb.spaceT("marginBottom"),marginBlockEnd:eb.spaceT("marginBlockEnd"),marginLeft:eb.spaceT("marginLeft"),marginInlineStart:eb.spaceT("marginInlineStart"),marginX:eb.spaceT(["marginInlineStart","marginInlineEnd"]),marginInline:eb.spaceT("marginInline"),marginY:eb.spaceT(["marginTop","marginBottom"]),marginBlock:eb.spaceT("marginBlock"),padding:eb.space("padding"),paddingTop:eb.space("paddingTop"),paddingBlockStart:eb.space("paddingBlockStart"),paddingRight:eb.space("paddingRight"),paddingBottom:eb.space("paddingBottom"),paddingBlockEnd:eb.space("paddingBlockEnd"),paddingLeft:eb.space("paddingLeft"),paddingInlineStart:eb.space("paddingInlineStart"),paddingInlineEnd:eb.space("paddingInlineEnd"),paddingX:eb.space(["paddingInlineStart","paddingInlineEnd"]),paddingInline:eb.space("paddingInline"),paddingY:eb.space(["paddingTop","paddingBottom"]),paddingBlock:eb.space("paddingBlock")};Object.assign(eM,{m:eM.margin,mt:eM.marginTop,mr:eM.marginRight,me:eM.marginInlineEnd,marginEnd:eM.marginInlineEnd,mb:eM.marginBottom,ml:eM.marginLeft,ms:eM.marginInlineStart,marginStart:eM.marginInlineStart,mx:eM.marginX,my:eM.marginY,p:eM.padding,pt:eM.paddingTop,py:eM.paddingY,px:eM.paddingX,pb:eM.paddingBottom,pl:eM.paddingLeft,ps:eM.paddingInlineStart,paddingStart:eM.paddingInlineStart,pr:eM.paddingRight,pe:eM.paddingInlineEnd,paddingEnd:eM.paddingInlineEnd});var e$={textDecorationColor:eb.colors("textDecorationColor"),textDecoration:!0,textDecor:{property:"textDecoration"},textDecorationLine:!0,textDecorationStyle:!0,textDecorationThickness:!0,textUnderlineOffset:!0,textShadow:eb.shadows("textShadow")},eB={clipPath:!0,transform:eb.propT("transform",em.transform),transformOrigin:!0,translateX:eb.spaceT("--chakra-translate-x"),translateY:eb.spaceT("--chakra-translate-y"),skewX:eb.degreeT("--chakra-skew-x"),skewY:eb.degreeT("--chakra-skew-y"),scaleX:eb.prop("--chakra-scale-x"),scaleY:eb.prop("--chakra-scale-y"),scale:eb.prop(["--chakra-scale-x","--chakra-scale-y"]),rotate:eb.degreeT("--chakra-rotate")},eD={transition:!0,transitionDelay:!0,animation:!0,willChange:!0,transitionDuration:eb.prop("transitionDuration","transition.duration"),transitionProperty:eb.prop("transitionProperty","transition.property"),transitionTimingFunction:eb.prop("transitionTimingFunction","transition.easing")},ej={fontFamily:eb.prop("fontFamily","fonts"),fontSize:eb.prop("fontSize","fontSizes",em.px),fontWeight:eb.prop("fontWeight","fontWeights"),lineHeight:eb.prop("lineHeight","lineHeights"),letterSpacing:eb.prop("letterSpacing","letterSpacings"),textAlign:!0,fontStyle:!0,textIndent:!0,wordBreak:!0,overflowWrap:!0,textOverflow:!0,textTransform:!0,whiteSpace:!0,isTruncated:{transform(c){if(!0===c)return{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}}},noOfLines:{static:{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:"var(--chakra-line-clamp)"},property:"--chakra-line-clamp"}},eL={scrollBehavior:!0,scrollSnapAlign:!0,scrollSnapStop:!0,scrollSnapType:!0,scrollMargin:eb.spaceT("scrollMargin"),scrollMarginTop:eb.spaceT("scrollMarginTop"),scrollMarginBottom:eb.spaceT("scrollMarginBottom"),scrollMarginLeft:eb.spaceT("scrollMarginLeft"),scrollMarginRight:eb.spaceT("scrollMarginRight"),scrollMarginX:eb.spaceT(["scrollMarginLeft","scrollMarginRight"]),scrollMarginY:eb.spaceT(["scrollMarginTop","scrollMarginBottom"]),scrollPadding:eb.spaceT("scrollPadding"),scrollPaddingTop:eb.spaceT("scrollPaddingTop"),scrollPaddingBottom:eb.spaceT("scrollPaddingBottom"),scrollPaddingLeft:eb.spaceT("scrollPaddingLeft"),scrollPaddingRight:eb.spaceT("scrollPaddingRight"),scrollPaddingX:eb.spaceT(["scrollPaddingLeft","scrollPaddingRight"]),scrollPaddingY:eb.spaceT(["scrollPaddingTop","scrollPaddingBottom"])};function resolveReference(c){return(0,eo.Kn)(c)&&c.reference?c.reference:String(c)}var toExpression=(c,...l)=>l.map(resolveReference).join(` ${c} `).replace(/calc/g,""),add=(...c)=>`calc(${toExpression("+",...c)})`,subtract=(...c)=>`calc(${toExpression("-",...c)})`,multiply=(...c)=>`calc(${toExpression("*",...c)})`,divide=(...c)=>`calc(${toExpression("/",...c)})`,negate=c=>{let l=resolveReference(c);return null==l||Number.isNaN(parseFloat(l))?multiply(l,-1):String(l).startsWith("-")?String(l).slice(1):`-${l}`},eF=Object.assign(c=>({add:(...l)=>eF(add(c,...l)),subtract:(...l)=>eF(subtract(c,...l)),multiply:(...l)=>eF(multiply(c,...l)),divide:(...l)=>eF(divide(c,...l)),negate:()=>eF(negate(c)),toString:()=>c.toString()}),{add,subtract,multiply,divide,negate});function cssVar(c,l,et){let eo=function(c,l=""){return function(c){let l=function(c,l="-"){return c.replace(/\s+/g,l)}(c.toString());return(function(c){if(c.includes("\\."))return c;let l=!Number.isInteger(parseFloat(c.toString()));return l?c.replace(".","\\."):c})(l).replace(/[!-,/:-@[-^`{-~]/g,"\\$&")}(`--${function(c,l=""){return[l,c].filter(Boolean).join("-")}(c,l)}`)}(c,et);return{variable:eo,reference:`var(${eo}${l?`, ${l}`:""})`}}function defineCssVars(c,l){let et={};for(let eo of l){if(Array.isArray(eo)){let[l,es]=eo;et[l]=cssVar(`${c}-${l}`,es);continue}et[eo]=cssVar(`${c}-${eo}`)}return et}function px(c){if(null==c)return c;let{unitless:l}=function(c){let l=parseFloat(c.toString()),et=c.toString().replace(String(l),"");return{unitless:!et,value:l,unit:et}}(c);return l||"number"==typeof c?`${c}px`:c}var sortByBreakpointValue=(c,l)=>parseInt(c[1],10)>parseInt(l[1],10)?1:-1,sortBps=c=>Object.fromEntries(Object.entries(c).sort(sortByBreakpointValue));function normalize(c){let l=sortBps(c);return Object.assign(Object.values(l),l)}function subtract2(c){var l;return c?"number"==typeof(c=null!=(l=px(c))?l:c)?`${c+-.02}`:c.replace(/(\d+\.?\d*)/u,c=>`${parseFloat(c)+-.02}`):c}function toMediaQueryString(c,l){let et=["@media screen"];return c&&et.push("and",`(min-width: ${px(c)})`),l&&et.push("and",`(max-width: ${px(l)})`),et.join(" ")}var eU={hover:(c,l)=>`${c}:hover ${l}, ${c}[data-hover] ${l}`,focus:(c,l)=>`${c}:focus ${l}, ${c}[data-focus] ${l}`,focusVisible:(c,l)=>`${c}:focus-visible ${l}`,focusWithin:(c,l)=>`${c}:focus-within ${l}`,active:(c,l)=>`${c}:active ${l}, ${c}[data-active] ${l}`,disabled:(c,l)=>`${c}:disabled ${l}, ${c}[data-disabled] ${l}`,invalid:(c,l)=>`${c}:invalid ${l}, ${c}[data-invalid] ${l}`,checked:(c,l)=>`${c}:checked ${l}, ${c}[data-checked] ${l}`,placeholderShown:(c,l)=>`${c}:placeholder-shown ${l}`},toGroup=c=>merge(l=>c(l,"&"),"[role=group]","[data-group]",".group"),toPeer=c=>merge(l=>c(l,"~ &"),"[data-peer]",".peer"),merge=(c,...l)=>l.map(c).join(", "),ez={_hover:"&:hover, &[data-hover]",_active:"&:active, &[data-active]",_focus:"&:focus, &[data-focus]",_highlighted:"&[data-highlighted]",_focusWithin:"&:focus-within",_focusVisible:"&:focus-visible, &[data-focus-visible]",_disabled:"&:disabled, &[disabled], &[aria-disabled=true], &[data-disabled]",_readOnly:"&[aria-readonly=true], &[readonly], &[data-readonly]",_before:"&::before",_after:"&::after",_empty:"&:empty",_expanded:"&[aria-expanded=true], &[data-expanded]",_checked:"&[aria-checked=true], &[data-checked]",_grabbed:"&[aria-grabbed=true], &[data-grabbed]",_pressed:"&[aria-pressed=true], &[data-pressed]",_invalid:"&[aria-invalid=true], &[data-invalid]",_valid:"&[data-valid], &[data-state=valid]",_loading:"&[data-loading], &[aria-busy=true]",_selected:"&[aria-selected=true], &[data-selected]",_hidden:"&[hidden], &[data-hidden]",_autofill:"&:-webkit-autofill",_even:"&:nth-of-type(even)",_odd:"&:nth-of-type(odd)",_first:"&:first-of-type",_firstLetter:"&::first-letter",_last:"&:last-of-type",_notFirst:"&:not(:first-of-type)",_notLast:"&:not(:last-of-type)",_visited:"&:visited",_activeLink:"&[aria-current=page]",_activeStep:"&[aria-current=step]",_indeterminate:"&:indeterminate, &[aria-checked=mixed], &[data-indeterminate]",_groupHover:toGroup(eU.hover),_peerHover:toPeer(eU.hover),_groupFocus:toGroup(eU.focus),_peerFocus:toPeer(eU.focus),_groupFocusVisible:toGroup(eU.focusVisible),_peerFocusVisible:toPeer(eU.focusVisible),_groupActive:toGroup(eU.active),_peerActive:toPeer(eU.active),_groupDisabled:toGroup(eU.disabled),_peerDisabled:toPeer(eU.disabled),_groupInvalid:toGroup(eU.invalid),_peerInvalid:toPeer(eU.invalid),_groupChecked:toGroup(eU.checked),_peerChecked:toPeer(eU.checked),_groupFocusWithin:toGroup(eU.focusWithin),_peerFocusWithin:toPeer(eU.focusWithin),_peerPlaceholderShown:toPeer(eU.placeholderShown),_placeholder:"&::placeholder",_placeholderShown:"&:placeholder-shown",_fullScreen:"&:fullscreen",_selection:"&::selection",_rtl:"[dir=rtl] &, &[dir=rtl]",_ltr:"[dir=ltr] &, &[dir=ltr]",_mediaDark:"@media (prefers-color-scheme: dark)",_mediaReduceMotion:"@media (prefers-reduced-motion: reduce)",_dark:".chakra-ui-dark &:not([data-theme]),[data-theme=dark] &:not([data-theme]),&[data-theme=dark]",_light:".chakra-ui-light &:not([data-theme]),[data-theme=light] &:not([data-theme]),&[data-theme=light]",_horizontal:"&[data-orientation=horizontal]",_vertical:"&[data-orientation=vertical]"},eH=Object.keys(ez);function tokenToCssVar(c,l){return cssVar(String(c).replace(/\./g,"-"),void 0,l)}function walkObject(c,l,et={}){let{stop:eo,getKey:es}=et;return function inner(c,et=[]){var ec;if("object"==typeof c&&null!=c&&!Array.isArray(c)||Array.isArray(c)){let el={};for(let[ed,eh]of Object.entries(c)){let ef=null!=(ec=null==es?void 0:es(ed))?ec:ed,ep=[...et,ef];if(null==eo?void 0:eo(c,ep))return l(c,et);el[ef]=inner(eh,ep)}return el}return l(c,et)}(c)}var eW=["colors","borders","borderWidths","borderStyles","fonts","fontSizes","fontWeights","gradients","letterSpacings","lineHeights","radii","space","shadows","sizes","zIndices","transition","blur","breakpoints"],isSemanticCondition=c=>eH.includes(c)||"default"===c;function toCSSVar(c){var l;let et=function(c){let{__cssMap:l,__cssVars:et,__breakpoints:eo,...es}=c;return es}(c),ec=function(c,l){let et={};for(let eo of l)eo in c&&(et[eo]=c[eo]);return et}(et,eW),el=et.semanticTokens,ed=function({tokens:c,semanticTokens:l}){let et={};return walkObject(c,(c,l)=>{null!=c&&(et[l.join(".")]={isSemantic:!1,value:c})}),walkObject(l,(c,l)=>{null!=c&&(et[l.join(".")]={isSemantic:!0,value:c})},{stop:c=>Object.keys(c).every(isSemanticCondition)}),et}({tokens:ec,semanticTokens:el}),eh=null==(l=et.config)?void 0:l.cssVarPrefix,{cssMap:ef,cssVars:ep}=function(c,l){let et={},ec={};for(let[el,ed]of Object.entries(c)){let{isSemantic:eh,value:ef}=ed,{variable:ep,reference:eg}=tokenToCssVar(el,null==l?void 0:l.cssVarPrefix);if(!eh){if(el.startsWith("space")){let c=el.split("."),[l,...et]=c,eo=`${l}.-${et.join(".")}`,es=eF.negate(ef),ed=eF.negate(eg);ec[eo]={value:es,var:ep,varRef:ed}}et[ep]=ef,ec[el]={value:ef,var:ep,varRef:eg};continue}let lookupToken=et=>{let eo=String(el).split(".")[0],es=[eo,et].join("."),ec=c[es];if(!ec)return et;let{reference:ed}=tokenToCssVar(es,null==l?void 0:l.cssVarPrefix);return ed},em=(0,eo.Kn)(ef)?ef:{default:ef};et=es(et,Object.entries(em).reduce((c,[l,et])=>{var eo;if(!et)return c;let es=lookupToken(`${et}`);if("default"===l)return c[ep]=es,c;let ec=null!=(eo=null==ez?void 0:ez[l])?eo:l;return c[ec]={[ep]:es},c},{})),ec[el]={value:eg,var:ep,varRef:eg}}return{cssVars:et,cssMap:ec}}(ed,{cssVarPrefix:eh});return Object.assign(et,{__cssVars:{"--chakra-ring-inset":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-ring-offset-width":"0px","--chakra-ring-offset-color":"#fff","--chakra-ring-color":"rgba(66, 153, 225, 0.6)","--chakra-ring-offset-shadow":"0 0 #0000","--chakra-ring-shadow":"0 0 #0000","--chakra-space-x-reverse":"0","--chakra-space-y-reverse":"0",...ep},__cssMap:ef,__breakpoints:function(c){var l;if(!c)return null;c.base=null!=(l=c.base)?l:"0px";let et=normalize(c),es=Object.entries(c).sort(sortByBreakpointValue).map(([c,l],et,eo)=>{var es;let[,ec]=null!=(es=eo[et+1])?es:[];return ec=parseFloat(ec)>0?subtract2(ec):void 0,{_minW:subtract2(l),breakpoint:c,minW:l,maxW:ec,maxWQuery:toMediaQueryString(null,ec),minWQuery:toMediaQueryString(l),minMaxQuery:toMediaQueryString(l,ec)}}),ec=function(c){let l=Object.keys(sortBps(c));return new Set(l)}(c),el=Array.from(ec.values());return{keys:ec,normalized:et,isResponsive(c){let l=Object.keys(c);return l.length>0&&l.every(c=>ec.has(c))},asObject:sortBps(c),asArray:normalize(c),details:es,get:c=>es.find(l=>l.breakpoint===c),media:[null,...et.map(c=>toMediaQueryString(c)).slice(1)],toArrayValue(c){if(!(0,eo.Kn)(c))throw Error("toArrayValue: value must be an object");let l=el.map(l=>{var et;return null!=(et=c[l])?et:null});for(;null===function(c){let l=null==c?0:c.length;return l?c[l-1]:void 0}(l);)l.pop();return l},toObjectValue(c){if(!Array.isArray(c))throw Error("toObjectValue: value must be an array");return c.reduce((c,l,et)=>{let eo=el[et];return null!=eo&&null!=l&&(c[eo]=l),c},{})}}}(et.breakpoints)}),et}var eV=es({},ey,e_,ew,ex,eA,eS,eN,eC,ek,{srOnly:{transform:c=>!0===c?eR:"focusable"===c?eO:{}},layerStyle:{processResult:!0,transform:(c,l,et)=>getWithPriority(l,`layerStyles.${c}`,et)},textStyle:{processResult:!0,transform:(c,l,et)=>getWithPriority(l,`textStyles.${c}`,et)},apply:{processResult:!0,transform:(c,l,et)=>getWithPriority(l,c,et)}},eT,eE,eM,eL,ej,e$,eB,eI,eD),eG=Object.keys(Object.assign({},eM,eA,ex,ek,eT)),eK=[...Object.keys(eV),...eH],eJ={...eV,...ez},isStyleProp=c=>c in eJ,expandResponsive=c=>l=>{if(!l.__breakpoints)return c;let{isResponsive:et,toArrayValue:es,media:ec}=l.__breakpoints,el={};for(let ed in c){let eh=(0,eo.Pu)(c[ed],l);if(null==eh)continue;if(!Array.isArray(eh=(0,eo.Kn)(eh)&&et(eh)?es(eh):eh)){el[ed]=eh;continue}let ef=eh.slice(0,ec.length).length;for(let c=0;cc.startsWith("--")&&"string"==typeof l&&!/^var\(--.+\)$/.test(l),resolveTokenValue=(c,l)=>{var et,eo;if(null==l)return l;let getVar=l=>{var et,eo;return null==(eo=null==(et=c.__cssMap)?void 0:et[l])?void 0:eo.varRef},getValue=c=>{var l;return null!=(l=getVar(c))?l:c},[es,ec]=function(c){let l=[],et="",eo=!1;for(let es=0;esl=>{let et=function(c){let{configs:l={},pseudos:et={},theme:ec}=c,css2=(c,el=!1)=>{var ed,eh,ef;let ep=(0,eo.Pu)(c,ec),eg=expandResponsive(ep)(ec),em={};for(let c in eg){let eb=eg[c],ey=(0,eo.Pu)(eb,ec);c in et&&(c=et[c]),isCSSVariableTokenValue(c,ey)&&(ey=resolveTokenValue(ec,ey));let e_=l[c];if(!0===e_&&(e_={property:c}),(0,eo.Kn)(ey)){em[c]=null!=(ed=em[c])?ed:{},em[c]=es({},em[c],css2(ey,!0));continue}let ew=null!=(ef=null==(eh=null==e_?void 0:e_.transform)?void 0:eh.call(e_,ey,ec,ep))?ef:ey;ew=(null==e_?void 0:e_.processResult)?css2(ew,!0):ew;let eE=(0,eo.Pu)(null==e_?void 0:e_.property,ec);if(!el&&(null==e_?void 0:e_.static)){let c=(0,eo.Pu)(e_.static,ec);em=es({},em,c)}if(eE&&Array.isArray(eE)){for(let c of eE)em[c]=ew;continue}if(eE){"&"===eE&&(0,eo.Kn)(ew)?em=es({},em,ew):em[eE]=ew;continue}if((0,eo.Kn)(ew)){em=es({},em,ew);continue}em[c]=ew}return em};return css2}({theme:l,pseudos:ez,configs:eV});return et(c)};function defineStyle(c){return c}function defineStyleConfig(c){return c}function createMultiStyleConfigHelpers(c){return{definePartsStyle:c=>c,defineMultiStyleConfig:l=>({parts:c,...l})}}function resolveStyleConfig(c){return l=>{var et;let{variant:ec,size:el,theme:ed}=l,eh=function(c){let l=c.__breakpoints;return function(c,et,ec,el){var ed,eh,ef;if(!l)return;let ep={},eg=(ef=l.toArrayValue,Array.isArray(ec)?ec:(0,eo.Kn)(ec)?ef(ec):null!=ec?[ec]:void 0);if(!eg)return ep;let em=eg.length,eb=1===em,ey=!!c.parts;for(let ec=0;ec{es(ep,{[c]:eb?ew[c]:{[e_]:ew[c]}})});continue}if(!ey){eb?es(ep,ew):ep[e_]=ew;continue}ep[e_]=ew}}return ep}}(ed);return es({},(0,eo.Pu)(null!=(et=c.baseStyle)?et:{},l),eh(c,"sizes",el,l),eh(c,"variants",ec,l))}}function getCSSVar(c,l,et){var eo,es,ec;return null!=(ec=null==(es=null==(eo=c.__cssMap)?void 0:eo[`${l}.${et}`])?void 0:es.varRef)?ec:et}function omitThemingProps(c){return function(c,l=[]){let et=Object.assign({},c);for(let c of l)c in et&&delete et[c];return et}(c,["styleConfig","size","variant","colorScheme"])}},71479:function(c,l,et){"use strict";et.r(l),et.d(l,{styled:function(){return styled},toCSSObject:function(){return toCSSObject}});var eo,es=et(77876),ec=et(85035),el=et(50446),ed=et(19307),eh=et(62788),ef=et(13428),ep=et(2265),eg=et(67008),em=et(65673),eb=et(94645),ey=et(53597),e_=et(7599),ew=eg.Z,testOmitPropsOnComponent=function(c){return"theme"!==c},getDefaultShouldForwardProp=function(c){return"string"==typeof c&&c.charCodeAt(0)>96?ew:testOmitPropsOnComponent},composeShouldForwardProps=function(c,l,et){var eo;if(l){var es=l.shouldForwardProp;eo=c.__emotion_forwardProp&&es?function(l){return c.__emotion_forwardProp(l)&&es(l)}:es}return"function"!=typeof eo&&et&&(eo=c.__emotion_forwardProp),eo},Insertion=function(c){var l=c.cache,et=c.serialized,eo=c.isStringTag;return(0,eb.hC)(l,et,eo),(0,e_.L)(function(){return(0,eb.My)(l,et,eo)}),null},eE=(function createStyled(c,l){var et,eo,es=c.__emotion_real===c,ec=es&&c.__emotion_base||c;void 0!==l&&(et=l.label,eo=l.target);var el=composeShouldForwardProps(c,l,es),ed=el||getDefaultShouldForwardProp(ec),eh=!ed("as");return function(){var eg=arguments,e_=es&&void 0!==c.__emotion_styles?c.__emotion_styles.slice(0):[];if(void 0!==et&&e_.push("label:"+et+";"),null==eg[0]||void 0===eg[0].raw)e_.push.apply(e_,eg);else{e_.push(eg[0][0]);for(var ew=eg.length,eE=1;eEl=>{let{theme:et,css:eo,__css:es,sx:ec,...ef}=l,ep=(0,ed.lw)(ef,(c,l)=>(0,el.ZR)(l)),eg=(0,eh.Pu)(c,l),em=function(c,...l){if(null==c)throw TypeError("Cannot convert undefined or null to object");let et={...c};for(let c of l)if(null!=c)for(let l in c)Object.prototype.hasOwnProperty.call(c,l)&&(l in et&&delete et[l],et[l]=c[l]);return et}({},es,eg,(0,ed.YU)(ep),ec),eb=(0,el.iv)(em)(l.theme);return eo?[eb,eo]:eb};function styled(c,l){let{baseStyle:et,...eo}=null!=l?l:{};eo.shouldForwardProp||(eo.shouldForwardProp=es.shouldForwardProp);let el=toCSSObject({baseStyle:et}),ed=eS(c,eo)(el),eh=ep.forwardRef(function(c,l){let{colorMode:et,forced:eo}=(0,ec.If)();return ep.createElement(ed,{ref:l,"data-theme":eo?et:void 0,...c})});return eh}},12704:function(c,l,et){"use strict";et.r(l),et.d(l,{getToken:function(){return getToken},useChakra:function(){return useChakra},useToken:function(){return useToken}});var eo=et(90865),es=et(85035);function useChakra(){let c=(0,es.If)(),l=(0,eo.useTheme)();return{...c,theme:l}}function useToken(c,l,et){let es=(0,eo.useTheme)();return getToken(c,l,et)(es)}function getToken(c,l,et){let eo=Array.isArray(l)?l:[l],es=Array.isArray(et)?et:[et];return et=>{let ec=es.filter(Boolean),el=eo.map((l,eo)=>{var es,el;if("breakpoints"===c)return function(c,l,et){var eo,es;if(null==l)return l;let getValue=l=>{var et,eo;return null==(eo=null==(et=c.__breakpoints)?void 0:et.asArray)?void 0:eo[l]};return null!=(es=null!=(eo=getValue(l))?eo:getValue(et))?es:et}(et,l,null!=(es=ec[eo])?es:l);let ed=`${c}.${l}`;return function(c,l,et){var eo,es;if(null==l)return l;let getValue=l=>{var et,eo;return null==(eo=null==(et=c.__cssMap)?void 0:et[l])?void 0:eo.value};return null!=(es=null!=(eo=getValue(l))?eo:getValue(et))?es:et}(et,ed,null!=(el=ec[eo])?el:l)});return Array.isArray(l)?el:el[0]}}},92013:function(c,l,et){"use strict";et.r(l),et.d(l,{useComponentStyles__unstable:function(){return useComponentStyles__unstable},useMultiStyleConfig:function(){return useMultiStyleConfig},useStyleConfig:function(){return useStyleConfig}});var eo=et(12704),es=et(50446),ec=et(16465),el=["borders","breakpoints","colors","components","config","direction","fonts","fontSizes","fontWeights","letterSpacings","lineHeights","radii","shadows","sizes","space","styles","transition","zIndices"],ed=et(62952),eh=et(94216);function isFunction(c){return"function"==typeof c}var createExtendTheme=c=>function(...l){var et;let eo=[...l],es=l[l.length-1];return(et=es,(0,ec.Kn)(et)&&el.every(c=>Object.prototype.hasOwnProperty.call(et,c))&&eo.length>1)?eo=eo.slice(0,eo.length-1):es=c,(function(...c){return l=>c.reduce((c,l)=>l(c),l)})(...eo.map(c=>l=>isFunction(c)?c(l):mergeThemeOverride(l,c)))(es)};function mergeThemeOverride(...c){return eh({},...c,mergeThemeCustomizer)}function mergeThemeCustomizer(c,l,et,eo){if((isFunction(c)||isFunction(l))&&Object.prototype.hasOwnProperty.call(eo,et))return(...et)=>{let eo=isFunction(c)?c(...et):c,es=isFunction(l)?l(...et):l;return eh({},eo,es,mergeThemeCustomizer)}}createExtendTheme(ed.rS),createExtendTheme(ed.wE);var ef=et(19307),ep=et(2265),eg=et(17966);function useStyleConfigImpl(c,l={}){var et;let{styleConfig:ec,...el}=l,{theme:ed,colorMode:em}=(0,eo.useChakra)(),eb=c?(0,ef.Wf)(ed,`components.${c}`):void 0,ey=ec||eb,e_=eh({theme:ed,colorMode:em},null!=(et=null==ey?void 0:ey.defaultProps)?et:{},(0,ef.YU)((0,ef.CE)(el,["children"]))),ew=(0,ep.useRef)({});if(ey){let c=(0,es.Ud)(ey),l=c(e_),et=eg(ew.current,l);et||(ew.current=l)}return ew.current}function useStyleConfig(c,l={}){return useStyleConfigImpl(c,l)}function useMultiStyleConfig(c,l={}){return useStyleConfigImpl(c,l)}function useComponentStyles__unstable(c,l){var et;let{baseConfig:es,...ec}=l,{theme:el}=(0,eo.useChakra)(),ed=null==(et=el.components)?void 0:et[c],eh=ed?mergeThemeOverride(ed,es):es;return useStyleConfigImpl(null,{...ec,styleConfig:eh})}},77876:function(c,l,et){"use strict";et.r(l),et.d(l,{shouldForwardProp:function(){return shouldForwardProp}});var eo=et(50446),es=new Set([...eo.cC,"textStyle","layerStyle","apply","noOfLines","focusBorderColor","errorBorderColor","as","__css","css","sx"]),ec=new Set(["htmlWidth","htmlHeight","htmlSize","htmlTranslate"]);function shouldForwardProp(c){return ec.has(c)||!es.has(c)}},90865:function(c,l,et){"use strict";et.r(l),et.d(l,{useTheme:function(){return useTheme}});var eo=et(65673),es=et(2265);function useTheme(){let c=(0,es.useContext)(eo.T);if(!c)throw Error("useTheme: `theme` is undefined. Seems you forgot to wrap your app in `` or ``");return c}},23145:function(c,l,et){"use strict";et.r(l),et.d(l,{chakra:function(){return es}});var eo=et(71479),es=function(){let c=new Map;return new Proxy(eo.styled,{apply:(c,l,et)=>(0,eo.styled)(...et),get:(l,et)=>(c.has(et)||c.set(et,(0,eo.styled)(et)),c.get(et))})}()},58250:function(c,l,et){"use strict";et.r(l),et.d(l,{forwardRef:function(){return forwardRef}});var eo=et(2265);function forwardRef(c){return(0,eo.forwardRef)(c)}},62952:function(c,l,et){"use strict";et.d(l,{wE:function(){return oJ},rS:function(){return oK}});var eo,es,ec,el,ed,eh,ef,ep,eg,em,eb,ey,e_,ew,eE,eS,ex,ek,eC,eA,eI,eP,eR,eO={letterSpacings:{tighter:"-0.05em",tight:"-0.025em",normal:"0",wide:"0.025em",wider:"0.05em",widest:"0.1em"},lineHeights:{normal:"normal",none:1,shorter:1.25,short:1.375,base:1.5,tall:1.625,taller:"2",3:".75rem",4:"1rem",5:"1.25rem",6:"1.5rem",7:"1.75rem",8:"2rem",9:"2.25rem",10:"2.5rem"},fontWeights:{hairline:100,thin:200,light:300,normal:400,medium:500,semibold:600,bold:700,extrabold:800,black:900},fonts:{heading:'-apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',body:'-apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',mono:'SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace'},fontSizes:{"3xs":"0.45rem","2xs":"0.625rem",xs:"0.75rem",sm:"0.875rem",md:"1rem",lg:"1.125rem",xl:"1.25rem","2xl":"1.5rem","3xl":"1.875rem","4xl":"2.25rem","5xl":"3rem","6xl":"3.75rem","7xl":"4.5rem","8xl":"6rem","9xl":"8rem"}},eT={px:"1px",.5:"0.125rem",1:"0.25rem",1.5:"0.375rem",2:"0.5rem",2.5:"0.625rem",3:"0.75rem",3.5:"0.875rem",4:"1rem",5:"1.25rem",6:"1.5rem",7:"1.75rem",8:"2rem",9:"2.25rem",10:"2.5rem",12:"3rem",14:"3.5rem",16:"4rem",20:"5rem",24:"6rem",28:"7rem",32:"8rem",36:"9rem",40:"10rem",44:"11rem",48:"12rem",52:"13rem",56:"14rem",60:"15rem",64:"16rem",72:"18rem",80:"20rem",96:"24rem"},eN={...eT,max:"max-content",min:"min-content",full:"100%","3xs":"14rem","2xs":"16rem",xs:"20rem",sm:"24rem",md:"28rem",lg:"32rem",xl:"36rem","2xl":"42rem","3xl":"48rem","4xl":"56rem","5xl":"64rem","6xl":"72rem","7xl":"80rem","8xl":"90rem",prose:"60ch",container:{sm:"640px",md:"768px",lg:"1024px",xl:"1280px"}},eM={breakpoints:{base:"0em",sm:"30em",md:"48em",lg:"62em",xl:"80em","2xl":"96em"},zIndices:{hide:-1,auto:"auto",base:0,docked:10,dropdown:1e3,sticky:1100,banner:1200,overlay:1300,modal:1400,popover:1500,skipLink:1600,toast:1700,tooltip:1800},radii:{none:"0",sm:"0.125rem",base:"0.25rem",md:"0.375rem",lg:"0.5rem",xl:"0.75rem","2xl":"1rem","3xl":"1.5rem",full:"9999px"},blur:{none:0,sm:"4px",base:"8px",md:"12px",lg:"16px",xl:"24px","2xl":"40px","3xl":"64px"},colors:{transparent:"transparent",current:"currentColor",black:"#000000",white:"#FFFFFF",whiteAlpha:{50:"rgba(255, 255, 255, 0.04)",100:"rgba(255, 255, 255, 0.06)",200:"rgba(255, 255, 255, 0.08)",300:"rgba(255, 255, 255, 0.16)",400:"rgba(255, 255, 255, 0.24)",500:"rgba(255, 255, 255, 0.36)",600:"rgba(255, 255, 255, 0.48)",700:"rgba(255, 255, 255, 0.64)",800:"rgba(255, 255, 255, 0.80)",900:"rgba(255, 255, 255, 0.92)"},blackAlpha:{50:"rgba(0, 0, 0, 0.04)",100:"rgba(0, 0, 0, 0.06)",200:"rgba(0, 0, 0, 0.08)",300:"rgba(0, 0, 0, 0.16)",400:"rgba(0, 0, 0, 0.24)",500:"rgba(0, 0, 0, 0.36)",600:"rgba(0, 0, 0, 0.48)",700:"rgba(0, 0, 0, 0.64)",800:"rgba(0, 0, 0, 0.80)",900:"rgba(0, 0, 0, 0.92)"},gray:{50:"#F7FAFC",100:"#EDF2F7",200:"#E2E8F0",300:"#CBD5E0",400:"#A0AEC0",500:"#718096",600:"#4A5568",700:"#2D3748",800:"#1A202C",900:"#171923"},red:{50:"#FFF5F5",100:"#FED7D7",200:"#FEB2B2",300:"#FC8181",400:"#F56565",500:"#E53E3E",600:"#C53030",700:"#9B2C2C",800:"#822727",900:"#63171B"},orange:{50:"#FFFAF0",100:"#FEEBC8",200:"#FBD38D",300:"#F6AD55",400:"#ED8936",500:"#DD6B20",600:"#C05621",700:"#9C4221",800:"#7B341E",900:"#652B19"},yellow:{50:"#FFFFF0",100:"#FEFCBF",200:"#FAF089",300:"#F6E05E",400:"#ECC94B",500:"#D69E2E",600:"#B7791F",700:"#975A16",800:"#744210",900:"#5F370E"},green:{50:"#F0FFF4",100:"#C6F6D5",200:"#9AE6B4",300:"#68D391",400:"#48BB78",500:"#38A169",600:"#2F855A",700:"#276749",800:"#22543D",900:"#1C4532"},teal:{50:"#E6FFFA",100:"#B2F5EA",200:"#81E6D9",300:"#4FD1C5",400:"#38B2AC",500:"#319795",600:"#2C7A7B",700:"#285E61",800:"#234E52",900:"#1D4044"},blue:{50:"#ebf8ff",100:"#bee3f8",200:"#90cdf4",300:"#63b3ed",400:"#4299e1",500:"#3182ce",600:"#2b6cb0",700:"#2c5282",800:"#2a4365",900:"#1A365D"},cyan:{50:"#EDFDFD",100:"#C4F1F9",200:"#9DECF9",300:"#76E4F7",400:"#0BC5EA",500:"#00B5D8",600:"#00A3C4",700:"#0987A0",800:"#086F83",900:"#065666"},purple:{50:"#FAF5FF",100:"#E9D8FD",200:"#D6BCFA",300:"#B794F4",400:"#9F7AEA",500:"#805AD5",600:"#6B46C1",700:"#553C9A",800:"#44337A",900:"#322659"},pink:{50:"#FFF5F7",100:"#FED7E2",200:"#FBB6CE",300:"#F687B3",400:"#ED64A6",500:"#D53F8C",600:"#B83280",700:"#97266D",800:"#702459",900:"#521B41"},linkedin:{50:"#E8F4F9",100:"#CFEDFB",200:"#9BDAF3",300:"#68C7EC",400:"#34B3E4",500:"#00A0DC",600:"#008CC9",700:"#0077B5",800:"#005E93",900:"#004471"},facebook:{50:"#E8F4F9",100:"#D9DEE9",200:"#B7C2DA",300:"#6482C0",400:"#4267B2",500:"#385898",600:"#314E89",700:"#29487D",800:"#223B67",900:"#1E355B"},messenger:{50:"#D0E6FF",100:"#B9DAFF",200:"#A2CDFF",300:"#7AB8FF",400:"#2E90FF",500:"#0078FF",600:"#0063D1",700:"#0052AC",800:"#003C7E",900:"#002C5C"},whatsapp:{50:"#dffeec",100:"#b9f5d0",200:"#90edb3",300:"#65e495",400:"#3cdd78",500:"#22c35e",600:"#179848",700:"#0c6c33",800:"#01421c",900:"#001803"},twitter:{50:"#E5F4FD",100:"#C8E9FB",200:"#A8DCFA",300:"#83CDF7",400:"#57BBF5",500:"#1DA1F2",600:"#1A94DA",700:"#1681BF",800:"#136B9E",900:"#0D4D71"},telegram:{50:"#E3F2F9",100:"#C5E4F3",200:"#A2D4EC",300:"#7AC1E4",400:"#47A9DA",500:"#0088CC",600:"#007AB8",700:"#006BA1",800:"#005885",900:"#003F5E"}},...eO,sizes:eN,shadows:{xs:"0 0 0 1px rgba(0, 0, 0, 0.05)",sm:"0 1px 2px 0 rgba(0, 0, 0, 0.05)",base:"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)",md:"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)",lg:"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)",xl:"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)","2xl":"0 25px 50px -12px rgba(0, 0, 0, 0.25)",outline:"0 0 0 3px rgba(66, 153, 225, 0.6)",inner:"inset 0 2px 4px 0 rgba(0,0,0,0.06)",none:"none","dark-lg":"rgba(0, 0, 0, 0.1) 0px 0px 0px 1px, rgba(0, 0, 0, 0.2) 0px 5px 10px, rgba(0, 0, 0, 0.4) 0px 15px 40px"},space:eT,borders:{none:0,"1px":"1px solid","2px":"2px solid","4px":"4px solid","8px":"8px solid"},transition:{property:{common:"background-color, border-color, color, fill, stroke, opacity, box-shadow, transform",colors:"background-color, border-color, color, fill, stroke",dimensions:"width, height",position:"left, right, top, bottom",background:"background-color, background-image, background-position"},easing:{"ease-in":"cubic-bezier(0.4, 0, 1, 1)","ease-out":"cubic-bezier(0, 0, 0.2, 1)","ease-in-out":"cubic-bezier(0.4, 0, 0.2, 1)"},duration:{"ultra-fast":"50ms",faster:"100ms",fast:"150ms",normal:"200ms",slow:"300ms",slower:"400ms","ultra-slow":"500ms"}}},e$=et(50446),{defineMultiStyleConfig:eB,definePartsStyle:eD}=(0,e$.D)(["stepper","step","title","description","indicator","separator","icon","number"]),ej=(0,e$.gJ)("stepper-indicator-size"),eL=(0,e$.gJ)("stepper-icon-size"),eF=(0,e$.gJ)("stepper-title-font-size"),eU=(0,e$.gJ)("stepper-description-font-size"),ez=(0,e$.gJ)("stepper-accent-color"),eH=eB({baseStyle:eD(({colorScheme:c})=>({stepper:{display:"flex",justifyContent:"space-between",gap:"4","&[data-orientation=vertical]":{flexDirection:"column",alignItems:"flex-start"},"&[data-orientation=horizontal]":{flexDirection:"row",alignItems:"center"},[ez.variable]:`colors.${c}.500`,_dark:{[ez.variable]:`colors.${c}.200`}},title:{fontSize:eF.reference,fontWeight:"medium"},description:{fontSize:eU.reference,color:"chakra-subtle-text"},number:{fontSize:eF.reference},step:{flexShrink:0,position:"relative",display:"flex",gap:"2","&[data-orientation=horizontal]":{alignItems:"center"},flex:"1","&:last-of-type:not([data-stretch])":{flex:"initial"}},icon:{flexShrink:0,width:eL.reference,height:eL.reference},indicator:{flexShrink:0,borderRadius:"full",width:ej.reference,height:ej.reference,display:"flex",justifyContent:"center",alignItems:"center","&[data-status=active]":{borderWidth:"2px",borderColor:ez.reference},"&[data-status=complete]":{bg:ez.reference,color:"chakra-inverse-text"},"&[data-status=incomplete]":{borderWidth:"2px"}},separator:{bg:"chakra-border-color",flex:"1","&[data-status=complete]":{bg:ez.reference},"&[data-orientation=horizontal]":{width:"100%",height:"2px",marginStart:"2"},"&[data-orientation=vertical]":{width:"2px",position:"absolute",height:"100%",maxHeight:`calc(100% - ${ej.reference} - 8px)`,top:`calc(${ej.reference} + 4px)`,insetStart:`calc(${ej.reference} / 2 - 1px)`}}})),sizes:{xs:eD({stepper:{[ej.variable]:"sizes.4",[eL.variable]:"sizes.3",[eF.variable]:"fontSizes.xs",[eU.variable]:"fontSizes.xs"}}),sm:eD({stepper:{[ej.variable]:"sizes.6",[eL.variable]:"sizes.4",[eF.variable]:"fontSizes.sm",[eU.variable]:"fontSizes.xs"}}),md:eD({stepper:{[ej.variable]:"sizes.8",[eL.variable]:"sizes.5",[eF.variable]:"fontSizes.md",[eU.variable]:"fontSizes.sm"}}),lg:eD({stepper:{[ej.variable]:"sizes.10",[eL.variable]:"sizes.6",[eF.variable]:"fontSizes.lg",[eU.variable]:"fontSizes.md"}})},defaultProps:{size:"md",colorScheme:"blue"}});function anatomy(c,l={}){let et=!1;function toPart(l){let et=["container","root"].includes(null!=l?l:"")?[c]:[c,l],eo=et.filter(Boolean).join("__"),es=`chakra-${eo}`,ec={className:es,selector:`.${es}`,toString:()=>l};return ec}return{parts:function(...eo){for(let c of(!function(){if(!et){et=!0;return}throw Error("[anatomy] .part(...) should only be called once. Did you mean to use .extend(...) ?")}(),eo))l[c]=toPart(c);return anatomy(c,l)},toPart,extend:function(...et){for(let c of et)c in l||(l[c]=toPart(c));return anatomy(c,l)},selectors:function(){let c=Object.fromEntries(Object.entries(l).map(([c,l])=>[c,l.selector]));return c},classnames:function(){let c=Object.fromEntries(Object.entries(l).map(([c,l])=>[c,l.className]));return c},get keys(){return Object.keys(l)},__type:{}}}var eW=anatomy("accordion").parts("root","container","button","panel").extend("icon"),eV=anatomy("alert").parts("title","description","container").extend("icon","spinner"),eG=anatomy("avatar").parts("label","badge","container").extend("excessLabel","group"),eK=anatomy("breadcrumb").parts("link","item","container").extend("separator");anatomy("button").parts();var eJ=anatomy("checkbox").parts("control","icon","container").extend("label");anatomy("progress").parts("track","filledTrack").extend("label");var eQ=anatomy("drawer").parts("overlay","dialogContainer","dialog").extend("header","closeButton","body","footer"),eY=anatomy("editable").parts("preview","input","textarea"),eZ=anatomy("form").parts("container","requiredIndicator","helperText"),eX=anatomy("formError").parts("text","icon"),e0=anatomy("input").parts("addon","field","element","group"),e1=anatomy("list").parts("container","item","icon"),e2=anatomy("menu").parts("button","list","item").extend("groupTitle","icon","command","divider"),e3=anatomy("modal").parts("overlay","dialogContainer","dialog").extend("header","closeButton","body","footer"),e5=anatomy("numberinput").parts("root","field","stepperGroup","stepper");anatomy("pininput").parts("field");var e6=anatomy("popover").parts("content","header","body","footer").extend("popper","arrow","closeButton"),e4=anatomy("progress").parts("label","filledTrack","track"),e8=anatomy("radio").parts("container","control","label"),e9=anatomy("select").parts("field","icon"),e7=anatomy("slider").parts("container","track","thumb","filledTrack","mark"),tn=anatomy("stat").parts("container","label","helpText","number","icon"),to=anatomy("switch").parts("container","track","thumb"),ts=anatomy("table").parts("table","thead","tbody","tr","th","td","tfoot","caption"),ta=anatomy("tabs").parts("root","tab","tablist","tabpanel","tabpanels","indicator"),tc=anatomy("tag").parts("container","label","closeButton"),tl=anatomy("card").parts("container","header","body","footer");function chunk_WSAJBJJ4_escape(c){let l=function(c,l="-"){return c.replace(/\s+/g,l)}(c.toString());return l.includes("\\.")?c:Number.isInteger(parseFloat(c.toString()))?c:l.replace(".","\\.")}function cssVar(c,l){var et,eo;let es=function(c,l=""){return`--${function(c,l=""){return[l,chunk_WSAJBJJ4_escape(c)].filter(Boolean).join("-")}(c,l)}`}(c,null==l?void 0:l.prefix);return{variable:es,reference:(et="string"==typeof(eo=null==l?void 0:l.fallback)?eo:null==eo?void 0:eo.reference,`var(${chunk_WSAJBJJ4_escape(es)}${et?`, ${et}`:""})`)}}var td=et(16465);function toRef(c){return(0,td.Kn)(c)&&c.reference?c.reference:String(c)}var toExpr=(c,...l)=>l.map(toRef).join(` ${c} `).replace(/calc/g,""),add=(...c)=>`calc(${toExpr("+",...c)})`,subtract=(...c)=>`calc(${toExpr("-",...c)})`,multiply=(...c)=>`calc(${toExpr("*",...c)})`,divide=(...c)=>`calc(${toExpr("/",...c)})`,negate=c=>{let l=toRef(c);return null==l||Number.isNaN(parseFloat(l))?multiply(l,-1):String(l).startsWith("-")?String(l).slice(1):`-${l}`},th=Object.assign(c=>({add:(...l)=>th(add(c,...l)),subtract:(...l)=>th(subtract(c,...l)),multiply:(...l)=>th(multiply(c,...l)),divide:(...l)=>th(divide(c,...l)),negate:()=>th(negate(c)),toString:()=>c.toString()}),{add,subtract,multiply,divide,negate}),{defineMultiStyleConfig:tf,definePartsStyle:tp}=(0,e$.D)(to.keys),tg=cssVar("switch-track-width"),tm=cssVar("switch-track-height"),tb=cssVar("switch-track-diff"),ty=th.subtract(tg,tm),t_=cssVar("switch-thumb-x"),tw=cssVar("switch-bg"),tE=(0,e$.k0)(c=>{let{colorScheme:l}=c;return{borderRadius:"full",p:"0.5",width:[tg.reference],height:[tm.reference],transitionProperty:"common",transitionDuration:"fast",[tw.variable]:"colors.gray.300",_dark:{[tw.variable]:"colors.whiteAlpha.400"},_focusVisible:{boxShadow:"outline"},_disabled:{opacity:.4,cursor:"not-allowed"},_checked:{[tw.variable]:`colors.${l}.500`,_dark:{[tw.variable]:`colors.${l}.200`}},bg:tw.reference}}),tS=(0,e$.k0)({bg:"white",transitionProperty:"transform",transitionDuration:"normal",borderRadius:"inherit",width:[tm.reference],height:[tm.reference],_checked:{transform:`translateX(${t_.reference})`}}),tx=tf({baseStyle:tp(c=>({container:{[tb.variable]:ty,[t_.variable]:tb.reference,_rtl:{[t_.variable]:th(tb).negate().toString()}},track:tE(c),thumb:tS})),sizes:{sm:tp({container:{[tg.variable]:"1.375rem",[tm.variable]:"sizes.3"}}),md:tp({container:{[tg.variable]:"1.875rem",[tm.variable]:"sizes.4"}}),lg:tp({container:{[tg.variable]:"2.875rem",[tm.variable]:"sizes.6"}})},defaultProps:{size:"md",colorScheme:"blue"}});function mode(c,l){return et=>"dark"===et.colorMode?l:c}function orient(c){let{orientation:l,vertical:et,horizontal:eo}=c;return l?"vertical"===l?et:eo:{}}var{defineMultiStyleConfig:tk,definePartsStyle:tC}=(0,e$.D)(ts.keys),tA=tC({table:{fontVariantNumeric:"lining-nums tabular-nums",borderCollapse:"collapse",width:"full"},th:{fontFamily:"heading",fontWeight:"bold",textTransform:"uppercase",letterSpacing:"wider",textAlign:"start"},td:{textAlign:"start"},caption:{mt:4,fontFamily:"heading",textAlign:"center",fontWeight:"medium"}}),tI=(0,e$.k0)({"&[data-is-numeric=true]":{textAlign:"end"}}),tP=tk({baseStyle:tA,variants:{simple:tC(c=>{let{colorScheme:l}=c;return{th:{color:mode("gray.600","gray.400")(c),borderBottom:"1px",borderColor:mode(`${l}.100`,`${l}.700`)(c),...tI},td:{borderBottom:"1px",borderColor:mode(`${l}.100`,`${l}.700`)(c),...tI},caption:{color:mode("gray.600","gray.100")(c)},tfoot:{tr:{"&:last-of-type":{th:{borderBottomWidth:0}}}}}}),striped:tC(c=>{let{colorScheme:l}=c;return{th:{color:mode("gray.600","gray.400")(c),borderBottom:"1px",borderColor:mode(`${l}.100`,`${l}.700`)(c),...tI},td:{borderBottom:"1px",borderColor:mode(`${l}.100`,`${l}.700`)(c),...tI},caption:{color:mode("gray.600","gray.100")(c)},tbody:{tr:{"&:nth-of-type(odd)":{"th, td":{borderBottomWidth:"1px",borderColor:mode(`${l}.100`,`${l}.700`)(c)},td:{background:mode(`${l}.100`,`${l}.700`)(c)}}}},tfoot:{tr:{"&:last-of-type":{th:{borderBottomWidth:0}}}}}}),unstyled:(0,e$.k0)({})},sizes:{sm:tC({th:{px:"4",py:"1",lineHeight:"4",fontSize:"xs"},td:{px:"4",py:"2",fontSize:"sm",lineHeight:"4"},caption:{px:"4",py:"2",fontSize:"xs"}}),md:tC({th:{px:"6",py:"3",lineHeight:"4",fontSize:"xs"},td:{px:"6",py:"4",lineHeight:"5"},caption:{px:"6",py:"2",fontSize:"sm"}}),lg:tC({th:{px:"8",py:"4",lineHeight:"5",fontSize:"sm"},td:{px:"8",py:"5",lineHeight:"6"},caption:{px:"6",py:"2",fontSize:"md"}})},defaultProps:{variant:"simple",size:"md",colorScheme:"gray"}});function guard(c,l,et){return Math.min(Math.max(c,et),l)}var tR=class extends Error{constructor(c){super(`Failed to parse color: "${c}"`)}};function parseToRgba(c){if("string"!=typeof c)throw new tR(c);if("transparent"===c.trim().toLowerCase())return[0,0,0,0];let l=c.trim();l=tB.test(c)?function(c){let l=c.toLowerCase().trim(),et=tO[function(c){let l=5381,et=c.length;for(;et;)l=33*l^c.charCodeAt(--et);return(l>>>0)%2341}(l)];if(!et)throw new tR(c);return`#${et}`}(c):c;let et=tT.exec(l);if(et){let c=Array.from(et).slice(1);return[...c.slice(0,3).map(c=>parseInt(r(c,2),16)),parseInt(r(c[3]||"f",2),16)/255]}let eo=tN.exec(l);if(eo){let c=Array.from(eo).slice(1);return[...c.slice(0,3).map(c=>parseInt(c,16)),parseInt(c[3]||"ff",16)/255]}let es=tM.exec(l);if(es){let c=Array.from(es).slice(1);return[...c.slice(0,3).map(c=>parseInt(c,10)),parseFloat(c[3]||"1")]}let ec=t$.exec(l);if(ec){let[l,et,eo,es]=Array.from(ec).slice(1).map(parseFloat);if(guard(0,100,et)!==et||guard(0,100,eo)!==eo)throw new tR(c);return[...hslToRgb(l,et,eo),Number.isNaN(es)?1:es]}throw new tR(c)}let colorToInt=c=>parseInt(c.replace(/_/g,""),36),tO="1q29ehhb 1n09sgk7 1kl1ekf_ _yl4zsno 16z9eiv3 1p29lhp8 _bd9zg04 17u0____ _iw9zhe5 _to73___ _r45e31e _7l6g016 _jh8ouiv _zn3qba8 1jy4zshs 11u87k0u 1ro9yvyo 1aj3xael 1gz9zjz0 _3w8l4xo 1bf1ekf_ _ke3v___ _4rrkb__ 13j776yz _646mbhl _nrjr4__ _le6mbhl 1n37ehkb _m75f91n _qj3bzfz 1939yygw 11i5z6x8 _1k5f8xs 1509441m 15t5lwgf _ae2th1n _tg1ugcv 1lp1ugcv 16e14up_ _h55rw7n _ny9yavn _7a11xb_ 1ih442g9 _pv442g9 1mv16xof 14e6y7tu 1oo9zkds 17d1cisi _4v9y70f _y98m8kc 1019pq0v 12o9zda8 _348j4f4 1et50i2o _8epa8__ _ts6senj 1o350i2o 1mi9eiuo 1259yrp0 1ln80gnw _632xcoy 1cn9zldc _f29edu4 1n490c8q _9f9ziet 1b94vk74 _m49zkct 1kz6s73a 1eu9dtog _q58s1rz 1dy9sjiq __u89jo3 _aj5nkwg _ld89jo3 13h9z6wx _qa9z2ii _l119xgq _bs5arju 1hj4nwk9 1qt4nwk9 1ge6wau6 14j9zlcw 11p1edc_ _ms1zcxe _439shk6 _jt9y70f _754zsow 1la40eju _oq5p___ _x279qkz 1fa5r3rv _yd2d9ip _424tcku _8y1di2_ _zi2uabw _yy7rn9h 12yz980_ __39ljp6 1b59zg0x _n39zfzp 1fy9zest _b33k___ _hp9wq92 1il50hz4 _io472ub _lj9z3eo 19z9ykg0 _8t8iu3a 12b9bl4a 1ak5yw0o _896v4ku _tb8k8lv _s59zi6t _c09ze0p 1lg80oqn 1id9z8wb _238nba5 1kq6wgdi _154zssg _tn3zk49 _da9y6tc 1sg7cv4f _r12jvtt 1gq5fmkz 1cs9rvci _lp9jn1c _xw1tdnb 13f9zje6 16f6973h _vo7ir40 _bt5arjf _rc45e4t _hr4e100 10v4e100 _hc9zke2 _w91egv_ _sj2r1kk 13c87yx8 _vqpds__ _ni8ggk8 _tj9yqfb 1ia2j4r4 _7x9b10u 1fc9ld4j 1eq9zldr _5j9lhpx _ez9zl6o _md61fzm".split(" ").reduce((c,l)=>{let et=colorToInt(l.substring(0,3)),eo=colorToInt(l.substring(3)).toString(16),es="";for(let c=0;c<6-eo.length;c++)es+="0";return c[et]=`${es}${eo}`,c},{}),r=(c,l)=>Array.from(Array(l)).map(()=>c).join(""),tT=RegExp(`^#${r("([a-f0-9])",3)}([a-f0-9])?$`,"i"),tN=RegExp(`^#${r("([a-f0-9]{2})",3)}([a-f0-9]{2})?$`,"i"),tM=RegExp(`^rgba?\\(\\s*(\\d+)\\s*${r(",\\s*(\\d+)\\s*",2)}(?:,\\s*([\\d.]+))?\\s*\\)$`,"i"),t$=/^hsla?\(\s*([\d.]+)\s*,\s*([\d.]+)%\s*,\s*([\d.]+)%(?:\s*,\s*([\d.]+))?\s*\)$/i,tB=/^[a-z]+$/i,roundColor=c=>Math.round(255*c),hslToRgb=(c,l,et)=>{let eo=et/100;if(0===l)return[eo,eo,eo].map(roundColor);let es=(c%360+360)%360/60,ec=(1-Math.abs(2*eo-1))*(l/100),el=ec*(1-Math.abs(es%2-1)),ed=0,eh=0,ef=0;es>=0&&es<1?(ed=ec,eh=el):es>=1&&es<2?(ed=el,eh=ec):es>=2&&es<3?(eh=ec,ef=el):es>=3&&es<4?(eh=el,ef=ec):es>=4&&es<5?(ed=el,ef=ec):es>=5&&es<6&&(ed=ec,ef=el);let ep=eo-ec/2,eg=ed+ep,em=eh+ep,eb=ef+ep;return[eg,em,eb].map(roundColor)};var isEmptyObject=c=>0===Object.keys(c).length,getColor=(c,l,et)=>{let eo=function(c,l,et,eo,es){for(l=l.split?l.split("."):l,eo=0;eo{let l=guard(0,255,c).toString(16);return 1===l.length?`0${l}`:l};hex(l),hex(et),hex(eo),es<1&&hex(Math.round(255*es))}(eo),eo}catch{return null!=et?et:"#000000"}},getBrightness=c=>{let[l,et,eo]=parseToRgba(c);return(299*l+587*et+114*eo)/1e3},tone=c=>l=>{let et=getColor(l,c),eo=getBrightness(et);return eo<128?"dark":"light"},isDark=c=>l=>"dark"===tone(c)(l),chunk_6IC2I3BY_transparentize=(c,l)=>et=>{let eo=getColor(et,c);return function(c,l){let[et,eo,es,ec]=parseToRgba(c);return`rgba(${guard(0,255,et).toFixed()}, ${guard(0,255,eo).toFixed()}, ${guard(0,255,es).toFixed()}, ${parseFloat(guard(0,1,ec-l).toFixed(3))})`}(eo,1-l)};function generateStripe(c="1rem",l="rgba(255, 255, 255, 0.15)"){return{backgroundImage:`linear-gradient( + 45deg, + ${l} 25%, + transparent 25%, + transparent 50%, + ${l} 50%, + ${l} 75%, + transparent 75%, + transparent + )`,backgroundSize:`${c} ${c}`}}var randomHex=()=>`#${Math.floor(16777215*Math.random()).toString(16).padEnd(6,"0")}`,tD=(0,e$.gJ)("tabs-color"),tj=(0,e$.gJ)("tabs-bg"),tL=(0,e$.gJ)("tabs-border-color"),{defineMultiStyleConfig:tF,definePartsStyle:tU}=(0,e$.D)(ta.keys),tz=(0,e$.k0)(c=>{let{orientation:l}=c;return{display:"vertical"===l?"flex":"block"}}),tq=(0,e$.k0)(c=>{let{isFitted:l}=c;return{flex:l?1:void 0,transitionProperty:"common",transitionDuration:"normal",_focusVisible:{zIndex:1,boxShadow:"outline"},_disabled:{cursor:"not-allowed",opacity:.4}}}),tH=(0,e$.k0)(c=>{let{align:l="start",orientation:et}=c;return{justifyContent:({end:"flex-end",center:"center",start:"flex-start"})[l],flexDirection:"vertical"===et?"column":"row"}}),tW=(0,e$.k0)({p:4}),tV=tF({baseStyle:tU(c=>({root:tz(c),tab:tq(c),tablist:tH(c),tabpanel:tW})),sizes:{sm:tU({tab:{py:1,px:4,fontSize:"sm"}}),md:tU({tab:{fontSize:"md",py:2,px:4}}),lg:tU({tab:{fontSize:"lg",py:3,px:4}})},variants:{line:tU(c=>{let{colorScheme:l,orientation:et}=c,eo="vertical"===et,es=eo?"borderStart":"borderBottom";return{tablist:{[es]:"2px solid",borderColor:"inherit"},tab:{[es]:"2px solid",borderColor:"transparent",[eo?"marginStart":"marginBottom"]:"-2px",_selected:{[tD.variable]:`colors.${l}.600`,_dark:{[tD.variable]:`colors.${l}.300`},borderColor:"currentColor"},_active:{[tj.variable]:"colors.gray.200",_dark:{[tj.variable]:"colors.whiteAlpha.300"}},_disabled:{_active:{bg:"none"}},color:tD.reference,bg:tj.reference}}}),enclosed:tU(c=>{let{colorScheme:l}=c;return{tab:{borderTopRadius:"md",border:"1px solid",borderColor:"transparent",mb:"-1px",[tL.variable]:"transparent",_selected:{[tD.variable]:`colors.${l}.600`,[tL.variable]:"colors.white",_dark:{[tD.variable]:`colors.${l}.300`,[tL.variable]:"colors.gray.800"},borderColor:"inherit",borderBottomColor:tL.reference},color:tD.reference},tablist:{mb:"-1px",borderBottom:"1px solid",borderColor:"inherit"}}}),"enclosed-colored":tU(c=>{let{colorScheme:l}=c;return{tab:{border:"1px solid",borderColor:"inherit",[tj.variable]:"colors.gray.50",_dark:{[tj.variable]:"colors.whiteAlpha.50"},mb:"-1px",_notLast:{marginEnd:"-1px"},_selected:{[tj.variable]:"colors.white",[tD.variable]:`colors.${l}.600`,_dark:{[tj.variable]:"colors.gray.800",[tD.variable]:`colors.${l}.300`},borderColor:"inherit",borderTopColor:"currentColor",borderBottomColor:"transparent"},color:tD.reference,bg:tj.reference},tablist:{mb:"-1px",borderBottom:"1px solid",borderColor:"inherit"}}}),"soft-rounded":tU(c=>{let{colorScheme:l,theme:et}=c;return{tab:{borderRadius:"full",fontWeight:"semibold",color:"gray.600",_selected:{color:getColor(et,`${l}.700`),bg:getColor(et,`${l}.100`)}}}}),"solid-rounded":tU(c=>{let{colorScheme:l}=c;return{tab:{borderRadius:"full",fontWeight:"semibold",[tD.variable]:"colors.gray.600",_dark:{[tD.variable]:"inherit"},_selected:{[tD.variable]:"colors.white",[tj.variable]:`colors.${l}.600`,_dark:{[tD.variable]:"colors.gray.800",[tj.variable]:`colors.${l}.300`}},color:tD.reference,bg:tj.reference}}}),unstyled:tU({})},defaultProps:{size:"md",variant:"line",colorScheme:"blue"}}),tG=(0,e$._6)("badge",["bg","color","shadow"]),tK=(0,e$.k0)({px:1,textTransform:"uppercase",fontSize:"xs",borderRadius:"sm",fontWeight:"bold",bg:tG.bg.reference,color:tG.color.reference,boxShadow:tG.shadow.reference}),tJ=(0,e$.k0)(c=>{let{colorScheme:l,theme:et}=c,eo=chunk_6IC2I3BY_transparentize(`${l}.500`,.6)(et);return{[tG.bg.variable]:`colors.${l}.500`,[tG.color.variable]:"colors.white",_dark:{[tG.bg.variable]:eo,[tG.color.variable]:"colors.whiteAlpha.800"}}}),tQ=(0,e$.k0)(c=>{let{colorScheme:l,theme:et}=c,eo=chunk_6IC2I3BY_transparentize(`${l}.200`,.16)(et);return{[tG.bg.variable]:`colors.${l}.100`,[tG.color.variable]:`colors.${l}.800`,_dark:{[tG.bg.variable]:eo,[tG.color.variable]:`colors.${l}.200`}}}),tY=(0,e$.k0)(c=>{let{colorScheme:l,theme:et}=c,eo=chunk_6IC2I3BY_transparentize(`${l}.200`,.8)(et);return{[tG.color.variable]:`colors.${l}.500`,_dark:{[tG.color.variable]:eo},[tG.shadow.variable]:`inset 0 0 0px 1px ${tG.color.reference}`}}),tZ=(0,e$.fj)({baseStyle:tK,variants:{solid:tJ,subtle:tQ,outline:tY},defaultProps:{variant:"subtle",colorScheme:"gray"}}),{defineMultiStyleConfig:tX,definePartsStyle:t0}=(0,e$.D)(tc.keys),t1=(0,e$.gJ)("tag-bg"),t2=(0,e$.gJ)("tag-color"),t3=(0,e$.gJ)("tag-shadow"),t5=(0,e$.gJ)("tag-min-height"),t6=(0,e$.gJ)("tag-min-width"),t4=(0,e$.gJ)("tag-font-size"),t8=(0,e$.gJ)("tag-padding-inline"),t9=t0({container:(0,e$.k0)({fontWeight:"medium",lineHeight:1.2,outline:0,[t2.variable]:tG.color.reference,[t1.variable]:tG.bg.reference,[t3.variable]:tG.shadow.reference,color:t2.reference,bg:t1.reference,boxShadow:t3.reference,borderRadius:"md",minH:t5.reference,minW:t6.reference,fontSize:t4.reference,px:t8.reference,_focusVisible:{[t3.variable]:"shadows.outline"}}),label:(0,e$.k0)({lineHeight:1.2,overflow:"visible"}),closeButton:(0,e$.k0)({fontSize:"lg",w:"5",h:"5",transitionProperty:"common",transitionDuration:"normal",borderRadius:"full",marginStart:"1.5",marginEnd:"-1",opacity:.5,_disabled:{opacity:.4},_focusVisible:{boxShadow:"outline",bg:"rgba(0, 0, 0, 0.14)"},_hover:{opacity:.8},_active:{opacity:1}})}),t7={sm:t0({container:{[t5.variable]:"sizes.5",[t6.variable]:"sizes.5",[t4.variable]:"fontSizes.xs",[t8.variable]:"space.2"},closeButton:{marginEnd:"-2px",marginStart:"0.35rem"}}),md:t0({container:{[t5.variable]:"sizes.6",[t6.variable]:"sizes.6",[t4.variable]:"fontSizes.sm",[t8.variable]:"space.2"}}),lg:t0({container:{[t5.variable]:"sizes.8",[t6.variable]:"sizes.8",[t4.variable]:"fontSizes.md",[t8.variable]:"space.3"}})},re=tX({variants:{subtle:t0(c=>{var l;return{container:null==(l=tZ.variants)?void 0:l.subtle(c)}}),solid:t0(c=>{var l;return{container:null==(l=tZ.variants)?void 0:l.solid(c)}}),outline:t0(c=>{var l;return{container:null==(l=tZ.variants)?void 0:l.outline(c)}})},baseStyle:t9,sizes:t7,defaultProps:{size:"md",variant:"subtle",colorScheme:"gray"}}),{definePartsStyle:rt,defineMultiStyleConfig:ro}=(0,e$.D)(e0.keys),rs=(0,e$.gJ)("input-height"),ra=(0,e$.gJ)("input-font-size"),rc=(0,e$.gJ)("input-padding"),rl=(0,e$.gJ)("input-border-radius"),rd=rt({addon:{height:rs.reference,fontSize:ra.reference,px:rc.reference,borderRadius:rl.reference},field:{width:"100%",height:rs.reference,fontSize:ra.reference,px:rc.reference,borderRadius:rl.reference,minWidth:0,outline:0,position:"relative",appearance:"none",transitionProperty:"common",transitionDuration:"normal",_disabled:{opacity:.4,cursor:"not-allowed"}}}),rh={lg:(0,e$.k0)({[ra.variable]:"fontSizes.lg",[rc.variable]:"space.4",[rl.variable]:"radii.md",[rs.variable]:"sizes.12"}),md:(0,e$.k0)({[ra.variable]:"fontSizes.md",[rc.variable]:"space.4",[rl.variable]:"radii.md",[rs.variable]:"sizes.10"}),sm:(0,e$.k0)({[ra.variable]:"fontSizes.sm",[rc.variable]:"space.3",[rl.variable]:"radii.sm",[rs.variable]:"sizes.8"}),xs:(0,e$.k0)({[ra.variable]:"fontSizes.xs",[rc.variable]:"space.2",[rl.variable]:"radii.sm",[rs.variable]:"sizes.6"})};function getDefaults(c){let{focusBorderColor:l,errorBorderColor:et}=c;return{focusBorderColor:l||mode("blue.500","blue.300")(c),errorBorderColor:et||mode("red.500","red.300")(c)}}var rp=ro({baseStyle:rd,sizes:{lg:rt({field:rh.lg,group:rh.lg}),md:rt({field:rh.md,group:rh.md}),sm:rt({field:rh.sm,group:rh.sm}),xs:rt({field:rh.xs,group:rh.xs})},variants:{outline:rt(c=>{let{theme:l}=c,{focusBorderColor:et,errorBorderColor:eo}=getDefaults(c);return{field:{border:"1px solid",borderColor:"inherit",bg:"inherit",_hover:{borderColor:mode("gray.300","whiteAlpha.400")(c)},_readOnly:{boxShadow:"none !important",userSelect:"all"},_invalid:{borderColor:getColor(l,eo),boxShadow:`0 0 0 1px ${getColor(l,eo)}`},_focusVisible:{zIndex:1,borderColor:getColor(l,et),boxShadow:`0 0 0 1px ${getColor(l,et)}`}},addon:{border:"1px solid",borderColor:mode("inherit","whiteAlpha.50")(c),bg:mode("gray.100","whiteAlpha.300")(c)}}}),filled:rt(c=>{let{theme:l}=c,{focusBorderColor:et,errorBorderColor:eo}=getDefaults(c);return{field:{border:"2px solid",borderColor:"transparent",bg:mode("gray.100","whiteAlpha.50")(c),_hover:{bg:mode("gray.200","whiteAlpha.100")(c)},_readOnly:{boxShadow:"none !important",userSelect:"all"},_invalid:{borderColor:getColor(l,eo)},_focusVisible:{bg:"transparent",borderColor:getColor(l,et)}},addon:{border:"2px solid",borderColor:"transparent",bg:mode("gray.100","whiteAlpha.50")(c)}}}),flushed:rt(c=>{let{theme:l}=c,{focusBorderColor:et,errorBorderColor:eo}=getDefaults(c);return{field:{borderBottom:"1px solid",borderColor:"inherit",borderRadius:"0",px:"0",bg:"transparent",_readOnly:{boxShadow:"none !important",userSelect:"all"},_invalid:{borderColor:getColor(l,eo),boxShadow:`0px 1px 0px 0px ${getColor(l,eo)}`},_focusVisible:{borderColor:getColor(l,et),boxShadow:`0px 1px 0px 0px ${getColor(l,et)}`}},addon:{borderBottom:"2px solid",borderColor:"inherit",borderRadius:"0",px:"0",bg:"transparent"}}}),unstyled:rt({field:{bg:"transparent",px:"0",height:"auto"},addon:{bg:"transparent",px:"0",height:"auto"}})},defaultProps:{size:"md",variant:"outline"}}),rg=(0,e$.k0)({...null==(eo=rp.baseStyle)?void 0:eo.field,paddingY:"2",minHeight:"20",lineHeight:"short",verticalAlign:"top"}),rm={outline:(0,e$.k0)(c=>{var l,et;return null!=(et=null==(l=rp.variants)?void 0:l.outline(c).field)?et:{}}),flushed:(0,e$.k0)(c=>{var l,et;return null!=(et=null==(l=rp.variants)?void 0:l.flushed(c).field)?et:{}}),filled:(0,e$.k0)(c=>{var l,et;return null!=(et=null==(l=rp.variants)?void 0:l.filled(c).field)?et:{}}),unstyled:null!=(ec=null==(es=rp.variants)?void 0:es.unstyled.field)?ec:{}},rb={xs:null!=(ed=null==(el=rp.sizes)?void 0:el.xs.field)?ed:{},sm:null!=(ef=null==(eh=rp.sizes)?void 0:eh.sm.field)?ef:{},md:null!=(eg=null==(ep=rp.sizes)?void 0:ep.md.field)?eg:{},lg:null!=(eb=null==(em=rp.sizes)?void 0:em.lg.field)?eb:{}},ry=(0,e$.fj)({baseStyle:rg,sizes:rb,variants:rm,defaultProps:{size:"md",variant:"outline"}}),r_=cssVar("tooltip-bg"),rw=cssVar("tooltip-fg"),rE=cssVar("popper-arrow-bg"),rS=(0,e$.k0)({bg:r_.reference,color:rw.reference,[r_.variable]:"colors.gray.700",[rw.variable]:"colors.whiteAlpha.900",_dark:{[r_.variable]:"colors.gray.300",[rw.variable]:"colors.gray.900"},[rE.variable]:r_.reference,px:"2",py:"0.5",borderRadius:"sm",fontWeight:"medium",fontSize:"sm",boxShadow:"md",maxW:"xs",zIndex:"tooltip"}),rx=(0,e$.fj)({baseStyle:rS}),{defineMultiStyleConfig:rk,definePartsStyle:rC}=(0,e$.D)(e4.keys),rA=(0,e$.k0)(c=>{let{colorScheme:l,theme:et,isIndeterminate:eo,hasStripe:es}=c,ec=mode(generateStripe(),generateStripe("1rem","rgba(0,0,0,0.1)"))(c),el=mode(`${l}.500`,`${l}.200`)(c),ed=`linear-gradient( + to right, + transparent 0%, + ${getColor(et,el)} 50%, + transparent 100% + )`;return{...!eo&&es&&ec,...eo?{bgImage:ed}:{bgColor:el}}}),rI=(0,e$.k0)({lineHeight:"1",fontSize:"0.25em",fontWeight:"bold",color:"white"}),rP=(0,e$.k0)(c=>({bg:mode("gray.100","whiteAlpha.300")(c)})),rR=(0,e$.k0)(c=>({transitionProperty:"common",transitionDuration:"slow",...rA(c)})),rO=rC(c=>({label:rI,filledTrack:rR(c),track:rP(c)})),rT=rk({sizes:{xs:rC({track:{h:"1"}}),sm:rC({track:{h:"2"}}),md:rC({track:{h:"3"}}),lg:rC({track:{h:"4"}})},baseStyle:rO,defaultProps:{size:"md",colorScheme:"blue"}}),isFunction=c=>"function"==typeof c;function runIfFn(c,...l){return isFunction(c)?c(...l):c}var{definePartsStyle:rN,defineMultiStyleConfig:rM}=(0,e$.D)(eJ.keys),r$=(0,e$.gJ)("checkbox-size"),rB=(0,e$.k0)(c=>{let{colorScheme:l}=c;return{w:r$.reference,h:r$.reference,transitionProperty:"box-shadow",transitionDuration:"normal",border:"2px solid",borderRadius:"sm",borderColor:"inherit",color:"white",_checked:{bg:mode(`${l}.500`,`${l}.200`)(c),borderColor:mode(`${l}.500`,`${l}.200`)(c),color:mode("white","gray.900")(c),_hover:{bg:mode(`${l}.600`,`${l}.300`)(c),borderColor:mode(`${l}.600`,`${l}.300`)(c)},_disabled:{borderColor:mode("gray.200","transparent")(c),bg:mode("gray.200","whiteAlpha.300")(c),color:mode("gray.500","whiteAlpha.500")(c)}},_indeterminate:{bg:mode(`${l}.500`,`${l}.200`)(c),borderColor:mode(`${l}.500`,`${l}.200`)(c),color:mode("white","gray.900")(c)},_disabled:{bg:mode("gray.100","whiteAlpha.100")(c),borderColor:mode("gray.100","transparent")(c)},_focusVisible:{boxShadow:"outline"},_invalid:{borderColor:mode("red.500","red.300")(c)}}}),rD=(0,e$.k0)({_disabled:{cursor:"not-allowed"}}),rj=(0,e$.k0)({userSelect:"none",_disabled:{opacity:.4}}),rL=(0,e$.k0)({transitionProperty:"transform",transitionDuration:"normal"}),rF=rM({baseStyle:rN(c=>({icon:rL,container:rD,control:runIfFn(rB,c),label:rj})),sizes:{sm:rN({control:{[r$.variable]:"sizes.3"},label:{fontSize:"sm"},icon:{fontSize:"3xs"}}),md:rN({control:{[r$.variable]:"sizes.4"},label:{fontSize:"md"},icon:{fontSize:"2xs"}}),lg:rN({control:{[r$.variable]:"sizes.5"},label:{fontSize:"lg"},icon:{fontSize:"2xs"}})},defaultProps:{size:"md",colorScheme:"blue"}}),{defineMultiStyleConfig:rU,definePartsStyle:rz}=(0,e$.D)(e8.keys),rq=(0,e$.k0)(c=>{var l;let et=null==(l=runIfFn(rF.baseStyle,c))?void 0:l.control;return{...et,borderRadius:"full",_checked:{...null==et?void 0:et._checked,_before:{content:'""',display:"inline-block",pos:"relative",w:"50%",h:"50%",borderRadius:"50%",bg:"currentColor"}}}}),rH=rU({baseStyle:rz(c=>{var l,et;return{label:null==(l=rF.baseStyle)?void 0:l.call(rF,c).label,container:null==(et=rF.baseStyle)?void 0:et.call(rF,c).container,control:rq(c)}}),sizes:{md:rz({control:{w:"4",h:"4"},label:{fontSize:"md"}}),lg:rz({control:{w:"5",h:"5"},label:{fontSize:"lg"}}),sm:rz({control:{width:"3",height:"3"},label:{fontSize:"sm"}})},defaultProps:{size:"md",colorScheme:"blue"}}),{defineMultiStyleConfig:rW,definePartsStyle:rV}=(0,e$.D)(e9.keys),rG=(0,e$.gJ)("select-bg"),rK=rV({field:(0,e$.k0)({...null==(ey=rp.baseStyle)?void 0:ey.field,appearance:"none",paddingBottom:"1px",lineHeight:"normal",bg:rG.reference,[rG.variable]:"colors.white",_dark:{[rG.variable]:"colors.gray.700"},"> option, > optgroup":{bg:rG.reference}}),icon:(0,e$.k0)({width:"6",height:"100%",insetEnd:"2",position:"relative",color:"currentColor",fontSize:"xl",_disabled:{opacity:.5}})}),rJ=(0,e$.k0)({paddingInlineEnd:"8"}),rQ=rW({baseStyle:rK,sizes:{lg:{...null==(e_=rp.sizes)?void 0:e_.lg,field:{...null==(ew=rp.sizes)?void 0:ew.lg.field,...rJ}},md:{...null==(eE=rp.sizes)?void 0:eE.md,field:{...null==(eS=rp.sizes)?void 0:eS.md.field,...rJ}},sm:{...null==(ex=rp.sizes)?void 0:ex.sm,field:{...null==(ek=rp.sizes)?void 0:ek.sm.field,...rJ}},xs:{...null==(eC=rp.sizes)?void 0:eC.xs,field:{...null==(eA=rp.sizes)?void 0:eA.xs.field,...rJ},icon:{insetEnd:"1"}}},variants:rp.variants,defaultProps:rp.defaultProps}),rY=(0,e$.gJ)("skeleton-start-color"),rZ=(0,e$.gJ)("skeleton-end-color"),rX=(0,e$.k0)({[rY.variable]:"colors.gray.100",[rZ.variable]:"colors.gray.400",_dark:{[rY.variable]:"colors.gray.800",[rZ.variable]:"colors.gray.600"},background:rY.reference,borderColor:rZ.reference,opacity:.7,borderRadius:"sm"}),r0=(0,e$.fj)({baseStyle:rX}),r1=(0,e$.gJ)("skip-link-bg"),r2=(0,e$.k0)({borderRadius:"md",fontWeight:"semibold",_focusVisible:{boxShadow:"outline",padding:"4",position:"fixed",top:"6",insetStart:"6",[r1.variable]:"colors.white",_dark:{[r1.variable]:"colors.gray.700"},bg:r1.reference}}),r3=(0,e$.fj)({baseStyle:r2}),{defineMultiStyleConfig:r5,definePartsStyle:r6}=(0,e$.D)(e7.keys),r4=(0,e$.gJ)("slider-thumb-size"),r8=(0,e$.gJ)("slider-track-size"),r9=(0,e$.gJ)("slider-bg"),r7=(0,e$.k0)(c=>{let{orientation:l}=c;return{display:"inline-block",position:"relative",cursor:"pointer",_disabled:{opacity:.6,cursor:"default",pointerEvents:"none"},...orient({orientation:l,vertical:{h:"100%"},horizontal:{w:"100%"}})}}),nn=(0,e$.k0)(c=>{let l=orient({orientation:c.orientation,horizontal:{h:r8.reference},vertical:{w:r8.reference}});return{...l,overflow:"hidden",borderRadius:"sm",[r9.variable]:"colors.gray.200",_dark:{[r9.variable]:"colors.whiteAlpha.200"},_disabled:{[r9.variable]:"colors.gray.300",_dark:{[r9.variable]:"colors.whiteAlpha.300"}},bg:r9.reference}}),no=(0,e$.k0)(c=>{let{orientation:l}=c,et=orient({orientation:l,vertical:{left:"50%",transform:"translateX(-50%)",_active:{transform:"translateX(-50%) scale(1.15)"}},horizontal:{top:"50%",transform:"translateY(-50%)",_active:{transform:"translateY(-50%) scale(1.15)"}}});return{...et,w:r4.reference,h:r4.reference,display:"flex",alignItems:"center",justifyContent:"center",position:"absolute",outline:0,zIndex:1,borderRadius:"full",bg:"white",boxShadow:"base",border:"1px solid",borderColor:"transparent",transitionProperty:"transform",transitionDuration:"normal",_focusVisible:{boxShadow:"outline"},_disabled:{bg:"gray.300"}}}),ns=(0,e$.k0)(c=>{let{colorScheme:l}=c;return{width:"inherit",height:"inherit",[r9.variable]:`colors.${l}.500`,_dark:{[r9.variable]:`colors.${l}.200`},bg:r9.reference}}),nc=r5({baseStyle:r6(c=>({container:r7(c),track:nn(c),thumb:no(c),filledTrack:ns(c)})),sizes:{lg:r6({container:{[r4.variable]:"sizes.4",[r8.variable]:"sizes.1"}}),md:r6({container:{[r4.variable]:"sizes.3.5",[r8.variable]:"sizes.1"}}),sm:r6({container:{[r4.variable]:"sizes.2.5",[r8.variable]:"sizes.0.5"}})},defaultProps:{size:"md",colorScheme:"blue"}}),nl=cssVar("spinner-size"),nd=(0,e$.k0)({width:[nl.reference],height:[nl.reference]}),nh={xs:(0,e$.k0)({[nl.variable]:"sizes.3"}),sm:(0,e$.k0)({[nl.variable]:"sizes.4"}),md:(0,e$.k0)({[nl.variable]:"sizes.6"}),lg:(0,e$.k0)({[nl.variable]:"sizes.8"}),xl:(0,e$.k0)({[nl.variable]:"sizes.12"})},nf=(0,e$.fj)({baseStyle:nd,sizes:nh,defaultProps:{size:"md"}}),{defineMultiStyleConfig:np,definePartsStyle:ng}=(0,e$.D)(tn.keys),nm=np({baseStyle:ng({container:{},label:(0,e$.k0)({fontWeight:"medium"}),helpText:(0,e$.k0)({opacity:.8,marginBottom:"2"}),number:(0,e$.k0)({verticalAlign:"baseline",fontWeight:"semibold"}),icon:(0,e$.k0)({marginEnd:1,w:"3.5",h:"3.5",verticalAlign:"middle"})}),sizes:{md:ng({label:{fontSize:"sm"},helpText:{fontSize:"sm"},number:{fontSize:"2xl"}})},defaultProps:{size:"md"}}),nb=(0,e$.gJ)("kbd-bg"),ny=(0,e$.k0)({[nb.variable]:"colors.gray.100",_dark:{[nb.variable]:"colors.whiteAlpha.100"},bg:nb.reference,borderRadius:"md",borderWidth:"1px",borderBottomWidth:"3px",fontSize:"0.8em",fontWeight:"bold",lineHeight:"normal",px:"0.4em",whiteSpace:"nowrap"}),n_=(0,e$.fj)({baseStyle:ny}),nw=(0,e$.k0)({transitionProperty:"common",transitionDuration:"fast",transitionTimingFunction:"ease-out",cursor:"pointer",textDecoration:"none",outline:"none",color:"inherit",_hover:{textDecoration:"underline"},_focusVisible:{boxShadow:"outline"}}),nE=(0,e$.fj)({baseStyle:nw}),{defineMultiStyleConfig:nS,definePartsStyle:nx}=(0,e$.D)(e1.keys),nk=nS({baseStyle:nx({icon:(0,e$.k0)({marginEnd:"2",display:"inline",verticalAlign:"text-bottom"})})}),{defineMultiStyleConfig:nC,definePartsStyle:nA}=(0,e$.D)(e2.keys),nI=(0,e$.gJ)("menu-bg"),nP=(0,e$.gJ)("menu-shadow"),nR=(0,e$.k0)({[nI.variable]:"#fff",[nP.variable]:"shadows.sm",_dark:{[nI.variable]:"colors.gray.700",[nP.variable]:"shadows.dark-lg"},color:"inherit",minW:"3xs",py:"2",zIndex:1,borderRadius:"md",borderWidth:"1px",bg:nI.reference,boxShadow:nP.reference}),nO=(0,e$.k0)({py:"1.5",px:"3",transitionProperty:"background",transitionDuration:"ultra-fast",transitionTimingFunction:"ease-in",_focus:{[nI.variable]:"colors.gray.100",_dark:{[nI.variable]:"colors.whiteAlpha.100"}},_active:{[nI.variable]:"colors.gray.200",_dark:{[nI.variable]:"colors.whiteAlpha.200"}},_expanded:{[nI.variable]:"colors.gray.100",_dark:{[nI.variable]:"colors.whiteAlpha.100"}},_disabled:{opacity:.4,cursor:"not-allowed"},bg:nI.reference}),nT=(0,e$.k0)({mx:4,my:2,fontWeight:"semibold",fontSize:"sm"}),nN=(0,e$.k0)({display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0}),nM=(0,e$.k0)({opacity:.6}),n$=(0,e$.k0)({border:0,borderBottom:"1px solid",borderColor:"inherit",my:"2",opacity:.6}),nB=nC({baseStyle:nA({button:(0,e$.k0)({transitionProperty:"common",transitionDuration:"normal"}),list:nR,item:nO,groupTitle:nT,icon:nN,command:nM,divider:n$})}),{defineMultiStyleConfig:nD,definePartsStyle:nj}=(0,e$.D)(e3.keys),nL=(0,e$.gJ)("modal-bg"),nF=(0,e$.gJ)("modal-shadow"),nU=(0,e$.k0)({bg:"blackAlpha.600",zIndex:"modal"}),nz=(0,e$.k0)(c=>{let{isCentered:l,scrollBehavior:et}=c;return{display:"flex",zIndex:"modal",justifyContent:"center",alignItems:l?"center":"flex-start",overflow:"inside"===et?"hidden":"auto",overscrollBehaviorY:"none"}}),nq=(0,e$.k0)(c=>{let{isCentered:l,scrollBehavior:et}=c;return{borderRadius:"md",color:"inherit",my:l?"auto":"16",mx:l?"auto":void 0,zIndex:"modal",maxH:"inside"===et?"calc(100% - 7.5rem)":void 0,[nL.variable]:"colors.white",[nF.variable]:"shadows.lg",_dark:{[nL.variable]:"colors.gray.700",[nF.variable]:"shadows.dark-lg"},bg:nL.reference,boxShadow:nF.reference}}),nH=(0,e$.k0)({px:"6",py:"4",fontSize:"xl",fontWeight:"semibold"}),nW=(0,e$.k0)({position:"absolute",top:"2",insetEnd:"3"}),nV=(0,e$.k0)(c=>{let{scrollBehavior:l}=c;return{px:"6",py:"2",flex:"1",overflow:"inside"===l?"auto":void 0}}),nG=(0,e$.k0)({px:"6",py:"4"});function getSize(c){return"full"===c?nj({dialog:{maxW:"100vw",minH:"$100vh",my:"0",borderRadius:"0"}}):nj({dialog:{maxW:c}})}var nK=nD({baseStyle:nj(c=>({overlay:nU,dialogContainer:runIfFn(nz,c),dialog:runIfFn(nq,c),header:nH,closeButton:nW,body:runIfFn(nV,c),footer:nG})),sizes:{xs:getSize("xs"),sm:getSize("sm"),md:getSize("md"),lg:getSize("lg"),xl:getSize("xl"),"2xl":getSize("2xl"),"3xl":getSize("3xl"),"4xl":getSize("4xl"),"5xl":getSize("5xl"),"6xl":getSize("6xl"),full:getSize("full")},defaultProps:{size:"md"}}),{defineMultiStyleConfig:nJ,definePartsStyle:nQ}=(0,e$.D)(e5.keys),nY=cssVar("number-input-stepper-width"),nZ=cssVar("number-input-input-padding"),nX=th(nY).add("0.5rem").toString(),n0=cssVar("number-input-bg"),n1=cssVar("number-input-color"),n2=cssVar("number-input-border-color"),n3=(0,e$.k0)({[nY.variable]:"sizes.6",[nZ.variable]:nX}),n5=(0,e$.k0)(c=>{var l,et;return null!=(et=null==(l=runIfFn(rp.baseStyle,c))?void 0:l.field)?et:{}}),n6=(0,e$.k0)({width:nY.reference}),n4=(0,e$.k0)({borderStart:"1px solid",borderStartColor:n2.reference,color:n1.reference,bg:n0.reference,[n1.variable]:"colors.chakra-body-text",[n2.variable]:"colors.chakra-border-color",_dark:{[n1.variable]:"colors.whiteAlpha.800",[n2.variable]:"colors.whiteAlpha.300"},_active:{[n0.variable]:"colors.gray.200",_dark:{[n0.variable]:"colors.whiteAlpha.300"}},_disabled:{opacity:.4,cursor:"not-allowed"}});function chunk_57T4IAPW_getSize(c){var l,et,eo;let es=null==(l=rp.sizes)?void 0:l[c],ec={lg:"md",md:"md",sm:"sm",xs:"sm"},el=null!=(eo=null==(et=es.field)?void 0:et.fontSize)?eo:"md",ed=eO.fontSizes[el];return nQ({field:{...es.field,paddingInlineEnd:nZ.reference,verticalAlign:"top"},stepper:{fontSize:th(ed).multiply(.75).toString(),_first:{borderTopEndRadius:ec[c]},_last:{borderBottomEndRadius:ec[c],mt:"-1px",borderTopWidth:1}}})}var n8=nJ({baseStyle:nQ(c=>{var l;return{root:n3,field:null!=(l=runIfFn(n5,c))?l:{},stepperGroup:n6,stepper:n4}}),sizes:{xs:chunk_57T4IAPW_getSize("xs"),sm:chunk_57T4IAPW_getSize("sm"),md:chunk_57T4IAPW_getSize("md"),lg:chunk_57T4IAPW_getSize("lg")},variants:rp.variants,defaultProps:rp.defaultProps}),n9=(0,e$.k0)({...null==(eI=rp.baseStyle)?void 0:eI.field,textAlign:"center"}),n7={lg:(0,e$.k0)({fontSize:"lg",w:12,h:12,borderRadius:"md"}),md:(0,e$.k0)({fontSize:"md",w:10,h:10,borderRadius:"md"}),sm:(0,e$.k0)({fontSize:"sm",w:8,h:8,borderRadius:"sm"}),xs:(0,e$.k0)({fontSize:"xs",w:6,h:6,borderRadius:"sm"})},ie={outline:(0,e$.k0)(c=>{var l,et,eo;return null!=(eo=null==(et=runIfFn(null==(l=rp.variants)?void 0:l.outline,c))?void 0:et.field)?eo:{}}),flushed:(0,e$.k0)(c=>{var l,et,eo;return null!=(eo=null==(et=runIfFn(null==(l=rp.variants)?void 0:l.flushed,c))?void 0:et.field)?eo:{}}),filled:(0,e$.k0)(c=>{var l,et,eo;return null!=(eo=null==(et=runIfFn(null==(l=rp.variants)?void 0:l.filled,c))?void 0:et.field)?eo:{}}),unstyled:null!=(eR=null==(eP=rp.variants)?void 0:eP.unstyled.field)?eR:{}},ir=(0,e$.fj)({baseStyle:n9,sizes:n7,variants:ie,defaultProps:rp.defaultProps}),{defineMultiStyleConfig:io,definePartsStyle:iu}=(0,e$.D)(e6.keys),ic=cssVar("popper-bg"),il=cssVar("popper-arrow-bg"),ih=cssVar("popper-arrow-shadow-color"),ip=io({baseStyle:iu({popper:(0,e$.k0)({zIndex:10}),content:(0,e$.k0)({[ic.variable]:"colors.white",bg:ic.reference,[il.variable]:ic.reference,[ih.variable]:"colors.gray.200",_dark:{[ic.variable]:"colors.gray.700",[ih.variable]:"colors.whiteAlpha.300"},width:"xs",border:"1px solid",borderColor:"inherit",borderRadius:"md",boxShadow:"sm",zIndex:"inherit",_focusVisible:{outline:0,boxShadow:"outline"}}),header:(0,e$.k0)({px:3,py:2,borderBottomWidth:"1px"}),body:(0,e$.k0)({px:3,py:2}),footer:(0,e$.k0)({px:3,py:2,borderTopWidth:"1px"}),closeButton:(0,e$.k0)({position:"absolute",borderRadius:"md",top:1,insetEnd:2,padding:2})})}),{definePartsStyle:ig,defineMultiStyleConfig:im}=(0,e$.D)(eQ.keys),ib=(0,e$.gJ)("drawer-bg"),iy=(0,e$.gJ)("drawer-box-shadow");function chunk_VWP3ZVQT_getSize(c){return"full"===c?ig({dialog:{maxW:"100vw",h:"100vh"}}):ig({dialog:{maxW:c}})}var i_=(0,e$.k0)({bg:"blackAlpha.600",zIndex:"modal"}),iw=(0,e$.k0)({display:"flex",zIndex:"modal",justifyContent:"center"}),iE=(0,e$.k0)(c=>{let{isFullHeight:l}=c;return{...l&&{height:"100vh"},zIndex:"modal",maxH:"100vh",color:"inherit",[ib.variable]:"colors.white",[iy.variable]:"shadows.lg",_dark:{[ib.variable]:"colors.gray.700",[iy.variable]:"shadows.dark-lg"},bg:ib.reference,boxShadow:iy.reference}}),iS=(0,e$.k0)({px:"6",py:"4",fontSize:"xl",fontWeight:"semibold"}),ix=(0,e$.k0)({position:"absolute",top:"2",insetEnd:"3"}),ik=(0,e$.k0)({px:"6",py:"2",flex:"1",overflow:"auto"}),iC=(0,e$.k0)({px:"6",py:"4"}),iA=im({baseStyle:ig(c=>({overlay:i_,dialogContainer:iw,dialog:runIfFn(iE,c),header:iS,closeButton:ix,body:ik,footer:iC})),sizes:{xs:chunk_VWP3ZVQT_getSize("xs"),sm:chunk_VWP3ZVQT_getSize("md"),md:chunk_VWP3ZVQT_getSize("lg"),lg:chunk_VWP3ZVQT_getSize("2xl"),xl:chunk_VWP3ZVQT_getSize("4xl"),full:chunk_VWP3ZVQT_getSize("full")},defaultProps:{size:"xs"}}),{definePartsStyle:iI,defineMultiStyleConfig:iP}=(0,e$.D)(eY.keys),iR=iP({baseStyle:iI({preview:(0,e$.k0)({borderRadius:"md",py:"1",transitionProperty:"common",transitionDuration:"normal"}),input:(0,e$.k0)({borderRadius:"md",py:"1",transitionProperty:"common",transitionDuration:"normal",width:"full",_focusVisible:{boxShadow:"outline"},_placeholder:{opacity:.6}}),textarea:(0,e$.k0)({borderRadius:"md",py:"1",transitionProperty:"common",transitionDuration:"normal",width:"full",_focusVisible:{boxShadow:"outline"},_placeholder:{opacity:.6}})})}),{definePartsStyle:iO,defineMultiStyleConfig:iT}=(0,e$.D)(eZ.keys),iN=(0,e$.gJ)("form-control-color"),iM=iT({baseStyle:iO({container:{width:"100%",position:"relative"},requiredIndicator:(0,e$.k0)({marginStart:"1",[iN.variable]:"colors.red.500",_dark:{[iN.variable]:"colors.red.300"},color:iN.reference}),helperText:(0,e$.k0)({mt:"2",[iN.variable]:"colors.gray.600",_dark:{[iN.variable]:"colors.whiteAlpha.600"},color:iN.reference,lineHeight:"normal",fontSize:"sm"})})}),{definePartsStyle:i$,defineMultiStyleConfig:iB}=(0,e$.D)(eX.keys),iD=(0,e$.gJ)("form-error-color"),ij=iB({baseStyle:i$({text:(0,e$.k0)({[iD.variable]:"colors.red.500",_dark:{[iD.variable]:"colors.red.300"},color:iD.reference,mt:"2",fontSize:"sm",lineHeight:"normal"}),icon:(0,e$.k0)({marginEnd:"0.5em",[iD.variable]:"colors.red.500",_dark:{[iD.variable]:"colors.red.300"},color:iD.reference})})}),iL=(0,e$.k0)({fontSize:"md",marginEnd:"3",mb:"2",fontWeight:"medium",transitionProperty:"common",transitionDuration:"normal",opacity:1,_disabled:{opacity:.4}}),iF=(0,e$.fj)({baseStyle:iL}),iU=(0,e$.k0)({fontFamily:"heading",fontWeight:"bold"}),iz={"4xl":(0,e$.k0)({fontSize:["6xl",null,"7xl"],lineHeight:1}),"3xl":(0,e$.k0)({fontSize:["5xl",null,"6xl"],lineHeight:1}),"2xl":(0,e$.k0)({fontSize:["4xl",null,"5xl"],lineHeight:[1.2,null,1]}),xl:(0,e$.k0)({fontSize:["3xl",null,"4xl"],lineHeight:[1.33,null,1.2]}),lg:(0,e$.k0)({fontSize:["2xl",null,"3xl"],lineHeight:[1.33,null,1.2]}),md:(0,e$.k0)({fontSize:"xl",lineHeight:1.2}),sm:(0,e$.k0)({fontSize:"md",lineHeight:1.2}),xs:(0,e$.k0)({fontSize:"sm",lineHeight:1.2})},iq=(0,e$.fj)({baseStyle:iU,sizes:iz,defaultProps:{size:"xl"}}),{defineMultiStyleConfig:iH,definePartsStyle:iW}=(0,e$.D)(eK.keys),iV=(0,e$.gJ)("breadcrumb-link-decor"),iG=iH({baseStyle:iW({link:(0,e$.k0)({transitionProperty:"common",transitionDuration:"fast",transitionTimingFunction:"ease-out",outline:"none",color:"inherit",textDecoration:iV.reference,[iV.variable]:"none","&:not([aria-current=page])":{cursor:"pointer",_hover:{[iV.variable]:"underline"},_focusVisible:{boxShadow:"outline"}}})})}),iK=(0,e$.k0)({lineHeight:"1.2",borderRadius:"md",fontWeight:"semibold",transitionProperty:"common",transitionDuration:"normal",_focusVisible:{boxShadow:"outline"},_disabled:{opacity:.4,cursor:"not-allowed",boxShadow:"none"},_hover:{_disabled:{bg:"initial"}}}),iJ=(0,e$.k0)(c=>{let{colorScheme:l,theme:et}=c;if("gray"===l)return{color:mode("gray.800","whiteAlpha.900")(c),_hover:{bg:mode("gray.100","whiteAlpha.200")(c)},_active:{bg:mode("gray.200","whiteAlpha.300")(c)}};let eo=chunk_6IC2I3BY_transparentize(`${l}.200`,.12)(et),es=chunk_6IC2I3BY_transparentize(`${l}.200`,.24)(et);return{color:mode(`${l}.600`,`${l}.200`)(c),bg:"transparent",_hover:{bg:mode(`${l}.50`,eo)(c)},_active:{bg:mode(`${l}.100`,es)(c)}}}),iQ=(0,e$.k0)(c=>{let{colorScheme:l}=c,et=mode("gray.200","whiteAlpha.300")(c);return{border:"1px solid",borderColor:"gray"===l?et:"currentColor",".chakra-button__group[data-attached][data-orientation=horizontal] > &:not(:last-of-type)":{marginEnd:"-1px"},".chakra-button__group[data-attached][data-orientation=vertical] > &:not(:last-of-type)":{marginBottom:"-1px"},...runIfFn(iJ,c)}}),iY={yellow:{bg:"yellow.400",color:"black",hoverBg:"yellow.500",activeBg:"yellow.600"},cyan:{bg:"cyan.400",color:"black",hoverBg:"cyan.500",activeBg:"cyan.600"}},iZ=(0,e$.k0)(c=>{var l;let{colorScheme:et}=c;if("gray"===et){let l=mode("gray.100","whiteAlpha.200")(c);return{bg:l,color:mode("gray.800","whiteAlpha.900")(c),_hover:{bg:mode("gray.200","whiteAlpha.300")(c),_disabled:{bg:l}},_active:{bg:mode("gray.300","whiteAlpha.400")(c)}}}let{bg:eo=`${et}.500`,color:es="white",hoverBg:ec=`${et}.600`,activeBg:el=`${et}.700`}=null!=(l=iY[et])?l:{},ed=mode(eo,`${et}.200`)(c);return{bg:ed,color:mode(es,"gray.800")(c),_hover:{bg:mode(ec,`${et}.300`)(c),_disabled:{bg:ed}},_active:{bg:mode(el,`${et}.400`)(c)}}}),iX=(0,e$.k0)(c=>{let{colorScheme:l}=c;return{padding:0,height:"auto",lineHeight:"normal",verticalAlign:"baseline",color:mode(`${l}.500`,`${l}.200`)(c),_hover:{textDecoration:"underline",_disabled:{textDecoration:"none"}},_active:{color:mode(`${l}.700`,`${l}.500`)(c)}}}),i0=(0,e$.k0)({bg:"none",color:"inherit",display:"inline",lineHeight:"inherit",m:"0",p:"0"}),i1={lg:(0,e$.k0)({h:"12",minW:"12",fontSize:"lg",px:"6"}),md:(0,e$.k0)({h:"10",minW:"10",fontSize:"md",px:"4"}),sm:(0,e$.k0)({h:"8",minW:"8",fontSize:"sm",px:"3"}),xs:(0,e$.k0)({h:"6",minW:"6",fontSize:"xs",px:"2"})},i2=(0,e$.fj)({baseStyle:iK,variants:{ghost:iJ,outline:iQ,solid:iZ,link:iX,unstyled:i0},sizes:i1,defaultProps:{variant:"solid",size:"md",colorScheme:"gray"}}),{definePartsStyle:i3,defineMultiStyleConfig:i5}=(0,e$.D)(tl.keys),i6=(0,e$.gJ)("card-bg"),i4=(0,e$.gJ)("card-padding"),i8=(0,e$.gJ)("card-shadow"),i9=(0,e$.gJ)("card-radius"),i7=(0,e$.gJ)("card-border-width","0"),ot=(0,e$.gJ)("card-border-color"),oo=i3({container:{[i6.variable]:"colors.chakra-body-bg",backgroundColor:i6.reference,boxShadow:i8.reference,borderRadius:i9.reference,color:"chakra-body-text",borderWidth:i7.reference,borderColor:ot.reference},body:{padding:i4.reference,flex:"1 1 0%"},header:{padding:i4.reference},footer:{padding:i4.reference}}),os={sm:i3({container:{[i9.variable]:"radii.base",[i4.variable]:"space.3"}}),md:i3({container:{[i9.variable]:"radii.md",[i4.variable]:"space.5"}}),lg:i3({container:{[i9.variable]:"radii.xl",[i4.variable]:"space.7"}})},oc=i5({baseStyle:oo,variants:{elevated:i3({container:{[i8.variable]:"shadows.base",_dark:{[i6.variable]:"colors.gray.700"}}}),outline:i3({container:{[i7.variable]:"1px",[ot.variable]:"colors.chakra-border-color"}}),filled:i3({container:{[i6.variable]:"colors.chakra-subtle-bg"}}),unstyled:{body:{[i4.variable]:0},header:{[i4.variable]:0},footer:{[i4.variable]:0}}},sizes:os,defaultProps:{variant:"elevated",size:"md"}}),ol=cssVar("close-button-size"),od=cssVar("close-button-bg"),oh=(0,e$.k0)({w:[ol.reference],h:[ol.reference],borderRadius:"md",transitionProperty:"common",transitionDuration:"normal",_disabled:{opacity:.4,cursor:"not-allowed",boxShadow:"none"},_hover:{[od.variable]:"colors.blackAlpha.100",_dark:{[od.variable]:"colors.whiteAlpha.100"}},_active:{[od.variable]:"colors.blackAlpha.200",_dark:{[od.variable]:"colors.whiteAlpha.200"}},_focusVisible:{boxShadow:"outline"},bg:od.reference}),op={lg:(0,e$.k0)({[ol.variable]:"sizes.10",fontSize:"md"}),md:(0,e$.k0)({[ol.variable]:"sizes.8",fontSize:"xs"}),sm:(0,e$.k0)({[ol.variable]:"sizes.6",fontSize:"2xs"})},og=(0,e$.fj)({baseStyle:oh,sizes:op,defaultProps:{size:"md"}}),{variants:om,defaultProps:ob}=tZ,oy=(0,e$.k0)({fontFamily:"mono",fontSize:"sm",px:"0.2em",borderRadius:"sm",bg:tG.bg.reference,color:tG.color.reference,boxShadow:tG.shadow.reference}),ov=(0,e$.fj)({baseStyle:oy,variants:om,defaultProps:ob}),o_=(0,e$.k0)({w:"100%",mx:"auto",maxW:"prose",px:"4"}),ow=(0,e$.fj)({baseStyle:o_}),oE=(0,e$.k0)({opacity:.6,borderColor:"inherit"}),oS=(0,e$.k0)({borderStyle:"solid"}),ox=(0,e$.k0)({borderStyle:"dashed"}),ok=(0,e$.fj)({baseStyle:oE,variants:{solid:oS,dashed:ox},defaultProps:{variant:"solid"}}),{definePartsStyle:oC,defineMultiStyleConfig:oA}=(0,e$.D)(eW.keys),oI=oA({baseStyle:oC({container:(0,e$.k0)({borderTopWidth:"1px",borderColor:"inherit",_last:{borderBottomWidth:"1px"}}),button:(0,e$.k0)({transitionProperty:"common",transitionDuration:"normal",fontSize:"md",_focusVisible:{boxShadow:"outline"},_hover:{bg:"blackAlpha.50"},_disabled:{opacity:.4,cursor:"not-allowed"},px:"4",py:"2"}),panel:(0,e$.k0)({pt:"2",px:"4",pb:"5"}),icon:(0,e$.k0)({fontSize:"1.25em"})})}),{definePartsStyle:oP,defineMultiStyleConfig:oR}=(0,e$.D)(eV.keys),oO=(0,e$.gJ)("alert-fg"),oT=(0,e$.gJ)("alert-bg");function getBg(c){let{theme:l,colorScheme:et}=c,eo=chunk_6IC2I3BY_transparentize(`${et}.200`,.16)(l);return{light:`colors.${et}.100`,dark:eo}}var oN=oR({baseStyle:oP({container:{bg:oT.reference,px:"4",py:"3"},title:{fontWeight:"bold",lineHeight:"6",marginEnd:"2"},description:{lineHeight:"6"},icon:{color:oO.reference,flexShrink:0,marginEnd:"3",w:"5",h:"6"},spinner:{color:oO.reference,flexShrink:0,marginEnd:"3",w:"5",h:"5"}}),variants:{subtle:oP(c=>{let{colorScheme:l}=c,et=getBg(c);return{container:{[oO.variable]:`colors.${l}.500`,[oT.variable]:et.light,_dark:{[oO.variable]:`colors.${l}.200`,[oT.variable]:et.dark}}}}),"left-accent":oP(c=>{let{colorScheme:l}=c,et=getBg(c);return{container:{[oO.variable]:`colors.${l}.500`,[oT.variable]:et.light,_dark:{[oO.variable]:`colors.${l}.200`,[oT.variable]:et.dark},paddingStart:"3",borderStartWidth:"4px",borderStartColor:oO.reference}}}),"top-accent":oP(c=>{let{colorScheme:l}=c,et=getBg(c);return{container:{[oO.variable]:`colors.${l}.500`,[oT.variable]:et.light,_dark:{[oO.variable]:`colors.${l}.200`,[oT.variable]:et.dark},pt:"2",borderTopWidth:"4px",borderTopColor:oO.reference}}}),solid:oP(c=>{let{colorScheme:l}=c;return{container:{[oO.variable]:"colors.white",[oT.variable]:`colors.${l}.500`,_dark:{[oO.variable]:"colors.gray.900",[oT.variable]:`colors.${l}.200`},color:oO.reference}}})},defaultProps:{variant:"subtle",colorScheme:"blue"}}),{definePartsStyle:oM,defineMultiStyleConfig:o$}=(0,e$.D)(eG.keys),oB=(0,e$.gJ)("avatar-border-color"),oD=(0,e$.gJ)("avatar-bg"),oj=(0,e$.gJ)("avatar-font-size"),oL=(0,e$.gJ)("avatar-size"),oF=(0,e$.k0)({borderRadius:"full",border:"0.2em solid",borderColor:oB.reference,[oB.variable]:"white",_dark:{[oB.variable]:"colors.gray.800"}}),oU=(0,e$.k0)({bg:oD.reference,fontSize:oj.reference,width:oL.reference,height:oL.reference,lineHeight:"1",[oD.variable]:"colors.gray.200",_dark:{[oD.variable]:"colors.whiteAlpha.400"}}),oz=(0,e$.k0)(c=>{let{name:l,theme:et}=c,eo=l?function(c){var l;let et=randomHex();return!c||isEmptyObject(c)?et:c.string&&c.colors?function(c,l){let et=0;if(0===c.length)return l[0];for(let l=0;l>8*c&255;et+=`00${eo.toString(16)}`.substr(-2)}return et}(c.string):c.colors&&!c.string?(l=c.colors)[Math.floor(Math.random()*l.length)]:et}({string:l}):"colors.gray.400",es=isDark(eo)(et),ec="white";return es||(ec="gray.800"),{bg:oD.reference,fontSize:oj.reference,color:ec,borderColor:oB.reference,verticalAlign:"top",width:oL.reference,height:oL.reference,"&:not([data-loaded])":{[oD.variable]:eo},[oB.variable]:"colors.white",_dark:{[oB.variable]:"colors.gray.800"}}}),oq=(0,e$.k0)({fontSize:oj.reference,lineHeight:"1"});function chunk_Q5ZQE4MD_getSize(c){let l="100%"!==c?eN[c]:void 0;return oM({container:{[oL.variable]:null!=l?l:c,[oj.variable]:`calc(${null!=l?l:c} / 2.5)`},excessLabel:{[oL.variable]:null!=l?l:c,[oj.variable]:`calc(${null!=l?l:c} / 2.5)`}})}var oH=o$({baseStyle:oM(c=>({badge:runIfFn(oF,c),excessLabel:runIfFn(oU,c),container:runIfFn(oz,c),label:oq})),sizes:{"2xs":chunk_Q5ZQE4MD_getSize(4),xs:chunk_Q5ZQE4MD_getSize(6),sm:chunk_Q5ZQE4MD_getSize(8),md:chunk_Q5ZQE4MD_getSize(12),lg:chunk_Q5ZQE4MD_getSize(16),xl:chunk_Q5ZQE4MD_getSize(24),"2xl":chunk_Q5ZQE4MD_getSize(32),full:chunk_Q5ZQE4MD_getSize("100%")},defaultProps:{size:"md"}}),oW={colors:{"chakra-body-text":{_light:"gray.800",_dark:"whiteAlpha.900"},"chakra-body-bg":{_light:"white",_dark:"gray.800"},"chakra-border-color":{_light:"gray.200",_dark:"whiteAlpha.300"},"chakra-inverse-text":{_light:"white",_dark:"gray.800"},"chakra-subtle-bg":{_light:"gray.100",_dark:"gray.700"},"chakra-subtle-text":{_light:"gray.600",_dark:"gray.400"},"chakra-placeholder-color":{_light:"gray.500",_dark:"whiteAlpha.400"}}},oV={global:{body:{fontFamily:"body",color:"chakra-body-text",bg:"chakra-body-bg",transitionProperty:"background-color",transitionDuration:"normal",lineHeight:"base"},"*::placeholder":{color:"chakra-placeholder-color"},"*, *::before, &::after":{borderColor:"chakra-border-color"}}},oG={useSystemColorMode:!1,initialColorMode:"light",cssVarPrefix:"chakra"},oK={semanticTokens:oW,direction:"ltr",...eM,components:{Accordion:oI,Alert:oN,Avatar:oH,Badge:tZ,Breadcrumb:iG,Button:i2,Checkbox:rF,CloseButton:og,Code:ov,Container:ow,Divider:ok,Drawer:iA,Editable:iR,Form:iM,FormError:ij,FormLabel:iF,Heading:iq,Input:rp,Kbd:n_,Link:nE,List:nk,Menu:nB,Modal:nK,NumberInput:n8,PinInput:ir,Popover:ip,Progress:rT,Radio:rH,Select:rQ,Skeleton:r0,SkipLink:r3,Slider:nc,Spinner:nf,Stat:nm,Switch:tx,Table:tP,Tabs:tV,Tag:re,Textarea:ry,Tooltip:rx,Card:oc,Stepper:eH},styles:oV,config:oG},oJ={semanticTokens:oW,direction:"ltr",components:{},...eM,styles:oV,config:oG}},62788:function(c,l,et){"use strict";let eo;et.d(l,{Pu:function(){return runIfFn},TE:function(){return distance},ZK:function(){return el},ZT:function(){return noop},v0:function(){return callAllHandlers},zG:function(){return pipe}});var es,ec=et(82136);function runIfFn(c,...l){return(0,ec.mf)(c)?c(...l):c}function callAllHandlers(...c){return function(l){c.some(c=>(null==c||c(l),null==l?void 0:l.defaultPrevented))}}var noop=()=>{},el=(es=c=>()=>{let{condition:l,message:et}=c;l&&ec.Ts&&console.warn(et)},function(...c){return es&&(eo=es.apply(this,c),es=null),eo}),pipe=(...c)=>l=>c.reduce((c,l)=>l(c),l),distance1D=(c,l)=>Math.abs(c-l),isPoint=c=>"x"in c&&"y"in c;function distance(c,l){if((0,ec.hj)(c)&&(0,ec.hj)(l))return distance1D(c,l);if(isPoint(c)&&isPoint(l)){let et=distance1D(c.x,l.x),eo=distance1D(c.y,l.y);return Math.sqrt(et**2+eo**2)}return 0}},82136:function(c,l,et){"use strict";function isNumber(c){return"number"==typeof c}function isFunction(c){return"function"==typeof c}et.d(l,{Ik:function(){return isRefObject},Ts:function(){return eo},hj:function(){return isNumber},mf:function(){return isFunction}});var eo=!1;function isRefObject(c){return"current"in c}},19307:function(c,l,et){"use strict";function omit(c,l){let et={};return Object.keys(c).forEach(eo=>{l.includes(eo)||(et[eo]=c[eo])}),et}et.d(l,{CE:function(){return omit},Wf:function(){return eo},YU:function(){return filterUndefined},lw:function(){return objectFilter}}),et(94216);var eo=(c=>{let l=new WeakMap;return(et,eo,es,ec)=>{if(void 0===et)return c(et,eo,es);l.has(et)||l.set(et,new Map);let el=l.get(et);if(el.has(eo))return el.get(eo);let ed=c(et,eo,es,ec);return el.set(eo,ed),ed}})(function(c,l,et,eo){let es="string"==typeof l?l.split("."):[l];for(eo=0;eo{let es=c[eo],ec=l(es,eo,c);ec&&(et[eo]=es)}),et}var filterUndefined=c=>objectFilter(c,c=>null!=c)},84209:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 16.5v2.25A2.25 2.25 0 005.25 21h13.5A2.25 2.25 0 0021 18.75V16.5M16.5 12L12 16.5m0 0L7.5 12m4.5 4.5V3"}))});l.Z=es},33753:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.5 19.5L3 12m0 0l7.5-7.5M3 12h18"}))});l.Z=es},31706:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0l3.181 3.183a8.25 8.25 0 0013.803-3.7M4.031 9.865a8.25 8.25 0 0113.803-3.7l3.181 3.182m0-4.991v4.99"}))});l.Z=es},49186:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z"}))});l.Z=es},84164:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19.5 8.25l-7.5 7.5-7.5-7.5"}))});l.Z=es},57548:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M11.35 3.836c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 00.75-.75 2.25 2.25 0 00-.1-.664m-5.8 0A2.251 2.251 0 0113.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m8.9-4.414c.376.023.75.05 1.124.08 1.131.094 1.976 1.057 1.976 2.192V16.5A2.25 2.25 0 0118 18.75h-2.25m-7.5-10.5H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V18.75m-7.5-10.5h6.375c.621 0 1.125.504 1.125 1.125v9.375m-8.25-3l1.5 1.5 3-3.75"}))});l.Z=es},82929:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z"}))});l.Z=es},36108:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 01-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 011.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 00-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 01-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 00-3.375-3.375h-1.5a1.125 1.125 0 01-1.125-1.125v-1.5a3.375 3.375 0 00-3.375-3.375H9.75"}))});l.Z=es},34424:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21.75 6.75v10.5a2.25 2.25 0 01-2.25 2.25h-15a2.25 2.25 0 01-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0019.5 4.5h-15a2.25 2.25 0 00-2.25 2.25m19.5 0v.243a2.25 2.25 0 01-1.07 1.916l-7.5 4.615a2.25 2.25 0 01-2.36 0L3.32 8.91a2.25 2.25 0 01-1.07-1.916V6.75"}))});l.Z=es},10887:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"}))});l.Z=es},91543:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.98 8.223A10.477 10.477 0 001.934 12C3.226 16.338 7.244 19.5 12 19.5c.993 0 1.953-.138 2.863-.395M6.228 6.228A10.45 10.45 0 0112 4.5c4.756 0 8.773 3.162 10.065 7.498a10.523 10.523 0 01-4.293 5.774M6.228 6.228L3 3m3.228 3.228l3.65 3.65m7.894 7.894L21 21m-3.228-3.228l-3.65-3.65m0 0a3 3 0 10-4.243-4.243m4.242 4.242L9.88 9.88"}))});l.Z=es},11226:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.75 5.25a3 3 0 013 3m3 0a6 6 0 01-7.029 5.912c-.563-.097-1.159.026-1.563.43L10.5 17.25H8.25v2.25H6v2.25H2.25v-2.818c0-.597.237-1.17.659-1.591l6.499-6.499c.404-.404.527-1 .43-1.563A6 6 0 1121.75 8.25z"}))});l.Z=es},77150:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M13.19 8.688a4.5 4.5 0 011.242 7.244l-4.5 4.5a4.5 4.5 0 01-6.364-6.364l1.757-1.757m13.35-.622l1.757-1.757a4.5 4.5 0 00-6.364-6.364l-4.5 4.5a4.5 4.5 0 001.242 7.244"}))});l.Z=es},25587:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 002.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.035 12.035 0 01-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 00-1.091-.852H4.5A2.25 2.25 0 002.25 4.5v2.25z"}))});l.Z=es},32938:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 12.75L11.25 15 15 9.75m-3-7.036A11.959 11.959 0 013.598 6 11.99 11.99 0 003 9.749c0 5.592 3.824 10.29 9 11.623 5.176-1.332 9-6.03 9-11.622 0-1.31-.21-2.571-.598-3.751h-.152c-3.196 0-6.1-1.248-8.25-3.285z"}))});l.Z=es},49863:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.982 18.725A7.488 7.488 0 0012 15.75a7.488 7.488 0 00-5.982 2.975m11.963 0a9 9 0 10-11.963 0m11.963 0A8.966 8.966 0 0112 21a8.966 8.966 0 01-5.982-2.275M15 9.75a3 3 0 11-6 0 3 3 0 016 0z"}))});l.Z=es},39427:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a2.25 2.25 0 00-2.25-2.25H15a3 3 0 11-6 0H5.25A2.25 2.25 0 003 12m18 0v6a2.25 2.25 0 01-2.25 2.25H5.25A2.25 2.25 0 013 18v-6m18 0V9M3 12V9m18 0a2.25 2.25 0 00-2.25-2.25H5.25A2.25 2.25 0 003 9m18 0V6a2.25 2.25 0 00-2.25-2.25H5.25A2.25 2.25 0 003 6v3"}))});l.Z=es},42893:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9.75 9.75l4.5 4.5m0-4.5l-4.5 4.5M21 12a9 9 0 11-18 0 9 9 0 0118 0z"}))});l.Z=es},96689:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"}))});l.Z=es},20387:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{fillRule:"evenodd",d:"M15.97 2.47a.75.75 0 011.06 0l4.5 4.5a.75.75 0 010 1.06l-4.5 4.5a.75.75 0 11-1.06-1.06l3.22-3.22H7.5a.75.75 0 010-1.5h11.69l-3.22-3.22a.75.75 0 010-1.06zm-7.94 9a.75.75 0 010 1.06l-3.22 3.22H16.5a.75.75 0 010 1.5H4.81l3.22 3.22a.75.75 0 11-1.06 1.06l-4.5-4.5a.75.75 0 010-1.06l4.5-4.5a.75.75 0 011.06 0z",clipRule:"evenodd"}))});l.Z=es},70432:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{fillRule:"evenodd",d:"M2.25 12c0-5.385 4.365-9.75 9.75-9.75s9.75 4.365 9.75 9.75-4.365 9.75-9.75 9.75S2.25 17.385 2.25 12zm13.36-1.814a.75.75 0 10-1.22-.872l-3.236 4.53L9.53 12.22a.75.75 0 00-1.06 1.06l2.25 2.25a.75.75 0 001.14-.094l3.75-5.25z",clipRule:"evenodd"}))});l.Z=es},34729:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{fillRule:"evenodd",d:"M12 1.5a5.25 5.25 0 00-5.25 5.25v3a3 3 0 00-3 3v6.75a3 3 0 003 3h10.5a3 3 0 003-3v-6.75a3 3 0 00-3-3v-3c0-2.9-2.35-5.25-5.25-5.25zm3.75 8.25v-3a3.75 3.75 0 10-7.5 0v3h7.5z",clipRule:"evenodd"}))});l.Z=es},52466:function(c,l,et){"use strict";var eo=et(2265);let es=eo.forwardRef(function({title:c,titleId:l,...et},es){return eo.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true",ref:es,"aria-labelledby":l},et),c?eo.createElement("title",{id:l},c):null,eo.createElement("path",{fillRule:"evenodd",d:"M12 2.25c-5.385 0-9.75 4.365-9.75 9.75s4.365 9.75 9.75 9.75 9.75-4.365 9.75-9.75S17.385 2.25 12 2.25zm-1.72 6.97a.75.75 0 10-1.06 1.06L10.94 12l-1.72 1.72a.75.75 0 101.06 1.06L12 13.06l1.72 1.72a.75.75 0 101.06-1.06L13.06 12l1.72-1.72a.75.75 0 10-1.06-1.06L12 10.94l-1.72-1.72z",clipRule:"evenodd"}))});l.Z=es},52069:function(c,l,et){"use strict";var eo=et(13076);l.Z=eo},38026:function(c,l,et){"use strict";et.d(l,{B:function(){return eo},N:function(){return es}});var eo=class extends Error{constructor({chainId:c,connectorId:l}){super(`Chain "${c}" not configured for connector "${l}".`),this.name="ChainNotConfiguredForConnectorError"}},es=class extends Error{constructor(){super(...arguments),this.name="ConnectorNotFoundError",this.message="Connector not found"}}},68635:function(c,l,et){"use strict";et.d(l,{wR:function(){return ed},Ko:function(){return __privateAdd},ac:function(){return __privateGet},qx:function(){return __privateSet}});var eo=et(66421),es=et(42168);let ec=(0,es.ax)({id:1,network:"homestead",name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-mainnet.g.alchemy.com/v2"],webSocket:["wss://eth-mainnet.g.alchemy.com/v2"]},infura:{http:["https://mainnet.infura.io/v3"],webSocket:["wss://mainnet.infura.io/ws/v3"]},default:{http:["https://cloudflare-eth.com"]},public:{http:["https://cloudflare-eth.com"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://etherscan.io"},default:{name:"Etherscan",url:"https://etherscan.io"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0xc0497E381f536Be9ce14B0dD3817cBcAe57d2F62",blockCreated:16966585},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}}),el=(0,es.ax)({id:5,network:"goerli",name:"Goerli",nativeCurrency:{name:"Goerli Ether",symbol:"ETH",decimals:18},rpcUrls:{alchemy:{http:["https://eth-goerli.g.alchemy.com/v2"],webSocket:["wss://eth-goerli.g.alchemy.com/v2"]},infura:{http:["https://goerli.infura.io/v3"],webSocket:["wss://goerli.infura.io/ws/v3"]},default:{http:["https://rpc.ankr.com/eth_goerli"]},public:{http:["https://rpc.ankr.com/eth_goerli"]}},blockExplorers:{etherscan:{name:"Etherscan",url:"https://goerli.etherscan.io"},default:{name:"Etherscan",url:"https://goerli.etherscan.io"}},contracts:{ensRegistry:{address:"0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e"},ensUniversalResolver:{address:"0x56522D00C410a43BFfDF00a9A569489297385790",blockCreated:8765204},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:6507670}},testnet:!0});var __accessCheck=(c,l,et)=>{if(!l.has(c))throw TypeError("Cannot "+et)},__privateGet=(c,l,et)=>(__accessCheck(c,l,"read from private field"),et?et.call(c):l.get(c)),__privateAdd=(c,l,et)=>{if(l.has(c))throw TypeError("Cannot add the same private member more than once");l instanceof WeakSet?l.add(c):l.set(c,et)},__privateSet=(c,l,et,eo)=>(__accessCheck(c,l,"write to private field"),eo?eo.call(c,et):l.set(c,et),et),ed=class extends eo{constructor({chains:c=[ec,el],options:l}){super(),this.chains=c,this.options=l}getBlockExplorerUrls(c){let{default:l,...et}=c.blockExplorers??{};if(l)return[l.url,...Object.values(et).map(c=>c.url)]}isChainUnsupported(c){return!this.chains.some(l=>l.id===c)}setStorage(c){this.storage=c}}},36694:function(c,l,et){"use strict";et.d(l,{X4:function(){return tx},QB:function(){return configureChains},_g:function(){return createConfig},o6:function(){return createStorage},vZ:function(){return function deepEqual(c,l){if(c===l)return!0;if(c&&l&&"object"==typeof c&&"object"==typeof l){let et,eo;if(c.constructor!==l.constructor)return!1;if(Array.isArray(c)&&Array.isArray(l)){if((et=c.length)!=l.length)return!1;for(eo=et;0!=eo--;)if(!deepEqual(c[eo],l[eo]))return!1;return!0}if(c.valueOf!==Object.prototype.valueOf)return c.valueOf()===l.valueOf();if(c.toString!==Object.prototype.toString)return c.toString()===l.toString();let es=Object.keys(c);if((et=es.length)!==Object.keys(l).length)return!1;for(eo=et;0!=eo--;)if(!Object.prototype.hasOwnProperty.call(l,es[eo]))return!1;for(eo=et;0!=eo--;){let et=es[eo];if(et&&!deepEqual(c[et],l[et]))return!1}return!0}return c!=c&&l!=l}},zP:function(){return disconnect},RQ:function(){return fetchBlockNumber},D0:function(){return getAccount},uV:function(){return getPublicClient},gY:function(){return getSendTransactionParameters},xz:function(){return getWalletClient},jr:function(){return getWebSocketPublicClient},wp:function(){return tk},a4:function(){return chunk_YAPWLAI7_readContract},Mn:function(){return waitForTransaction},uH:function(){return watchAccount},pC:function(){return watchPublicClient},Tb:function(){return watchWalletClient},fq:function(){return watchWebSocketPublicClient},n9:function(){return writeContract}});var eo,es,ec,el,ed,eh,ef=et(38026);function normalizeChainId(c){return"string"==typeof c?Number.parseInt(c,"0x"===c.trim().substring(0,2)?16:10):"bigint"==typeof c?Number(c):c}var ep=et(68635),eg=et(39803),em=et(48519),eb=et(22570),ey=et(39730),e_=et(21693),ew=class extends ep.wR{constructor({chains:c,options:l}={}){let et={shimDisconnect:!0,getProvider(){if("undefined"==typeof window)return;let c=window.ethereum;return c?.providers?c.providers[0]:c},...l};super({chains:c,options:et}),this.id="injected",(0,ep.Ko)(this,eo,void 0),this.shimDisconnectKey=`${this.id}.shimDisconnect`,this.onAccountsChanged=c=>{0===c.length?this.emit("disconnect"):this.emit("change",{account:(0,eg.K)(c[0])})},this.onChainChanged=c=>{let l=normalizeChainId(c),et=this.isChainUnsupported(l);this.emit("change",{chain:{id:l,unsupported:et}})},this.onDisconnect=async c=>{if(1013===c.code){let c=await this.getProvider();if(c){let c=await this.getAccount();if(c)return}}this.emit("disconnect"),this.options.shimDisconnect&&this.storage?.removeItem(this.shimDisconnectKey)};let es=et.getProvider();if("string"==typeof et.name)this.name=et.name;else if(es){let c=function(c){if(!c)return"Injected";let getName=c=>c.isApexWallet?"Apex Wallet":c.isAvalanche?"Core Wallet":c.isBackpack?"Backpack":c.isBifrost?"Bifrost Wallet":c.isBitKeep?"BitKeep":c.isBitski?"Bitski":c.isBlockWallet?"BlockWallet":c.isBraveWallet?"Brave Wallet":c.isCoin98?"Coin98 Wallet":c.isCoinbaseWallet?"Coinbase Wallet":c.isDawn?"Dawn Wallet":c.isDefiant?"Defiant":c.isDesig?"Desig Wallet":c.isEnkrypt?"Enkrypt":c.isExodus?"Exodus":c.isFordefi?"Fordefi":c.isFrame?"Frame":c.isFrontier?"Frontier Wallet":c.isGamestop?"GameStop Wallet":c.isHaqqWallet?"HAQQ Wallet":c.isHyperPay?"HyperPay Wallet":c.isImToken?"ImToken":c.isHaloWallet?"Halo Wallet":c.isKuCoinWallet?"KuCoin Wallet":c.isMathWallet?"MathWallet":c.isNovaWallet?"Nova Wallet":c.isOkxWallet||c.isOKExWallet?"OKX Wallet":c.isOneInchIOSWallet||c.isOneInchAndroidWallet?"1inch Wallet":c.isOpera?"Opera":c.isPhantom?"Phantom":c.isPortal?"Ripio Portal":c.isRabby?"Rabby Wallet":c.isRainbow?"Rainbow":c.isStatus?"Status":c.isSubWallet?"SubWallet":c.isTalisman?"Talisman":c.isTally?"Taho":c.isTokenPocket?"TokenPocket":c.isTokenary?"Tokenary":c.isTrust||c.isTrustWallet?"Trust Wallet":c.isTTWallet?"TTWallet":c.isXDEFI?"XDEFI Wallet":c.isZeal?"Zeal":c.isZerion?"Zerion":c.isMetaMask?"MetaMask":void 0;if(c.providers?.length){let l=new Set,et=1;for(let eo of c.providers){let c=getName(eo);c||(c=`Unknown Wallet #${et}`,et+=1),l.add(c)}let eo=[...l];return eo.length?eo:eo[0]??"Injected"}return getName(c)??"Injected"}(es);et.name?this.name=et.name(c):"string"==typeof c?this.name=c:this.name=c[0]}else this.name="Injected";this.ready=!!es}async connect({chainId:c}={}){try{let l=await this.getProvider();if(!l)throw new ef.N;l.on&&(l.on("accountsChanged",this.onAccountsChanged),l.on("chainChanged",this.onChainChanged),l.on("disconnect",this.onDisconnect)),this.emit("message",{type:"connecting"});let et=await l.request({method:"eth_requestAccounts"}),eo=(0,eg.K)(et[0]),es=await this.getChainId(),ec=this.isChainUnsupported(es);if(c&&es!==c){let l=await this.switchChain(c);es=l.id,ec=this.isChainUnsupported(es)}return this.options.shimDisconnect&&this.storage?.setItem(this.shimDisconnectKey,!0),{account:eo,chain:{id:es,unsupported:ec}}}catch(c){if(this.isUserRejectedRequestError(c))throw new em.ab(c);if(-32002===c.code)throw new em.pT(c);throw c}}async disconnect(){let c=await this.getProvider();c?.removeListener&&(c.removeListener("accountsChanged",this.onAccountsChanged),c.removeListener("chainChanged",this.onChainChanged),c.removeListener("disconnect",this.onDisconnect),this.options.shimDisconnect&&this.storage?.removeItem(this.shimDisconnectKey))}async getAccount(){let c=await this.getProvider();if(!c)throw new ef.N;let l=await c.request({method:"eth_accounts"});return(0,eg.K)(l[0])}async getChainId(){let c=await this.getProvider();if(!c)throw new ef.N;return c.request({method:"eth_chainId"}).then(normalizeChainId)}async getProvider(){let c=this.options.getProvider();return c&&(0,ep.qx)(this,eo,c),(0,ep.ac)(this,eo)}async getWalletClient({chainId:c}={}){let[l,et]=await Promise.all([this.getProvider(),this.getAccount()]),eo=this.chains.find(l=>l.id===c);if(!l)throw Error("provider is required.");return(0,eb.K)({account:et,chain:eo,transport:(0,ey.P)(l)})}async isAuthorized(){try{if(this.options.shimDisconnect&&!this.storage?.getItem(this.shimDisconnectKey))return!1;let c=await this.getProvider();if(!c)throw new ef.N;let l=await this.getAccount();return!!l}catch{return!1}}async switchChain(c){let l=await this.getProvider();if(!l)throw new ef.N;let et=(0,e_.eC)(c);try{return await Promise.all([l.request({method:"wallet_switchEthereumChain",params:[{chainId:et}]}),new Promise(l=>this.on("change",({chain:et})=>{et?.id===c&&l()}))]),this.chains.find(l=>l.id===c)??{id:c,name:`Chain ${et}`,network:`${et}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}}}catch(es){let eo=this.chains.find(l=>l.id===c);if(!eo)throw new ef.B({chainId:c,connectorId:this.id});if(4902===es.code||es?.data?.originalError?.code===4902)try{await l.request({method:"wallet_addEthereumChain",params:[{chainId:et,chainName:eo.name,nativeCurrency:eo.nativeCurrency,rpcUrls:[eo.rpcUrls.public?.http[0]??""],blockExplorerUrls:this.getBlockExplorerUrls(eo)}]});let es=await this.getChainId();if(es!==c)throw new em.ab(Error("User rejected switch after adding network."));return eo}catch(c){throw new em.ab(c)}if(this.isUserRejectedRequestError(es))throw new em.ab(es);throw new em.x3(es)}}async watchAsset({address:c,decimals:l=18,image:et,symbol:eo}){let es=await this.getProvider();if(!es)throw new ef.N;return es.request({method:"wallet_watchAsset",params:{type:"ERC20",options:{address:c,decimals:l,image:et,symbol:eo}}})}isUserRejectedRequestError(c){return 4001===c.code}};eo=new WeakMap;var __accessCheck=(c,l,et)=>{if(!l.has(c))throw TypeError("Cannot "+et)},__privateGet=(c,l,et)=>(__accessCheck(c,l,"read from private field"),et?et.call(c):l.get(c)),__privateAdd=(c,l,et)=>{if(l.has(c))throw TypeError("Cannot add the same private member more than once");l instanceof WeakSet?l.add(c):l.set(c,et)},__privateSet=(c,l,et,eo)=>(__accessCheck(c,l,"write to private field"),eo?eo.call(c,et):l.set(c,et),et),__privateMethod=(c,l,et)=>(__accessCheck(c,l,"access private method"),et),eE=et(30315),eS=et(42980),ex=et(3458),ek=et(53883),eC=et(42168),eA=et(94973),eI=et(28483),eP=et(95950),eR=et(98458);function isNullUniversalResolverError(c,l){if(!(c instanceof eP.G))return!1;let et=c.walk(c=>c instanceof eR.Lu);return et instanceof eR.Lu&&(!!(et.data?.errorName==="ResolverNotFound"||et.data?.errorName==="ResolverWildcardNotSupported"||et.reason?.includes("Wildcard on non-extended resolvers is not supported"))||"reverse"===l&&et.reason===eI.$[50])}var eO=et(69809),eT=et(56728),eN=et(55852),eM=et(45008);function encodedLabelToLabelhash(c){if(66!==c.length||0!==c.indexOf("[")||65!==c.indexOf("]"))return null;let l=`0x${c.slice(1,65)}`;return(0,eM.v)(l)?l:null}function namehash(c){let l=new Uint8Array(32).fill(0);if(!c)return(0,e_.ci)(l);let et=c.split(".");for(let c=et.length-1;c>=0;c-=1){let eo=encodedLabelToLabelhash(et[c]),es=eo?(0,eT.O0)(eo):(0,eN.w)((0,eT.qX)(et[c]),"bytes");l=(0,eN.w)((0,eO.zo)([l,es]),"bytes")}return(0,e_.ci)(l)}function packetToBytes(c){let l=c.replace(/^\.|\.$/gm,"");if(0===l.length)return new Uint8Array(1);let et=new Uint8Array((0,eT.qX)(l).byteLength+2),eo=0,es=l.split(".");for(let c=0;c255){var ec;l=(0,eT.qX)((ec=function(c){let l=new Uint8Array(32).fill(0);return c?encodedLabelToLabelhash(c)||(0,eN.w)((0,eT.qX)(c)):(0,e_.ci)(l)}(es[c]),`[${ec.slice(2)}]`))}et[eo]=l.length,et.set(l,eo+1),eo+=l.length+1}return et.byteLength!==eo+1?et.slice(0,eo+1):et}var e$=et(71878);function getContractError(c,{abi:l,address:et,args:eo,docsPath:es,functionName:ec,sender:el}){let{code:ed,data:eh,message:ef,shortMessage:ep}=c instanceof eR.VQ?c:c instanceof eP.G?c.walk(c=>"data"in c)||c.walk():{},eg=c instanceof e$.wb?new eR.Dk({functionName:ec}):[3,em.XS.code].includes(ed)&&(eh||ef||ep)?new eR.Lu({abi:l,data:"object"==typeof eh?eh.data:eh,functionName:ec,message:ep??ef}):c;return new eR.uq(eg,{abi:l,args:eo,contractAddress:et,docsPath:es,functionName:ec,sender:el})}var eB=et(98873);async function readContract(c,{abi:l,address:et,args:eo,functionName:es,...ec}){let el=(0,ek.R)({abi:l,args:eo,functionName:es});try{let{data:ed}=await (0,eB.R)(c,{data:el,to:et,...ec});return(0,ex.k)({abi:l,args:eo,functionName:es,data:ed||"0x"})}catch(c){throw getContractError(c,{abi:l,address:et,args:eo,docsPath:"/docs/contract/readContract",functionName:es})}}async function getEnsAddress(c,{blockNumber:l,blockTag:et,coinType:eo,name:es,universalResolverAddress:ec}){let el=ec;if(!el){if(!c.chain)throw Error("client chain not configured. universalResolverAddress is required.");el=(0,eC.LI)({blockNumber:l,chain:c.chain,contract:"ensUniversalResolver"})}try{let ec=(0,ek.R)({abi:eS.X$,functionName:"addr",...null!=eo?{args:[namehash(es),BigInt(eo)]}:{args:[namehash(es)]}}),ed=await readContract(c,{address:el,abi:eS.k3,functionName:"resolve",args:[(0,e_.NC)(packetToBytes(es)),ec],blockNumber:l,blockTag:et});if("0x"===ed[0])return null;let eh=(0,ex.k)({abi:eS.X$,args:null!=eo?[namehash(es),BigInt(eo)]:void 0,functionName:"addr",data:ed[0]});if("0x"===eh||"0x00"===(0,eA.f)(eh))return null;return eh}catch(c){if(isNullUniversalResolverError(c,"resolve"))return null;throw c}}let EnsAvatarInvalidMetadataError=class EnsAvatarInvalidMetadataError extends eP.G{constructor({data:c}){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(c)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidMetadataError"})}};let EnsAvatarInvalidNftUriError=class EnsAvatarInvalidNftUriError extends eP.G{constructor({reason:c}){super(`ENS NFT avatar URI is invalid. ${c}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarInvalidNftUriError"})}};let EnsAvatarUriResolutionError=class EnsAvatarUriResolutionError extends eP.G{constructor({uri:c}){super(`Unable to resolve ENS avatar URI "${c}". The URI may be malformed, invalid, or does not respond with a valid image.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarUriResolutionError"})}};let EnsAvatarUnsupportedNamespaceError=class EnsAvatarUnsupportedNamespaceError extends eP.G{constructor({namespace:c}){super(`ENS NFT avatar namespace "${c}" is not supported. Must be "erc721" or "erc1155".`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EnsAvatarUnsupportedNamespaceError"})}};let eD=/(?https?:\/\/[^\/]*|ipfs:\/|ipns:\/|ar:\/)?(?\/)?(?ipfs\/|ipns\/)?(?[\w\-.]+)(?\/.*)?/,ej=/^(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,})(\/(?[\w\-.]+))?(?\/.*)?$/,eL=/^data:([a-zA-Z\-/+]*);base64,([^"].*)/,eF=/^data:([a-zA-Z\-/+]*)?(;[a-zA-Z0-9].*?)?(,)/;async function isImageUri(c){try{let l=await fetch(c,{method:"HEAD"});if(200===l.status){let c=l.headers.get("content-type");return c?.startsWith("image/")}return!1}catch(l){if("object"==typeof l&&void 0!==l.response||!globalThis.hasOwnProperty("Image"))return!1;return new Promise(l=>{let et=new Image;et.onload=()=>{l(!0)},et.onerror=()=>{l(!1)},et.src=c})}}function getGateway(c,l){return c?c.endsWith("/")?c.slice(0,-1):c:l}function resolveAvatarUri({uri:c,gatewayUrls:l}){let et=eL.test(c);if(et)return{uri:c,isOnChain:!0,isEncoded:et};let eo=getGateway(l?.ipfs,"https://ipfs.io"),es=getGateway(l?.arweave,"https://arweave.net"),ec=c.match(eD),{protocol:el,subpath:ed,target:eh,subtarget:ef=""}=ec?.groups||{},ep="ipns:/"===el||"ipns/"===ed,eg="ipfs:/"===el||"ipfs/"===ed||ej.test(c);if(c.startsWith("http")&&!ep&&!eg){let et=c;return l?.arweave&&(et=c.replace(/https:\/\/arweave.net/g,l?.arweave)),{uri:et,isOnChain:!1,isEncoded:!1}}if((ep||eg)&&eh)return{uri:`${eo}/${ep?"ipns":"ipfs"}/${eh}${ef}`,isOnChain:!1,isEncoded:!1};if("ar:/"===el&&eh)return{uri:`${es}/${eh}${ef||""}`,isOnChain:!1,isEncoded:!1};let em=c.replace(eF,"");if(em.startsWith("c.json()),eo=await parseAvatarUri({gatewayUrls:c,uri:getJsonImage(et)});return eo}catch{throw new EnsAvatarUriResolutionError({uri:l})}}async function parseAvatarUri({gatewayUrls:c,uri:l}){let{uri:et,isOnChain:eo}=resolveAvatarUri({uri:l,gatewayUrls:c});if(eo)return et;let es=await isImageUri(et);if(es)return et;throw new EnsAvatarUriResolutionError({uri:l})}async function getNftTokenUri(c,{nft:l}){if("erc721"===l.namespace)return readContract(c,{address:l.contractAddress,abi:[{name:"tokenURI",type:"function",stateMutability:"view",inputs:[{name:"tokenId",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"tokenURI",args:[BigInt(l.tokenID)]});if("erc1155"===l.namespace)return readContract(c,{address:l.contractAddress,abi:[{name:"uri",type:"function",stateMutability:"view",inputs:[{name:"_id",type:"uint256"}],outputs:[{name:"",type:"string"}]}],functionName:"uri",args:[BigInt(l.tokenID)]});throw new EnsAvatarUnsupportedNamespaceError({namespace:l.namespace})}async function parseAvatarRecord(c,{gatewayUrls:l,record:et}){return/eip155:/i.test(et)?parseNftAvatarUri(c,{gatewayUrls:l,record:et}):parseAvatarUri({uri:et,gatewayUrls:l})}async function parseNftAvatarUri(c,{gatewayUrls:l,record:et}){let eo=function(c){let l=c;l.startsWith("did:nft:")&&(l=l.replace("did:nft:","").replace(/_/g,"/"));let[et,eo,es]=l.split("/"),[ec,el]=et.split(":"),[ed,eh]=eo.split(":");if(!ec||"eip155"!==ec.toLowerCase())throw new EnsAvatarInvalidNftUriError({reason:"Only EIP-155 supported"});if(!el)throw new EnsAvatarInvalidNftUriError({reason:"Chain ID not found"});if(!eh)throw new EnsAvatarInvalidNftUriError({reason:"Contract address not found"});if(!es)throw new EnsAvatarInvalidNftUriError({reason:"Token ID not found"});if(!ed)throw new EnsAvatarInvalidNftUriError({reason:"ERC namespace not found"});return{chainID:parseInt(el),namespace:ed.toLowerCase(),contractAddress:eh,tokenID:es}}(et),es=await getNftTokenUri(c,{nft:eo}),{uri:ec,isOnChain:el,isEncoded:ed}=resolveAvatarUri({uri:es,gatewayUrls:l});if(el&&(ec.includes("data:application/json;base64,")||ec.startsWith("{"))){let c=ed?atob(ec.replace("data:application/json;base64,","")):ec,et=JSON.parse(c);return parseAvatarUri({uri:getJsonImage(et),gatewayUrls:l})}let eh=eo.tokenID;return"erc1155"===eo.namespace&&(eh=eh.replace("0x","").padStart(64,"0")),getMetadataAvatarUri({gatewayUrls:l,uri:ec.replace(/(?:0x)?{id}/,eh)})}async function getEnsText(c,{blockNumber:l,blockTag:et,name:eo,key:es,universalResolverAddress:ec}){let el=ec;if(!el){if(!c.chain)throw Error("client chain not configured. universalResolverAddress is required.");el=(0,eC.LI)({blockNumber:l,chain:c.chain,contract:"ensUniversalResolver"})}try{let ec=await readContract(c,{address:el,abi:eS.k3,functionName:"resolve",args:[(0,e_.NC)(packetToBytes(eo)),(0,ek.R)({abi:eS.nZ,functionName:"text",args:[namehash(eo),es]})],blockNumber:l,blockTag:et});if("0x"===ec[0])return null;let ed=(0,ex.k)({abi:eS.nZ,functionName:"text",data:ec[0]});return""===ed?null:ed}catch(c){if(isNullUniversalResolverError(c,"resolve"))return null;throw c}}async function getEnsAvatar(c,{blockNumber:l,blockTag:et,gatewayUrls:eo,name:es,universalResolverAddress:ec}){let el=await getEnsText(c,{blockNumber:l,blockTag:et,key:"avatar",name:es,universalResolverAddress:ec});if(!el)return null;try{return await parseAvatarRecord(c,{record:el,gatewayUrls:eo})}catch{return null}}async function getEnsName(c,{address:l,blockNumber:et,blockTag:eo,universalResolverAddress:es}){let ec=es;if(!ec){if(!c.chain)throw Error("client chain not configured. universalResolverAddress is required.");ec=(0,eC.LI)({blockNumber:et,chain:c.chain,contract:"ensUniversalResolver"})}let el=`${l.toLowerCase().substring(2)}.addr.reverse`;try{let l=await readContract(c,{address:ec,abi:eS.du,functionName:"reverse",args:[(0,e_.NC)(packetToBytes(el))],blockNumber:et,blockTag:eo});return l[0]}catch(c){if(isNullUniversalResolverError(c,"reverse"))return null;throw c}}async function getEnsResolver(c,{blockNumber:l,blockTag:et,name:eo,universalResolverAddress:es}){let ec=es;if(!ec){if(!c.chain)throw Error("client chain not configured. universalResolverAddress is required.");ec=(0,eC.LI)({blockNumber:l,chain:c.chain,contract:"ensUniversalResolver"})}let[el]=await readContract(c,{address:ec,abi:[{inputs:[{type:"bytes"}],name:"findResolver",outputs:[{type:"address"},{type:"bytes32"}],stateMutability:"view",type:"function"}],functionName:"findResolver",args:[(0,e_.NC)(packetToBytes(eo))],blockNumber:l,blockTag:et});return el}function createFilterRequestScope(c,{method:l}){let et={};return"fallback"===c.transport.type&&c.transport.onResponse?.(({method:c,response:eo,status:es,transport:ec})=>{"success"===es&&l===c&&(et[eo]=ec.request)}),l=>et[l]||c.request}async function createBlockFilter(c){let l=createFilterRequestScope(c,{method:"eth_newBlockFilter"}),et=await c.request({method:"eth_newBlockFilter"});return{id:et,request:l(et),type:"block"}}let FilterTypeNotSupportedError=class FilterTypeNotSupportedError extends eP.G{constructor(c){super(`Filter type "${c}" is not supported.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FilterTypeNotSupportedError"})}};var eU=et(77688),ez=et(90929),eH=et(40928),eW=et(77804);function encodeEventTopics({abi:c,eventName:l,args:et}){let eo=c[0];if(l&&!(eo=(0,eW.m)({abi:c,args:et,name:l})))throw new e$.mv(l,{docsPath:"/docs/contract/encodeEventTopics"});if("event"!==eo.type)throw new e$.mv(void 0,{docsPath:"/docs/contract/encodeEventTopics"});let es=(0,eH.t)(eo),ec=(0,eU.e)(es),el=[];if(et&&"inputs"in eo){let c=eo.inputs?.filter(c=>"indexed"in c&&c.indexed),l=Array.isArray(et)?et:Object.values(et).length>0?c?.map(c=>et[c.name])??[]:[];l.length>0&&(el=c?.map((c,et)=>Array.isArray(l[et])?l[et].map((eo,es)=>encodeArg({param:c,value:l[et][es]})):l[et]?encodeArg({param:c,value:l[et]}):null)??[])}return[ec,...el]}function encodeArg({param:c,value:l}){if("string"===c.type||"bytes"===c.type)return(0,eN.w)((0,eT.O0)(l));if("tuple"===c.type||c.type.match(/^(.*)\[(\d+)?\]$/))throw new FilterTypeNotSupportedError(c.type);return(0,ez.E)([c],[l])}async function createContractEventFilter(c,{address:l,abi:et,args:eo,eventName:es,fromBlock:ec,strict:el,toBlock:ed}){let eh=createFilterRequestScope(c,{method:"eth_newFilter"}),ef=es?encodeEventTopics({abi:et,args:eo,eventName:es}):void 0,ep=await c.request({method:"eth_newFilter",params:[{address:l,fromBlock:"bigint"==typeof ec?(0,e_.eC)(ec):ec,toBlock:"bigint"==typeof ed?(0,e_.eC)(ed):ed,topics:ef}]});return{abi:et,args:eo,eventName:es,id:ep,request:eh(ep),strict:el,type:"event"}}async function createEventFilter(c,{address:l,args:et,event:eo,events:es,fromBlock:ec,strict:el,toBlock:ed}={}){let eh=es??(eo?[eo]:void 0),ef=createFilterRequestScope(c,{method:"eth_newFilter"}),ep=[];eh&&(ep=[eh.flatMap(c=>encodeEventTopics({abi:[c],eventName:c.name,args:et}))],eo&&(ep=ep[0]));let eg=await c.request({method:"eth_newFilter",params:[{address:l,fromBlock:"bigint"==typeof ec?(0,e_.eC)(ec):ec,toBlock:"bigint"==typeof ed?(0,e_.eC)(ed):ed,...ep.length?{topics:ep}:{}}]});return{abi:eh,args:et,eventName:eo?eo.name:void 0,fromBlock:ec,id:eg,request:ef(eg),strict:el,toBlock:ed,type:"event"}}async function createPendingTransactionFilter(c){let l=createFilterRequestScope(c,{method:"eth_newPendingTransactionFilter"}),et=await c.request({method:"eth_newPendingTransactionFilter"});return{id:et,request:l(et),type:"transaction"}}var eV=et(4832),eG=et(89412);async function estimateContractGas(c,{abi:l,address:et,args:eo,functionName:es,...ec}){let el=(0,ek.R)({abi:l,args:eo,functionName:es});try{let l=await (0,eG.Q)(c,{data:el,to:et,...ec});return l}catch(el){let c=ec.account?(0,eV.T)(ec.account):void 0;throw getContractError(el,{abi:l,address:et,args:eo,docsPath:"/docs/contract/estimateContractGas",functionName:es,sender:c?.address})}}var eK=et(77451),eJ=et(17976);async function getBalance(c,{address:l,blockNumber:et,blockTag:eo="latest"}){let es=et?(0,e_.eC)(et):void 0,ec=await c.request({method:"eth_getBalance",params:[l,es||eo]});return BigInt(ec)}var eQ=et(85731);let eY=new Map,eZ=new Map;async function withCache(c,{cacheKey:l,cacheTime:et=1/0}){let eo=function(c){let buildCache=(c,l)=>({clear:()=>l.delete(c),get:()=>l.get(c),set:et=>l.set(c,et)}),l=buildCache(c,eY),et=buildCache(c,eZ);return{clear:()=>{l.clear(),et.clear()},promise:l,response:et}}(l),es=eo.response.get();if(es&&et>0){let c=new Date().getTime()-es.created.getTime();if(c`blockNumber.${c}`;async function getBlockNumber(c,{cacheTime:l=c.cacheTime,maxAge:et}={}){let eo=await withCache(()=>c.request({method:"eth_blockNumber"}),{cacheKey:cacheKey(c.uid),cacheTime:et??l});return BigInt(eo)}var eX=et(30838);async function getBlockTransactionCount(c,{blockHash:l,blockNumber:et,blockTag:eo="latest"}={}){let es;let ec=void 0!==et?(0,e_.eC)(et):void 0;return es=l?await c.request({method:"eth_getBlockTransactionCountByHash",params:[l]}):await c.request({method:"eth_getBlockTransactionCountByNumber",params:[ec||eo]}),(0,eX.ly)(es)}async function getBytecode(c,{address:l,blockNumber:et,blockTag:eo="latest"}){let es=void 0!==et?(0,e_.eC)(et):void 0,ec=await c.request({method:"eth_getCode",params:[l,es||eo]});if("0x"!==ec)return ec}var e0=et(13438),e1=et(63610);function formatLog(c,{args:l,eventName:et}={}){return{...c,blockHash:c.blockHash?c.blockHash:null,blockNumber:c.blockNumber?BigInt(c.blockNumber):null,logIndex:c.logIndex?Number(c.logIndex):null,transactionHash:c.transactionHash?c.transactionHash:null,transactionIndex:c.transactionIndex?Number(c.transactionIndex):null,...et?{args:l,eventName:et}:{}}}async function getLogs(c,{address:l,blockHash:et,fromBlock:eo,toBlock:es,event:ec,events:el,args:ed,strict:eh}={}){let ef=eh??!1,ep=el??(ec?[ec]:void 0),eg=[];return ep&&(eg=[ep.flatMap(c=>encodeEventTopics({abi:[c],eventName:c.name,args:ed}))],ec&&(eg=eg[0])),(et?await c.request({method:"eth_getLogs",params:[{address:l,topics:eg,blockHash:et}]}):await c.request({method:"eth_getLogs",params:[{address:l,topics:eg,fromBlock:"bigint"==typeof eo?(0,e_.eC)(eo):eo,toBlock:"bigint"==typeof es?(0,e_.eC)(es):es}]})).map(c=>{try{let{eventName:l,args:et}=ep?(0,e1.F)({abi:ep,data:c.data,topics:c.topics,strict:ef}):{eventName:void 0,args:void 0};return formatLog(c,{args:et,eventName:l})}catch(eo){let l,et;if(eo instanceof e$.SM||eo instanceof e$.Gy){if(ef)return;l=eo.abiItem.name,et=eo.abiItem.inputs?.some(c=>!("name"in c&&c.name))}return formatLog(c,{args:et?[]:{},eventName:l})}}).filter(Boolean)}async function getContractEvents(c,{abi:l,address:et,args:eo,blockHash:es,eventName:ec,fromBlock:el,toBlock:ed,strict:eh}){let ef=ec?(0,eW.m)({abi:l,name:ec}):void 0,ep=ef?void 0:l.filter(c=>"event"===c.type);return getLogs(c,{address:et,args:eo,blockHash:es,event:ef,events:ep,fromBlock:el,toBlock:ed,strict:eh})}async function getFeeHistory(c,{blockCount:l,blockNumber:et,blockTag:eo="latest",rewardPercentiles:es}){let ec=et?(0,e_.eC)(et):void 0,el=await c.request({method:"eth_feeHistory",params:[(0,e_.eC)(l),ec||eo,es]});return{baseFeePerGas:el.baseFeePerGas.map(c=>BigInt(c)),gasUsedRatio:el.gasUsedRatio,oldestBlock:BigInt(el.oldestBlock),reward:el.reward?.map(c=>c.map(c=>BigInt(c)))}}async function getFilterChanges(c,{filter:l}){let et="strict"in l&&l.strict,eo=await l.request({method:"eth_getFilterChanges",params:[l.id]});return eo.map(c=>{if("string"==typeof c)return c;try{let{eventName:eo,args:es}="abi"in l&&l.abi?(0,e1.F)({abi:l.abi,data:c.data,topics:c.topics,strict:et}):{eventName:void 0,args:void 0};return formatLog(c,{args:es,eventName:eo})}catch(es){let et,eo;if(es instanceof e$.SM||es instanceof e$.Gy){if("strict"in l&&l.strict)return;et=es.abiItem.name,eo=es.abiItem.inputs?.some(c=>!("name"in c&&c.name))}return formatLog(c,{args:eo?[]:{},eventName:et})}}).filter(Boolean)}async function getFilterLogs(c,{filter:l}){let et=l.strict??!1,eo=await l.request({method:"eth_getFilterLogs",params:[l.id]});return eo.map(c=>{try{let{eventName:eo,args:es}="abi"in l&&l.abi?(0,e1.F)({abi:l.abi,data:c.data,topics:c.topics,strict:et}):{eventName:void 0,args:void 0};return formatLog(c,{args:es,eventName:eo})}catch(es){let et,eo;if(es instanceof e$.SM||es instanceof e$.Gy){if("strict"in l&&l.strict)return;et=es.abiItem.name,eo=es.abiItem.inputs?.some(c=>!("name"in c&&c.name))}return formatLog(c,{args:eo?[]:{},eventName:et})}}).filter(Boolean)}var e2=et(75188);async function getStorageAt(c,{address:l,blockNumber:et,blockTag:eo="latest",slot:es}){let ec=void 0!==et?(0,e_.eC)(et):void 0,el=await c.request({method:"eth_getStorageAt",params:[l,es,ec||eo]});return el}var e3=et(44818),e5=et(52017);async function getTransaction(c,{blockHash:l,blockNumber:et,blockTag:eo,hash:es,index:ec}){let el=eo||"latest",ed=void 0!==et?(0,e_.eC)(et):void 0,eh=null;if(es?eh=await c.request({method:"eth_getTransactionByHash",params:[es]}):l?eh=await c.request({method:"eth_getTransactionByBlockHashAndIndex",params:[l,(0,e_.eC)(ec)]}):(ed||el)&&(eh=await c.request({method:"eth_getTransactionByBlockNumberAndIndex",params:[ed||el,(0,e_.eC)(ec)]})),!eh)throw new e3.Bh({blockHash:l,blockNumber:et,blockTag:el,hash:es,index:ec});let ef=c.chain?.formatters?.transaction?.format||e5.Tr;return ef(eh)}async function getTransactionConfirmations(c,{hash:l,transactionReceipt:et}){let[eo,es]=await Promise.all([getBlockNumber(c),l?getTransaction(c,{hash:l}):void 0]),ec=et?.blockNumber||es?.blockNumber;return ec?eo-ec+1n:0n}var e6=et(31742);let e4={"0x0":"reverted","0x1":"success"};function formatTransactionReceipt(c){return{...c,blockNumber:c.blockNumber?BigInt(c.blockNumber):null,contractAddress:c.contractAddress?c.contractAddress:null,cumulativeGasUsed:c.cumulativeGasUsed?BigInt(c.cumulativeGasUsed):null,effectiveGasPrice:c.effectiveGasPrice?BigInt(c.effectiveGasPrice):null,gasUsed:c.gasUsed?BigInt(c.gasUsed):null,logs:c.logs?c.logs.map(c=>formatLog(c)):null,to:c.to?c.to:null,transactionIndex:c.transactionIndex?(0,eX.ly)(c.transactionIndex):null,status:c.status?e4[c.status]:null,type:c.type?e5.c8[c.type]||c.type:null}}async function getTransactionReceipt(c,{hash:l}){let et=await c.request({method:"eth_getTransactionReceipt",params:[l]});if(!et)throw new e3.Yb({hash:l});let eo=c.chain?.formatters?.transactionReceipt?.format||formatTransactionReceipt;return eo(et)}async function multicall(c,l){let{allowFailure:et=!0,batchSize:eo,blockNumber:es,blockTag:ec,contracts:el,multicallAddress:ed}=l,eh=eo??("object"==typeof c.batch?.multicall&&c.batch.multicall.batchSize||1024),ef=ed;if(!ef){if(!c.chain)throw Error("client chain not configured. multicallAddress is required.");ef=(0,eC.LI)({blockNumber:es,chain:c.chain,contract:"multicall3"})}let ep=[[]],eg=0,em=0;for(let c=0;c0&&em>eh&&ep[eg].length>0&&(eg++,em=(c.length-2)/2,ep[eg]=[]),ep[eg]=[...ep[eg],{allowFailure:!0,callData:c,target:eo}]}catch(el){let c=getContractError(el,{abi:l,address:eo,args:es,docsPath:"/docs/contract/multicall",functionName:ec});if(!et)throw c;ep[eg]=[...ep[eg],{allowFailure:!0,callData:"0x",target:eo}]}}let eb=await Promise.allSettled(ep.map(l=>readContract(c,{abi:eS.F8,address:ef,args:[l],blockNumber:es,blockTag:ec,functionName:"aggregate3"}))),ey=[];for(let c=0;c`${l} ${c}`).join(",")})`;return et}({primaryType:c,types:l}));return(0,eN.w)(et)}({primaryType:l,types:et})];for(let ec of et[l]){let[l,el]=function encodeField({types:c,name:l,type:et,value:eo}){if(void 0!==c[et])return[{type:"bytes32"},(0,eN.w)(encodeData({data:eo,primaryType:et,types:c}))];if("bytes"===et){let c=eo.length%2?"0":"";return eo=`0x${c+eo.slice(2)}`,[{type:"bytes32"},(0,eN.w)(eo)]}if("string"===et)return[{type:"bytes32"},(0,eN.w)((0,e_.NC)(eo))];if(et.lastIndexOf("]")===et.length-1){let es=et.slice(0,et.lastIndexOf("[")),ec=eo.map(et=>encodeField({name:l,type:es,types:c,value:et}));return[{type:"bytes32"},(0,eN.w)((0,ez.E)(ec.map(([c])=>c),ec.map(([,c])=>c)))]}return[{type:et},eo]}({types:et,name:ec.name,type:ec.type,value:c[ec.name]});eo.push(l),es.push(el)}return(0,ez.E)(eo,es)}({data:c,primaryType:l,types:et});return(0,eN.w)(eo)}async function verifyTypedData(c,{address:l,signature:et,message:eo,primaryType:es,types:ec,domain:el,...ed}){let eh=function({domain:c,message:l,primaryType:et,types:eo}){let es=void 0===c?{}:c,ec={EIP712Domain:(0,e9.cj)({domain:es}),...eo};(0,e9.iC)({domain:es,message:l,primaryType:et,types:ec});let el=["0x1901"];return es&&el.push(function({domain:c,types:l}){return hashStruct({data:c,primaryType:"EIP712Domain",types:l})}({domain:es,types:ec})),"EIP712Domain"!==et&&el.push(hashStruct({data:l,primaryType:et,types:ec})),(0,eN.w)((0,eO.zo)(el))}({message:eo,primaryType:es,types:ec,domain:el});return verifyHash(c,{address:l,hash:eh,signature:et,...ed})}let e7=new Map,tn=new Map,to=0;function observe(c,l,et){let eo=++to,getListeners=()=>e7.get(c)||[],unsubscribe=()=>{let l=getListeners();e7.set(c,l.filter(c=>c.id!==eo))},unwatch=()=>{let l=tn.get(c);1===getListeners().length&&l&&l(),unsubscribe()},es=getListeners();if(e7.set(c,[...es,{id:eo,fns:l}]),es&&es.length>0)return unwatch;let ec={};for(let c in l)ec[c]=(...l)=>{let et=getListeners();0!==et.length&&et.forEach(et=>et.fns[c]?.(...l))};let el=et(ec);return"function"==typeof el&&tn.set(c,el),unwatch}var ts=et(36063),ta=et(71891),tc=et(21810);function poll(c,{emitOnBegin:l,initialWaitTime:et,interval:eo}){let es=!0,unwatch=()=>es=!1,watch=async()=>{let ec;l&&(ec=await c({unpoll:unwatch}));let el=await et?.(ec)??eo;await (0,tc.D)(el);let poll=async()=>{es&&(await c({unpoll:unwatch}),await (0,tc.D)(eo),poll())};poll()};return watch(),unwatch}function watchBlockNumber(c,{emitOnBegin:l=!1,emitMissed:et=!1,onBlockNumber:eo,onError:es,poll:ec,pollingInterval:el=c.pollingInterval}){let ed,eh,ef;let ep=void 0!==ec?ec:"webSocket"!==c.transport.type;return ep?(()=>{let ec=(0,ta.P)(["watchBlockNumber",c.uid,l,et,el]);return observe(ec,{onBlockNumber:eo,onError:es},eo=>poll(async()=>{try{let l=await getBlockNumber(c,{cacheTime:0});if(ed){if(l===ed)return;if(l-ed>1&&et)for(let c=ed+1n;ced)&&(eo.onBlockNumber(l,ed),ed=l)}catch(c){eo.onError?.(c)}},{emitOnBegin:l,interval:el}))})():(eh=!0,ef=()=>eh=!1,(async()=>{try{let{unsubscribe:l}=await c.transport.subscribe({params:["newHeads"],onData(c){if(!eh)return;let l=(0,eX.y_)(c.result?.number);eo(l,ed),ed=l},onError(c){es?.(c)}});ef=l,eh||ef()}catch(c){es?.(c)}})(),ef)}async function waitForTransactionReceipt(c,{confirmations:l=1,hash:et,onReplaced:eo,pollingInterval:es=c.pollingInterval,timeout:ec}){let el,ed,eh;let ef=(0,ta.P)(["waitForTransactionReceipt",c.uid,et]),ep=!1;return new Promise((eg,em)=>{ec&&setTimeout(()=>em(new e3.mc({hash:et})),ec);let eb=observe(ef,{onReplaced:eo,resolve:eg,reject:em},eo=>{let ec=watchBlockNumber(c,{emitMissed:!0,emitOnBegin:!0,poll:!0,pollingInterval:es,async onBlockNumber(es){if(ep)return;let ef=es,done=c=>{ec(),c(),eb()};try{if(eh){if(l>1&&(!eh.blockNumber||ef-eh.blockNumber+1neo.resolve(eh));return}if(el||(ep=!0,await (0,ts.J)(async()=>{(el=await getTransaction(c,{hash:et})).blockNumber&&(ef=el.blockNumber)},{delay:({count:c})=>200*~~(1<1&&(!eh.blockNumber||ef-eh.blockNumber+1neo.resolve(eh))}catch(et){if(el&&(et instanceof e3.Bh||et instanceof e3.Yb))try{ed=el;let et=await (0,eQ.Q)(c,{blockNumber:ef,includeTransactions:!0}),es=et.transactions.find(({from:c,nonce:l})=>c===ed.from&&l===ed.nonce);if(!es||(eh=await getTransactionReceipt(c,{hash:es.hash}),l>1&&(!eh.blockNumber||ef-eh.blockNumber+1n{eo.onReplaced?.({reason:ec,replacedTransaction:ed,transaction:es,transactionReceipt:eh}),eo.resolve(eh)})}catch(c){done(()=>eo.reject(c))}else done(()=>eo.reject(et))}}})})})}var tl=et(78723),td=et(40044),th=et(73971);function publicActions(c){return{call:l=>(0,eB.R)(c,l),createBlockFilter:()=>createBlockFilter(c),createContractEventFilter:l=>createContractEventFilter(c,l),createEventFilter:l=>createEventFilter(c,l),createPendingTransactionFilter:()=>createPendingTransactionFilter(c),estimateContractGas:l=>estimateContractGas(c,l),estimateGas:l=>(0,eG.Q)(c,l),getBalance:l=>getBalance(c,l),getBlock:l=>(0,eQ.Q)(c,l),getBlockNumber:l=>getBlockNumber(c,l),getBlockTransactionCount:l=>getBlockTransactionCount(c,l),getBytecode:l=>getBytecode(c,l),getChainId:()=>(0,e0.L)(c),getContractEvents:l=>getContractEvents(c,l),getEnsAddress:l=>getEnsAddress(c,l),getEnsAvatar:l=>getEnsAvatar(c,l),getEnsName:l=>getEnsName(c,l),getEnsResolver:l=>getEnsResolver(c,l),getEnsText:l=>getEnsText(c,l),getFeeHistory:l=>getFeeHistory(c,l),estimateFeesPerGas:l=>(0,eK.X)(c,l),getFilterChanges:l=>getFilterChanges(c,l),getFilterLogs:l=>getFilterLogs(c,l),getGasPrice:()=>(0,e2.o)(c),getLogs:l=>getLogs(c,l),estimateMaxPriorityFeePerGas:l=>(0,eJ._)(c,l),getStorageAt:l=>getStorageAt(c,l),getTransaction:l=>getTransaction(c,l),getTransactionConfirmations:l=>getTransactionConfirmations(c,l),getTransactionCount:l=>(0,e6.K)(c,l),getTransactionReceipt:l=>getTransactionReceipt(c,l),multicall:l=>multicall(c,l),prepareTransactionRequest:l=>(0,td.Z)(c,l),readContract:l=>readContract(c,l),sendRawTransaction:l=>(0,th.p)(c,l),simulateContract:l=>simulateContract(c,l),verifyMessage:l=>verifyMessage(c,l),verifyTypedData:l=>verifyTypedData(c,l),uninstallFilter:l=>uninstallFilter(c,l),waitForTransactionReceipt:l=>waitForTransactionReceipt(c,l),watchBlocks:l=>(function(c,{blockTag:l="latest",emitMissed:et=!1,emitOnBegin:eo=!1,onBlock:es,onError:ec,includeTransactions:el,poll:ed,pollingInterval:eh=c.pollingInterval}){let ef,ep,eg;let em=void 0!==ed?ed:"webSocket"!==c.transport.type,eb=el??!1;return em?(()=>{let el=(0,ta.P)(["watchBlocks",c.uid,et,eo,eb,eh]);return observe(el,{onBlock:es,onError:ec},es=>poll(async()=>{try{let eo=await (0,eQ.Q)(c,{blockTag:l,includeTransactions:eb});if(eo.number&&ef?.number){if(eo.number===ef.number)return;if(eo.number-ef.number>1&&et)for(let l=ef?.number+1n;lef.number)&&(es.onBlock(eo,ef),ef=eo)}catch(c){es.onError?.(c)}},{emitOnBegin:eo,interval:eh}))})():(ep=!0,eg=()=>ep=!1,(async()=>{try{let{unsubscribe:l}=await c.transport.subscribe({params:["newHeads"],onData(l){if(!ep)return;let et=c.chain?.formatters?.block?.format||tl.Z,eo=et(l.result);es(eo,ef),ef=eo},onError(c){ec?.(c)}});eg=l,ep||eg()}catch(c){ec?.(c)}})(),eg)})(c,l),watchBlockNumber:l=>watchBlockNumber(c,l),watchContractEvent:l=>(function(c,{abi:l,address:et,args:eo,batch:es=!0,eventName:ec,onError:el,onLogs:ed,poll:eh,pollingInterval:ef=c.pollingInterval,strict:ep}){let eg,eb;let ey=void 0!==eh?eh:"webSocket"!==c.transport.type;return ey?(()=>{let eh=(0,ta.P)(["watchContractEvent",et,eo,es,c.uid,ec,ef]),eg=ep??!1;return observe(eh,{onLogs:ed,onError:el},el=>{let ed,eh;let ep=!1,eb=poll(async()=>{if(!ep){try{eh=await createContractEventFilter(c,{abi:l,address:et,args:eo,eventName:ec,strict:eg})}catch{}ep=!0;return}try{let ec;if(eh)ec=await getFilterChanges(c,{filter:eh});else{let es=await getBlockNumber(c);ec=ed&&ed!==es?await getContractEvents(c,{abi:l,address:et,args:eo,fromBlock:ed+1n,toBlock:es,strict:eg}):[],ed=es}if(0===ec.length)return;es?el.onLogs(ec):ec.forEach(c=>el.onLogs([c]))}catch(c){eh&&c instanceof em.yR&&(ep=!1),el.onError?.(c)}},{emitOnBegin:!0,interval:ef});return async()=>{eh&&await uninstallFilter(c,{filter:eh}),eb()}})})():(eg=!0,eb=()=>eg=!1,(async()=>{try{let es=ec?encodeEventTopics({abi:l,eventName:ec,args:eo}):[],{unsubscribe:eh}=await c.transport.subscribe({params:["logs",{address:et,topics:es}],onData(c){if(!eg)return;let et=c.result;try{let{eventName:c,args:eo}=(0,e1.F)({abi:l,data:et.data,topics:et.topics,strict:ep}),es=formatLog(et,{args:eo,eventName:c});ed([es])}catch(es){let c,l;if(es instanceof e$.SM||es instanceof e$.Gy){if(ep)return;c=es.abiItem.name,l=es.abiItem.inputs?.some(c=>!("name"in c&&c.name))}let eo=formatLog(et,{args:l?[]:{},eventName:c});ed([eo])}},onError(c){el?.(c)}});eb=eh,eg||eb()}catch(c){el?.(c)}})(),eb)})(c,l),watchEvent:l=>(function(c,{address:l,args:et,batch:eo=!0,event:es,events:ec,onError:el,onLogs:ed,poll:eh,pollingInterval:ef=c.pollingInterval,strict:ep}){let eg,eb;let ey=void 0!==eh?eh:"webSocket"!==c.transport.type,e_=ep??!1;return ey?(()=>{let eh=(0,ta.P)(["watchEvent",l,et,eo,c.uid,es,ef]);return observe(eh,{onLogs:ed,onError:el},el=>{let ed,eh;let ep=!1,eg=poll(async()=>{if(!ep){try{eh=await createEventFilter(c,{address:l,args:et,event:es,events:ec,strict:e_})}catch{}ep=!0;return}try{let ef;if(eh)ef=await getFilterChanges(c,{filter:eh});else{let eo=await getBlockNumber(c);ef=ed&&ed!==eo?await getLogs(c,{address:l,args:et,event:es,events:ec,fromBlock:ed+1n,toBlock:eo}):[],ed=eo}if(0===ef.length)return;eo?el.onLogs(ef):ef.forEach(c=>el.onLogs([c]))}catch(c){eh&&c instanceof em.yR&&(ep=!1),el.onError?.(c)}},{emitOnBegin:!0,interval:ef});return async()=>{eh&&await uninstallFilter(c,{filter:eh}),eg()}})})():(eg=!0,eb=()=>eg=!1,(async()=>{try{let eo=ec??(es?[es]:void 0),eh=[];eo&&(eh=[eo.flatMap(c=>encodeEventTopics({abi:[c],eventName:c.name,args:et}))],es&&(eh=eh[0]));let{unsubscribe:ef}=await c.transport.subscribe({params:["logs",{address:l,topics:eh}],onData(c){if(!eg)return;let l=c.result;try{let{eventName:c,args:et}=(0,e1.F)({abi:eo,data:l.data,topics:l.topics,strict:e_}),es=formatLog(l,{args:et,eventName:c});ed([es])}catch(es){let c,et;if(es instanceof e$.SM||es instanceof e$.Gy){if(ep)return;c=es.abiItem.name,et=es.abiItem.inputs?.some(c=>!("name"in c&&c.name))}let eo=formatLog(l,{args:et?[]:{},eventName:c});ed([eo])}},onError(c){el?.(c)}});eb=ef,eg||eb()}catch(c){el?.(c)}})(),eb)})(c,l),watchPendingTransactions:l=>(function(c,{batch:l=!0,onError:et,onTransactions:eo,poll:es,pollingInterval:ec=c.pollingInterval}){let el,ed;let eh=void 0!==es?es:"webSocket"!==c.transport.type;return eh?(()=>{let es=(0,ta.P)(["watchPendingTransactions",c.uid,l,ec]);return observe(es,{onTransactions:eo,onError:et},et=>{let eo;let es=poll(async()=>{try{if(!eo)try{eo=await createPendingTransactionFilter(c);return}catch(c){throw es(),c}let ec=await getFilterChanges(c,{filter:eo});if(0===ec.length)return;l?et.onTransactions(ec):ec.forEach(c=>et.onTransactions([c]))}catch(c){et.onError?.(c)}},{emitOnBegin:!0,interval:ec});return async()=>{eo&&await uninstallFilter(c,{filter:eo}),es()}})})():(el=!0,ed=()=>el=!1,(async()=>{try{let{unsubscribe:l}=await c.transport.subscribe({params:["newPendingTransactions"],onData(c){if(!el)return;let l=c.result;eo([l])},onError(c){et?.(c)}});ed=l,el||ed()}catch(c){et?.(c)}})(),ed)})(c,l)}}function createPublicClient(c){let{key:l="public",name:et="Public Client"}=c,eo=(0,eE.e)({...c,key:l,name:et,type:"publicClient"});return eo.extend(publicActions)}var tf=et(35215),tp=et(68124);function fallback(c,l={}){let{key:et="fallback",name:eo="Fallback",rank:es=!1,retryCount:ec,retryDelay:el}=l;return({chain:l,pollingInterval:ed=4e3,timeout:eh})=>{let ef=c,onResponse=()=>{},ep=(0,tp.q)({key:et,name:eo,async request({method:c,params:et}){let fetch=async(eo=0)=>{let es=ef[eo]({chain:l,retryCount:0,timeout:eh});try{let l=await es.request({method:c,params:et});return onResponse({method:c,params:et,response:l,transport:es,status:"success"}),l}catch(l){if(onResponse({error:l,method:c,params:et,transport:es,status:"error"}),(0,tf.y)(l)||eo===ef.length-1)throw l;return fetch(eo+1)}};return fetch()},retryCount:ec,retryDelay:el,type:"fallback"},{onResponse:c=>onResponse=c,transports:ef.map(c=>c({chain:l,retryCount:0}))});if(es){let c="object"==typeof es?es:{};!function({chain:c,interval:l=4e3,onTransports:et,sampleCount:eo=10,timeout:es=1e3,transports:ec,weights:el={}}){let{stability:ed=.7,latency:eh=.3}=el,ef=[],rankTransports_=async()=>{let el=await Promise.all(ec.map(async l=>{let et,eo;let ec=l({chain:c,retryCount:0,timeout:es}),el=Date.now();try{await ec.request({method:"net_listening"}),eo=1}catch{eo=0}finally{et=Date.now()}let ed=et-el;return{latency:ed,success:eo}}));ef.push(el),ef.length>eo&&ef.shift();let ep=Math.max(...ef.map(c=>Math.max(...c.map(({latency:c})=>c)))),eg=ec.map((c,l)=>{let et=ef.map(c=>c[l].latency),eo=et.reduce((c,l)=>c+l,0)/et.length,es=ef.map(c=>c[l].success),ec=es.reduce((c,l)=>c+l,0)/es.length;return 0===ec?[0,l]:[eh*(1-eo/ep)+ed*ec,l]}).sort((c,l)=>l[0]-c[0]);et(eg.map(([,c])=>ec[c])),await (0,tc.D)(l),rankTransports_()};rankTransports_()}({chain:l,interval:c.interval??ed,onTransports:c=>ef=c,sampleCount:c.sampleCount,timeout:c.timeout,transports:ef,weights:c.weights})}return ep}}var tg=et(20722);let UrlRequiredError=class UrlRequiredError extends eP.G{constructor(){super("No URL was provided to the Transport. Please provide a valid RPC URL to the Transport.",{docsPath:"/docs/clients/intro"})}};var tm=et(33668),tb=null;"undefined"!=typeof WebSocket?tb=WebSocket:"undefined"!=typeof MozWebSocket?tb=MozWebSocket:void 0!==et.g?tb=et.g.WebSocket||et.g.MozWebSocket:"undefined"!=typeof window?tb=window.WebSocket||window.MozWebSocket:"undefined"!=typeof self&&(tb=self.WebSocket||self.MozWebSocket);var ty=tb;function withTimeout(c,{errorInstance:l,timeout:et,signal:eo}){return new Promise((es,ec)=>{(async()=>{let el;try{let ed=new AbortController;et>0&&(el=setTimeout(()=>{eo?ed.abort():ec(l)},et)),es(await c({signal:ed?.signal}))}catch(c){"AbortError"===c.name&&ec(l),ec(c)}finally{clearTimeout(el)}})()})}let t_=0;async function http(c,{body:l,fetchOptions:et={},timeout:eo=1e4}){let{headers:es,method:ec,signal:el}=et;try{let ed;let eh=await withTimeout(async({signal:ed})=>{let eh=await fetch(c,{...et,body:Array.isArray(l)?(0,ta.P)(l.map(c=>({jsonrpc:"2.0",id:c.id??t_++,...c}))):(0,ta.P)({jsonrpc:"2.0",id:l.id??t_++,...l}),headers:{...es,"Content-Type":"application/json"},method:ec||"POST",signal:el||(eo>0?ed:void 0)});return eh},{errorInstance:new tg.W5({body:l,url:c}),timeout:eo,signal:!0});if(ed=eh.headers.get("Content-Type")?.startsWith("application/json")?await eh.json():await eh.text(),!eh.ok)throw new tg.Gg({body:l,details:(0,ta.P)(ed.error)||eh.statusText,headers:eh.headers,status:eh.status,url:c});return ed}catch(et){if(et instanceof tg.Gg||et instanceof tg.W5)throw et;throw new tg.Gg({body:l,details:et.message,url:c})}}let tw=new Map;async function getSocket(c){let l=tw.get(c);if(l)return l;let{schedule:et}=(0,tm.S)({id:c,fn:async()=>{let et=ty;ty.constructor||(et=ty.WebSocket);let eo=new et(c),es=new Map,ec=new Map,onMessage=({data:c})=>{let l=JSON.parse(c),et="eth_subscription"===l.method,eo=et?l.params.subscription:l.id,el=et?ec:es,ed=el.get(eo);ed&&ed({data:c}),et||el.delete(eo)},onClose=()=>{tw.delete(c),eo.removeEventListener("close",onClose),eo.removeEventListener("message",onMessage)};return eo.addEventListener("close",onClose),eo.addEventListener("message",onMessage),eo.readyState===ty.CONNECTING&&await new Promise((c,l)=>{eo&&(eo.onopen=c,eo.onerror=l)}),l=Object.assign(eo,{requests:es,subscriptions:ec}),tw.set(c,l),[l]}}),[eo,[es]]=await et();return es}async function webSocketAsync(c,{body:l,timeout:et=1e4}){return withTimeout(()=>new Promise(et=>tE.webSocket(c,{body:l,onResponse:et})),{errorInstance:new tg.W5({body:l,url:c.url}),timeout:et})}let tE={http,webSocket:function(c,{body:l,onResponse:et}){if(c.readyState===c.CLOSED||c.readyState===c.CLOSING)throw new tg.c9({body:l,url:c.url,details:"Socket is closed."});let eo=t_++,callback=({data:es})=>{let ec=JSON.parse(es);("number"!=typeof ec.id||eo===ec.id)&&(et?.(ec),"eth_subscribe"===l.method&&"string"==typeof ec.result&&c.subscriptions.set(ec.result,callback),"eth_unsubscribe"===l.method&&c.subscriptions.delete(l.params?.[0]))};return c.requests.set(eo,callback),c.send(JSON.stringify({jsonrpc:"2.0",...l,id:eo})),c},webSocketAsync},subscribeWithSelector=c=>(l,et,eo)=>{let es=eo.subscribe;eo.subscribe=(c,l,et)=>{let ec=c;if(l){let es=(null==et?void 0:et.equalityFn)||Object.is,el=c(eo.getState());ec=et=>{let eo=c(et);if(!es(el,eo)){let c=el;l(el=eo,c)}},(null==et?void 0:et.fireImmediately)&&l(el,el)}return es(ec)};let ec=c(l,et,eo);return ec},toThenable=c=>l=>{try{let et=c(l);if(et instanceof Promise)return et;return{then:c=>toThenable(c)(et),catch(c){return this}}}catch(c){return{then(c){return this},catch:l=>toThenable(l)(c)}}},oldImpl=(c,l)=>(et,eo,es)=>{let ec,el,ed={getStorage:()=>localStorage,serialize:JSON.stringify,deserialize:JSON.parse,partialize:c=>c,version:0,merge:(c,l)=>({...l,...c}),...l},eh=!1,ef=new Set,ep=new Set;try{ec=ed.getStorage()}catch(c){}if(!ec)return c((...c)=>{console.warn(`[zustand persist middleware] Unable to update item '${ed.name}', the given storage is currently unavailable.`),et(...c)},eo,es);let eg=toThenable(ed.serialize),setItem=()=>{let c;let l=ed.partialize({...eo()}),et=eg({state:l,version:ed.version}).then(c=>ec.setItem(ed.name,c)).catch(l=>{c=l});if(c)throw c;return et},em=es.setState;es.setState=(c,l)=>{em(c,l),setItem()};let eb=c((...c)=>{et(...c),setItem()},eo,es),hydrate=()=>{var c;if(!ec)return;eh=!1,ef.forEach(c=>c(eo()));let l=(null==(c=ed.onRehydrateStorage)?void 0:c.call(ed,eo()))||void 0;return toThenable(ec.getItem.bind(ec))(ed.name).then(c=>{if(c)return ed.deserialize(c)}).then(c=>{if(c){if("number"!=typeof c.version||c.version===ed.version)return c.state;if(ed.migrate)return ed.migrate(c.state,c.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}}).then(c=>{var l;return et(el=ed.merge(c,null!=(l=eo())?l:eb),!0),setItem()}).then(()=>{null==l||l(el,void 0),eh=!0,ep.forEach(c=>c(el))}).catch(c=>{null==l||l(void 0,c)})};return es.persist={setOptions:c=>{ed={...ed,...c},c.getStorage&&(ec=c.getStorage())},clearStorage:()=>{null==ec||ec.removeItem(ed.name)},getOptions:()=>ed,rehydrate:()=>hydrate(),hasHydrated:()=>eh,onHydrate:c=>(ef.add(c),()=>{ef.delete(c)}),onFinishHydration:c=>(ep.add(c),()=>{ep.delete(c)})},hydrate(),el||eb},newImpl=(c,l)=>(et,eo,es)=>{let ec,el={storage:function(c,l){let et;try{et=c()}catch(c){return}return{getItem:c=>{var eo;let parse=c=>null===c?null:JSON.parse(c,null==l?void 0:l.reviver),es=null!=(eo=et.getItem(c))?eo:null;return es instanceof Promise?es.then(parse):parse(es)},setItem:(c,eo)=>et.setItem(c,JSON.stringify(eo,null==l?void 0:l.replacer)),removeItem:c=>et.removeItem(c)}}(()=>localStorage),partialize:c=>c,version:0,merge:(c,l)=>({...l,...c}),...l},ed=!1,eh=new Set,ef=new Set,ep=el.storage;if(!ep)return c((...c)=>{console.warn(`[zustand persist middleware] Unable to update item '${el.name}', the given storage is currently unavailable.`),et(...c)},eo,es);let setItem=()=>{let c=el.partialize({...eo()});return ep.setItem(el.name,{state:c,version:el.version})},eg=es.setState;es.setState=(c,l)=>{eg(c,l),setItem()};let em=c((...c)=>{et(...c),setItem()},eo,es),hydrate=()=>{var c,l;if(!ep)return;ed=!1,eh.forEach(c=>{var l;return c(null!=(l=eo())?l:em)});let es=(null==(l=el.onRehydrateStorage)?void 0:l.call(el,null!=(c=eo())?c:em))||void 0;return toThenable(ep.getItem.bind(ep))(el.name).then(c=>{if(c){if("number"!=typeof c.version||c.version===el.version)return c.state;if(el.migrate)return el.migrate(c.state,c.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}}).then(c=>{var l;return et(ec=el.merge(c,null!=(l=eo())?l:em),!0),setItem()}).then(()=>{null==es||es(ec,void 0),ec=eo(),ed=!0,ef.forEach(c=>c(ec))}).catch(c=>{null==es||es(void 0,c)})};return es.persist={setOptions:c=>{el={...el,...c},c.storage&&(ep=c.storage)},clearStorage:()=>{null==ep||ep.removeItem(el.name)},getOptions:()=>el,rehydrate:()=>hydrate(),hasHydrated:()=>ed,onHydrate:c=>(eh.add(c),()=>{eh.delete(c)}),onFinishHydration:c=>(ef.add(c),()=>{ef.delete(c)})},el.skipHydration||hydrate(),ec||em},persist=(c,l)=>"getStorage"in l||"serialize"in l||"deserialize"in l?(console.warn("[DEPRECATED] `getStorage`, `serialize` and `deserialize` options are deprecated. Use `storage` option instead."),oldImpl(c,l)):newImpl(c,l),createStoreImpl=c=>{let l;let et=new Set,setState=(c,eo)=>{let es="function"==typeof c?c(l):c;if(!Object.is(es,l)){let c=l;l=(null!=eo?eo:"object"!=typeof es)?es:Object.assign({},l,es),et.forEach(et=>et(l,c))}},getState=()=>l,eo={setState,getState,subscribe:c=>(et.add(c),()=>et.delete(c)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),et.clear()}};return l=c(setState,getState,eo),eo},createStore=c=>c?createStoreImpl(c):createStoreImpl;function shallow$1(c,l){if(Object.is(c,l))return!0;if("object"!=typeof c||null===c||"object"!=typeof l||null===l)return!1;if(c instanceof Map&&l instanceof Map){if(c.size!==l.size)return!1;for(let[et,eo]of c)if(!Object.is(eo,l.get(et)))return!1;return!0}if(c instanceof Set&&l instanceof Set){if(c.size!==l.size)return!1;for(let et of c)if(!l.has(et))return!1;return!0}let et=Object.keys(c);if(et.length!==Object.keys(l).length)return!1;for(let eo=0;eoc===et.id)||(eh=[...eh,l.chain]),ef[et.id]=[...ef[et.id]||[],...l.rpcUrls.http],l.rpcUrls.webSocket&&(ep[et.id]=[...ep[et.id]||[],...l.rpcUrls.webSocket]))}if(!c)throw Error(`Could not find valid provider configuration for chain "${et.name}". + +You may need to add \`jsonRpcProvider\` to \`configureChains\` with the chain's RPC URLs. +Read more: https://wagmi.sh/core/providers/jsonRpc`)}return{chains:eh,publicClient:({chainId:l})=>{let ep=eh.find(c=>c.id===l)??c[0],eg=ef[ep.id];if(!eg||!eg[0])throw Error(`No providers configured for chain "${ep.id}"`);let em=createPublicClient({batch:et,chain:ep,transport:fallback(eg.map(c=>(function(c,l={}){let{batch:et,fetchOptions:eo,key:es="http",name:ec="HTTP JSON-RPC",retryDelay:el}=l;return({chain:ed,retryCount:eh,timeout:ef})=>{let{batchSize:ep=1e3,wait:eg=0}="object"==typeof et?et:{},em=l.retryCount??eh,eb=ef??l.timeout??1e4,ey=c||ed?.rpcUrls.default.http[0];if(!ey)throw new UrlRequiredError;return(0,tp.q)({key:es,name:ec,async request({method:l,params:es}){let ec={method:l,params:es},{schedule:el}=(0,tm.S)({id:`${c}`,wait:eg,shouldSplitBatch:c=>c.length>ep,fn:c=>tE.http(ey,{body:c,fetchOptions:eo,timeout:eb})}),fn=async c=>et?el(c):[await tE.http(ey,{body:c,fetchOptions:eo,timeout:eb})],[{error:ed,result:eh}]=await fn(ec);if(ed)throw new tg.bs({body:ec,error:ed,url:ey});return eh},retryCount:em,retryDelay:el,timeout:eb,type:"http"},{url:c})}})(c,{timeout:ed})),{rank:es,retryCount:ec,retryDelay:el}),pollingInterval:eo});return Object.assign(em,{chains:eh})},webSocketPublicClient:({chainId:l})=>{let ef=eh.find(c=>c.id===l)??c[0],eg=ep[ef.id];if(!eg||!eg[0])return;let em=createPublicClient({batch:et,chain:ef,transport:fallback(eg.map(c=>(function(c,l={}){let{key:et="webSocket",name:eo="WebSocket JSON-RPC",retryDelay:es}=l;return({chain:ec,retryCount:el,timeout:ed})=>{let eh=l.retryCount??el,ef=ed??l.timeout??1e4,ep=c||ec?.rpcUrls.default.webSocket?.[0];if(!ep)throw new UrlRequiredError;return(0,tp.q)({key:et,name:eo,async request({method:c,params:l}){let et={method:c,params:l},eo=await getSocket(ep),{error:es,result:ec}=await tE.webSocketAsync(eo,{body:et,timeout:ef});if(es)throw new tg.bs({body:et,error:es,url:ep});return ec},retryCount:eh,retryDelay:es,timeout:ef,type:"webSocket"},{getSocket:()=>getSocket(ep),async subscribe({params:c,onData:l,onError:et}){let eo=await getSocket(ep),{result:es}=await new Promise((es,ec)=>tE.webSocket(eo,{body:{method:"eth_subscribe",params:c},onResponse(c){if(c.error){ec(c.error),et?.(c.error);return}if("number"==typeof c.id){es(c);return}"eth_subscription"===c.method&&l(c.params)}}));return{subscriptionId:es,unsubscribe:async()=>new Promise(c=>tE.webSocket(eo,{body:{method:"eth_unsubscribe",params:[es]},onResponse:c}))}}})}})(c,{timeout:ed})),{rank:es,retryCount:ec,retryDelay:el}),pollingInterval:eo});return Object.assign(em,{chains:eh})}}}var tS=class extends Error{constructor({activeChain:c,targetChain:l}){super(`Chain mismatch: Expected "${l}", received "${c}".`),this.name="ChainMismatchError"}},tx=class extends Error{constructor({chainId:c,connectorId:l}){super(`Chain "${c}" not configured${l?` for connector "${l}"`:""}.`),this.name="ChainNotConfigured"}},findAndReplace=(c,{find:l,replace:et})=>c&&l(c)?et(c):"object"!=typeof c?c:Array.isArray(c)?c.map(c=>findAndReplace(c,{find:l,replace:et})):c instanceof Object?Object.entries(c).reduce((c,[eo,es])=>({...c,[eo]:findAndReplace(es,{find:l,replace:et})}),{}):c;function deserialize(c){let l=JSON.parse(c),et=findAndReplace(l,{find:c=>"string"==typeof c&&c.startsWith("#bigint."),replace:c=>BigInt(c.replace("#bigint.",""))});return et}function getSendTransactionParameters(c){return{accessList:c.accessList,account:c.account,data:c.data,gas:c.gas,gasPrice:c.gasPrice,maxFeePerGas:c.maxFeePerGas,maxPriorityFeePerGas:c.maxPriorityFeePerGas,nonce:c.nonce,to:c.to,value:c.value}}function getReferenceKey(c,l){return c.slice(0,l).join(".")||"."}function getCutoff(c,l){let{length:et}=c;for(let eo=0;eo{let eo="bigint"==typeof et?`#bigint.${et.toString()}`:et;return l?.(c,eo)||eo},eo),et??void 0)}var tk={getItem:c=>"",setItem:(c,l)=>null,removeItem:c=>null};function createStorage({deserialize:c=deserialize,key:l="wagmi",serialize:et=serialize,storage:eo}){return{...eo,getItem:(et,es=null)=>{let ec=eo.getItem(`${l}.${et}`);try{return ec?c(ec):es}catch(c){return console.warn(c),es}},setItem:(c,es)=>{if(null===es)eo.removeItem(`${l}.${c}`);else try{eo.setItem(`${l}.${c}`,et(es))}catch(c){console.error(c)}},removeItem:c=>eo.removeItem(`${l}.${c}`)}}var tC="store",tA=class{constructor({autoConnect:c=!1,connectors:l=[new ew],publicClient:et,storage:eo=createStorage({storage:"undefined"!=typeof window?window.localStorage:tk}),logger:eh={warn:console.warn},webSocketPublicClient:ef}){let ep;__privateAdd(this,el),this.publicClients=new Map,this.webSocketPublicClients=new Map,__privateAdd(this,es,void 0),__privateAdd(this,ec,void 0),this.args={autoConnect:c,connectors:l,logger:eh,publicClient:et,storage:eo,webSocketPublicClient:ef};let eg="disconnected";if(c)try{let c=eo.getItem(tC),l=c?.state?.data;eg=l?.account?"reconnecting":"connecting",ep=l?.chain?.id}catch(c){}let em="function"==typeof l?l():l;em.forEach(c=>c.setStorage(eo)),this.store=createStore(subscribeWithSelector(persist(()=>({connectors:em,publicClient:this.getPublicClient({chainId:ep}),status:eg,webSocketPublicClient:this.getWebSocketPublicClient({chainId:ep})}),{name:tC,storage:eo,partialize:l=>({...c&&{data:{account:l?.data?.account,chain:l?.data?.chain}},chains:l?.chains}),version:2}))),this.storage=eo,__privateSet(this,ec,eo?.getItem("wallet")),__privateMethod(this,el,ed).call(this),c&&"undefined"!=typeof window&&setTimeout(async()=>await this.autoConnect(),0)}get chains(){return this.store.getState().chains}get connectors(){return this.store.getState().connectors}get connector(){return this.store.getState().connector}get data(){return this.store.getState().data}get error(){return this.store.getState().error}get lastUsedChainId(){return this.data?.chain?.id}get publicClient(){return this.store.getState().publicClient}get status(){return this.store.getState().status}get subscribe(){return this.store.subscribe}get webSocketPublicClient(){return this.store.getState().webSocketPublicClient}setState(c){let l="function"==typeof c?c(this.store.getState()):c;this.store.setState(l,!0)}clearState(){this.setState(c=>({...c,chains:void 0,connector:void 0,data:void 0,error:void 0,status:"disconnected"}))}async destroy(){this.connector&&await this.connector.disconnect?.(),__privateSet(this,es,!1),this.clearState(),this.store.destroy()}async autoConnect(){if(__privateGet(this,es))return;__privateSet(this,es,!0),this.setState(c=>({...c,status:c.data?.account?"reconnecting":"connecting"}));let c=__privateGet(this,ec)?[...this.connectors].sort(c=>c.id===__privateGet(this,ec)?-1:1):this.connectors,l=!1;for(let et of c){if(!et.ready||!et.isAuthorized)continue;let c=await et.isAuthorized();if(!c)continue;let eo=await et.connect();this.setState(c=>({...c,connector:et,chains:et?.chains,data:eo,status:"connected"})),l=!0;break}return l||this.setState(c=>({...c,data:void 0,status:"disconnected"})),__privateSet(this,es,!1),this.data}setConnectors(c){this.args={...this.args,connectors:c};let l="function"==typeof c?c():c;l.forEach(c=>c.setStorage(this.args.storage)),this.setState(c=>({...c,connectors:l}))}getPublicClient({chainId:c}={}){let l=this.publicClients.get(-1);if(l&&l?.chain.id===c||(l=this.publicClients.get(c??-1)))return l;let{publicClient:et}=this.args;return l="function"==typeof et?et({chainId:c}):et,this.publicClients.set(c??-1,l),l}setPublicClient(c){let l=this.data?.chain?.id;this.args={...this.args,publicClient:c},this.publicClients.clear(),this.setState(c=>({...c,publicClient:this.getPublicClient({chainId:l})}))}getWebSocketPublicClient({chainId:c}={}){let l=this.webSocketPublicClients.get(-1);if(l&&l?.chain.id===c||(l=this.webSocketPublicClients.get(c??-1)))return l;let{webSocketPublicClient:et}=this.args;return(l="function"==typeof et?et({chainId:c}):et)&&this.webSocketPublicClients.set(c??-1,l),l}setWebSocketPublicClient(c){let l=this.data?.chain?.id;this.args={...this.args,webSocketPublicClient:c},this.webSocketPublicClients.clear(),this.setState(c=>({...c,webSocketPublicClient:this.getWebSocketPublicClient({chainId:l})}))}setLastUsedConnector(c=null){this.storage?.setItem("wallet",c)}};function createConfig(c){let l=new tA(c);return eh=l,l}function getConfig(){if(!eh)throw Error("No wagmi config found. Ensure you have set up a config: https://wagmi.sh/react/config");return eh}async function disconnect(){let c=getConfig();c.connector&&await c.connector.disconnect(),c.clearState(),c.storage.removeItem("connected")}function getPublicClient({chainId:c}={}){let l=getConfig();return c&&l.getPublicClient({chainId:c})||l.publicClient}async function getWalletClient({chainId:c}={}){let l=getConfig(),et=await l.connector?.getWalletClient?.({chainId:c})||null;return et}function getWebSocketPublicClient({chainId:c}={}){let l=getConfig();return c&&l.getWebSocketPublicClient({chainId:c})||l.webSocketPublicClient}function watchPublicClient(c,l){let et=getConfig(),handleChange=async()=>l(getPublicClient(c)),eo=et.subscribe(({publicClient:c})=>c,handleChange);return eo}function watchWalletClient({chainId:c},l){let et=getConfig(),handleChange=async({chainId:et})=>{if(c&&et&&c!==et)return;let eo=await getWalletClient({chainId:c});return getConfig().connector?l(eo):l(null)},eo=et.subscribe(({data:c,connector:l})=>({account:c?.account,chainId:c?.chain?.id,connector:l}),handleChange,{equalityFn:shallow$1});return eo}function watchWebSocketPublicClient(c,l){let et=getConfig(),handleChange=async()=>l(getWebSocketPublicClient(c)),eo=et.subscribe(({webSocketPublicClient:c})=>c,handleChange);return eo}async function prepareWriteContract({abi:c,address:l,args:et,chainId:eo,functionName:es,walletClient:ec,...el}){let ed=getPublicClient({chainId:eo}),eh=ec??await getWalletClient({chainId:eo});if(!eh)throw new ef.N;eo&&assertActiveChain({chainId:eo});let{account:ep,accessList:eg,blockNumber:em,blockTag:eb,gas:ey,gasPrice:e_,maxFeePerGas:ew,maxPriorityFeePerGas:eE,nonce:eS,value:ex}={accessList:el.accessList,account:el.account,blockNumber:el.blockNumber,blockTag:el.blockTag,data:el.data,gas:el.gas,gasPrice:el.gasPrice,maxFeePerGas:el.maxFeePerGas,maxPriorityFeePerGas:el.maxPriorityFeePerGas,nonce:el.nonce,to:el.to,value:el.value},{result:ek,request:eC}=await ed.simulateContract({abi:c,address:l,functionName:es,args:et,account:ep||eh.account,accessList:eg,blockNumber:em,blockTag:eb,gas:ey,gasPrice:e_,maxFeePerGas:ew,maxPriorityFeePerGas:eE,nonce:eS,value:ex}),eA=c.filter(c=>"name"in c&&c.name===es);return{mode:"prepared",request:{...eC,abi:eA,chainId:eo},result:ek}}async function chunk_YAPWLAI7_readContract({address:c,account:l,chainId:et,abi:eo,args:es,functionName:ec,blockNumber:el,blockTag:ed}){let eh=getPublicClient({chainId:et});return eh.readContract({abi:eo,address:c,account:l,functionName:ec,args:es,blockNumber:el,blockTag:ed})}async function writeContract(c){let l;let et=await getWalletClient({chainId:c.chainId});if(!et)throw new ef.N;if(c.chainId&&assertActiveChain({chainId:c.chainId}),"prepared"===c.mode)l=c.request;else{let{chainId:et,mode:eo,...es}=c,ec=await prepareWriteContract(es);l=ec.request}let eo=await et.writeContract({...l,chain:c.chainId?{id:c.chainId}:null});return{hash:eo}}function getAccount(){let{data:c,connector:l,status:et}=getConfig();switch(et){case"connected":return{address:c?.account,connector:l,isConnected:!0,isConnecting:!1,isDisconnected:!1,isReconnecting:!1,status:et};case"reconnecting":return{address:c?.account,connector:l,isConnected:!!c?.account,isConnecting:!1,isDisconnected:!1,isReconnecting:!0,status:et};case"connecting":return{address:c?.account,connector:l,isConnected:!1,isConnecting:!0,isDisconnected:!1,isReconnecting:!1,status:et};case"disconnected":return{address:void 0,connector:void 0,isConnected:!1,isConnecting:!1,isDisconnected:!0,isReconnecting:!1,status:et}}}function watchAccount(c,{selector:l=c=>c}={}){let et=getConfig(),eo=et.subscribe(({data:c,connector:et,status:eo})=>l({address:c?.account,connector:et,status:eo}),()=>c(getAccount()),{equalityFn:shallow$1});return eo}async function fetchBlockNumber({chainId:c}={}){let l=getPublicClient({chainId:c}),et=await l.getBlockNumber();return et}async function waitForTransaction({chainId:c,confirmations:l=1,hash:et,onReplaced:eo,timeout:es=0}){let ec=getPublicClient({chainId:c}),el=await ec.waitForTransactionReceipt({hash:et,confirmations:l,onReplaced:eo,timeout:es});if("reverted"===el.status){let c=await ec.getTransaction({hash:el.transactionHash}),l=await ec.call({...c,gasPrice:"eip1559"!==c.type?c.gasPrice:void 0,maxFeePerGas:"eip1559"===c.type?c.maxFeePerGas:void 0,maxPriorityFeePerGas:"eip1559"===c.type?c.maxPriorityFeePerGas:void 0}),et=(0,eX.rR)(`0x${l.substring(138)}`);throw Error(et)}return el}function assertActiveChain({chainId:c}){let{chain:l,chains:et}=function(){let c=getConfig(),l=c.data?.chain?.id,et=c.chains??[],eo=[...c.publicClient?.chains||[],...et].find(c=>c.id===l)??{id:l,name:`Chain ${l}`,network:`${l}`,nativeCurrency:{name:"Ether",decimals:18,symbol:"ETH"},rpcUrls:{default:{http:[""]},public:{http:[""]}}};return{chain:l?{...eo,...c.data?.chain,id:l}:void 0,chains:et}}(),eo=l?.id;if(eo&&c!==eo)throw new tS({activeChain:et.find(c=>c.id===eo)?.name??`Chain ${eo}`,targetChain:et.find(l=>l.id===c)?.name??`Chain ${c}`})}es=new WeakMap,ec=new WeakMap,el=new WeakSet,ed=function(){let onChange=c=>{this.setState(l=>({...l,data:{...l.data,...c}}))},onDisconnect=()=>{this.clearState()},onError=c=>{this.setState(l=>({...l,error:c}))};this.store.subscribe(({connector:c})=>c,(c,l)=>{l?.off?.("change",onChange),l?.off?.("disconnect",onDisconnect),l?.off?.("error",onError),c&&(c.on?.("change",onChange),c.on?.("disconnect",onDisconnect),c.on?.("error",onError))});let{publicClient:c,webSocketPublicClient:l}=this.args;("function"==typeof c||"function"==typeof l)&&this.store.subscribe(({data:c})=>c?.chain?.id,c=>{this.setState(l=>({...l,publicClient:this.getPublicClient({chainId:c}),webSocketPublicClient:this.getWebSocketPublicClient({chainId:c})}))})}},37943:function(c,l,et){"use strict";et.d(l,{t5:function(){return decodeJwt}}),new TextEncoder;let eo=new TextDecoder,base64url_decodeBase64=c=>{let l=atob(c),et=new Uint8Array(l.length);for(let c=0;c{let l=c;l instanceof Uint8Array&&(l=eo.decode(l)),l=l.replace(/-/g,"+").replace(/_/g,"/").replace(/\s/g,"");try{return base64url_decodeBase64(l)}catch(c){throw TypeError("The input to be decoded is not correctly encoded.")}};function decodeJwt(c){let l,et;if("string"!=typeof c)throw new errors_JWTInvalid("JWTs must use Compact JWS serialization, JWT must be a string");let{1:es,length:ec}=c.split(".");if(5===ec)throw new errors_JWTInvalid("Only JWTs using Compact JWS serialization can be decoded");if(3!==ec)throw new errors_JWTInvalid("Invalid JWT");if(!es)throw new errors_JWTInvalid("JWTs must contain a payload");try{l=base64url_decode(es)}catch(c){throw new errors_JWTInvalid("Failed to base64url decode the payload")}try{et=JSON.parse(eo.decode(l))}catch(c){throw new errors_JWTInvalid("Failed to parse the decoded payload as JSON")}if(!function(c){if(!("object"==typeof c&&null!==c)||"[object Object]"!==Object.prototype.toString.call(c))return!1;if(null===Object.getPrototypeOf(c))return!0;let l=c;for(;null!==Object.getPrototypeOf(l);)l=Object.getPrototypeOf(l);return Object.getPrototypeOf(c)===l}(et))throw new errors_JWTInvalid("Invalid JWT Claims Set");return et}},11490:function(c,l,et){"use strict";/*! js-cookie v3.0.5 | MIT */function assign(c){for(var l=1;lc.length)&&(l=c.length);for(var et=0,eo=Array(l);etel)return 1;if(el>ec)return -1;if(!isNaN(ec)&&isNaN(el))return 1;if(isNaN(ec)&&!isNaN(el))return -1}return c[1]&&l[1]?c[1]>l[1]?1:c[1]c.length)&&(l=c.length);for(var et=0,eo=Array(l);et=c.length?{done:!0}:{done:!1,value:c[eo++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(c.split(""));!(l=eo()).done;){var es=l.value;et+=function(c,l){if("+"===c){if(l)return;return"+"}return ek[c]}(es,et)||""}return et}function mergeArrays_arrayLikeToArray(c,l){(null==l||l>c.length)&&(l=c.length);for(var et=0,eo=Array(l);et=c.length?{done:!0}:{done:!1,value:c[eo++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(l);!(et=es()).done;){var ec=et.value;0>c.indexOf(ec)&&eo.push(ec)}return eo.sort(function(c,l){return c-l})}(es,ec.possibleLengths()))}else if(l&&!eo)return"INVALID_LENGTH";var el=c.length,ed=es[0];return ed===el?"IS_POSSIBLE":ed>el?"TOO_SHORT":es[es.length-1]=0?"IS_POSSIBLE":"INVALID_LENGTH"}(c,void 0,l)}function isPossibleNumber(c,l){return"IS_POSSIBLE"===checkNumberLength(c,l)}function matchesEntirely(c,l){return c=c||"",RegExp("^(?:"+l+")$").test(c)}function getNumberType_arrayLikeToArray(c,l){(null==l||l>c.length)&&(l=c.length);for(var et=0,eo=Array(l);et=c.length?{done:!0}:{done:!1,value:c[eo++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(eC);!(es=ec()).done;){var el=es.value;if(isNumberTypeEqualTo(eo,el,et))return el}}}}function isNumberTypeEqualTo(c,l,et){return!(!(l=et.type(l))||!l.pattern()||l.possibleLengths()&&0>l.possibleLengths().indexOf(c.length))&&matchesEntirely(c,l.pattern())}var eA=/(\$\d)/,eI=/^[\d]+(?:[~\u2053\u223C\uFF5E][\d]+)?$/;function format_arrayLikeToArray(c,l){(null==l||l>c.length)&&(l=c.length);for(var et=0,eo=Array(l);et=c.length?{done:!0}:{done:!1,value:c[eo++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(c);!(et=eo()).done;){var es=et.value;if(es.leadingDigitsPatterns().length>0){var ec=es.leadingDigitsPatterns()[es.leadingDigitsPatterns().length-1];if(0!==l.search(ec))continue}if(matchesEntirely(l,es.pattern()))return es}}(eo.formats(),c);return ep?(ed=(ec={useInternationalFormat:"INTERNATIONAL"===et,withNationalPrefix:!ep.nationalPrefixIsOptionalWhenFormattingInNationalFormat()||!es||!1!==es.nationalPrefix,carrierCode:l,metadata:eo}).useInternationalFormat,eh=ec.withNationalPrefix,ec.carrierCode,ec.metadata,ef=c.replace(new RegExp(ep.pattern()),ed?ep.internationalFormat():eh&&ep.nationalPrefixFormattingRule()?ep.format().replace(eA,ep.nationalPrefixFormattingRule()):ep.format()),ed?ef.replace(RegExp("[".concat(el,"]+"),"g")," ").trim():ef):c}function PhoneNumber_ownKeys(c,l){var et=Object.keys(c);if(Object.getOwnPropertySymbols){var eo=Object.getOwnPropertySymbols(c);l&&(eo=eo.filter(function(l){return Object.getOwnPropertyDescriptor(c,l).enumerable})),et.push.apply(et,eo)}return et}function PhoneNumber_objectSpread(c){for(var l=1;l=0}):[])}},{key:"isPossible",value:function(){return function(c,l,et){if(void 0===l&&(l={}),et=new eg(et),l.v2){if(!c.countryCallingCode)throw Error("Invalid phone number object passed");et.selectNumberingPlan(c.countryCallingCode)}else{if(!c.phone)return!1;if(c.country){if(!et.hasCountry(c.country))throw Error("Unknown country: ".concat(c.country));et.country(c.country)}else{if(!c.countryCallingCode)throw Error("Invalid phone number object passed");et.selectNumberingPlan(c.countryCallingCode)}}if(et.possibleLengths())return isPossibleNumber(c.phone||c.nationalNumber,et);if(c.countryCallingCode&&et.isNonGeographicCallingCode(c.countryCallingCode))return!0;throw Error('Missing "possibleLengths" in metadata. Perhaps the metadata has been generated before v1.0.18.')}(this,{v2:!0},this.getMetadata())}},{key:"isValid",value:function(){var c,l;return c={v2:!0},l=this.getMetadata(),(c=c||{},(l=new eg(l)).selectNumberingPlan(this.country,this.countryCallingCode),l.hasTypes())?void 0!==getNumberType(this,c,l.metadata):matchesEntirely(c.v2?this.nationalNumber:this.phone,l.nationalNumberPattern())}},{key:"isNonGeographic",value:function(){return new eg(this.getMetadata()).isNonGeographicCallingCode(this.countryCallingCode)}},{key:"isEqual",value:function(c){return this.number===c.number&&this.ext===c.ext}},{key:"getType",value:function(){return getNumberType(this,{v2:!0},this.getMetadata())}},{key:"format",value:function(c,l){return function(c,l,et,eo){if(et=et?format_objectSpread(format_objectSpread({},eP),et):eP,eo=new eg(eo),c.country&&"001"!==c.country){if(!eo.hasCountry(c.country))throw Error("Unknown country: ".concat(c.country));eo.country(c.country)}else{if(!c.countryCallingCode)return c.phone||"";eo.selectNumberingPlan(c.countryCallingCode)}var es,ec,el,ed,eh,ef,ep,em,eb,ey,e_,ew,eE,eS=eo.countryCallingCode(),ex=et.v2?c.nationalNumber:c.phone;switch(l){case"NATIONAL":if(!ex)return"";return es=eE=formatNationalNumber(ex,c.carrierCode,"NATIONAL",eo,et),ec=c.ext,el=eo,ed=et.formatExtension,ec?ed(es,ec,el):es;case"INTERNATIONAL":if(!ex)return"+".concat(eS);return eE=formatNationalNumber(ex,null,"INTERNATIONAL",eo,et),eh=eE="+".concat(eS," ").concat(eE),ef=c.ext,ep=eo,em=et.formatExtension,ef?em(eh,ef,ep):eh;case"E.164":return"+".concat(eS).concat(ex);case"RFC3966":return function(c){var l=c.number,et=c.ext;if(!l)return"";if("+"!==l[0])throw Error('"formatRFC3966()" expects "number" to be in E.164 format.');return"tel:".concat(l).concat(et?";ext="+et:"")}({number:"+".concat(eS).concat(ex),ext:c.ext});case"IDD":if(!et.fromCountry)return;return eb=function(c,l,et,eo,es){if(getCountryCallingCode(eo,es.metadata)===et){var ec,el,ed=formatNationalNumber(c,l,"NATIONAL",es);return"1"===et?et+" "+ed:ed}var eh=(ec=es.metadata,((el=new eg(ec)).selectNumberingPlan(eo,void 0),el.defaultIDDPrefix())?el.defaultIDDPrefix():eI.test(el.IDDPrefix())?el.IDDPrefix():void 0);if(eh)return"".concat(eh," ").concat(et," ").concat(formatNationalNumber(c,null,"INTERNATIONAL",es))}(ex,c.carrierCode,eS,et.fromCountry,eo),ey=c.ext,e_=eo,ew=et.formatExtension,ey?ew(eb,ey,e_):eb;default:throw Error('Unknown "format" argument passed to "formatNumber()": "'.concat(l,'"'))}}(this,c,l?PhoneNumber_objectSpread(PhoneNumber_objectSpread({},l),{},{v2:!0}):{v2:!0},this.getMetadata())}},{key:"formatNational",value:function(c){return this.format("NATIONAL",c)}},{key:"formatInternational",value:function(c){return this.format("INTERNATIONAL",c)}},{key:"getURI",value:function(c){return this.format("RFC3966",c)}}],PhoneNumber_defineProperties(PhoneNumber.prototype,c),l&&PhoneNumber_defineProperties(PhoneNumber,l),Object.defineProperty(PhoneNumber,"prototype",{writable:!1}),PhoneNumber}(),eO=RegExp("(["+ec+"])");function extractNationalNumber(c,l){var et=function(c,l){if(c&&l.numberingPlan.nationalPrefixForParsing()){var et=RegExp("^(?:"+l.numberingPlan.nationalPrefixForParsing()+")"),eo=et.exec(c);if(eo){var es,ec,el,ed=eo.length-1,eh=ed>0&&eo[ed];if(l.nationalPrefixTransformRule()&&eh)es=c.replace(et,l.nationalPrefixTransformRule()),ed>1&&(ec=eo[1]);else{var ef=eo[0];es=c.slice(ef.length),eh&&(ec=eo[1])}if(eh){var ep=c.indexOf(eo[1]);c.slice(0,ep)===l.numberingPlan.nationalPrefix()&&(el=l.numberingPlan.nationalPrefix())}else el=eo[0];return{nationalNumber:es,nationalPrefix:el,carrierCode:ec}}}return{nationalNumber:c}}(c,l),eo=et.carrierCode,es=et.nationalNumber;return es!==c&&(!(!matchesEntirely(c,l.nationalNumberPattern())||matchesEntirely(es,l.nationalNumberPattern()))||l.possibleLengths()&&!function(c,l){switch(checkNumberLength(c,l)){case"TOO_SHORT":case"INVALID_LENGTH":return!1;default:return!0}}(es,l))?{nationalNumber:c}:{nationalNumber:es,carrierCode:eo}}function getCountryByNationalNumber_arrayLikeToArray(c,l){(null==l||l>c.length)&&(l=c.length);for(var et=0,eo=Array(l);et=c.length)return"";var eo=c.indexOf(";",et);return eo>=0?c.substring(et,eo):c.substring(et)}(c);if(!(null===eo||0!==eo.length&&(eN.test(eo)||eM.test(eo))))throw new eh("NOT_A_NUMBER");if(null===eo)es=et(c)||"";else{es="","+"===eo.charAt(0)&&(es+=eo);var es,ec,el=c.indexOf(e$);ec=el>=0?el+e$.length:0;var ed=c.indexOf(eB);es+=c.substring(ec,ed)}var ef=es.indexOf(";isub=");if(ef>0&&(es=es.substring(0,ef)),""!==es)return es}(c,{extractFormattedPhoneNumber:function(c){return function(c,l,et){if(c){if(c.length>250){if(et)throw new eh("TOO_LONG");return}if(!1===l)return c;var eo=c.search(eD);if(!(eo<0))return c.slice(eo).replace(ej,"")}}(c,et,l)}});if(!eo)return{};if(!(eo.length>=2&&eS.test(eo)))return ew.test(eo)?{error:"TOO_SHORT"}:{};var es=function(c){var l=c.search(ex);if(l<0)return{};for(var et=c.slice(0,l),eo=c.match(ex),es=1;es0)||"0"!==el[1])return c}}}(c,l,et,eo);if(ec&&ec!==c)es=!0,c="+"+ec;else{if(l||et){var el=function(c,l,et,eo){var es=l?getCountryCallingCode(l,eo):et;if(0===c.indexOf(es)){(eo=new eg(eo)).selectNumberingPlan(l,et);var ec=c.slice(es.length),el=extractNationalNumber(ec,eo).nationalNumber,ed=extractNationalNumber(c,eo).nationalNumber;if(!matchesEntirely(ed,eo.nationalNumberPattern())&&matchesEntirely(el,eo.nationalNumberPattern())||"TOO_LONG"===checkNumberLength(ed,eo))return{countryCallingCode:es,number:ec}}return{number:c}}(c,l,et,eo),ed=el.countryCallingCode,eh=el.number;if(ed)return{countryCallingCodeSource:"FROM_NUMBER_WITHOUT_PLUS_SIGN",countryCallingCode:ed,number:eh}}return{number:c}}}if("0"===c[1])return{};eo=new eg(eo);for(var ef=2;ef-1<=3&&ef<=c.length;){var ep=c.slice(1,ef);if(eo.hasCallingCode(ep))return eo.selectNumberingPlan(ep),{countryCallingCodeSource:es?"FROM_NUMBER_WITH_IDD":"FROM_NUMBER_WITH_PLUS_SIGN",countryCallingCode:ep,number:c.slice(ef)};ef++}return{}}(parseIncompletePhoneNumber(c),l,et,eo.metadata),eb=em.countryCallingCodeSource,ey=em.countryCallingCode,e_=em.number;if(ey)eo.selectNumberingPlan(ey);else{if(!e_||!l&&!et)return{};eo.selectNumberingPlan(l,et),l&&(ep=l),ey=et||getCountryCallingCode(l,eo.metadata)}if(!e_)return{countryCallingCodeSource:eb,countryCallingCode:ey};var ew=extractNationalNumber(parseIncompletePhoneNumber(e_),eo),eE=ew.nationalNumber,eS=ew.carrierCode,ex=(es=ey,el=(ec={nationalNumber:eE,defaultCountry:l,metadata:eo}).nationalNumber,ed=ec.defaultCountry,(ef=(eh=ec.metadata).getCountryCodesForCallingCode(es))?1===ef.length?ef[0]:function(c,l){var et=l.countries,eo=l.defaultCountry,es=l.metadata;es=new eg(es);for(var ec,el=[],ed=function(c,l){var et="undefined"!=typeof Symbol&&c[Symbol.iterator]||c["@@iterator"];if(et)return(et=et.call(c)).next.bind(et);if(Array.isArray(c)||(et=function(c,l){if(c){if("string"==typeof c)return getCountryByNationalNumber_arrayLikeToArray(c,l);var et=Object.prototype.toString.call(c).slice(8,-1);if("Object"===et&&c.constructor&&(et=c.constructor.name),"Map"===et||"Set"===et)return Array.from(c);if("Arguments"===et||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(et))return getCountryByNationalNumber_arrayLikeToArray(c,l)}}(c))){et&&(c=et);var eo=0;return function(){return eo>=c.length?{done:!0}:{done:!1,value:c[eo++]}}}throw TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(et);!(ec=ed()).done;){var eh=ec.value;if(es.country(eh),es.leadingDigits()){if(c&&0===c.search(es.leadingDigits()))return eh}else if(getNumberType({phone:c,country:eh},void 0,es.metadata)){if(!eo||eh===eo)return eh;el.push(eh)}}if(el.length>0)return el[0]}(el,{countries:ef,defaultCountry:ed,metadata:eh.metadata}):void 0);return ex&&(ep=ex,"001"===ex||eo.country(ep)),{country:ep,countryCallingCode:ey,countryCallingCodeSource:eb,nationalNumber:eE,carrierCode:eS}}(ec,l.defaultCountry,l.defaultCallingCode,et),ep=ef.country,em=ef.nationalNumber,eb=ef.countryCallingCode,ey=ef.countryCallingCodeSource,e_=ef.carrierCode;if(!et.hasSelectedNumberingPlan()){if(l.v2)throw new eh("INVALID_COUNTRY");return{}}if(!em||em.length<2){if(l.v2)throw new eh("TOO_SHORT");return{}}if(em.length>17){if(l.v2)throw new eh("TOO_LONG");return{}}if(l.v2){var eE=new eR(eb,em,et.metadata);return ep&&(eE.country=ep),e_&&(eE.carrierCode=e_),el&&(eE.ext=el),eE.__countryCallingCodeSource=ey,eE}var ek=(l.extended?!!et.hasSelectedNumberingPlan():!!ep)&&matchesEntirely(em,et.nationalNumberPattern());return l.extended?{country:ep,countryCallingCode:eb,carrierCode:e_,valid:ek,possible:!!ek||!!(!0===l.extended&&et.possibleLengths()&&isPossibleNumber(em,et)),phone:em,ext:el}:ek?(eo={country:ep,phone:em},el&&(eo.ext=el),eo):{}}(c,parsePhoneNumberWithError_objectSpread(parsePhoneNumberWithError_objectSpread({},es),{},{v2:!0}),et)}catch(c){if(c instanceof eh);else throw c}}(l,et=isPossiblePhoneNumber_objectSpread(isPossiblePhoneNumber_objectSpread({},et),{},{extract:!1}),eo);return es&&es.isPossible()||!1}function exports_isPossiblePhoneNumber_isPossiblePhoneNumber(){return function(c,l){var et=Array.prototype.slice.call(l);return et.push(eo),c.apply(this,et)}(isPossiblePhoneNumber_isPossiblePhoneNumber,arguments)}},14228:function(c,l,et){"use strict";et.d(l,{Wg:function(){return eh}});var eo=et(30059);let es=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;if("undefined"!=typeof global)return global;throw Error("unable to locate global object")}(),ec=es.fetch||(()=>Promise.reject(Error("[ofetch] global.fetch is not supported!"))),el=es.Headers,ed=es.AbortController,eh=(0,eo.c)({fetch:ec,Headers:el,AbortController:ed})},30059:function(c,l,et){"use strict";et.d(l,{F:function(){return FetchError},c:function(){return function createFetch(c={}){let{fetch:l=globalThis.fetch,Headers:et=globalThis.Headers,AbortController:eo=globalThis.AbortController}=c;async function onError(c){let l=c.error&&"AbortError"===c.error.name&&!c.options.timeout||!1;if(!1!==c.options.retry&&!l){let l;l="number"==typeof c.options.retry?c.options.retry:isPayloadMethod(c.options.method)?0:1;let et=c.response&&c.response.status||500;if(l>0&&(Array.isArray(c.options.retryStatusCodes)?c.options.retryStatusCodes.includes(et):eA.has(et))){let et=c.options.retryDelay||0;return et>0&&await new Promise(c=>setTimeout(c,et)),$fetchRaw(c.request,{...c.options,retry:l-1,timeout:c.options.timeout})}}let et=function(c){let l=c.error?.message||c.error?.toString()||"",et=c.request?.method||c.options?.method||"GET",eo=c.request?.url||String(c.request)||"/",es=`[${et}] ${JSON.stringify(eo)}`,ec=c.response?`${c.response.status} ${c.response.statusText}`:"",el=`${es}: ${ec}${l?` ${l}`:""}`,ed=new FetchError(el,c.error?{cause:c.error}:void 0);for(let l of["request","options","response"])Object.defineProperty(ed,l,{get:()=>c[l]});for(let[l,et]of[["data","_data"],["status","status"],["statusCode","status"],["statusText","statusText"],["statusMessage","statusText"]])Object.defineProperty(ed,l,{get:()=>c.response&&c.response[et]});return ed}(c);throw Error.captureStackTrace&&Error.captureStackTrace(et,$fetchRaw),et}let $fetchRaw=async function(es,ec={}){let el={request:es,options:function(c,l,et=globalThis.Headers){let eo={...l,...c};if(l?.params&&c?.params&&(eo.params={...l?.params,...c?.params}),l?.query&&c?.query&&(eo.query={...l?.query,...c?.query}),l?.headers&&c?.headers)for(let[es,ec]of(eo.headers=new et(l?.headers||{}),new et(c?.headers||{})))eo.headers.set(es,ec);return eo}(ec,c.defaults,et),response:void 0,error:void 0};if(el.options.method=el.options.method?.toUpperCase(),el.options.onRequest&&await el.options.onRequest(el),"string"==typeof el.request&&(el.options.baseURL&&(el.request=function(c,l){if(!l||"/"===l||hasProtocol(c))return c;let et=function(c="",l=!1){if(!l)return(hasTrailingSlash(c)?c.slice(0,-1):c)||"/";if(!hasTrailingSlash(c,!0))return c||"/";let[et,...eo]=c.split("?");return(et.slice(0,-1)||"/")+(eo.length>0?`?${eo.join("?")}`:"")}(l);return c.startsWith(et)?c:function(c,...l){let et=c||"";for(let c of l.filter(c=>c&&"/"!==c))if(et){let l=c.replace(eS,"");et=function(c="",l=!1){if(!l)return c.endsWith("/")?c:c+"/";if(hasTrailingSlash(c,!0))return c||"/";let[et,...eo]=c.split("?");return et+"/"+(eo.length>0?`?${eo.join("?")}`:"")}(et)+l}else et=c;return et}(et,c)}(el.request,el.options.baseURL)),(el.options.query||el.options.params)&&(el.request=function(c,l){let et=function parseURL(c="",l){let et=c.match(/^[\s\0]*(blob:|data:|javascript:|vbscript:)(.*)/);if(et){let[,c,l=""]=et;return{protocol:c,pathname:l,href:c+l,auth:"",host:"",search:"",hash:""}}if(!hasProtocol(c,{acceptRelative:!0}))return l?parseURL(l+c):parsePath(c);let[,eo="",es,ec=""]=c.replace(/\\/g,"/").match(/^[\s\0]*([\w+.-]{2,}:)?\/\/([^/@]+@)?(.*)/)||[],[,el="",ed=""]=ec.match(/([^#/?]*)(.*)?/)||[],{pathname:eh,search:ef,hash:ep}=parsePath(ed.replace(/\/(?=[A-Za-z]:)/,""));return{protocol:eo,auth:es?es.slice(0,Math.max(0,es.length-1)):"",host:el,pathname:eh,search:ef,hash:ep}}(c),eo={...function(c=""){let l={};for(let et of("?"===c[0]&&(c=c.slice(1)),c.split("&"))){let c=et.match(/([^=]+)=?(.*)/)||[];if(c.length<2)continue;let eo=decode(c[1].replace(ef," "));if("__proto__"===eo||"constructor"===eo)continue;let es=decode((c[2]||"").replace(ef," "));void 0===l[eo]?l[eo]=es:Array.isArray(l[eo])?l[eo].push(es):l[eo]=[l[eo],es]}return l}(et.search),...l};return et.search=Object.keys(eo).filter(c=>void 0!==eo[c]).map(c=>{var l;return(("number"==typeof(l=eo[c])||"boolean"==typeof l)&&(l=String(l)),l)?Array.isArray(l)?l.map(l=>`${encodeQueryKey(c)}=${encodeQueryValue(l)}`).join("&"):`${encodeQueryKey(c)}=${encodeQueryValue(l)}`:encodeQueryKey(c)}).filter(Boolean).join("&"),function(c){let l=c.pathname||"",et=c.search?(c.search.startsWith("?")?"":"?")+c.search:"",eo=c.hash||"",es=c.auth?c.auth+"@":"",ec=c.host||"",el=c.protocol?c.protocol+"//":"";return el+es+ec+l+et+eo}(et)}(el.request,{...el.options.params,...el.options.query}))),el.options.body&&isPayloadMethod(el.options.method)&&(function(c){if(void 0===c)return!1;let l=typeof c;return"string"===l||"number"===l||"boolean"===l||null===l||"object"===l&&(!!Array.isArray(c)||!c.buffer&&(c.constructor&&"Object"===c.constructor.name||"function"==typeof c.toJSON))}(el.options.body)?(el.options.body="string"==typeof el.options.body?el.options.body:JSON.stringify(el.options.body),el.options.headers=new et(el.options.headers||{}),el.options.headers.has("content-type")||el.options.headers.set("content-type","application/json"),el.options.headers.has("accept")||el.options.headers.set("accept","application/json")):("pipeTo"in el.options.body&&"function"==typeof el.options.body.pipeTo||"function"==typeof el.options.body.pipe)&&!("duplex"in el.options)&&(el.options.duplex="half")),!el.options.signal&&el.options.timeout){let c=new eo;setTimeout(()=>c.abort(),el.options.timeout),el.options.signal=c.signal}try{el.response=await l(el.request,el.options)}catch(c){return el.error=c,el.options.onRequestError&&await el.options.onRequestError(el),await onError(el)}let ed=el.response.body&&!eI.has(el.response.status)&&"HEAD"!==el.options.method;if(ed){let c=(el.options.parseResponse?"json":el.options.responseType)||function(c=""){if(!c)return"json";let l=c.split(";").shift()||"";return eC.test(l)?"json":ek.has(l)||l.startsWith("text/")?"text":"blob"}(el.response.headers.get("content-type")||"");switch(c){case"json":{let c=await el.response.text(),l=el.options.parseResponse||destr;el.response._data=l(c);break}case"stream":el.response._data=el.response.body;break;default:el.response._data=await el.response[c]()}}return(el.options.onResponse&&await el.options.onResponse(el),!el.options.ignoreResponseError&&el.response.status>=400&&el.response.status<600)?(el.options.onResponseError&&await el.options.onResponseError(el),await onError(el)):el.response},$fetch=async function(c,l){let et=await $fetchRaw(c,l);return et._data};return $fetch.raw=$fetchRaw,$fetch.native=(...c)=>l(...c),$fetch.create=(l={})=>createFetch({...c,defaults:{...c.defaults,...l}}),$fetch}}});let eo=/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,es=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,ec=/^\s*["[{]|^\s*-?\d[\d.]{0,14}\s*$/;function jsonParseTransform(c,l){if("__proto__"===c||"constructor"===c&&l&&"object"==typeof l&&"prototype"in l){console.warn(`[destr] Dropping "${c}" key to prevent prototype pollution.`);return}return l}function destr(c,l={}){if("string"!=typeof c)return c;let et=c.trim();if('"'===c[0]&&'"'===c[c.length-1])return et.slice(1,-1);if(et.length<=9){let c=et.toLowerCase();if("true"===c)return!0;if("false"===c)return!1;if("undefined"===c)return;if("null"===c)return null;if("nan"===c)return Number.NaN;if("infinity"===c)return Number.POSITIVE_INFINITY;if("-infinity"===c)return Number.NEGATIVE_INFINITY}if(!ec.test(c)){if(l.strict)throw SyntaxError("[destr] Invalid JSON");return c}try{if(eo.test(c)||es.test(c)){if(l.strict)throw Error("[destr] Possible prototype pollution");return JSON.parse(c,jsonParseTransform)}return JSON.parse(c)}catch(et){if(l.strict)throw et;return c}}let el=/#/g,ed=/&/g,eh=/=/g,ef=/\+/g,ep=/%5e/gi,eg=/%60/gi,em=/%7c/gi,eb=/%20/gi;function encodeQueryValue(c){return encodeURI(""+("string"==typeof c?c:JSON.stringify(c))).replace(em,"|").replace(ef,"%2B").replace(eb,"+").replace(el,"%23").replace(ed,"%26").replace(eg,"`").replace(ep,"^")}function encodeQueryKey(c){return encodeQueryValue(c).replace(eh,"%3D")}function decode(c=""){try{return decodeURIComponent(""+c)}catch{return""+c}}let ey=/^[\s\w\0+.-]{2,}:([/\\]{1,2})/,e_=/^[\s\w\0+.-]{2,}:([/\\]{2})?/,ew=/^([/\\]\s*){2,}[^/\\]/;function hasProtocol(c,l={}){return("boolean"==typeof l&&(l={acceptRelative:l}),l.strict)?ey.test(c):e_.test(c)||!!l.acceptRelative&&ew.test(c)}let eE=/\/$|\/\?/;function hasTrailingSlash(c="",l=!1){return l?eE.test(c):c.endsWith("/")}let eS=/^\.?\//;function parsePath(c=""){let[l="",et="",eo=""]=(c.match(/([^#?]*)(\?[^#]*)?(#.*)?/)||[]).splice(1);return{pathname:l,search:et,hash:eo}}let FetchError=class FetchError extends Error{constructor(c,l){super(c,l),this.name="FetchError",l?.cause&&!this.cause&&(this.cause=l.cause)}};let ex=new Set(Object.freeze(["PATCH","POST","PUT","DELETE"]));function isPayloadMethod(c="GET"){return ex.has(c.toUpperCase())}let ek=new Set(["image/svg","application/xml","application/xhtml","application/html"]),eC=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i,eA=new Set([408,409,425,429,500,502,503,504]),eI=new Set([101,204,205,304])},50683:function(c,l,et){"use strict";function csprng_getRandomBytes(c){return crypto.getRandomValues(new Uint8Array(c))}function getOneByteRandomInteger(){let[c]=csprng_getRandomBytes(1);return c}function getTwoByteRandomInteger(){let[c,l]=csprng_getRandomBytes(2);return(c<<8)+l}function generatePassphrase(c,l,et="-"){if("number"!=typeof c||c<1)throw Error("Invalid argument: length argument must be a number greater than or equal to 1");if(!Array.isArray(l)||l.length<2)throw Error("Invalid argument: wordlist argument must be an array with length greater than or equal to 2");if("string"!=typeof et)throw Error("Invalid argument: sep argument must be a string");return(function(c,l,et){if("number"!=typeof c||c<1)throw Error("Invalid argument: length must be a number greater than or equal to 1");if("number"!=typeof l||l<0)throw Error("Invalid argument: start must be a number greater than or equal to 0");if("number"!=typeof et||et>65536)throw Error("Invalid argument: end must be a number less than or equal to 65536");if(et-l<2)throw Error("Invalid range: range must contain at least two values");let eo=[];for(let es=0;es65536)throw Error("Invalid number: number must be at least two and at most 65536");let l=c>256,et=l?getTwoByteRandomInteger:getOneByteRandomInteger,eo=c*Math.floor((l?65536:256)/c);for(;;){let l=et();if(l{let ec=l[eo];return c+(0===es?ec:et+ec)},"")}et.d(l,{OW:function(){return generatePassphrase}})},54184:function(c,l,et){"use strict";et.d(l,{k:function(){return es}});let eo=Object.freeze(["abacus","abdomen","abdominal","abide","abiding","ability","ablaze","able","abnormal","abrasion","abrasive","abreast","abridge","abroad","abruptly","absence","absentee","absently","absinthe","absolute","absolve","abstain","abstract","absurd","accent","acclaim","acclimate","accompany","account","accuracy","accurate","accustom","acetone","achiness","aching","acid","acorn","acquaint","acquire","acre","acrobat","acronym","acting","action","activate","activator","active","activism","activist","activity","actress","acts","acutely","acuteness","aeration","aerobics","aerosol","aerospace","afar","affair","affected","affecting","affection","affidavit","affiliate","affirm","affix","afflicted","affluent","afford","affront","aflame","afloat","aflutter","afoot","afraid","afterglow","afterlife","aftermath","aftermost","afternoon","aged","ageless","agency","agenda","agent","aggregate","aghast","agile","agility","aging","agnostic","agonize","agonizing","agony","agreeable","agreeably","agreed","agreeing","agreement","aground","ahead","ahoy","aide","aids","aim","ajar","alabaster","alarm","albatross","album","alfalfa","algebra","algorithm","alias","alibi","alienable","alienate","aliens","alike","alive","alkaline","alkalize","almanac","almighty","almost","aloe","aloft","aloha","alone","alongside","aloof","alphabet","alright","although","altitude","alto","aluminum","alumni","always","amaretto","amaze","amazingly","amber","ambiance","ambiguity","ambiguous","ambition","ambitious","ambulance","ambush","amendable","amendment","amends","amenity","amiable","amicably","amid","amigo","amino","amiss","ammonia","ammonium","amnesty","amniotic","among","amount","amperage","ample","amplifier","amplify","amply","amuck","amulet","amusable","amused","amusement","amuser","amusing","anaconda","anaerobic","anagram","anatomist","anatomy","anchor","anchovy","ancient","android","anemia","anemic","aneurism","anew","angelfish","angelic","anger","angled","angler","angles","angling","angrily","angriness","anguished","angular","animal","animate","animating","animation","animator","anime","animosity","ankle","annex","annotate","announcer","annoying","annually","annuity","anointer","another","answering","antacid","antarctic","anteater","antelope","antennae","anthem","anthill","anthology","antibody","antics","antidote","antihero","antiquely","antiques","antiquity","antirust","antitoxic","antitrust","antiviral","antivirus","antler","antonym","antsy","anvil","anybody","anyhow","anymore","anyone","anyplace","anything","anytime","anyway","anywhere","aorta","apache","apostle","appealing","appear","appease","appeasing","appendage","appendix","appetite","appetizer","applaud","applause","apple","appliance","applicant","applied","apply","appointee","appraisal","appraiser","apprehend","approach","approval","approve","apricot","april","apron","aptitude","aptly","aqua","aqueduct","arbitrary","arbitrate","ardently","area","arena","arguable","arguably","argue","arise","armadillo","armband","armchair","armed","armful","armhole","arming","armless","armoire","armored","armory","armrest","army","aroma","arose","around","arousal","arrange","array","arrest","arrival","arrive","arrogance","arrogant","arson","art","ascend","ascension","ascent","ascertain","ashamed","ashen","ashes","ashy","aside","askew","asleep","asparagus","aspect","aspirate","aspire","aspirin","astonish","astound","astride","astrology","astronaut","astronomy","astute","atlantic","atlas","atom","atonable","atop","atrium","atrocious","atrophy","attach","attain","attempt","attendant","attendee","attention","attentive","attest","attic","attire","attitude","attractor","attribute","atypical","auction","audacious","audacity","audible","audibly","audience","audio","audition","augmented","august","authentic","author","autism","autistic","autograph","automaker","automated","automatic","autopilot","available","avalanche","avatar","avenge","avenging","avenue","average","aversion","avert","aviation","aviator","avid","avoid","await","awaken","award","aware","awhile","awkward","awning","awoke","awry","axis","babble","babbling","babied","baboon","backache","backboard","backboned","backdrop","backed","backer","backfield","backfire","backhand","backing","backlands","backlash","backless","backlight","backlit","backlog","backpack","backpedal","backrest","backroom","backshift","backside","backslid","backspace","backspin","backstab","backstage","backtalk","backtrack","backup","backward","backwash","backwater","backyard","bacon","bacteria","bacterium","badass","badge","badland","badly","badness","baffle","baffling","bagel","bagful","baggage","bagged","baggie","bagginess","bagging","baggy","bagpipe","baguette","baked","bakery","bakeshop","baking","balance","balancing","balcony","balmy","balsamic","bamboo","banana","banish","banister","banjo","bankable","bankbook","banked","banker","banking","banknote","bankroll","banner","bannister","banshee","banter","barbecue","barbed","barbell","barber","barcode","barge","bargraph","barista","baritone","barley","barmaid","barman","barn","barometer","barrack","barracuda","barrel","barrette","barricade","barrier","barstool","bartender","barterer","bash","basically","basics","basil","basin","basis","basket","batboy","batch","bath","baton","bats","battalion","battered","battering","battery","batting","battle","bauble","bazooka","blabber","bladder","blade","blah","blame","blaming","blanching","blandness","blank","blaspheme","blasphemy","blast","blatancy","blatantly","blazer","blazing","bleach","bleak","bleep","blemish","blend","bless","blighted","blimp","bling","blinked","blinker","blinking","blinks","blip","blissful","blitz","blizzard","bloated","bloating","blob","blog","bloomers","blooming","blooper","blot","blouse","blubber","bluff","bluish","blunderer","blunt","blurb","blurred","blurry","blurt","blush","blustery","boaster","boastful","boasting","boat","bobbed","bobbing","bobble","bobcat","bobsled","bobtail","bodacious","body","bogged","boggle","bogus","boil","bok","bolster","bolt","bonanza","bonded","bonding","bondless","boned","bonehead","boneless","bonelike","boney","bonfire","bonnet","bonsai","bonus","bony","boogeyman","boogieman","book","boondocks","booted","booth","bootie","booting","bootlace","bootleg","boots","boozy","borax","boring","borough","borrower","borrowing","boss","botanical","botanist","botany","botch","both","bottle","bottling","bottom","bounce","bouncing","bouncy","bounding","boundless","bountiful","bovine","boxcar","boxer","boxing","boxlike","boxy","breach","breath","breeches","breeching","breeder","breeding","breeze","breezy","brethren","brewery","brewing","briar","bribe","brick","bride","bridged","brigade","bright","brilliant","brim","bring","brink","brisket","briskly","briskness","bristle","brittle","broadband","broadcast","broaden","broadly","broadness","broadside","broadways","broiler","broiling","broken","broker","bronchial","bronco","bronze","bronzing","brook","broom","brought","browbeat","brownnose","browse","browsing","bruising","brunch","brunette","brunt","brush","brussels","brute","brutishly","bubble","bubbling","bubbly","buccaneer","bucked","bucket","buckle","buckshot","buckskin","bucktooth","buckwheat","buddhism","buddhist","budding","buddy","budget","buffalo","buffed","buffer","buffing","buffoon","buggy","bulb","bulge","bulginess","bulgur","bulk","bulldog","bulldozer","bullfight","bullfrog","bullhorn","bullion","bullish","bullpen","bullring","bullseye","bullwhip","bully","bunch","bundle","bungee","bunion","bunkbed","bunkhouse","bunkmate","bunny","bunt","busboy","bush","busily","busload","bust","busybody","buzz","cabana","cabbage","cabbie","cabdriver","cable","caboose","cache","cackle","cacti","cactus","caddie","caddy","cadet","cadillac","cadmium","cage","cahoots","cake","calamari","calamity","calcium","calculate","calculus","caliber","calibrate","calm","caloric","calorie","calzone","camcorder","cameo","camera","camisole","camper","campfire","camping","campsite","campus","canal","canary","cancel","candied","candle","candy","cane","canine","canister","cannabis","canned","canning","cannon","cannot","canola","canon","canopener","canopy","canteen","canyon","capable","capably","capacity","cape","capillary","capital","capitol","capped","capricorn","capsize","capsule","caption","captivate","captive","captivity","capture","caramel","carat","caravan","carbon","cardboard","carded","cardiac","cardigan","cardinal","cardstock","carefully","caregiver","careless","caress","caretaker","cargo","caring","carless","carload","carmaker","carnage","carnation","carnival","carnivore","carol","carpenter","carpentry","carpool","carport","carried","carrot","carrousel","carry","cartel","cartload","carton","cartoon","cartridge","cartwheel","carve","carving","carwash","cascade","case","cash","casing","casino","casket","cassette","casually","casualty","catacomb","catalog","catalyst","catalyze","catapult","cataract","catatonic","catcall","catchable","catcher","catching","catchy","caterer","catering","catfight","catfish","cathedral","cathouse","catlike","catnap","catnip","catsup","cattail","cattishly","cattle","catty","catwalk","caucasian","caucus","causal","causation","cause","causing","cauterize","caution","cautious","cavalier","cavalry","caviar","cavity","cedar","celery","celestial","celibacy","celibate","celtic","cement","census","ceramics","ceremony","certainly","certainty","certified","certify","cesarean","cesspool","chafe","chaffing","chain","chair","chalice","challenge","chamber","chamomile","champion","chance","change","channel","chant","chaos","chaperone","chaplain","chapped","chaps","chapter","character","charbroil","charcoal","charger","charging","chariot","charity","charm","charred","charter","charting","chase","chasing","chaste","chastise","chastity","chatroom","chatter","chatting","chatty","cheating","cheddar","cheek","cheer","cheese","cheesy","chef","chemicals","chemist","chemo","cherisher","cherub","chess","chest","chevron","chevy","chewable","chewer","chewing","chewy","chief","chihuahua","childcare","childhood","childish","childless","childlike","chili","chill","chimp","chip","chirping","chirpy","chitchat","chivalry","chive","chloride","chlorine","choice","chokehold","choking","chomp","chooser","choosing","choosy","chop","chosen","chowder","chowtime","chrome","chubby","chuck","chug","chummy","chump","chunk","churn","chute","cider","cilantro","cinch","cinema","cinnamon","circle","circling","circular","circulate","circus","citable","citadel","citation","citizen","citric","citrus","city","civic","civil","clad","claim","clambake","clammy","clamor","clamp","clamshell","clang","clanking","clapped","clapper","clapping","clarify","clarinet","clarity","clash","clasp","class","clatter","clause","clavicle","claw","clay","clean","clear","cleat","cleaver","cleft","clench","clergyman","clerical","clerk","clever","clicker","client","climate","climatic","cling","clinic","clinking","clip","clique","cloak","clobber","clock","clone","cloning","closable","closure","clothes","clothing","cloud","clover","clubbed","clubbing","clubhouse","clump","clumsily","clumsy","clunky","clustered","clutch","clutter","coach","coagulant","coastal","coaster","coasting","coastland","coastline","coat","coauthor","cobalt","cobbler","cobweb","cocoa","coconut","cod","coeditor","coerce","coexist","coffee","cofounder","cognition","cognitive","cogwheel","coherence","coherent","cohesive","coil","coke","cola","cold","coleslaw","coliseum","collage","collapse","collar","collected","collector","collide","collie","collision","colonial","colonist","colonize","colony","colossal","colt","coma","come","comfort","comfy","comic","coming","comma","commence","commend","comment","commerce","commode","commodity","commodore","common","commotion","commute","commuting","compacted","compacter","compactly","compactor","companion","company","compare","compel","compile","comply","component","composed","composer","composite","compost","composure","compound","compress","comprised","computer","computing","comrade","concave","conceal","conceded","concept","concerned","concert","conch","concierge","concise","conclude","concrete","concur","condense","condiment","condition","condone","conducive","conductor","conduit","cone","confess","confetti","confidant","confident","confider","confiding","configure","confined","confining","confirm","conflict","conform","confound","confront","confused","confusing","confusion","congenial","congested","congrats","congress","conical","conjoined","conjure","conjuror","connected","connector","consensus","consent","console","consoling","consonant","constable","constant","constrain","constrict","construct","consult","consumer","consuming","contact","container","contempt","contend","contented","contently","contents","contest","context","contort","contour","contrite","control","contusion","convene","convent","copartner","cope","copied","copier","copilot","coping","copious","copper","copy","coral","cork","cornball","cornbread","corncob","cornea","corned","corner","cornfield","cornflake","cornhusk","cornmeal","cornstalk","corny","coronary","coroner","corporal","corporate","corral","correct","corridor","corrode","corroding","corrosive","corsage","corset","cortex","cosigner","cosmetics","cosmic","cosmos","cosponsor","cost","cottage","cotton","couch","cough","could","countable","countdown","counting","countless","country","county","courier","covenant","cover","coveted","coveting","coyness","cozily","coziness","cozy","crabbing","crabgrass","crablike","crabmeat","cradle","cradling","crafter","craftily","craftsman","craftwork","crafty","cramp","cranberry","crane","cranial","cranium","crank","crate","crave","craving","crawfish","crawlers","crawling","crayfish","crayon","crazed","crazily","craziness","crazy","creamed","creamer","creamlike","crease","creasing","creatable","create","creation","creative","creature","credible","credibly","credit","creed","creme","creole","crepe","crept","crescent","crested","cresting","crestless","crevice","crewless","crewman","crewmate","crib","cricket","cried","crier","crimp","crimson","cringe","cringing","crinkle","crinkly","crisped","crisping","crisply","crispness","crispy","criteria","critter","croak","crock","crook","croon","crop","cross","crouch","crouton","crowbar","crowd","crown","crucial","crudely","crudeness","cruelly","cruelness","cruelty","crumb","crummiest","crummy","crumpet","crumpled","cruncher","crunching","crunchy","crusader","crushable","crushed","crusher","crushing","crust","crux","crying","cryptic","crystal","cubbyhole","cube","cubical","cubicle","cucumber","cuddle","cuddly","cufflink","culinary","culminate","culpable","culprit","cultivate","cultural","culture","cupbearer","cupcake","cupid","cupped","cupping","curable","curator","curdle","cure","curfew","curing","curled","curler","curliness","curling","curly","curry","curse","cursive","cursor","curtain","curtly","curtsy","curvature","curve","curvy","cushy","cusp","cussed","custard","custodian","custody","customary","customer","customize","customs","cut","cycle","cyclic","cycling","cyclist","cylinder","cymbal","cytoplasm","cytoplast","dab","dad","daffodil","dagger","daily","daintily","dainty","dairy","daisy","dallying","dance","dancing","dandelion","dander","dandruff","dandy","danger","dangle","dangling","daredevil","dares","daringly","darkened","darkening","darkish","darkness","darkroom","darling","darn","dart","darwinism","dash","dastardly","data","datebook","dating","daughter","daunting","dawdler","dawn","daybed","daybreak","daycare","daydream","daylight","daylong","dayroom","daytime","dazzler","dazzling","deacon","deafening","deafness","dealer","dealing","dealmaker","dealt","dean","debatable","debate","debating","debit","debrief","debtless","debtor","debug","debunk","decade","decaf","decal","decathlon","decay","deceased","deceit","deceiver","deceiving","december","decency","decent","deception","deceptive","decibel","decidable","decimal","decimeter","decipher","deck","declared","decline","decode","decompose","decorated","decorator","decoy","decrease","decree","dedicate","dedicator","deduce","deduct","deed","deem","deepen","deeply","deepness","deface","defacing","defame","default","defeat","defection","defective","defendant","defender","defense","defensive","deferral","deferred","defiance","defiant","defile","defiling","define","definite","deflate","deflation","deflator","deflected","deflector","defog","deforest","defraud","defrost","deftly","defuse","defy","degraded","degrading","degrease","degree","dehydrate","deity","dejected","delay","delegate","delegator","delete","deletion","delicacy","delicate","delicious","delighted","delirious","delirium","deliverer","delivery","delouse","delta","deluge","delusion","deluxe","demanding","demeaning","demeanor","demise","democracy","democrat","demote","demotion","demystify","denatured","deniable","denial","denim","denote","dense","density","dental","dentist","denture","deny","deodorant","deodorize","departed","departure","depict","deplete","depletion","deplored","deploy","deport","depose","depraved","depravity","deprecate","depress","deprive","depth","deputize","deputy","derail","deranged","derby","derived","desecrate","deserve","deserving","designate","designed","designer","designing","deskbound","desktop","deskwork","desolate","despair","despise","despite","destiny","destitute","destruct","detached","detail","detection","detective","detector","detention","detergent","detest","detonate","detonator","detoxify","detract","deuce","devalue","deviancy","deviant","deviate","deviation","deviator","device","devious","devotedly","devotee","devotion","devourer","devouring","devoutly","dexterity","dexterous","diabetes","diabetic","diabolic","diagnoses","diagnosis","diagram","dial","diameter","diaper","diaphragm","diary","dice","dicing","dictate","dictation","dictator","difficult","diffused","diffuser","diffusion","diffusive","dig","dilation","diligence","diligent","dill","dilute","dime","diminish","dimly","dimmed","dimmer","dimness","dimple","diner","dingbat","dinghy","dinginess","dingo","dingy","dining","dinner","diocese","dioxide","diploma","dipped","dipper","dipping","directed","direction","directive","directly","directory","direness","dirtiness","disabled","disagree","disallow","disarm","disarray","disaster","disband","disbelief","disburse","discard","discern","discharge","disclose","discolor","discount","discourse","discover","discuss","disdain","disengage","disfigure","disgrace","dish","disinfect","disjoin","disk","dislike","disliking","dislocate","dislodge","disloyal","dismantle","dismay","dismiss","dismount","disobey","disorder","disown","disparate","disparity","dispatch","dispense","dispersal","dispersed","disperser","displace","display","displease","disposal","dispose","disprove","dispute","disregard","disrupt","dissuade","distance","distant","distaste","distill","distinct","distort","distract","distress","district","distrust","ditch","ditto","ditzy","dividable","divided","dividend","dividers","dividing","divinely","diving","divinity","divisible","divisibly","division","divisive","divorcee","dizziness","dizzy","doable","docile","dock","doctrine","document","dodge","dodgy","doily","doing","dole","dollar","dollhouse","dollop","dolly","dolphin","domain","domelike","domestic","dominion","dominoes","donated","donation","donator","donor","donut","doodle","doorbell","doorframe","doorknob","doorman","doormat","doornail","doorpost","doorstep","doorstop","doorway","doozy","dork","dormitory","dorsal","dosage","dose","dotted","doubling","douche","dove","down","dowry","doze","drab","dragging","dragonfly","dragonish","dragster","drainable","drainage","drained","drainer","drainpipe","dramatic","dramatize","drank","drapery","drastic","draw","dreaded","dreadful","dreadlock","dreamboat","dreamily","dreamland","dreamless","dreamlike","dreamt","dreamy","drearily","dreary","drench","dress","drew","dribble","dried","drier","drift","driller","drilling","drinkable","drinking","dripping","drippy","drivable","driven","driver","driveway","driving","drizzle","drizzly","drone","drool","droop","drop-down","dropbox","dropkick","droplet","dropout","dropper","drove","drown","drowsily","drudge","drum","dry","dubbed","dubiously","duchess","duckbill","ducking","duckling","ducktail","ducky","duct","dude","duffel","dugout","duh","duke","duller","dullness","duly","dumping","dumpling","dumpster","duo","dupe","duplex","duplicate","duplicity","durable","durably","duration","duress","during","dusk","dust","dutiful","duty","duvet","dwarf","dweeb","dwelled","dweller","dwelling","dwindle","dwindling","dynamic","dynamite","dynasty","dyslexia","dyslexic","each","eagle","earache","eardrum","earflap","earful","earlobe","early","earmark","earmuff","earphone","earpiece","earplugs","earring","earshot","earthen","earthlike","earthling","earthly","earthworm","earthy","earwig","easeful","easel","easiest","easily","easiness","easing","eastbound","eastcoast","easter","eastward","eatable","eaten","eatery","eating","eats","ebay","ebony","ebook","ecard","eccentric","echo","eclair","eclipse","ecologist","ecology","economic","economist","economy","ecosphere","ecosystem","edge","edginess","edging","edgy","edition","editor","educated","education","educator","eel","effective","effects","efficient","effort","eggbeater","egging","eggnog","eggplant","eggshell","egomaniac","egotism","egotistic","either","eject","elaborate","elastic","elated","elbow","eldercare","elderly","eldest","electable","election","elective","elephant","elevate","elevating","elevation","elevator","eleven","elf","eligible","eligibly","eliminate","elite","elitism","elixir","elk","ellipse","elliptic","elm","elongated","elope","eloquence","eloquent","elsewhere","elude","elusive","elves","email","embargo","embark","embassy","embattled","embellish","ember","embezzle","emblaze","emblem","embody","embolism","emboss","embroider","emcee","emerald","emergency","emission","emit","emote","emoticon","emotion","empathic","empathy","emperor","emphases","emphasis","emphasize","emphatic","empirical","employed","employee","employer","emporium","empower","emptier","emptiness","empty","emu","enable","enactment","enamel","enchanted","enchilada","encircle","enclose","enclosure","encode","encore","encounter","encourage","encroach","encrust","encrypt","endanger","endeared","endearing","ended","ending","endless","endnote","endocrine","endorphin","endorse","endowment","endpoint","endurable","endurance","enduring","energetic","energize","energy","enforced","enforcer","engaged","engaging","engine","engorge","engraved","engraver","engraving","engross","engulf","enhance","enigmatic","enjoyable","enjoyably","enjoyer","enjoying","enjoyment","enlarged","enlarging","enlighten","enlisted","enquirer","enrage","enrich","enroll","enslave","ensnare","ensure","entail","entangled","entering","entertain","enticing","entire","entitle","entity","entomb","entourage","entrap","entree","entrench","entrust","entryway","entwine","enunciate","envelope","enviable","enviably","envious","envision","envoy","envy","enzyme","epic","epidemic","epidermal","epidermis","epidural","epilepsy","epileptic","epilogue","epiphany","episode","equal","equate","equation","equator","equinox","equipment","equity","equivocal","eradicate","erasable","erased","eraser","erasure","ergonomic","errand","errant","erratic","error","erupt","escalate","escalator","escapable","escapade","escapist","escargot","eskimo","esophagus","espionage","espresso","esquire","essay","essence","essential","establish","estate","esteemed","estimate","estimator","estranged","estrogen","etching","eternal","eternity","ethanol","ether","ethically","ethics","euphemism","evacuate","evacuee","evade","evaluate","evaluator","evaporate","evasion","evasive","even","everglade","evergreen","everybody","everyday","everyone","evict","evidence","evident","evil","evoke","evolution","evolve","exact","exalted","example","excavate","excavator","exceeding","exception","excess","exchange","excitable","exciting","exclaim","exclude","excluding","exclusion","exclusive","excretion","excretory","excursion","excusable","excusably","excuse","exemplary","exemplify","exemption","exerciser","exert","exes","exfoliate","exhale","exhaust","exhume","exile","existing","exit","exodus","exonerate","exorcism","exorcist","expand","expanse","expansion","expansive","expectant","expedited","expediter","expel","expend","expenses","expensive","expert","expire","expiring","explain","expletive","explicit","explode","exploit","explore","exploring","exponent","exporter","exposable","expose","exposure","express","expulsion","exquisite","extended","extending","extent","extenuate","exterior","external","extinct","extortion","extradite","extras","extrovert","extrude","extruding","exuberant","fable","fabric","fabulous","facebook","facecloth","facedown","faceless","facelift","faceplate","faceted","facial","facility","facing","facsimile","faction","factoid","factor","factsheet","factual","faculty","fade","fading","failing","falcon","fall","false","falsify","fame","familiar","family","famine","famished","fanatic","fancied","fanciness","fancy","fanfare","fang","fanning","fantasize","fantastic","fantasy","fascism","fastball","faster","fasting","fastness","faucet","favorable","favorably","favored","favoring","favorite","fax","feast","federal","fedora","feeble","feed","feel","feisty","feline","felt-tip","feminine","feminism","feminist","feminize","femur","fence","fencing","fender","ferment","fernlike","ferocious","ferocity","ferret","ferris","ferry","fervor","fester","festival","festive","festivity","fetal","fetch","fever","fiber","fiction","fiddle","fiddling","fidelity","fidgeting","fidgety","fifteen","fifth","fiftieth","fifty","figment","figure","figurine","filing","filled","filler","filling","film","filter","filth","filtrate","finale","finalist","finalize","finally","finance","financial","finch","fineness","finer","finicky","finished","finisher","finishing","finite","finless","finlike","fiscally","fit","five","flaccid","flagman","flagpole","flagship","flagstick","flagstone","flail","flakily","flaky","flame","flammable","flanked","flanking","flannels","flap","flaring","flashback","flashbulb","flashcard","flashily","flashing","flashy","flask","flatbed","flatfoot","flatly","flatness","flatten","flattered","flatterer","flattery","flattop","flatware","flatworm","flavored","flavorful","flavoring","flaxseed","fled","fleshed","fleshy","flick","flier","flight","flinch","fling","flint","flip","flirt","float","flock","flogging","flop","floral","florist","floss","flounder","flyable","flyaway","flyer","flying","flyover","flypaper","foam","foe","fog","foil","folic","folk","follicle","follow","fondling","fondly","fondness","fondue","font","food","fool","footage","football","footbath","footboard","footer","footgear","foothill","foothold","footing","footless","footman","footnote","footpad","footpath","footprint","footrest","footsie","footsore","footwear","footwork","fossil","foster","founder","founding","fountain","fox","foyer","fraction","fracture","fragile","fragility","fragment","fragrance","fragrant","frail","frame","framing","frantic","fraternal","frayed","fraying","frays","freckled","freckles","freebase","freebee","freebie","freedom","freefall","freehand","freeing","freeload","freely","freemason","freeness","freestyle","freeware","freeway","freewill","freezable","freezing","freight","french","frenzied","frenzy","frequency","frequent","fresh","fretful","fretted","friction","friday","fridge","fried","friend","frighten","frightful","frigidity","frigidly","frill","fringe","frisbee","frisk","fritter","frivolous","frolic","from","front","frostbite","frosted","frostily","frosting","frostlike","frosty","froth","frown","frozen","fructose","frugality","frugally","fruit","frustrate","frying","gab","gaffe","gag","gainfully","gaining","gains","gala","gallantly","galleria","gallery","galley","gallon","gallows","gallstone","galore","galvanize","gambling","game","gaming","gamma","gander","gangly","gangrene","gangway","gap","garage","garbage","garden","gargle","garland","garlic","garment","garnet","garnish","garter","gas","gatherer","gathering","gating","gauging","gauntlet","gauze","gave","gawk","gazing","gear","gecko","geek","geiger","gem","gender","generic","generous","genetics","genre","gentile","gentleman","gently","gents","geography","geologic","geologist","geology","geometric","geometry","geranium","gerbil","geriatric","germicide","germinate","germless","germproof","gestate","gestation","gesture","getaway","getting","getup","giant","gibberish","giblet","giddily","giddiness","giddy","gift","gigabyte","gigahertz","gigantic","giggle","giggling","giggly","gigolo","gilled","gills","gimmick","girdle","giveaway","given","giver","giving","gizmo","gizzard","glacial","glacier","glade","gladiator","gladly","glamorous","glamour","glance","glancing","glandular","glare","glaring","glass","glaucoma","glazing","gleaming","gleeful","glider","gliding","glimmer","glimpse","glisten","glitch","glitter","glitzy","gloater","gloating","gloomily","gloomy","glorified","glorifier","glorify","glorious","glory","gloss","glove","glowing","glowworm","glucose","glue","gluten","glutinous","glutton","gnarly","gnat","goal","goatskin","goes","goggles","going","goldfish","goldmine","goldsmith","golf","goliath","gonad","gondola","gone","gong","good","gooey","goofball","goofiness","goofy","google","goon","gopher","gore","gorged","gorgeous","gory","gosling","gossip","gothic","gotten","gout","gown","grab","graceful","graceless","gracious","gradation","graded","grader","gradient","grading","gradually","graduate","graffiti","grafted","grafting","grain","granddad","grandkid","grandly","grandma","grandpa","grandson","granite","granny","granola","grant","granular","grape","graph","grapple","grappling","grasp","grass","gratified","gratify","grating","gratitude","gratuity","gravel","graveness","graves","graveyard","gravitate","gravity","gravy","gray","grazing","greasily","greedily","greedless","greedy","green","greeter","greeting","grew","greyhound","grid","grief","grievance","grieving","grievous","grill","grimace","grimacing","grime","griminess","grimy","grinch","grinning","grip","gristle","grit","groggily","groggy","groin","groom","groove","grooving","groovy","grope","ground","grouped","grout","grove","grower","growing","growl","grub","grudge","grudging","grueling","gruffly","grumble","grumbling","grumbly","grumpily","grunge","grunt","guacamole","guidable","guidance","guide","guiding","guileless","guise","gulf","gullible","gully","gulp","gumball","gumdrop","gumminess","gumming","gummy","gurgle","gurgling","guru","gush","gusto","gusty","gutless","guts","gutter","guy","guzzler","gyration","habitable","habitant","habitat","habitual","hacked","hacker","hacking","hacksaw","had","haggler","haiku","half","halogen","halt","halved","halves","hamburger","hamlet","hammock","hamper","hamster","hamstring","handbag","handball","handbook","handbrake","handcart","handclap","handclasp","handcraft","handcuff","handed","handful","handgrip","handgun","handheld","handiness","handiwork","handlebar","handled","handler","handling","handmade","handoff","handpick","handprint","handrail","handsaw","handset","handsfree","handshake","handstand","handwash","handwork","handwoven","handwrite","handyman","hangnail","hangout","hangover","hangup","hankering","hankie","hanky","haphazard","happening","happier","happiest","happily","happiness","happy","harbor","hardcopy","hardcore","hardcover","harddisk","hardened","hardener","hardening","hardhat","hardhead","hardiness","hardly","hardness","hardship","hardware","hardwired","hardwood","hardy","harmful","harmless","harmonica","harmonics","harmonize","harmony","harness","harpist","harsh","harvest","hash","hassle","haste","hastily","hastiness","hasty","hatbox","hatchback","hatchery","hatchet","hatching","hatchling","hate","hatless","hatred","haunt","haven","hazard","hazelnut","hazily","haziness","hazing","hazy","headache","headband","headboard","headcount","headdress","headed","header","headfirst","headgear","heading","headlamp","headless","headlock","headphone","headpiece","headrest","headroom","headscarf","headset","headsman","headstand","headstone","headway","headwear","heap","heat","heave","heavily","heaviness","heaving","hedge","hedging","heftiness","hefty","helium","helmet","helper","helpful","helping","helpless","helpline","hemlock","hemstitch","hence","henchman","henna","herald","herbal","herbicide","herbs","heritage","hermit","heroics","heroism","herring","herself","hertz","hesitancy","hesitant","hesitate","hexagon","hexagram","hubcap","huddle","huddling","huff","hug","hula","hulk","hull","human","humble","humbling","humbly","humid","humiliate","humility","humming","hummus","humongous","humorist","humorless","humorous","humpback","humped","humvee","hunchback","hundredth","hunger","hungrily","hungry","hunk","hunter","hunting","huntress","huntsman","hurdle","hurled","hurler","hurling","hurray","hurricane","hurried","hurry","hurt","husband","hush","husked","huskiness","hut","hybrid","hydrant","hydrated","hydration","hydrogen","hydroxide","hyperlink","hypertext","hyphen","hypnoses","hypnosis","hypnotic","hypnotism","hypnotist","hypnotize","hypocrisy","hypocrite","ibuprofen","ice","iciness","icing","icky","icon","icy","idealism","idealist","idealize","ideally","idealness","identical","identify","identity","ideology","idiocy","idiom","idly","igloo","ignition","ignore","iguana","illicitly","illusion","illusive","image","imaginary","imagines","imaging","imbecile","imitate","imitation","immature","immerse","immersion","imminent","immobile","immodest","immorally","immortal","immovable","immovably","immunity","immunize","impaired","impale","impart","impatient","impeach","impeding","impending","imperfect","imperial","impish","implant","implement","implicate","implicit","implode","implosion","implosive","imply","impolite","important","importer","impose","imposing","impotence","impotency","impotent","impound","imprecise","imprint","imprison","impromptu","improper","improve","improving","improvise","imprudent","impulse","impulsive","impure","impurity","iodine","iodize","ion","ipad","iphone","ipod","irate","irk","iron","irregular","irrigate","irritable","irritably","irritant","irritate","islamic","islamist","isolated","isolating","isolation","isotope","issue","issuing","italicize","italics","item","itinerary","itunes","ivory","ivy","jab","jackal","jacket","jackknife","jackpot","jailbird","jailbreak","jailer","jailhouse","jalapeno","jam","janitor","january","jargon","jarring","jasmine","jaundice","jaunt","java","jawed","jawless","jawline","jaws","jaybird","jaywalker","jazz","jeep","jeeringly","jellied","jelly","jersey","jester","jet","jiffy","jigsaw","jimmy","jingle","jingling","jinx","jitters","jittery","job","jockey","jockstrap","jogger","jogging","john","joining","jokester","jokingly","jolliness","jolly","jolt","jot","jovial","joyfully","joylessly","joyous","joyride","joystick","jubilance","jubilant","judge","judgingly","judicial","judiciary","judo","juggle","juggling","jugular","juice","juiciness","juicy","jujitsu","jukebox","july","jumble","jumbo","jump","junction","juncture","june","junior","juniper","junkie","junkman","junkyard","jurist","juror","jury","justice","justifier","justify","justly","justness","juvenile","kabob","kangaroo","karaoke","karate","karma","kebab","keenly","keenness","keep","keg","kelp","kennel","kept","kerchief","kerosene","kettle","kick","kiln","kilobyte","kilogram","kilometer","kilowatt","kilt","kimono","kindle","kindling","kindly","kindness","kindred","kinetic","kinfolk","king","kinship","kinsman","kinswoman","kissable","kisser","kissing","kitchen","kite","kitten","kitty","kiwi","kleenex","knapsack","knee","knelt","knickers","knoll","koala","kooky","kosher","krypton","kudos","kung","labored","laborer","laboring","laborious","labrador","ladder","ladies","ladle","ladybug","ladylike","lagged","lagging","lagoon","lair","lake","lance","landed","landfall","landfill","landing","landlady","landless","landline","landlord","landmark","landmass","landmine","landowner","landscape","landside","landslide","language","lankiness","lanky","lantern","lapdog","lapel","lapped","lapping","laptop","lard","large","lark","lash","lasso","last","latch","late","lather","latitude","latrine","latter","latticed","launch","launder","laundry","laurel","lavender","lavish","laxative","lazily","laziness","lazy","lecturer","left","legacy","legal","legend","legged","leggings","legible","legibly","legislate","lego","legroom","legume","legwarmer","legwork","lemon","lend","length","lens","lent","leotard","lesser","letdown","lethargic","lethargy","letter","lettuce","level","leverage","levers","levitate","levitator","liability","liable","liberty","librarian","library","licking","licorice","lid","life","lifter","lifting","liftoff","ligament","likely","likeness","likewise","liking","lilac","lilly","lily","limb","limeade","limelight","limes","limit","limping","limpness","line","lingo","linguini","linguist","lining","linked","linoleum","linseed","lint","lion","lip","liquefy","liqueur","liquid","lisp","list","litigate","litigator","litmus","litter","little","livable","lived","lively","liver","livestock","lividly","living","lizard","lubricant","lubricate","lucid","luckily","luckiness","luckless","lucrative","ludicrous","lugged","lukewarm","lullaby","lumber","luminance","luminous","lumpiness","lumping","lumpish","lunacy","lunar","lunchbox","luncheon","lunchroom","lunchtime","lung","lurch","lure","luridness","lurk","lushly","lushness","luster","lustfully","lustily","lustiness","lustrous","lusty","luxurious","luxury","lying","lyrically","lyricism","lyricist","lyrics","macarena","macaroni","macaw","mace","machine","machinist","magazine","magenta","maggot","magical","magician","magma","magnesium","magnetic","magnetism","magnetize","magnifier","magnify","magnitude","magnolia","mahogany","maimed","majestic","majesty","majorette","majority","makeover","maker","makeshift","making","malformed","malt","mama","mammal","mammary","mammogram","manager","managing","manatee","mandarin","mandate","mandatory","mandolin","manger","mangle","mango","mangy","manhandle","manhole","manhood","manhunt","manicotti","manicure","manifesto","manila","mankind","manlike","manliness","manly","manmade","manned","mannish","manor","manpower","mantis","mantra","manual","many","map","marathon","marauding","marbled","marbles","marbling","march","mardi","margarine","margarita","margin","marigold","marina","marine","marital","maritime","marlin","marmalade","maroon","married","marrow","marry","marshland","marshy","marsupial","marvelous","marxism","mascot","masculine","mashed","mashing","massager","masses","massive","mastiff","matador","matchbook","matchbox","matcher","matching","matchless","material","maternal","maternity","math","mating","matriarch","matrimony","matrix","matron","matted","matter","maturely","maturing","maturity","mauve","maverick","maximize","maximum","maybe","mayday","mayflower","moaner","moaning","mobile","mobility","mobilize","mobster","mocha","mocker","mockup","modified","modify","modular","modulator","module","moisten","moistness","moisture","molar","molasses","mold","molecular","molecule","molehill","mollusk","mom","monastery","monday","monetary","monetize","moneybags","moneyless","moneywise","mongoose","mongrel","monitor","monkhood","monogamy","monogram","monologue","monopoly","monorail","monotone","monotype","monoxide","monsieur","monsoon","monstrous","monthly","monument","moocher","moodiness","moody","mooing","moonbeam","mooned","moonlight","moonlike","moonlit","moonrise","moonscape","moonshine","moonstone","moonwalk","mop","morale","morality","morally","morbidity","morbidly","morphine","morphing","morse","mortality","mortally","mortician","mortified","mortify","mortuary","mosaic","mossy","most","mothball","mothproof","motion","motivate","motivator","motive","motocross","motor","motto","mountable","mountain","mounted","mounting","mourner","mournful","mouse","mousiness","moustache","mousy","mouth","movable","move","movie","moving","mower","mowing","much","muck","mud","mug","mulberry","mulch","mule","mulled","mullets","multiple","multiply","multitask","multitude","mumble","mumbling","mumbo","mummified","mummify","mummy","mumps","munchkin","mundane","municipal","muppet","mural","murkiness","murky","murmuring","muscular","museum","mushily","mushiness","mushroom","mushy","music","musket","muskiness","musky","mustang","mustard","muster","mustiness","musty","mutable","mutate","mutation","mute","mutilated","mutilator","mutiny","mutt","mutual","muzzle","myself","myspace","mystified","mystify","myth","nacho","nag","nail","name","naming","nanny","nanometer","nape","napkin","napped","napping","nappy","narrow","nastily","nastiness","national","native","nativity","natural","nature","naturist","nautical","navigate","navigator","navy","nearby","nearest","nearly","nearness","neatly","neatness","nebula","nebulizer","nectar","negate","negation","negative","neglector","negligee","negligent","negotiate","nemeses","nemesis","neon","nephew","nerd","nervous","nervy","nest","net","neurology","neuron","neurosis","neurotic","neuter","neutron","never","next","nibble","nickname","nicotine","niece","nifty","nimble","nimbly","nineteen","ninetieth","ninja","nintendo","ninth","nuclear","nuclei","nucleus","nugget","nullify","number","numbing","numbly","numbness","numeral","numerate","numerator","numeric","numerous","nuptials","nursery","nursing","nurture","nutcase","nutlike","nutmeg","nutrient","nutshell","nuttiness","nutty","nuzzle","nylon","oaf","oak","oasis","oat","obedience","obedient","obituary","object","obligate","obliged","oblivion","oblivious","oblong","obnoxious","oboe","obscure","obscurity","observant","observer","observing","obsessed","obsession","obsessive","obsolete","obstacle","obstinate","obstruct","obtain","obtrusive","obtuse","obvious","occultist","occupancy","occupant","occupier","occupy","ocean","ocelot","octagon","octane","october","octopus","ogle","oil","oink","ointment","okay","old","olive","olympics","omega","omen","ominous","omission","omit","omnivore","onboard","oncoming","ongoing","onion","online","onlooker","only","onscreen","onset","onshore","onslaught","onstage","onto","onward","onyx","oops","ooze","oozy","opacity","opal","open","operable","operate","operating","operation","operative","operator","opium","opossum","opponent","oppose","opposing","opposite","oppressed","oppressor","opt","opulently","osmosis","other","otter","ouch","ought","ounce","outage","outback","outbid","outboard","outbound","outbreak","outburst","outcast","outclass","outcome","outdated","outdoors","outer","outfield","outfit","outflank","outgoing","outgrow","outhouse","outing","outlast","outlet","outline","outlook","outlying","outmatch","outmost","outnumber","outplayed","outpost","outpour","output","outrage","outrank","outreach","outright","outscore","outsell","outshine","outshoot","outsider","outskirts","outsmart","outsource","outspoken","outtakes","outthink","outward","outweigh","outwit","oval","ovary","oven","overact","overall","overarch","overbid","overbill","overbite","overblown","overboard","overbook","overbuilt","overcast","overcoat","overcome","overcook","overcrowd","overdraft","overdrawn","overdress","overdrive","overdue","overeager","overeater","overexert","overfed","overfeed","overfill","overflow","overfull","overgrown","overhand","overhang","overhaul","overhead","overhear","overheat","overhung","overjoyed","overkill","overlabor","overlaid","overlap","overlay","overload","overlook","overlord","overlying","overnight","overpass","overpay","overplant","overplay","overpower","overprice","overrate","overreach","overreact","override","overripe","overrule","overrun","overshoot","overshot","oversight","oversized","oversleep","oversold","overspend","overstate","overstay","overstep","overstock","overstuff","oversweet","overtake","overthrow","overtime","overtly","overtone","overture","overturn","overuse","overvalue","overview","overwrite","owl","oxford","oxidant","oxidation","oxidize","oxidizing","oxygen","oxymoron","oyster","ozone","paced","pacemaker","pacific","pacifier","pacifism","pacifist","pacify","padded","padding","paddle","paddling","padlock","pagan","pager","paging","pajamas","palace","palatable","palm","palpable","palpitate","paltry","pampered","pamperer","pampers","pamphlet","panama","pancake","pancreas","panda","pandemic","pang","panhandle","panic","panning","panorama","panoramic","panther","pantomime","pantry","pants","pantyhose","paparazzi","papaya","paper","paprika","papyrus","parabola","parachute","parade","paradox","paragraph","parakeet","paralegal","paralyses","paralysis","paralyze","paramedic","parameter","paramount","parasail","parasite","parasitic","parcel","parched","parchment","pardon","parish","parka","parking","parkway","parlor","parmesan","parole","parrot","parsley","parsnip","partake","parted","parting","partition","partly","partner","partridge","party","passable","passably","passage","passcode","passenger","passerby","passing","passion","passive","passivism","passover","passport","password","pasta","pasted","pastel","pastime","pastor","pastrami","pasture","pasty","patchwork","patchy","paternal","paternity","path","patience","patient","patio","patriarch","patriot","patrol","patronage","patronize","pauper","pavement","paver","pavestone","pavilion","paving","pawing","payable","payback","paycheck","payday","payee","payer","paying","payment","payphone","payroll","pebble","pebbly","pecan","pectin","peculiar","peddling","pediatric","pedicure","pedigree","pedometer","pegboard","pelican","pellet","pelt","pelvis","penalize","penalty","pencil","pendant","pending","penholder","penknife","pennant","penniless","penny","penpal","pension","pentagon","pentagram","pep","perceive","percent","perch","percolate","perennial","perfected","perfectly","perfume","periscope","perish","perjurer","perjury","perkiness","perky","perm","peroxide","perpetual","perplexed","persecute","persevere","persuaded","persuader","pesky","peso","pessimism","pessimist","pester","pesticide","petal","petite","petition","petri","petroleum","petted","petticoat","pettiness","petty","petunia","phantom","phobia","phoenix","phonebook","phoney","phonics","phoniness","phony","phosphate","photo","phrase","phrasing","placard","placate","placidly","plank","planner","plant","plasma","plaster","plastic","plated","platform","plating","platinum","platonic","platter","platypus","plausible","plausibly","playable","playback","player","playful","playgroup","playhouse","playing","playlist","playmaker","playmate","playoff","playpen","playroom","playset","plaything","playtime","plaza","pleading","pleat","pledge","plentiful","plenty","plethora","plexiglas","pliable","plod","plop","plot","plow","ploy","pluck","plug","plunder","plunging","plural","plus","plutonium","plywood","poach","pod","poem","poet","pogo","pointed","pointer","pointing","pointless","pointy","poise","poison","poker","poking","polar","police","policy","polio","polish","politely","polka","polo","polyester","polygon","polygraph","polymer","poncho","pond","pony","popcorn","pope","poplar","popper","poppy","popsicle","populace","popular","populate","porcupine","pork","porous","porridge","portable","portal","portfolio","porthole","portion","portly","portside","poser","posh","posing","possible","possibly","possum","postage","postal","postbox","postcard","posted","poster","posting","postnasal","posture","postwar","pouch","pounce","pouncing","pound","pouring","pout","powdered","powdering","powdery","power","powwow","pox","praising","prance","prancing","pranker","prankish","prankster","prayer","praying","preacher","preaching","preachy","preamble","precinct","precise","precision","precook","precut","predator","predefine","predict","preface","prefix","preflight","preformed","pregame","pregnancy","pregnant","preheated","prelaunch","prelaw","prelude","premiere","premises","premium","prenatal","preoccupy","preorder","prepaid","prepay","preplan","preppy","preschool","prescribe","preseason","preset","preshow","president","presoak","press","presume","presuming","preteen","pretended","pretender","pretense","pretext","pretty","pretzel","prevail","prevalent","prevent","preview","previous","prewar","prewashed","prideful","pried","primal","primarily","primary","primate","primer","primp","princess","print","prior","prism","prison","prissy","pristine","privacy","private","privatize","prize","proactive","probable","probably","probation","probe","probing","probiotic","problem","procedure","process","proclaim","procreate","procurer","prodigal","prodigy","produce","product","profane","profanity","professed","professor","profile","profound","profusely","progeny","prognosis","program","progress","projector","prologue","prolonged","promenade","prominent","promoter","promotion","prompter","promptly","prone","prong","pronounce","pronto","proofing","proofread","proofs","propeller","properly","property","proponent","proposal","propose","props","prorate","protector","protegee","proton","prototype","protozoan","protract","protrude","proud","provable","proved","proven","provided","provider","providing","province","proving","provoke","provoking","provolone","prowess","prowler","prowling","proximity","proxy","prozac","prude","prudishly","prune","pruning","pry","psychic","public","publisher","pucker","pueblo","pug","pull","pulmonary","pulp","pulsate","pulse","pulverize","puma","pumice","pummel","punch","punctual","punctuate","punctured","pungent","punisher","punk","pupil","puppet","puppy","purchase","pureblood","purebred","purely","pureness","purgatory","purge","purging","purifier","purify","purist","puritan","purity","purple","purplish","purposely","purr","purse","pursuable","pursuant","pursuit","purveyor","pushcart","pushchair","pusher","pushiness","pushing","pushover","pushpin","pushup","pushy","putdown","putt","puzzle","puzzling","pyramid","pyromania","python","quack","quadrant","quail","quaintly","quake","quaking","qualified","qualifier","qualify","quality","qualm","quantum","quarrel","quarry","quartered","quarterly","quarters","quartet","quench","query","quicken","quickly","quickness","quicksand","quickstep","quiet","quill","quilt","quintet","quintuple","quirk","quit","quiver","quizzical","quotable","quotation","quote","rabid","race","racing","racism","rack","racoon","radar","radial","radiance","radiantly","radiated","radiation","radiator","radio","radish","raffle","raft","rage","ragged","raging","ragweed","raider","railcar","railing","railroad","railway","raisin","rake","raking","rally","ramble","rambling","ramp","ramrod","ranch","rancidity","random","ranged","ranger","ranging","ranked","ranking","ransack","ranting","rants","rare","rarity","rascal","rash","rasping","ravage","raven","ravine","raving","ravioli","ravishing","reabsorb","reach","reacquire","reaction","reactive","reactor","reaffirm","ream","reanalyze","reappear","reapply","reappoint","reapprove","rearrange","rearview","reason","reassign","reassure","reattach","reawake","rebalance","rebate","rebel","rebirth","reboot","reborn","rebound","rebuff","rebuild","rebuilt","reburial","rebuttal","recall","recant","recapture","recast","recede","recent","recess","recharger","recipient","recital","recite","reckless","reclaim","recliner","reclining","recluse","reclusive","recognize","recoil","recollect","recolor","reconcile","reconfirm","reconvene","recopy","record","recount","recoup","recovery","recreate","rectal","rectangle","rectified","rectify","recycled","recycler","recycling","reemerge","reenact","reenter","reentry","reexamine","referable","referee","reference","refill","refinance","refined","refinery","refining","refinish","reflected","reflector","reflex","reflux","refocus","refold","reforest","reformat","reformed","reformer","reformist","refract","refrain","refreeze","refresh","refried","refueling","refund","refurbish","refurnish","refusal","refuse","refusing","refutable","refute","regain","regalia","regally","reggae","regime","region","register","registrar","registry","regress","regretful","regroup","regular","regulate","regulator","rehab","reheat","rehire","rehydrate","reimburse","reissue","reiterate","rejoice","rejoicing","rejoin","rekindle","relapse","relapsing","relatable","related","relation","relative","relax","relay","relearn","release","relenting","reliable","reliably","reliance","reliant","relic","relieve","relieving","relight","relish","relive","reload","relocate","relock","reluctant","rely","remake","remark","remarry","rematch","remedial","remedy","remember","reminder","remindful","remission","remix","remnant","remodeler","remold","remorse","remote","removable","removal","removed","remover","removing","rename","renderer","rendering","rendition","renegade","renewable","renewably","renewal","renewed","renounce","renovate","renovator","rentable","rental","rented","renter","reoccupy","reoccur","reopen","reorder","repackage","repacking","repaint","repair","repave","repaying","repayment","repeal","repeated","repeater","repent","rephrase","replace","replay","replica","reply","reporter","repose","repossess","repost","repressed","reprimand","reprint","reprise","reproach","reprocess","reproduce","reprogram","reps","reptile","reptilian","repugnant","repulsion","repulsive","repurpose","reputable","reputably","request","require","requisite","reroute","rerun","resale","resample","rescuer","reseal","research","reselect","reseller","resemble","resend","resent","reset","reshape","reshoot","reshuffle","residence","residency","resident","residual","residue","resigned","resilient","resistant","resisting","resize","resolute","resolved","resonant","resonate","resort","resource","respect","resubmit","result","resume","resupply","resurface","resurrect","retail","retainer","retaining","retake","retaliate","retention","rethink","retinal","retired","retiree","retiring","retold","retool","retorted","retouch","retrace","retract","retrain","retread","retreat","retrial","retrieval","retriever","retry","return","retying","retype","reunion","reunite","reusable","reuse","reveal","reveler","revenge","revenue","reverb","revered","reverence","reverend","reversal","reverse","reversing","reversion","revert","revisable","revise","revision","revisit","revivable","revival","reviver","reviving","revocable","revoke","revolt","revolver","revolving","reward","rewash","rewind","rewire","reword","rework","rewrap","rewrite","rhyme","ribbon","ribcage","rice","riches","richly","richness","rickety","ricotta","riddance","ridden","ride","riding","rifling","rift","rigging","rigid","rigor","rimless","rimmed","rind","rink","rinse","rinsing","riot","ripcord","ripeness","ripening","ripping","ripple","rippling","riptide","rise","rising","risk","risotto","ritalin","ritzy","rival","riverbank","riverbed","riverboat","riverside","riveter","riveting","roamer","roaming","roast","robbing","robe","robin","robotics","robust","rockband","rocker","rocket","rockfish","rockiness","rocking","rocklike","rockslide","rockstar","rocky","rogue","roman","romp","rope","roping","roster","rosy","rotten","rotting","rotunda","roulette","rounding","roundish","roundness","roundup","roundworm","routine","routing","rover","roving","royal","rubbed","rubber","rubbing","rubble","rubdown","ruby","ruckus","rudder","rug","ruined","rule","rumble","rumbling","rummage","rumor","runaround","rundown","runner","running","runny","runt","runway","rupture","rural","ruse","rush","rust","rut","sabbath","sabotage","sacrament","sacred","sacrifice","sadden","saddlebag","saddled","saddling","sadly","sadness","safari","safeguard","safehouse","safely","safeness","saffron","saga","sage","sagging","saggy","said","saint","sake","salad","salami","salaried","salary","saline","salon","saloon","salsa","salt","salutary","salute","salvage","salvaging","salvation","same","sample","sampling","sanction","sanctity","sanctuary","sandal","sandbag","sandbank","sandbar","sandblast","sandbox","sanded","sandfish","sanding","sandlot","sandpaper","sandpit","sandstone","sandstorm","sandworm","sandy","sanitary","sanitizer","sank","santa","sapling","sappiness","sappy","sarcasm","sarcastic","sardine","sash","sasquatch","sassy","satchel","satiable","satin","satirical","satisfied","satisfy","saturate","saturday","sauciness","saucy","sauna","savage","savanna","saved","savings","savior","savor","saxophone","say","scabbed","scabby","scalded","scalding","scale","scaling","scallion","scallop","scalping","scam","scandal","scanner","scanning","scant","scapegoat","scarce","scarcity","scarecrow","scared","scarf","scarily","scariness","scarring","scary","scavenger","scenic","schedule","schematic","scheme","scheming","schilling","schnapps","scholar","science","scientist","scion","scoff","scolding","scone","scoop","scooter","scope","scorch","scorebook","scorecard","scored","scoreless","scorer","scoring","scorn","scorpion","scotch","scoundrel","scoured","scouring","scouting","scouts","scowling","scrabble","scraggly","scrambled","scrambler","scrap","scratch","scrawny","screen","scribble","scribe","scribing","scrimmage","script","scroll","scrooge","scrounger","scrubbed","scrubber","scruffy","scrunch","scrutiny","scuba","scuff","sculptor","sculpture","scurvy","scuttle","secluded","secluding","seclusion","second","secrecy","secret","sectional","sector","secular","securely","security","sedan","sedate","sedation","sedative","sediment","seduce","seducing","segment","seismic","seizing","seldom","selected","selection","selective","selector","self","seltzer","semantic","semester","semicolon","semifinal","seminar","semisoft","semisweet","senate","senator","send","senior","senorita","sensation","sensitive","sensitize","sensually","sensuous","sepia","september","septic","septum","sequel","sequence","sequester","series","sermon","serotonin","serpent","serrated","serve","service","serving","sesame","sessions","setback","setting","settle","settling","setup","sevenfold","seventeen","seventh","seventy","severity","shabby","shack","shaded","shadily","shadiness","shading","shadow","shady","shaft","shakable","shakily","shakiness","shaking","shaky","shale","shallot","shallow","shame","shampoo","shamrock","shank","shanty","shape","shaping","share","sharpener","sharper","sharpie","sharply","sharpness","shawl","sheath","shed","sheep","sheet","shelf","shell","shelter","shelve","shelving","sherry","shield","shifter","shifting","shiftless","shifty","shimmer","shimmy","shindig","shine","shingle","shininess","shining","shiny","ship","shirt","shivering","shock","shone","shoplift","shopper","shopping","shoptalk","shore","shortage","shortcake","shortcut","shorten","shorter","shorthand","shortlist","shortly","shortness","shorts","shortwave","shorty","shout","shove","showbiz","showcase","showdown","shower","showgirl","showing","showman","shown","showoff","showpiece","showplace","showroom","showy","shrank","shrapnel","shredder","shredding","shrewdly","shriek","shrill","shrimp","shrine","shrink","shrivel","shrouded","shrubbery","shrubs","shrug","shrunk","shucking","shudder","shuffle","shuffling","shun","shush","shut","shy","siamese","siberian","sibling","siding","sierra","siesta","sift","sighing","silenced","silencer","silent","silica","silicon","silk","silliness","silly","silo","silt","silver","similarly","simile","simmering","simple","simplify","simply","sincere","sincerity","singer","singing","single","singular","sinister","sinless","sinner","sinuous","sip","siren","sister","sitcom","sitter","sitting","situated","situation","sixfold","sixteen","sixth","sixties","sixtieth","sixtyfold","sizable","sizably","size","sizing","sizzle","sizzling","skater","skating","skedaddle","skeletal","skeleton","skeptic","sketch","skewed","skewer","skid","skied","skier","skies","skiing","skilled","skillet","skillful","skimmed","skimmer","skimming","skimpily","skincare","skinhead","skinless","skinning","skinny","skintight","skipper","skipping","skirmish","skirt","skittle","skydiver","skylight","skyline","skype","skyrocket","skyward","slab","slacked","slacker","slacking","slackness","slacks","slain","slam","slander","slang","slapping","slapstick","slashed","slashing","slate","slather","slaw","sled","sleek","sleep","sleet","sleeve","slept","sliceable","sliced","slicer","slicing","slick","slider","slideshow","sliding","slighted","slighting","slightly","slimness","slimy","slinging","slingshot","slinky","slip","slit","sliver","slobbery","slogan","sloped","sloping","sloppily","sloppy","slot","slouching","slouchy","sludge","slug","slum","slurp","slush","sly","small","smartly","smartness","smasher","smashing","smashup","smell","smelting","smile","smilingly","smirk","smite","smith","smitten","smock","smog","smoked","smokeless","smokiness","smoking","smoky","smolder","smooth","smother","smudge","smudgy","smuggler","smuggling","smugly","smugness","snack","snagged","snaking","snap","snare","snarl","snazzy","sneak","sneer","sneeze","sneezing","snide","sniff","snippet","snipping","snitch","snooper","snooze","snore","snoring","snorkel","snort","snout","snowbird","snowboard","snowbound","snowcap","snowdrift","snowdrop","snowfall","snowfield","snowflake","snowiness","snowless","snowman","snowplow","snowshoe","snowstorm","snowsuit","snowy","snub","snuff","snuggle","snugly","snugness","speak","spearfish","spearhead","spearman","spearmint","species","specimen","specked","speckled","specks","spectacle","spectator","spectrum","speculate","speech","speed","spellbind","speller","spelling","spendable","spender","spending","spent","spew","sphere","spherical","sphinx","spider","spied","spiffy","spill","spilt","spinach","spinal","spindle","spinner","spinning","spinout","spinster","spiny","spiral","spirited","spiritism","spirits","spiritual","splashed","splashing","splashy","splatter","spleen","splendid","splendor","splice","splicing","splinter","splotchy","splurge","spoilage","spoiled","spoiler","spoiling","spoils","spoken","spokesman","sponge","spongy","sponsor","spoof","spookily","spooky","spool","spoon","spore","sporting","sports","sporty","spotless","spotlight","spotted","spotter","spotting","spotty","spousal","spouse","spout","sprain","sprang","sprawl","spray","spree","sprig","spring","sprinkled","sprinkler","sprint","sprite","sprout","spruce","sprung","spry","spud","spur","sputter","spyglass","squabble","squad","squall","squander","squash","squatted","squatter","squatting","squeak","squealer","squealing","squeamish","squeegee","squeeze","squeezing","squid","squiggle","squiggly","squint","squire","squirt","squishier","squishy","stability","stabilize","stable","stack","stadium","staff","stage","staging","stagnant","stagnate","stainable","stained","staining","stainless","stalemate","staleness","stalling","stallion","stamina","stammer","stamp","stand","stank","staple","stapling","starboard","starch","stardom","stardust","starfish","stargazer","staring","stark","starless","starlet","starlight","starlit","starring","starry","starship","starter","starting","startle","startling","startup","starved","starving","stash","state","static","statistic","statue","stature","status","statute","statutory","staunch","stays","steadfast","steadier","steadily","steadying","steam","steed","steep","steerable","steering","steersman","stegosaur","stellar","stem","stench","stencil","step","stereo","sterile","sterility","sterilize","sterling","sternness","sternum","stew","stick","stiffen","stiffly","stiffness","stifle","stifling","stillness","stilt","stimulant","stimulate","stimuli","stimulus","stinger","stingily","stinging","stingray","stingy","stinking","stinky","stipend","stipulate","stir","stitch","stock","stoic","stoke","stole","stomp","stonewall","stoneware","stonework","stoning","stony","stood","stooge","stool","stoop","stoplight","stoppable","stoppage","stopped","stopper","stopping","stopwatch","storable","storage","storeroom","storewide","storm","stout","stove","stowaway","stowing","straddle","straggler","strained","strainer","straining","strangely","stranger","strangle","strategic","strategy","stratus","straw","stray","streak","stream","street","strength","strenuous","strep","stress","stretch","strewn","stricken","strict","stride","strife","strike","striking","strive","striving","strobe","strode","stroller","strongbox","strongly","strongman","struck","structure","strudel","struggle","strum","strung","strut","stubbed","stubble","stubbly","stubborn","stucco","stuck","student","studied","studio","study","stuffed","stuffing","stuffy","stumble","stumbling","stump","stung","stunned","stunner","stunning","stunt","stupor","sturdily","sturdy","styling","stylishly","stylist","stylized","stylus","suave","subarctic","subatomic","subdivide","subdued","subduing","subfloor","subgroup","subheader","subject","sublease","sublet","sublevel","sublime","submarine","submerge","submersed","submitter","subpanel","subpar","subplot","subprime","subscribe","subscript","subsector","subside","subsiding","subsidize","subsidy","subsoil","subsonic","substance","subsystem","subtext","subtitle","subtly","subtotal","subtract","subtype","suburb","subway","subwoofer","subzero","succulent","such","suction","sudden","sudoku","suds","sufferer","suffering","suffice","suffix","suffocate","suffrage","sugar","suggest","suing","suitable","suitably","suitcase","suitor","sulfate","sulfide","sulfite","sulfur","sulk","sullen","sulphate","sulphuric","sultry","superbowl","superglue","superhero","superior","superjet","superman","supermom","supernova","supervise","supper","supplier","supply","support","supremacy","supreme","surcharge","surely","sureness","surface","surfacing","surfboard","surfer","surgery","surgical","surging","surname","surpass","surplus","surprise","surreal","surrender","surrogate","surround","survey","survival","survive","surviving","survivor","sushi","suspect","suspend","suspense","sustained","sustainer","swab","swaddling","swagger","swampland","swan","swapping","swarm","sway","swear","sweat","sweep","swell","swept","swerve","swifter","swiftly","swiftness","swimmable","swimmer","swimming","swimsuit","swimwear","swinger","swinging","swipe","swirl","switch","swivel","swizzle","swooned","swoop","swoosh","swore","sworn","swung","sycamore","sympathy","symphonic","symphony","symptom","synapse","syndrome","synergy","synopses","synopsis","synthesis","synthetic","syrup","system","t-shirt","tabasco","tabby","tableful","tables","tablet","tableware","tabloid","tackiness","tacking","tackle","tackling","tacky","taco","tactful","tactical","tactics","tactile","tactless","tadpole","taekwondo","tag","tainted","take","taking","talcum","talisman","tall","talon","tamale","tameness","tamer","tamper","tank","tanned","tannery","tanning","tantrum","tapeless","tapered","tapering","tapestry","tapioca","tapping","taps","tarantula","target","tarmac","tarnish","tarot","tartar","tartly","tartness","task","tassel","taste","tastiness","tasting","tasty","tattered","tattle","tattling","tattoo","taunt","tavern","thank","that","thaw","theater","theatrics","thee","theft","theme","theology","theorize","thermal","thermos","thesaurus","these","thesis","thespian","thicken","thicket","thickness","thieving","thievish","thigh","thimble","thing","think","thinly","thinner","thinness","thinning","thirstily","thirsting","thirsty","thirteen","thirty","thong","thorn","those","thousand","thrash","thread","threaten","threefold","thrift","thrill","thrive","thriving","throat","throbbing","throng","throttle","throwaway","throwback","thrower","throwing","thud","thumb","thumping","thursday","thus","thwarting","thyself","tiara","tibia","tidal","tidbit","tidiness","tidings","tidy","tiger","tighten","tightly","tightness","tightrope","tightwad","tigress","tile","tiling","till","tilt","timid","timing","timothy","tinderbox","tinfoil","tingle","tingling","tingly","tinker","tinkling","tinsel","tinsmith","tint","tinwork","tiny","tipoff","tipped","tipper","tipping","tiptoeing","tiptop","tiring","tissue","trace","tracing","track","traction","tractor","trade","trading","tradition","traffic","tragedy","trailing","trailside","train","traitor","trance","tranquil","transfer","transform","translate","transpire","transport","transpose","trapdoor","trapeze","trapezoid","trapped","trapper","trapping","traps","trash","travel","traverse","travesty","tray","treachery","treading","treadmill","treason","treat","treble","tree","trekker","tremble","trembling","tremor","trench","trend","trespass","triage","trial","triangle","tribesman","tribunal","tribune","tributary","tribute","triceps","trickery","trickily","tricking","trickle","trickster","tricky","tricolor","tricycle","trident","tried","trifle","trifocals","trillion","trilogy","trimester","trimmer","trimming","trimness","trinity","trio","tripod","tripping","triumph","trivial","trodden","trolling","trombone","trophy","tropical","tropics","trouble","troubling","trough","trousers","trout","trowel","truce","truck","truffle","trump","trunks","trustable","trustee","trustful","trusting","trustless","truth","try","tubby","tubeless","tubular","tucking","tuesday","tug","tuition","tulip","tumble","tumbling","tummy","turban","turbine","turbofan","turbojet","turbulent","turf","turkey","turmoil","turret","turtle","tusk","tutor","tutu","tux","tweak","tweed","tweet","tweezers","twelve","twentieth","twenty","twerp","twice","twiddle","twiddling","twig","twilight","twine","twins","twirl","twistable","twisted","twister","twisting","twisty","twitch","twitter","tycoon","tying","tyke","udder","ultimate","ultimatum","ultra","umbilical","umbrella","umpire","unabashed","unable","unadorned","unadvised","unafraid","unaired","unaligned","unaltered","unarmored","unashamed","unaudited","unawake","unaware","unbaked","unbalance","unbeaten","unbend","unbent","unbiased","unbitten","unblended","unblessed","unblock","unbolted","unbounded","unboxed","unbraided","unbridle","unbroken","unbuckled","unbundle","unburned","unbutton","uncanny","uncapped","uncaring","uncertain","unchain","unchanged","uncharted","uncheck","uncivil","unclad","unclaimed","unclamped","unclasp","uncle","unclip","uncloak","unclog","unclothed","uncoated","uncoiled","uncolored","uncombed","uncommon","uncooked","uncork","uncorrupt","uncounted","uncouple","uncouth","uncover","uncross","uncrown","uncrushed","uncured","uncurious","uncurled","uncut","undamaged","undated","undaunted","undead","undecided","undefined","underage","underarm","undercoat","undercook","undercut","underdog","underdone","underfed","underfeed","underfoot","undergo","undergrad","underhand","underline","underling","undermine","undermost","underpaid","underpass","underpay","underrate","undertake","undertone","undertook","undertow","underuse","underwear","underwent","underwire","undesired","undiluted","undivided","undocked","undoing","undone","undrafted","undress","undrilled","undusted","undying","unearned","unearth","unease","uneasily","uneasy","uneatable","uneaten","unedited","unelected","unending","unengaged","unenvied","unequal","unethical","uneven","unexpired","unexposed","unfailing","unfair","unfasten","unfazed","unfeeling","unfiled","unfilled","unfitted","unfitting","unfixable","unfixed","unflawed","unfocused","unfold","unfounded","unframed","unfreeze","unfrosted","unfrozen","unfunded","unglazed","ungloved","unglue","ungodly","ungraded","ungreased","unguarded","unguided","unhappily","unhappy","unharmed","unhealthy","unheard","unhearing","unheated","unhelpful","unhidden","unhinge","unhitched","unholy","unhook","unicorn","unicycle","unified","unifier","uniformed","uniformly","unify","unimpeded","uninjured","uninstall","uninsured","uninvited","union","uniquely","unisexual","unison","unissued","unit","universal","universe","unjustly","unkempt","unkind","unknotted","unknowing","unknown","unlaced","unlatch","unlawful","unleaded","unlearned","unleash","unless","unleveled","unlighted","unlikable","unlimited","unlined","unlinked","unlisted","unlit","unlivable","unloaded","unloader","unlocked","unlocking","unlovable","unloved","unlovely","unloving","unluckily","unlucky","unmade","unmanaged","unmanned","unmapped","unmarked","unmasked","unmasking","unmatched","unmindful","unmixable","unmixed","unmolded","unmoral","unmovable","unmoved","unmoving","unnamable","unnamed","unnatural","unneeded","unnerve","unnerving","unnoticed","unopened","unopposed","unpack","unpadded","unpaid","unpainted","unpaired","unpaved","unpeeled","unpicked","unpiloted","unpinned","unplanned","unplanted","unpleased","unpledged","unplowed","unplug","unpopular","unproven","unquote","unranked","unrated","unraveled","unreached","unread","unreal","unreeling","unrefined","unrelated","unrented","unrest","unretired","unrevised","unrigged","unripe","unrivaled","unroasted","unrobed","unroll","unruffled","unruly","unrushed","unsaddle","unsafe","unsaid","unsalted","unsaved","unsavory","unscathed","unscented","unscrew","unsealed","unseated","unsecured","unseeing","unseemly","unseen","unselect","unselfish","unsent","unsettled","unshackle","unshaken","unshaved","unshaven","unsheathe","unshipped","unsightly","unsigned","unskilled","unsliced","unsmooth","unsnap","unsocial","unsoiled","unsold","unsolved","unsorted","unspoiled","unspoken","unstable","unstaffed","unstamped","unsteady","unsterile","unstirred","unstitch","unstopped","unstuck","unstuffed","unstylish","unsubtle","unsubtly","unsuited","unsure","unsworn","untagged","untainted","untaken","untamed","untangled","untapped","untaxed","unthawed","unthread","untidy","untie","until","untimed","untimely","untitled","untoasted","untold","untouched","untracked","untrained","untreated","untried","untrimmed","untrue","untruth","unturned","untwist","untying","unusable","unused","unusual","unvalued","unvaried","unvarying","unveiled","unveiling","unvented","unviable","unvisited","unvocal","unwanted","unwarlike","unwary","unwashed","unwatched","unweave","unwed","unwelcome","unwell","unwieldy","unwilling","unwind","unwired","unwitting","unwomanly","unworldly","unworn","unworried","unworthy","unwound","unwoven","unwrapped","unwritten","unzip","upbeat","upchuck","upcoming","upcountry","update","upfront","upgrade","upheaval","upheld","uphill","uphold","uplifted","uplifting","upload","upon","upper","upright","uprising","upriver","uproar","uproot","upscale","upside","upstage","upstairs","upstart","upstate","upstream","upstroke","upswing","uptake","uptight","uptown","upturned","upward","upwind","uranium","urban","urchin","urethane","urgency","urgent","urging","urologist","urology","usable","usage","useable","used","uselessly","user","usher","usual","utensil","utility","utilize","utmost","utopia","utter","vacancy","vacant","vacate","vacation","vagabond","vagrancy","vagrantly","vaguely","vagueness","valiant","valid","valium","valley","valuables","value","vanilla","vanish","vanity","vanquish","vantage","vaporizer","variable","variably","varied","variety","various","varmint","varnish","varsity","varying","vascular","vaseline","vastly","vastness","veal","vegan","veggie","vehicular","velcro","velocity","velvet","vendetta","vending","vendor","veneering","vengeful","venomous","ventricle","venture","venue","venus","verbalize","verbally","verbose","verdict","verify","verse","version","versus","vertebrae","vertical","vertigo","very","vessel","vest","veteran","veto","vexingly","viability","viable","vibes","vice","vicinity","victory","video","viewable","viewer","viewing","viewless","viewpoint","vigorous","village","villain","vindicate","vineyard","vintage","violate","violation","violator","violet","violin","viper","viral","virtual","virtuous","virus","visa","viscosity","viscous","viselike","visible","visibly","vision","visiting","visitor","visor","vista","vitality","vitalize","vitally","vitamins","vivacious","vividly","vividness","vixen","vocalist","vocalize","vocally","vocation","voice","voicing","void","volatile","volley","voltage","volumes","voter","voting","voucher","vowed","vowel","voyage","wackiness","wad","wafer","waffle","waged","wager","wages","waggle","wagon","wake","waking","walk","walmart","walnut","walrus","waltz","wand","wannabe","wanted","wanting","wasabi","washable","washbasin","washboard","washbowl","washcloth","washday","washed","washer","washhouse","washing","washout","washroom","washstand","washtub","wasp","wasting","watch","water","waviness","waving","wavy","whacking","whacky","wham","wharf","wheat","whenever","whiff","whimsical","whinny","whiny","whisking","whoever","whole","whomever","whoopee","whooping","whoops","why","wick","widely","widen","widget","widow","width","wieldable","wielder","wife","wifi","wikipedia","wildcard","wildcat","wilder","wildfire","wildfowl","wildland","wildlife","wildly","wildness","willed","willfully","willing","willow","willpower","wilt","wimp","wince","wincing","wind","wing","winking","winner","winnings","winter","wipe","wired","wireless","wiring","wiry","wisdom","wise","wish","wisplike","wispy","wistful","wizard","wobble","wobbling","wobbly","wok","wolf","wolverine","womanhood","womankind","womanless","womanlike","womanly","womb","woof","wooing","wool","woozy","word","work","worried","worrier","worrisome","worry","worsening","worshiper","worst","wound","woven","wow","wrangle","wrath","wreath","wreckage","wrecker","wrecking","wrench","wriggle","wriggly","wrinkle","wrinkly","wrist","writing","written","wrongdoer","wronged","wrongful","wrongly","wrongness","wrought","xbox","xerox","yahoo","yam","yanking","yapping","yard","yarn","yeah","yearbook","yearling","yearly","yearning","yeast","yelling","yelp","yen","yesterday","yiddish","yield","yin","yippee","yo-yo","yodel","yoga","yogurt","yonder","yoyo","yummy","zap","zealous","zebra","zen","zeppelin","zero","zestfully","zesty","zigzagged","zipfile","zipping","zippy","zips","zit","zodiac","zombie","zone","zoning","zookeeper","zoologist","zoology","zoom"]),es=Object.freeze(eo.filter(c=>!c.includes("-")))},13142:function(c,l,et){"use strict";et.r(l),et.d(l,{Struct:function(){return Struct},StructError:function(){return StructError},any:function(){return any},array:function(){return array},assert:function(){return assert},assign:function(){return assign},bigint:function(){return bigint},boolean:function(){return boolean},coerce:function(){return coerce},create:function(){return create},date:function(){return date},defaulted:function(){return defaulted},define:function(){return define},deprecated:function(){return deprecated},dynamic:function(){return dynamic},empty:function(){return empty},enums:function(){return enums},func:function(){return func},instance:function(){return instance},integer:function(){return integer},intersection:function(){return intersection},is:function(){return is},lazy:function(){return lazy},literal:function(){return literal},map:function(){return map},mask:function(){return mask},max:function(){return max},min:function(){return min},never:function(){return never},nonempty:function(){return nonempty},nullable:function(){return nullable},number:function(){return number},object:function(){return object},omit:function(){return omit},optional:function(){return optional},partial:function(){return partial},pattern:function(){return pattern},pick:function(){return pick},record:function(){return record},refine:function(){return refine},regexp:function(){return regexp},set:function(){return set},size:function(){return size},string:function(){return string},struct:function(){return struct},trimmed:function(){return trimmed},tuple:function(){return tuple},type:function(){return type},union:function(){return union},unknown:function(){return unknown},validate:function(){return validate}});let StructError=class StructError extends TypeError{constructor(c,l){let et;let{message:eo,explanation:es,...ec}=c,{path:el}=c,ed=0===el.length?eo:`At path: ${el.join(".")} -- ${eo}`;super(es??ed),null!=es&&(this.cause=ed),Object.assign(this,ec),this.name=this.constructor.name,this.failures=()=>et??(et=[c,...l()])}};function isObject(c){return"object"==typeof c&&null!=c}function isPlainObject(c){if("[object Object]"!==Object.prototype.toString.call(c))return!1;let l=Object.getPrototypeOf(c);return null===l||l===Object.prototype}function print(c){return"symbol"==typeof c?c.toString():"string"==typeof c?JSON.stringify(c):`${c}`}function*toFailures(c,l,et,eo){var es;for(let ec of(isObject(es=c)&&"function"==typeof es[Symbol.iterator]||(c=[c]),c)){let c=function(c,l,et,eo){if(!0===c)return;!1===c?c={}:"string"==typeof c&&(c={message:c});let{path:es,branch:ec}=l,{type:el}=et,{refinement:ed,message:eh=`Expected a value of type \`${el}\`${ed?` with refinement \`${ed}\``:""}, but received: \`${print(eo)}\``}=c;return{value:eo,type:el,refinement:ed,key:es[es.length-1],path:es,branch:ec,...c,message:eh}}(ec,l,et,eo);c&&(yield c)}}function*run(c,l,et={}){let{path:eo=[],branch:es=[c],coerce:ec=!1,mask:el=!1}=et,ed={path:eo,branch:es};if(ec&&(c=l.coercer(c,ed),el&&"type"!==l.type&&isObject(l.schema)&&isObject(c)&&!Array.isArray(c)))for(let et in c)void 0===l.schema[et]&&delete c[et];let eh="valid";for(let eo of l.validator(c,ed))eo.explanation=et.message,eh="not_valid",yield[eo,void 0];for(let[ef,ep,eg]of l.entries(c,ed)){let l=run(ep,eg,{path:void 0===ef?eo:[...eo,ef],branch:void 0===ef?es:[...es,ep],coerce:ec,mask:el,message:et.message});for(let et of l)et[0]?(eh=null!=et[0].refinement?"not_refined":"not_valid",yield[et[0],void 0]):ec&&(ep=et[1],void 0===ef?c=ep:c instanceof Map?c.set(ef,ep):c instanceof Set?c.add(ep):isObject(c)&&(void 0!==ep||ef in c)&&(c[ef]=ep))}if("not_valid"!==eh)for(let eo of l.refiner(c,ed))eo.explanation=et.message,eh="not_refined",yield[eo,void 0];"valid"===eh&&(yield[void 0,c])}let Struct=class Struct{constructor(c){let{type:l,schema:et,validator:eo,refiner:es,coercer:ec=c=>c,entries:el=function*(){}}=c;this.type=l,this.schema=et,this.entries=el,this.coercer=ec,eo?this.validator=(c,l)=>{let et=eo(c,l);return toFailures(et,l,this,c)}:this.validator=()=>[],es?this.refiner=(c,l)=>{let et=es(c,l);return toFailures(et,l,this,c)}:this.refiner=()=>[]}assert(c,l){return assert(c,this,l)}create(c,l){return create(c,this,l)}is(c){return is(c,this)}mask(c,l){return mask(c,this,l)}validate(c,l={}){return validate(c,this,l)}};function assert(c,l,et){let eo=validate(c,l,{message:et});if(eo[0])throw eo[0]}function create(c,l,et){let eo=validate(c,l,{coerce:!0,message:et});if(!eo[0])return eo[1];throw eo[0]}function mask(c,l,et){let eo=validate(c,l,{coerce:!0,mask:!0,message:et});if(!eo[0])return eo[1];throw eo[0]}function is(c,l){let et=validate(c,l);return!et[0]}function validate(c,l,et={}){let eo=run(c,l,et),es=function(c){let{done:l,value:et}=c.next();return l?void 0:et}(eo);if(es[0]){let c=new StructError(es[0],function*(){for(let c of eo)c[0]&&(yield c[0])});return[c,void 0]}{let c=es[1];return[void 0,c]}}function assign(...c){let l="type"===c[0].type,et=c.map(c=>c.schema),eo=Object.assign({},...et);return l?type(eo):object(eo)}function define(c,l){return new Struct({type:c,schema:null,validator:l})}function deprecated(c,l){return new Struct({...c,refiner:(l,et)=>void 0===l||c.refiner(l,et),validator:(et,eo)=>void 0===et||(l(et,eo),c.validator(et,eo))})}function dynamic(c){return new Struct({type:"dynamic",schema:null,*entries(l,et){let eo=c(l,et);yield*eo.entries(l,et)},validator(l,et){let eo=c(l,et);return eo.validator(l,et)},coercer(l,et){let eo=c(l,et);return eo.coercer(l,et)},refiner(l,et){let eo=c(l,et);return eo.refiner(l,et)}})}function lazy(c){let l;return new Struct({type:"lazy",schema:null,*entries(et,eo){l??(l=c()),yield*l.entries(et,eo)},validator:(et,eo)=>(l??(l=c()),l.validator(et,eo)),coercer:(et,eo)=>(l??(l=c()),l.coercer(et,eo)),refiner:(et,eo)=>(l??(l=c()),l.refiner(et,eo))})}function omit(c,l){let{schema:et}=c,eo={...et};for(let c of l)delete eo[c];return"type"===c.type?type(eo):object(eo)}function partial(c){let l=c instanceof Struct?{...c.schema}:{...c};for(let c in l)l[c]=optional(l[c]);return object(l)}function pick(c,l){let{schema:et}=c,eo={};for(let c of l)eo[c]=et[c];return object(eo)}function struct(c,l){return console.warn("superstruct@0.11 - The `struct` helper has been renamed to `define`."),define(c,l)}function any(){return define("any",()=>!0)}function array(c){return new Struct({type:"array",schema:c,*entries(l){if(c&&Array.isArray(l))for(let[et,eo]of l.entries())yield[et,eo,c]},coercer:c=>Array.isArray(c)?c.slice():c,validator:c=>Array.isArray(c)||`Expected an array value, but received: ${print(c)}`})}function bigint(){return define("bigint",c=>"bigint"==typeof c)}function boolean(){return define("boolean",c=>"boolean"==typeof c)}function date(){return define("date",c=>c instanceof Date&&!isNaN(c.getTime())||`Expected a valid \`Date\` object, but received: ${print(c)}`)}function enums(c){let l={},et=c.map(c=>print(c)).join();for(let et of c)l[et]=et;return new Struct({type:"enums",schema:l,validator:l=>c.includes(l)||`Expected one of \`${et}\`, but received: ${print(l)}`})}function func(){return define("func",c=>"function"==typeof c||`Expected a function, but received: ${print(c)}`)}function instance(c){return define("instance",l=>l instanceof c||`Expected a \`${c.name}\` instance, but received: ${print(l)}`)}function integer(){return define("integer",c=>"number"==typeof c&&!isNaN(c)&&Number.isInteger(c)||`Expected an integer, but received: ${print(c)}`)}function intersection(c){return new Struct({type:"intersection",schema:null,*entries(l,et){for(let eo of c)yield*eo.entries(l,et)},*validator(l,et){for(let eo of c)yield*eo.validator(l,et)},*refiner(l,et){for(let eo of c)yield*eo.refiner(l,et)}})}function literal(c){let l=print(c),et=typeof c;return new Struct({type:"literal",schema:"string"===et||"number"===et||"boolean"===et?c:null,validator:et=>et===c||`Expected the literal \`${l}\`, but received: ${print(et)}`})}function map(c,l){return new Struct({type:"map",schema:null,*entries(et){if(c&&l&&et instanceof Map)for(let[eo,es]of et.entries())yield[eo,eo,c],yield[eo,es,l]},coercer:c=>c instanceof Map?new Map(c):c,validator:c=>c instanceof Map||`Expected a \`Map\` object, but received: ${print(c)}`})}function never(){return define("never",()=>!1)}function nullable(c){return new Struct({...c,validator:(l,et)=>null===l||c.validator(l,et),refiner:(l,et)=>null===l||c.refiner(l,et)})}function number(){return define("number",c=>"number"==typeof c&&!isNaN(c)||`Expected a number, but received: ${print(c)}`)}function object(c){let l=c?Object.keys(c):[],et=never();return new Struct({type:"object",schema:c||null,*entries(eo){if(c&&isObject(eo)){let es=new Set(Object.keys(eo));for(let et of l)es.delete(et),yield[et,eo[et],c[et]];for(let c of es)yield[c,eo[c],et]}},validator:c=>isObject(c)||`Expected an object, but received: ${print(c)}`,coercer:c=>isObject(c)?{...c}:c})}function optional(c){return new Struct({...c,validator:(l,et)=>void 0===l||c.validator(l,et),refiner:(l,et)=>void 0===l||c.refiner(l,et)})}function record(c,l){return new Struct({type:"record",schema:null,*entries(et){if(isObject(et))for(let eo in et){let es=et[eo];yield[eo,eo,c],yield[eo,es,l]}},validator:c=>isObject(c)||`Expected an object, but received: ${print(c)}`})}function regexp(){return define("regexp",c=>c instanceof RegExp)}function set(c){return new Struct({type:"set",schema:null,*entries(l){if(c&&l instanceof Set)for(let et of l)yield[et,et,c]},coercer:c=>c instanceof Set?new Set(c):c,validator:c=>c instanceof Set||`Expected a \`Set\` object, but received: ${print(c)}`})}function string(){return define("string",c=>"string"==typeof c||`Expected a string, but received: ${print(c)}`)}function tuple(c){let l=never();return new Struct({type:"tuple",schema:null,*entries(et){if(Array.isArray(et)){let eo=Math.max(c.length,et.length);for(let es=0;esArray.isArray(c)||`Expected an array, but received: ${print(c)}`})}function type(c){let l=Object.keys(c);return new Struct({type:"type",schema:c,*entries(et){if(isObject(et))for(let eo of l)yield[eo,et[eo],c[eo]]},validator:c=>isObject(c)||`Expected an object, but received: ${print(c)}`,coercer:c=>isObject(c)?{...c}:c})}function union(c){let l=c.map(c=>c.type).join(" | ");return new Struct({type:"union",schema:null,coercer(l){for(let et of c){let[c,eo]=et.validate(l,{coerce:!0});if(!c)return eo}return l},validator(et,eo){let es=[];for(let l of c){let[...c]=run(et,l,eo),[ec]=c;if(!ec[0])return[];for(let[l]of c)l&&es.push(l)}return[`Expected the value to satisfy a union of \`${l}\`, but received: ${print(et)}`,...es]}})}function unknown(){return define("unknown",()=>!0)}function coerce(c,l,et){return new Struct({...c,coercer:(eo,es)=>is(eo,l)?c.coercer(et(eo,es),es):c.coercer(eo,es)})}function defaulted(c,l,et={}){return coerce(c,unknown(),c=>{let eo="function"==typeof l?l():l;if(void 0===c)return eo;if(!et.strict&&isPlainObject(c)&&isPlainObject(eo)){let l={...c},et=!1;for(let c in eo)void 0===l[c]&&(l[c]=eo[c],et=!0);if(et)return l}return c})}function trimmed(c){return coerce(c,string(),c=>c.trim())}function empty(c){return refine(c,"empty",l=>{let et=getSize(l);return 0===et||`Expected an empty ${c.type} but received one with a size of \`${et}\``})}function getSize(c){return c instanceof Map||c instanceof Set?c.size:c.length}function max(c,l,et={}){let{exclusive:eo}=et;return refine(c,"max",et=>eo?eteo?et>l:et>=l||`Expected a ${c.type} greater than ${eo?"":"or equal to "}${l} but received \`${et}\``)}function nonempty(c){return refine(c,"nonempty",l=>{let et=getSize(l);return et>0||`Expected a nonempty ${c.type} but received an empty one`})}function pattern(c,l){return refine(c,"pattern",et=>l.test(et)||`Expected a ${c.type} matching \`/${l.source}/\` but received "${et}"`)}function size(c,l,et=l){let eo=`Expected a ${c.type}`,es=l===et?`of \`${l}\``:`between \`${l}\` and \`${et}\``;return refine(c,"size",c=>{if("number"==typeof c||c instanceof Date)return l<=c&&c<=et||`${eo} ${es} but received \`${c}\``;if(c instanceof Map||c instanceof Set){let{size:ec}=c;return l<=ec&&ec<=et||`${eo} with a size ${es} but received one with a size of \`${ec}\``}{let{length:ec}=c;return l<=ec&&ec<=et||`${eo} with a length ${es} but received one with a length of \`${ec}\``}})}function refine(c,l,et){return new Struct({...c,*refiner(eo,es){yield*c.refiner(eo,es);let ec=et(eo,es),el=toFailures(ec,es,c,eo);for(let c of el)yield{...c,refinement:l}}})}},10375:function(c,l,et){"use strict";function _typeof(c){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(c){return typeof c}:function(c){return c&&"function"==typeof Symbol&&c.constructor===Symbol&&c!==Symbol.prototype?"symbol":typeof c})(c)}et.d(l,{Z:function(){return tinycolor}});var eo,es,ec,el=/^\s+/,ed=/\s+$/;function tinycolor(c,l){if(l=l||{},(c=c||"")instanceof tinycolor)return c;if(!(this instanceof tinycolor))return new tinycolor(c,l);var et,eo,es,ec,ef,eg,em,eb,ey,e_,ew,eE,eS,ex,ek,eC,eA,eI,eP,eR,eO=(eo={r:0,g:0,b:0},es=1,ec=null,ef=null,eg=null,em=!1,eb=!1,"string"==typeof(et=c)&&(et=function(c){c=c.replace(el,"").replace(ed,"").toLowerCase();var l,et=!1;if(eh[c])c=eh[c],et=!0;else if("transparent"==c)return{r:0,g:0,b:0,a:0,format:"name"};return(l=ep.rgb.exec(c))?{r:l[1],g:l[2],b:l[3]}:(l=ep.rgba.exec(c))?{r:l[1],g:l[2],b:l[3],a:l[4]}:(l=ep.hsl.exec(c))?{h:l[1],s:l[2],l:l[3]}:(l=ep.hsla.exec(c))?{h:l[1],s:l[2],l:l[3],a:l[4]}:(l=ep.hsv.exec(c))?{h:l[1],s:l[2],v:l[3]}:(l=ep.hsva.exec(c))?{h:l[1],s:l[2],v:l[3],a:l[4]}:(l=ep.hex8.exec(c))?{r:parseIntFromHex(l[1]),g:parseIntFromHex(l[2]),b:parseIntFromHex(l[3]),a:parseIntFromHex(l[4])/255,format:et?"name":"hex8"}:(l=ep.hex6.exec(c))?{r:parseIntFromHex(l[1]),g:parseIntFromHex(l[2]),b:parseIntFromHex(l[3]),format:et?"name":"hex"}:(l=ep.hex4.exec(c))?{r:parseIntFromHex(l[1]+""+l[1]),g:parseIntFromHex(l[2]+""+l[2]),b:parseIntFromHex(l[3]+""+l[3]),a:parseIntFromHex(l[4]+""+l[4])/255,format:et?"name":"hex8"}:!!(l=ep.hex3.exec(c))&&{r:parseIntFromHex(l[1]+""+l[1]),g:parseIntFromHex(l[2]+""+l[2]),b:parseIntFromHex(l[3]+""+l[3]),format:et?"name":"hex"}}(et)),"object"==_typeof(et)&&(isValidCSSUnit(et.r)&&isValidCSSUnit(et.g)&&isValidCSSUnit(et.b)?(ey=et.r,e_=et.g,ew=et.b,eo={r:255*bound01(ey,255),g:255*bound01(e_,255),b:255*bound01(ew,255)},em=!0,eb="%"===String(et.r).substr(-1)?"prgb":"rgb"):isValidCSSUnit(et.h)&&isValidCSSUnit(et.s)&&isValidCSSUnit(et.v)?(ec=convertToPercentage(et.s),ef=convertToPercentage(et.v),eE=et.h,eS=ec,ex=ef,eE=6*bound01(eE,360),eS=bound01(eS,100),ex=bound01(ex,100),ek=Math.floor(eE),eC=eE-ek,eA=ex*(1-eS),eI=ex*(1-eC*eS),eP=ex*(1-(1-eC)*eS),eo={r:255*[ex,eI,eA,eA,eP,ex][eR=ek%6],g:255*[eP,ex,ex,eI,eA,eA][eR],b:255*[eA,eA,eP,ex,ex,eI][eR]},em=!0,eb="hsv"):isValidCSSUnit(et.h)&&isValidCSSUnit(et.s)&&isValidCSSUnit(et.l)&&(ec=convertToPercentage(et.s),eg=convertToPercentage(et.l),eo=function(c,l,et){var eo,es,ec;function hue2rgb(c,l,et){return(et<0&&(et+=1),et>1&&(et-=1),et<1/6)?c+(l-c)*6*et:et<.5?l:et<2/3?c+(l-c)*(2/3-et)*6:c}if(c=bound01(c,360),l=bound01(l,100),et=bound01(et,100),0===l)eo=es=ec=et;else{var el=et<.5?et*(1+l):et+l-et*l,ed=2*et-el;eo=hue2rgb(ed,el,c+1/3),es=hue2rgb(ed,el,c),ec=hue2rgb(ed,el,c-1/3)}return{r:255*eo,g:255*es,b:255*ec}}(et.h,ec,eg),em=!0,eb="hsl"),et.hasOwnProperty("a")&&(es=et.a)),es=boundAlpha(es),{ok:em,format:et.format||eb,r:Math.min(255,Math.max(eo.r,0)),g:Math.min(255,Math.max(eo.g,0)),b:Math.min(255,Math.max(eo.b,0)),a:es});this._originalInput=c,this._r=eO.r,this._g=eO.g,this._b=eO.b,this._a=eO.a,this._roundA=Math.round(100*this._a)/100,this._format=l.format||eO.format,this._gradientType=l.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=eO.ok}function rgbToHsl(c,l,et){var eo,es,ec=Math.max(c=bound01(c,255),l=bound01(l,255),et=bound01(et,255)),el=Math.min(c,l,et),ed=(ec+el)/2;if(ec==el)eo=es=0;else{var eh=ec-el;switch(es=ed>.5?eh/(2-ec-el):eh/(ec+el),ec){case c:eo=(l-et)/eh+(l>1)+720)%360;--l;)eo.h=(eo.h+es)%360,ec.push(tinycolor(eo));return ec}function _monochromatic(c,l){l=l||6;for(var et=tinycolor(c).toHsv(),eo=et.h,es=et.s,ec=et.v,el=[],ed=1/l;l--;)el.push(tinycolor({h:eo,s:es,v:ec})),ec=(ec+ed)%1;return el}tinycolor.prototype={isDark:function(){return 128>this.getBrightness()},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var c=this.toRgb();return(299*c.r+587*c.g+114*c.b)/1e3},getLuminance:function(){var c,l,et,eo=this.toRgb();return c=eo.r/255,.2126*(c<=.03928?c/12.92:Math.pow((c+.055)/1.055,2.4))+.7152*((l=eo.g/255)<=.03928?l/12.92:Math.pow((l+.055)/1.055,2.4))+.0722*((et=eo.b/255)<=.03928?et/12.92:Math.pow((et+.055)/1.055,2.4))},setAlpha:function(c){return this._a=boundAlpha(c),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var c=rgbToHsv(this._r,this._g,this._b);return{h:360*c.h,s:c.s,v:c.v,a:this._a}},toHsvString:function(){var c=rgbToHsv(this._r,this._g,this._b),l=Math.round(360*c.h),et=Math.round(100*c.s),eo=Math.round(100*c.v);return 1==this._a?"hsv("+l+", "+et+"%, "+eo+"%)":"hsva("+l+", "+et+"%, "+eo+"%, "+this._roundA+")"},toHsl:function(){var c=rgbToHsl(this._r,this._g,this._b);return{h:360*c.h,s:c.s,l:c.l,a:this._a}},toHslString:function(){var c=rgbToHsl(this._r,this._g,this._b),l=Math.round(360*c.h),et=Math.round(100*c.s),eo=Math.round(100*c.l);return 1==this._a?"hsl("+l+", "+et+"%, "+eo+"%)":"hsla("+l+", "+et+"%, "+eo+"%, "+this._roundA+")"},toHex:function(c){return rgbToHex(this._r,this._g,this._b,c)},toHexString:function(c){return"#"+this.toHex(c)},toHex8:function(c){var l,et,eo,es,ec;return l=this._r,et=this._g,eo=this._b,es=this._a,ec=[pad2(Math.round(l).toString(16)),pad2(Math.round(et).toString(16)),pad2(Math.round(eo).toString(16)),pad2(convertDecimalToHex(es))],c&&ec[0].charAt(0)==ec[0].charAt(1)&&ec[1].charAt(0)==ec[1].charAt(1)&&ec[2].charAt(0)==ec[2].charAt(1)&&ec[3].charAt(0)==ec[3].charAt(1)?ec[0].charAt(0)+ec[1].charAt(0)+ec[2].charAt(0)+ec[3].charAt(0):ec.join("")},toHex8String:function(c){return"#"+this.toHex8(c)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(100*bound01(this._r,255))+"%",g:Math.round(100*bound01(this._g,255))+"%",b:Math.round(100*bound01(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+Math.round(100*bound01(this._r,255))+"%, "+Math.round(100*bound01(this._g,255))+"%, "+Math.round(100*bound01(this._b,255))+"%)":"rgba("+Math.round(100*bound01(this._r,255))+"%, "+Math.round(100*bound01(this._g,255))+"%, "+Math.round(100*bound01(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(ef[rgbToHex(this._r,this._g,this._b,!0)]||!1)},toFilter:function(c){var l="#"+rgbaToArgbHex(this._r,this._g,this._b,this._a),et=l,eo=this._gradientType?"GradientType = 1, ":"";if(c){var es=tinycolor(c);et="#"+rgbaToArgbHex(es._r,es._g,es._b,es._a)}return"progid:DXImageTransform.Microsoft.gradient("+eo+"startColorstr="+l+",endColorstr="+et+")"},toString:function(c){var l=!!c;c=c||this._format;var et=!1,eo=this._a<1&&this._a>=0;return!l&&eo&&("hex"===c||"hex6"===c||"hex3"===c||"hex4"===c||"hex8"===c||"name"===c)?"name"===c&&0===this._a?this.toName():this.toRgbString():("rgb"===c&&(et=this.toRgbString()),"prgb"===c&&(et=this.toPercentageRgbString()),("hex"===c||"hex6"===c)&&(et=this.toHexString()),"hex3"===c&&(et=this.toHexString(!0)),"hex4"===c&&(et=this.toHex8String(!0)),"hex8"===c&&(et=this.toHex8String()),"name"===c&&(et=this.toName()),"hsl"===c&&(et=this.toHslString()),"hsv"===c&&(et=this.toHsvString()),et||this.toHexString())},clone:function(){return tinycolor(this.toString())},_applyModification:function(c,l){var et=c.apply(null,[this].concat([].slice.call(l)));return this._r=et._r,this._g=et._g,this._b=et._b,this.setAlpha(et._a),this},lighten:function(){return this._applyModification(_lighten,arguments)},brighten:function(){return this._applyModification(_brighten,arguments)},darken:function(){return this._applyModification(_darken,arguments)},desaturate:function(){return this._applyModification(_desaturate,arguments)},saturate:function(){return this._applyModification(_saturate,arguments)},greyscale:function(){return this._applyModification(_greyscale,arguments)},spin:function(){return this._applyModification(_spin,arguments)},_applyCombination:function(c,l){return c.apply(null,[this].concat([].slice.call(l)))},analogous:function(){return this._applyCombination(_analogous,arguments)},complement:function(){return this._applyCombination(_complement,arguments)},monochromatic:function(){return this._applyCombination(_monochromatic,arguments)},splitcomplement:function(){return this._applyCombination(_splitcomplement,arguments)},triad:function(){return this._applyCombination(polyad,[3])},tetrad:function(){return this._applyCombination(polyad,[4])}},tinycolor.fromRatio=function(c,l){if("object"==_typeof(c)){var et={};for(var eo in c)c.hasOwnProperty(eo)&&("a"===eo?et[eo]=c[eo]:et[eo]=convertToPercentage(c[eo]));c=et}return tinycolor(c,l)},tinycolor.equals=function(c,l){return!!c&&!!l&&tinycolor(c).toRgbString()==tinycolor(l).toRgbString()},tinycolor.random=function(){return tinycolor.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})},tinycolor.mix=function(c,l,et){et=0===et?0:et||50;var eo=tinycolor(c).toRgb(),es=tinycolor(l).toRgb(),ec=et/100;return tinycolor({r:(es.r-eo.r)*ec+eo.r,g:(es.g-eo.g)*ec+eo.g,b:(es.b-eo.b)*ec+eo.b,a:(es.a-eo.a)*ec+eo.a})},tinycolor.readability=function(c,l){var et=tinycolor(c),eo=tinycolor(l);return(Math.max(et.getLuminance(),eo.getLuminance())+.05)/(Math.min(et.getLuminance(),eo.getLuminance())+.05)},tinycolor.isReadable=function(c,l,et){var eo,es,ec,el,ed,eh=tinycolor.readability(c,l);switch(ed=!1,(es=((eo=(eo=et)||{level:"AA",size:"small"}).level||"AA").toUpperCase(),ec=(eo.size||"small").toLowerCase(),"AA"!==es&&"AAA"!==es&&(es="AA"),"small"!==ec&&"large"!==ec&&(ec="small"),el={level:es,size:ec}).level+el.size){case"AAsmall":case"AAAlarge":ed=eh>=4.5;break;case"AAlarge":ed=eh>=3;break;case"AAAsmall":ed=eh>=7}return ed},tinycolor.mostReadable=function(c,l,et){var eo,es,ec,el,ed=null,eh=0;es=(et=et||{}).includeFallbackColors,ec=et.level,el=et.size;for(var ef=0;efeh&&(eh=eo,ed=tinycolor(l[ef]));return tinycolor.isReadable(c,ed,{level:ec,size:el})||!es?ed:(et.includeFallbackColors=!1,tinycolor.mostReadable(c,["#fff","#000"],et))};var eh=tinycolor.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},ef=tinycolor.hexNames=function(c){var l={};for(var et in c)c.hasOwnProperty(et)&&(l[c[et]]=et);return l}(eh);function boundAlpha(c){return(isNaN(c=parseFloat(c))||c<0||c>1)&&(c=1),c}function bound01(c,l){"string"==typeof(et=c)&&-1!=et.indexOf(".")&&1===parseFloat(et)&&(c="100%");var et,eo,es="string"==typeof(eo=c)&&-1!=eo.indexOf("%");return(c=Math.min(l,Math.max(0,parseFloat(c))),es&&(c=parseInt(c*l,10)/100),1e-6>Math.abs(c-l))?1:c%l/parseFloat(l)}function clamp01(c){return Math.min(1,Math.max(0,c))}function parseIntFromHex(c){return parseInt(c,16)}function pad2(c){return 1==c.length?"0"+c:""+c}function convertToPercentage(c){return c<=1&&(c=100*c+"%"),c}function convertDecimalToHex(c){return Math.round(255*parseFloat(c)).toString(16)}var ep=(es="[\\s|\\(]+("+(eo="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+eo+")[,|\\s]+("+eo+")\\s*\\)?",ec="[\\s|\\(]+("+eo+")[,|\\s]+("+eo+")[,|\\s]+("+eo+")[,|\\s]+("+eo+")\\s*\\)?",{CSS_UNIT:new RegExp(eo),rgb:RegExp("rgb"+es),rgba:RegExp("rgba"+ec),hsl:RegExp("hsl"+es),hsla:RegExp("hsla"+ec),hsv:RegExp("hsv"+es),hsva:RegExp("hsva"+ec),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/});function isValidCSSUnit(c){return!!ep.CSS_UNIT.exec(c)}},50044:function(c,l,et){"use strict";et.r(l),et.d(l,{__addDisposableResource:function(){return __addDisposableResource},__assign:function(){return __assign},__asyncDelegator:function(){return __asyncDelegator},__asyncGenerator:function(){return __asyncGenerator},__asyncValues:function(){return __asyncValues},__await:function(){return __await},__awaiter:function(){return __awaiter},__classPrivateFieldGet:function(){return __classPrivateFieldGet},__classPrivateFieldIn:function(){return __classPrivateFieldIn},__classPrivateFieldSet:function(){return __classPrivateFieldSet},__createBinding:function(){return eo},__decorate:function(){return __decorate},__disposeResources:function(){return __disposeResources},__esDecorate:function(){return __esDecorate},__exportStar:function(){return __exportStar},__extends:function(){return __extends},__generator:function(){return __generator},__importDefault:function(){return __importDefault},__importStar:function(){return __importStar},__makeTemplateObject:function(){return __makeTemplateObject},__metadata:function(){return __metadata},__param:function(){return __param},__propKey:function(){return __propKey},__read:function(){return __read},__rest:function(){return __rest},__runInitializers:function(){return __runInitializers},__setFunctionName:function(){return __setFunctionName},__spread:function(){return __spread},__spreadArray:function(){return __spreadArray},__spreadArrays:function(){return __spreadArrays},__values:function(){return __values}});var extendStatics=function(c,l){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(c,l){c.__proto__=l}||function(c,l){for(var et in l)Object.prototype.hasOwnProperty.call(l,et)&&(c[et]=l[et])})(c,l)};function __extends(c,l){if("function"!=typeof l&&null!==l)throw TypeError("Class extends value "+String(l)+" is not a constructor or null");function __(){this.constructor=c}extendStatics(c,l),c.prototype=null===l?Object.create(l):(__.prototype=l.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(c){for(var l,et=1,eo=arguments.length;etl.indexOf(eo)&&(et[eo]=c[eo]);if(null!=c&&"function"==typeof Object.getOwnPropertySymbols)for(var es=0,eo=Object.getOwnPropertySymbols(c);esl.indexOf(eo[es])&&Object.prototype.propertyIsEnumerable.call(c,eo[es])&&(et[eo[es]]=c[eo[es]]);return et}function __decorate(c,l,et,eo){var es,ec=arguments.length,el=ec<3?l:null===eo?eo=Object.getOwnPropertyDescriptor(l,et):eo;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)el=Reflect.decorate(c,l,et,eo);else for(var ed=c.length-1;ed>=0;ed--)(es=c[ed])&&(el=(ec<3?es(el):ec>3?es(l,et,el):es(l,et))||el);return ec>3&&el&&Object.defineProperty(l,et,el),el}function __param(c,l){return function(et,eo){l(et,eo,c)}}function __esDecorate(c,l,et,eo,es,ec){function accept(c){if(void 0!==c&&"function"!=typeof c)throw TypeError("Function expected");return c}for(var el,ed=eo.kind,eh="getter"===ed?"get":"setter"===ed?"set":"value",ef=!l&&c?eo.static?c:c.prototype:null,ep=l||(ef?Object.getOwnPropertyDescriptor(ef,eo.name):{}),eg=!1,em=et.length-1;em>=0;em--){var eb={};for(var ey in eo)eb[ey]="access"===ey?{}:eo[ey];for(var ey in eo.access)eb.access[ey]=eo.access[ey];eb.addInitializer=function(c){if(eg)throw TypeError("Cannot add initializers after decoration has completed");ec.push(accept(c||null))};var e_=(0,et[em])("accessor"===ed?{get:ep.get,set:ep.set}:ep[eh],eb);if("accessor"===ed){if(void 0===e_)continue;if(null===e_||"object"!=typeof e_)throw TypeError("Object expected");(el=accept(e_.get))&&(ep.get=el),(el=accept(e_.set))&&(ep.set=el),(el=accept(e_.init))&&es.unshift(el)}else(el=accept(e_))&&("field"===ed?es.unshift(el):ep[eh]=el)}ef&&Object.defineProperty(ef,eo.name,ep),eg=!0}function __runInitializers(c,l,et){for(var eo=arguments.length>2,es=0;es0&&es[es.length-1])&&(6===ed[0]||2===ed[0])){el=0;continue}if(3===ed[0]&&(!es||ed[1]>es[0]&&ed[1]=c.length&&(c=void 0),{value:c&&c[eo++],done:!c}}};throw TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}function __read(c,l){var et="function"==typeof Symbol&&c[Symbol.iterator];if(!et)return c;var eo,es,ec=et.call(c),el=[];try{for(;(void 0===l||l-- >0)&&!(eo=ec.next()).done;)el.push(eo.value)}catch(c){es={error:c}}finally{try{eo&&!eo.done&&(et=ec.return)&&et.call(ec)}finally{if(es)throw es.error}}return el}function __spread(){for(var c=[],l=0;l1||resume(c,l)})})}function resume(c,l){try{var et;(et=es[c](l)).value instanceof __await?Promise.resolve(et.value.v).then(fulfill,reject):settle(ec[0][2],et)}catch(c){settle(ec[0][3],c)}}function fulfill(c){resume("next",c)}function reject(c){resume("throw",c)}function settle(c,l){c(l),ec.shift(),ec.length&&resume(ec[0][0],ec[0][1])}}function __asyncDelegator(c){var l,et;return l={},verb("next"),verb("throw",function(c){throw c}),verb("return"),l[Symbol.iterator]=function(){return this},l;function verb(eo,es){l[eo]=c[eo]?function(l){return(et=!et)?{value:__await(c[eo](l)),done:!1}:es?es(l):l}:es}}function __asyncValues(c){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var l,et=c[Symbol.asyncIterator];return et?et.call(c):(c=__values(c),l={},verb("next"),verb("throw"),verb("return"),l[Symbol.asyncIterator]=function(){return this},l);function verb(et){l[et]=c[et]&&function(l){return new Promise(function(eo,es){!function(c,l,et,eo){Promise.resolve(eo).then(function(l){c({value:l,done:et})},l)}(eo,es,(l=c[et](l)).done,l.value)})}}}function __makeTemplateObject(c,l){return Object.defineProperty?Object.defineProperty(c,"raw",{value:l}):c.raw=l,c}var es=Object.create?function(c,l){Object.defineProperty(c,"default",{enumerable:!0,value:l})}:function(c,l){c.default=l};function __importStar(c){if(c&&c.__esModule)return c;var l={};if(null!=c)for(var et in c)"default"!==et&&Object.prototype.hasOwnProperty.call(c,et)&&eo(l,c,et);return es(l,c),l}function __importDefault(c){return c&&c.__esModule?c:{default:c}}function __classPrivateFieldGet(c,l,et,eo){if("a"===et&&!eo)throw TypeError("Private accessor was defined without a getter");if("function"==typeof l?c!==l||!eo:!l.has(c))throw TypeError("Cannot read private member from an object whose class did not declare it");return"m"===et?eo:"a"===et?eo.call(c):eo?eo.value:l.get(c)}function __classPrivateFieldSet(c,l,et,eo,es){if("m"===eo)throw TypeError("Private method is not writable");if("a"===eo&&!es)throw TypeError("Private accessor was defined without a setter");if("function"==typeof l?c!==l||!es:!l.has(c))throw TypeError("Cannot write private member to an object whose class did not declare it");return"a"===eo?es.call(c,et):es?es.value=et:l.set(c,et),et}function __classPrivateFieldIn(c,l){if(null===l||"object"!=typeof l&&"function"!=typeof l)throw TypeError("Cannot use 'in' operator on non-object");return"function"==typeof c?l===c:c.has(l)}function __addDisposableResource(c,l,et){if(null!=l){var eo;if("object"!=typeof l&&"function"!=typeof l)throw TypeError("Object expected.");if(et){if(!Symbol.asyncDispose)throw TypeError("Symbol.asyncDispose is not defined.");eo=l[Symbol.asyncDispose]}if(void 0===eo){if(!Symbol.dispose)throw TypeError("Symbol.dispose is not defined.");eo=l[Symbol.dispose]}if("function"!=typeof eo)throw TypeError("Object not disposable.");c.stack.push({value:l,dispose:eo,async:et})}else et&&c.stack.push({async:!0});return l}var ec="function"==typeof SuppressedError?SuppressedError:function(c,l,et){var eo=Error(et);return eo.name="SuppressedError",eo.error=c,eo.suppressed=l,eo};function __disposeResources(c){function fail(l){c.error=c.hasError?new ec(l,c.error,"An error was suppressed during disposal."):l,c.hasError=!0}return function next(){for(;c.stack.length;){var l=c.stack.pop();try{var et=l.dispose&&l.dispose.call(l.value);if(l.async)return Promise.resolve(et).then(next,function(c){return fail(c),next()})}catch(c){fail(c)}}if(c.hasError)throw c.error}()}l.default={__extends,__assign,__rest,__decorate,__param,__metadata,__awaiter,__generator,__createBinding:eo,__exportStar,__values,__read,__spread,__spreadArrays,__spreadArray,__await,__asyncGenerator,__asyncDelegator,__asyncValues,__makeTemplateObject,__importStar,__importDefault,__classPrivateFieldGet,__classPrivateFieldSet,__classPrivateFieldIn,__addDisposableResource,__disposeResources}},4832:function(c,l,et){"use strict";function parseAccount(c){return"string"==typeof c?{address:c,type:"json-rpc"}:c}et.d(l,{T:function(){return parseAccount}})},98873:function(c,l,et){"use strict";et.d(l,{R:function(){return call}});var eo=et(4832),es=et(42980),ec=et(95950),el=et(27878),ed=et(98458),eh=et(3458),ef=et(53883),ep=et(42168),eg=et(21693),em=et(40009),eb=et(36074),ey=et(21028),e_=et(86868),ew=et(33668),eE=et(2445);async function call(c,l){let{account:es=c.account,batch:eh=!!c.batch?.multicall,blockNumber:ef,blockTag:ep="latest",accessList:ew,data:eS,gas:ex,gasPrice:ek,maxFeePerGas:eC,maxPriorityFeePerGas:eA,nonce:eI,to:eP,value:eR,...eO}=l,eT=es?(0,eo.T)(es):void 0;try{(0,eE.F)(l);let et=ef?(0,eg.eC)(ef):void 0,eo=et||ep,es=c.chain?.formatters?.transactionRequest?.format||e_.tG,ec=es({...(0,ey.K)(eO,{format:es}),from:eT?.address,accessList:ew,data:eS,gas:ex,gasPrice:ek,maxFeePerGas:eC,maxPriorityFeePerGas:eA,nonce:eI,to:eP,value:eR});if(eh&&function({request:c}){let{data:l,to:et,...eo}=c;return!(!l||l.startsWith("0x82ad56cb"))&&!!et&&!(Object.values(eo).filter(c=>void 0!==c).length>0)}({request:ec}))try{return await scheduleMulticall(c,{...ec,blockNumber:ef,blockTag:ep})}catch(c){if(!(c instanceof el.pZ)&&!(c instanceof el.mm))throw c}let ed=await c.request({method:"eth_call",params:eo?[ec,eo]:[ec]});if("0x"===ed)return{data:void 0};return{data:ed}}catch(eh){let eo=function(c){if(!(c instanceof ec.G))return;let l=c.walk();return"object"==typeof l.data?l.data.data:l.data}(eh),{offchainLookup:es,offchainLookupSignature:el}=await et.e(572).then(et.bind(et,5572));if(eo?.slice(0,10)===el&&eP)return{data:await es(c,{data:eo,to:eP})};throw function(c,{docsPath:l,...et}){let eo=(()=>{let l=(0,eb.k)(c,et);return l instanceof em.cj?c:l})();return new ed.cg(eo,{docsPath:l,...et})}(eh,{...l,account:eT,chain:c.chain})}}async function scheduleMulticall(c,l){let{batchSize:et=1024,wait:eo=0}="object"==typeof c.batch?.multicall?c.batch.multicall:{},{blockNumber:ec,blockTag:em="latest",data:eb,multicallAddress:ey,to:e_}=l,eE=ey;if(!eE){if(!c.chain)throw new el.pZ;eE=(0,ep.LI)({blockNumber:ec,chain:c.chain,contract:"multicall3"})}let eS=ec?(0,eg.eC)(ec):void 0,ex=eS||em,{schedule:ek}=(0,ew.S)({id:`${c.uid}.${ex}`,wait:eo,shouldSplitBatch(c){let l=c.reduce((c,{data:l})=>c+(l.length-2),0);return l>2*et},fn:async l=>{let et=l.map(c=>({allowFailure:!0,callData:c.data,target:c.to})),eo=(0,ef.R)({abi:es.F8,args:[et],functionName:"aggregate3"}),ec=await c.request({method:"eth_call",params:[{data:eo,to:eE},ex]});return(0,eh.k)({abi:es.F8,args:[et],functionName:"aggregate3",data:ec||"0x"})}}),[{returnData:eC,success:eA}]=await ek({data:eb,to:e_});if(!eA)throw new ed.VQ({data:eC});return"0x"===eC?{data:void 0}:{data:eC}}},77451:function(c,l,et){"use strict";et.d(l,{C:function(){return internal_estimateFeesPerGas},X:function(){return estimateFeesPerGas}});var eo=et(84161),es=et(17976),ec=et(85731),el=et(75188);async function estimateFeesPerGas(c,l){return internal_estimateFeesPerGas(c,l)}async function internal_estimateFeesPerGas(c,l){let{block:et,chain:ed=c.chain,request:eh,type:ef="eip1559"}=l||{},ep=await (async()=>"function"==typeof ed?.fees?.baseFeeMultiplier?ed.fees.baseFeeMultiplier({block:et,client:c,request:eh}):ed?.fees?.baseFeeMultiplier??1.2)();if(ep<1)throw new eo.Fz;let eg=ep.toString().split(".")[1]?.length??0,em=10**eg,multiply=c=>c*BigInt(Math.ceil(ep*em))/BigInt(em),eb=et||await (0,ec.Q)(c);if("function"==typeof ed?.fees?.estimateFeesPerGas)return ed.fees.estimateFeesPerGas({block:et,client:c,multiply,request:eh,type:ef});if("eip1559"===ef){if("bigint"!=typeof eb.baseFeePerGas)throw new eo.e5;let l=eh?.maxPriorityFeePerGas?eh.maxPriorityFeePerGas:await (0,es.h)(c,{block:eb,chain:ed,request:eh}),et=multiply(eb.baseFeePerGas),ec=eh?.maxFeePerGas??et+l;return{maxFeePerGas:ec,maxPriorityFeePerGas:l}}let ey=eh?.gasPrice??multiply(await (0,el.o)(c));return{gasPrice:ey}}},89412:function(c,l,et){"use strict";et.d(l,{Q:function(){return estimateGas}});var eo=et(4832),es=et(67333),ec=et(21693),el=et(79352),ed=et(32421),eh=et(95950),ef=et(44818);let EstimateGasExecutionError=class EstimateGasExecutionError extends eh.G{constructor(c,{account:l,docsPath:et,chain:eo,data:es,gas:ec,gasPrice:eh,maxFeePerGas:ep,maxPriorityFeePerGas:eg,nonce:em,to:eb,value:ey}){let e_=(0,ef.xr)({from:l?.address,to:eb,value:void 0!==ey&&`${(0,el.d)(ey)} ${eo?.nativeCurrency.symbol||"ETH"}`,data:es,gas:ec,gasPrice:void 0!==eh&&`${(0,ed.o)(eh)} gwei`,maxFeePerGas:void 0!==ep&&`${(0,ed.o)(ep)} gwei`,maxPriorityFeePerGas:void 0!==eg&&`${(0,ed.o)(eg)} gwei`,nonce:em});super(c.shortMessage,{cause:c,docsPath:et,metaMessages:[...c.metaMessages?[...c.metaMessages," "]:[],"Estimate Gas Arguments:",e_].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"EstimateGasExecutionError"}),this.cause=c}};var ep=et(40009),eg=et(36074),em=et(21028),eb=et(86868),ey=et(2445),e_=et(40044);async function estimateGas(c,l){let et=l.account??c.account;if(!et)throw new es.o({docsPath:"/docs/actions/public/estimateGas"});let el=(0,eo.T)(et);try{let{accessList:et,blockNumber:eo,blockTag:es,data:ed,gas:eh,gasPrice:ef,maxFeePerGas:ep,maxPriorityFeePerGas:eg,nonce:ew,to:eE,value:eS,...ex}="local"===el.type?await (0,e_.Z)(c,l):l,ek=eo?(0,ec.eC)(eo):void 0,eC=ek||es;(0,ey.F)(l);let eA=c.chain?.formatters?.transactionRequest?.format||eb.tG,eI=eA({...(0,em.K)(ex,{format:eA}),from:el.address,accessList:et,data:ed,gas:eh,gasPrice:ef,maxFeePerGas:ep,maxPriorityFeePerGas:eg,nonce:ew,to:eE,value:eS}),eP=await c.request({method:"eth_estimateGas",params:eC?[eI,eC]:[eI]});return BigInt(eP)}catch(et){throw function(c,{docsPath:l,...et}){let eo=(()=>{let l=(0,eg.k)(c,et);return l instanceof ep.cj?c:l})();return new EstimateGasExecutionError(eo,{docsPath:l,...et})}(et,{...l,account:el,chain:c.chain})}}},17976:function(c,l,et){"use strict";et.d(l,{_:function(){return estimateMaxPriorityFeePerGas},h:function(){return internal_estimateMaxPriorityFeePerGas}});var eo=et(84161),es=et(30838),ec=et(85731),el=et(75188);async function estimateMaxPriorityFeePerGas(c,l){return internal_estimateMaxPriorityFeePerGas(c,l)}async function internal_estimateMaxPriorityFeePerGas(c,l){let{block:et,chain:ed=c.chain,request:eh}=l||{};if("function"==typeof ed?.fees?.defaultPriorityFee){let l=et||await (0,ec.Q)(c);return ed.fees.defaultPriorityFee({block:l,client:c,request:eh})}if(void 0!==ed?.fees?.defaultPriorityFee)return ed?.fees?.defaultPriorityFee;try{let l=await c.request({method:"eth_maxPriorityFeePerGas"});return(0,es.y_)(l)}catch{let[l,es]=await Promise.all([et?Promise.resolve(et):(0,ec.Q)(c),(0,el.o)(c)]);if("bigint"!=typeof l.baseFeePerGas)throw new eo.e5;let ed=es-l.baseFeePerGas;if(ed<0n)return 0n;return ed}}},85731:function(c,l,et){"use strict";et.d(l,{Q:function(){return getBlock}});var eo=et(95950);let BlockNotFoundError=class BlockNotFoundError extends eo.G{constructor({blockHash:c,blockNumber:l}){let et="Block";c&&(et=`Block at hash "${c}"`),l&&(et=`Block at number "${l}"`),super(`${et} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BlockNotFoundError"})}};var es=et(21693),ec=et(78723);async function getBlock(c,{blockHash:l,blockNumber:et,blockTag:eo,includeTransactions:el}={}){let ed=el??!1,eh=void 0!==et?(0,es.eC)(et):void 0,ef=null;if(!(ef=l?await c.request({method:"eth_getBlockByHash",params:[l,ed]}):await c.request({method:"eth_getBlockByNumber",params:[eh||(eo??"latest"),ed]})))throw new BlockNotFoundError({blockHash:l,blockNumber:et});let ep=c.chain?.formatters?.block?.format||ec.Z;return ep(ef)}},13438:function(c,l,et){"use strict";et.d(l,{L:function(){return getChainId}});var eo=et(30838);async function getChainId(c){let l=await c.request({method:"eth_chainId"});return(0,eo.ly)(l)}},75188:function(c,l,et){"use strict";async function getGasPrice(c){let l=await c.request({method:"eth_gasPrice"});return BigInt(l)}et.d(l,{o:function(){return getGasPrice}})},31742:function(c,l,et){"use strict";et.d(l,{K:function(){return getTransactionCount}});var eo=et(30838),es=et(21693);async function getTransactionCount(c,{address:l,blockTag:et="latest",blockNumber:ec}){let el=await c.request({method:"eth_getTransactionCount",params:[l,ec?(0,es.eC)(ec):et]});return(0,eo.ly)(el)}},40044:function(c,l,et){"use strict";et.d(l,{Z:function(){return prepareTransactionRequest}});var eo=et(4832),es=et(77451),ec=et(89412),el=et(85731),ed=et(31742),eh=et(67333),ef=et(84161),ep=et(2445),eg=et(44818);async function prepareTransactionRequest(c,l){let{account:et=c.account,chain:em,gas:eb,nonce:ey,type:e_}=l;if(!et)throw new eh.o;let ew=(0,eo.T)(et),eE=await (0,el.Q)(c,{blockTag:"latest"}),eS={...l,from:ew.address};if(void 0===ey&&(eS.nonce=await (0,ed.K)(c,{address:ew.address,blockTag:"pending"})),void 0===e_)try{eS.type=function(c){if(c.type)return c.type;if(void 0!==c.maxFeePerGas||void 0!==c.maxPriorityFeePerGas)return"eip1559";if(void 0!==c.gasPrice)return void 0!==c.accessList?"eip2930":"legacy";throw new eg.j3({transaction:c})}(eS)}catch{eS.type="bigint"==typeof eE.baseFeePerGas?"eip1559":"legacy"}if("eip1559"===eS.type){let{maxFeePerGas:et,maxPriorityFeePerGas:eo}=await (0,es.C)(c,{block:eE,chain:em,request:eS});if(void 0===l.maxPriorityFeePerGas&&l.maxFeePerGas&&l.maxFeePerGas512){eo="",ec=0;for(let c=0;c<256;c++)eo+=(256+256*Math.random()|0).toString(16).substring(1)}return eo.substring(ec,ec+++c)}()};return Object.assign(ew,{extend:function extend(c){return l=>{let et=l(c);for(let c in ew)delete et[c];let eo={...c,...et};return Object.assign(eo,{extend:extend(eo)})}}(ew)})}},22570:function(c,l,et){"use strict";et.d(l,{K:function(){return createWalletClient}});var eo=et(30315),es=et(13438),ec=et(21693);async function addChain(c,{chain:l}){let{id:et,name:eo,nativeCurrency:es,rpcUrls:el,blockExplorers:ed}=l;await c.request({method:"wallet_addEthereumChain",params:[{chainId:(0,ec.eC)(et),chainName:eo,nativeCurrency:es,rpcUrls:el.default.http,blockExplorerUrls:ed?Object.values(ed).map(({url:c})=>c):void 0}]})}var el=et(12732),ed=et(4832),eh=et(67333),ef=et(42168),ep=et(40009),eg=et(44818),em=et(36074),eb=et(21028),ey=et(86868),e_=et(2445),ew=et(40044),eE=et(73971);async function sendTransaction(c,l){let{account:et=c.account,chain:eo=c.chain,accessList:ec,data:el,gas:eS,gasPrice:ex,maxFeePerGas:ek,maxPriorityFeePerGas:eC,nonce:eA,to:eI,value:eP,...eR}=l;if(!et)throw new eh.o({docsPath:"/docs/actions/wallet/sendTransaction"});let eO=(0,ed.T)(et);try{let et;if((0,e_.F)(l),null!==eo&&(et=await (0,es.L)(c),(0,ef.qg)({currentChainId:et,chain:eo})),"local"===eO.type){let l=await (0,ew.Z)(c,{account:eO,accessList:ec,chain:eo,data:el,gas:eS,gasPrice:ex,maxFeePerGas:ek,maxPriorityFeePerGas:eC,nonce:eA,to:eI,value:eP,...eR});et||(et=await (0,es.L)(c));let ed=eo?.serializers?.transaction,eh=await eO.signTransaction({...l,chainId:et},{serializer:ed});return await (0,eE.p)(c,{serializedTransaction:eh})}let ed=eo?.formatters?.transactionRequest?.format||ey.tG,eh=ed({...(0,eb.K)(eR,{format:ed}),accessList:ec,data:el,from:eO.address,gas:eS,gasPrice:ex,maxFeePerGas:ek,maxPriorityFeePerGas:eC,nonce:eA,to:eI,value:eP});return await c.request({method:"eth_sendTransaction",params:[eh]})}catch(c){throw function(c,{docsPath:l,...et}){let eo=(()=>{let l=(0,em.k)(c,et);return l instanceof ep.cj?c:l})();return new eg.mk(eo,{docsPath:l,...et})}(c,{...l,account:eO,chain:l.chain||void 0})}}var eS=et(39803);async function getAddresses(c){let l=await c.request({method:"eth_accounts"});return l.map(c=>(0,eS.x)(c))}async function getPermissions(c){let l=await c.request({method:"wallet_getPermissions"});return l}async function requestAddresses(c){let l=await c.request({method:"eth_requestAccounts"});return l.map(c=>(0,eS.K)(c))}async function requestPermissions(c,l){return c.request({method:"wallet_requestPermissions",params:[l]})}async function signMessage(c,{account:l=c.account,message:et}){if(!l)throw new eh.o({docsPath:"/docs/actions/wallet/signMessage"});let eo=(0,ed.T)(l);if("local"===eo.type)return eo.signMessage({message:et});let es="string"==typeof et?(0,ec.$G)(et):et.raw instanceof Uint8Array?(0,ec.NC)(et.raw):et.raw;return c.request({method:"personal_sign",params:[es,eo.address]})}async function signTransaction(c,l){let{account:et=c.account,chain:eo=c.chain,...el}=l;if(!et)throw new eh.o({docsPath:"/docs/actions/wallet/signTransaction"});let ep=(0,ed.T)(et);(0,e_.F)({account:ep,...l});let eg=await (0,es.L)(c);null!==eo&&(0,ef.qg)({currentChainId:eg,chain:eo});let em=eo?.formatters||c.chain?.formatters,eb=em?.transactionRequest?.format||ey.tG;return"local"===ep.type?ep.signTransaction({chainId:eg,...el},{serializer:c.chain?.serializers?.transaction}):await c.request({method:"eth_signTransaction",params:[{...eb(el),chainId:(0,ec.eC)(eg),from:ep.address}]})}var ex=et(45008),ek=et(71891),eC=et(29578);async function signTypedData(c,{account:l=c.account,domain:et,message:eo,primaryType:es,types:ec}){if(!l)throw new eh.o({docsPath:"/docs/actions/wallet/signTypedData"});let el=(0,ed.T)(l),ef={EIP712Domain:(0,eC.cj)({domain:et}),...ec};if((0,eC.iC)({domain:et,message:eo,primaryType:es,types:ef}),"local"===el.type)return el.signTypedData({domain:et,primaryType:es,types:ef,message:eo});let ep=(0,ek.P)({domain:et??{},primaryType:es,types:ef,message:eo},(c,l)=>(0,ex.v)(l)?l.toLowerCase():l);return c.request({method:"eth_signTypedData_v4",params:[el.address,ep]})}async function switchChain(c,{id:l}){await c.request({method:"wallet_switchEthereumChain",params:[{chainId:(0,ec.eC)(l)}]})}async function watchAsset(c,l){let et=await c.request({method:"wallet_watchAsset",params:l});return et}var eA=et(53883);async function writeContract(c,{abi:l,address:et,args:eo,dataSuffix:es,functionName:ec,...el}){let ed=(0,eA.R)({abi:l,args:eo,functionName:ec}),eh=await sendTransaction(c,{data:`${ed}${es?es.replace("0x",""):""}`,to:et,...el});return eh}function walletActions(c){return{addChain:l=>addChain(c,l),deployContract:l=>(function(c,{abi:l,args:et,bytecode:eo,...es}){let ec=(0,el.w)({abi:l,args:et,bytecode:eo});return sendTransaction(c,{...es,data:ec})})(c,l),getAddresses:()=>getAddresses(c),getChainId:()=>(0,es.L)(c),getPermissions:()=>getPermissions(c),prepareTransactionRequest:l=>(0,ew.Z)(c,l),requestAddresses:()=>requestAddresses(c),requestPermissions:l=>requestPermissions(c,l),sendRawTransaction:l=>(0,eE.p)(c,l),sendTransaction:l=>sendTransaction(c,l),signMessage:l=>signMessage(c,l),signTransaction:l=>signTransaction(c,l),signTypedData:l=>signTypedData(c,l),switchChain:l=>switchChain(c,l),watchAsset:l=>watchAsset(c,l),writeContract:l=>writeContract(c,l)}}function createWalletClient(c){let{key:l="wallet",name:et="Wallet Client",transport:es}=c,ec=(0,eo.e)({...c,key:l,name:et,transport:c=>es({...c,retryCount:0}),type:"walletClient"});return ec.extend(walletActions)}},68124:function(c,l,et){"use strict";et.d(l,{q:function(){return createTransport}});var eo=et(35215);function createTransport({key:c,name:l,request:et,retryCount:es=3,retryDelay:ec=150,timeout:el,type:ed},eh){return{config:{key:c,name:l,request:et,retryCount:es,retryDelay:ec,timeout:el,type:ed},request:(0,eo.n)(et,{retryCount:es,retryDelay:ec}),value:eh}}},39730:function(c,l,et){"use strict";et.d(l,{P:function(){return custom}});var eo=et(68124);function custom(c,l={}){let{key:et="custom",name:es="Custom Provider",retryDelay:ec}=l;return({retryCount:el})=>(0,eo.q)({key:et,name:es,request:c.request.bind(c),retryCount:l.retryCount??el,retryDelay:ec,type:"custom"})}},42980:function(c,l,et){"use strict";et.d(l,{$o:function(){return ef},F8:function(){return eo},X$:function(){return eh},du:function(){return el},k3:function(){return ec},nZ:function(){return ed}});let eo=[{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"}],es=[{inputs:[],name:"ResolverNotFound",type:"error"},{inputs:[],name:"ResolverWildcardNotSupported",type:"error"}],ec=[...es,{name:"resolve",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes"},{name:"data",type:"bytes"}],outputs:[{name:"",type:"bytes"},{name:"address",type:"address"}]}],el=[...es,{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"}]}],ed=[{name:"text",type:"function",stateMutability:"view",inputs:[{name:"name",type:"bytes32"},{name:"key",type:"string"}],outputs:[{name:"",type:"string"}]}],eh=[{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"}]}],ef=[{inputs:[{internalType:"address",name:"_signer",type:"address"},{internalType:"bytes32",name:"_hash",type:"bytes32"},{internalType:"bytes",name:"_signature",type:"bytes"}],stateMutability:"nonpayable",type:"constructor"}]},28483:function(c,l,et){"use strict";et.d(l,{$:function(){return eo},Up:function(){return es},hZ:function(){return ec}});let eo={1:"An `assert` condition failed.",17:"Arithmic 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."},es={inputs:[{name:"message",type:"string"}],name:"Error",type:"error"},ec={inputs:[{name:"reason",type:"uint256"}],name:"Panic",type:"error"}},36238:function(c,l,et){"use strict";et.d(l,{Zn:function(){return es},ez:function(){return eo}});let eo={gwei:9,wei:18},es={ether:-9,wei:9}},71878:function(c,l,et){"use strict";et.d(l,{CI:function(){return InvalidAbiDecodingTypeError},FM:function(){return AbiEventSignatureEmptyTopicsError},Gy:function(){return DecodeLogTopicsMismatch},KY:function(){return BytesSizeMismatchError},M4:function(){return AbiEncodingBytesSizeMismatchError},MX:function(){return AbiFunctionOutputsNotFoundError},SM:function(){return DecodeLogDataMismatch},cO:function(){return AbiConstructorParamsNotFoundError},dh:function(){return InvalidAbiEncodingTypeError},fM:function(){return AbiConstructorNotFoundError},fs:function(){return AbiEncodingLengthMismatchError},gr:function(){return AbiEncodingArrayLengthMismatchError},hn:function(){return InvalidArrayError},lC:function(){return AbiEventSignatureNotFoundError},mv:function(){return AbiEventNotFoundError},wM:function(){return InvalidDefinitionTypeError},wb:function(){return AbiDecodingZeroDataError},xB:function(){return AbiDecodingDataSizeTooSmallError},xL:function(){return AbiFunctionNotFoundError},yP:function(){return AbiErrorSignatureNotFoundError}});var eo=et(40928),es=et(39868),ec=et(95950);let AbiConstructorNotFoundError=class AbiConstructorNotFoundError extends ec.G{constructor({docsPath:c}){super("A constructor was not found on the ABI.\nMake sure you are using the correct ABI and that the constructor exists on it.",{docsPath:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorNotFoundError"})}};let AbiConstructorParamsNotFoundError=class AbiConstructorParamsNotFoundError extends ec.G{constructor({docsPath:c}){super("Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.\nMake sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists.",{docsPath:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiConstructorParamsNotFoundError"})}};let AbiDecodingDataSizeTooSmallError=class AbiDecodingDataSizeTooSmallError extends ec.G{constructor({data:c,params:l,size:et}){super(`Data size of ${et} bytes is too small for given parameters.`,{metaMessages:[`Params: (${(0,eo.h)(l,{includeName:!0})})`,`Data: ${c} (${et} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"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=c,this.params=l,this.size=et}};let AbiDecodingZeroDataError=class AbiDecodingZeroDataError extends ec.G{constructor(){super('Cannot decode zero data ("0x") with ABI parameters.'),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiDecodingZeroDataError"})}};let AbiEncodingArrayLengthMismatchError=class AbiEncodingArrayLengthMismatchError extends ec.G{constructor({expectedLength:c,givenLength:l,type:et}){super(`ABI encoding array length mismatch for type ${et}. +Expected length: ${c} +Given length: ${l}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingArrayLengthMismatchError"})}};let AbiEncodingBytesSizeMismatchError=class AbiEncodingBytesSizeMismatchError extends ec.G{constructor({expectedSize:c,value:l}){super(`Size of bytes "${l}" (bytes${(0,es.d)(l)}) does not match expected size (bytes${c}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingBytesSizeMismatchError"})}};let AbiEncodingLengthMismatchError=class AbiEncodingLengthMismatchError extends ec.G{constructor({expectedLength:c,givenLength:l}){super(`ABI encoding params/values length mismatch. +Expected length (params): ${c} +Given length (values): ${l}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEncodingLengthMismatchError"})}};let AbiErrorSignatureNotFoundError=class AbiErrorSignatureNotFoundError extends ec.G{constructor(c,{docsPath:l}){super(`Encoded error signature "${c}" 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=${c}.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiErrorSignatureNotFoundError"}),Object.defineProperty(this,"signature",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.signature=c}};let AbiEventSignatureEmptyTopicsError=class AbiEventSignatureEmptyTopicsError extends ec.G{constructor({docsPath:c}){super("Cannot extract event signature from empty topics.",{docsPath:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureEmptyTopicsError"})}};let AbiEventSignatureNotFoundError=class AbiEventSignatureNotFoundError extends ec.G{constructor(c,{docsPath:l}){super(`Encoded event signature "${c}" 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=${c}.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventSignatureNotFoundError"})}};let AbiEventNotFoundError=class AbiEventNotFoundError extends ec.G{constructor(c,{docsPath:l}={}){super(`Event ${c?`"${c}" `:""}not found on ABI. +Make sure you are using the correct ABI and that the event exists on it.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiEventNotFoundError"})}};let AbiFunctionNotFoundError=class AbiFunctionNotFoundError extends ec.G{constructor(c,{docsPath:l}={}){super(`Function ${c?`"${c}" `:""}not found on ABI. +Make sure you are using the correct ABI and that the function exists on it.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionNotFoundError"})}};let AbiFunctionOutputsNotFoundError=class AbiFunctionOutputsNotFoundError extends ec.G{constructor(c,{docsPath:l}){super(`Function "${c}" 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.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AbiFunctionOutputsNotFoundError"})}};let BytesSizeMismatchError=class BytesSizeMismatchError extends ec.G{constructor({expectedSize:c,givenSize:l}){super(`Expected bytes${c}, got bytes${l}.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BytesSizeMismatchError"})}};let DecodeLogDataMismatch=class DecodeLogDataMismatch extends ec.G{constructor({abiItem:c,data:l,params:et,size:es}){super(`Data size of ${es} bytes is too small for non-indexed event parameters.`,{metaMessages:[`Params: (${(0,eo.h)(et,{includeName:!0})})`,`Data: ${l} (${es} bytes)`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"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=c,this.data=l,this.params=et,this.size=es}};let DecodeLogTopicsMismatch=class DecodeLogTopicsMismatch extends ec.G{constructor({abiItem:c,param:l}){super(`Expected a topic for indexed event parameter${l.name?` "${l.name}"`:""} on event "${(0,eo.t)(c,{includeName:!0})}".`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"DecodeLogTopicsMismatch"}),Object.defineProperty(this,"abiItem",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.abiItem=c}};let InvalidAbiEncodingTypeError=class InvalidAbiEncodingTypeError extends ec.G{constructor(c,{docsPath:l}){super(`Type "${c}" is not a valid encoding type. +Please provide a valid ABI type.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiEncodingType"})}};let InvalidAbiDecodingTypeError=class InvalidAbiDecodingTypeError extends ec.G{constructor(c,{docsPath:l}){super(`Type "${c}" is not a valid decoding type. +Please provide a valid ABI type.`,{docsPath:l}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAbiDecodingType"})}};let InvalidArrayError=class InvalidArrayError extends ec.G{constructor(c){super(`Value "${c}" is not a valid array.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidArrayError"})}};let InvalidDefinitionTypeError=class InvalidDefinitionTypeError extends ec.G{constructor(c){super(`"${c}" is not a valid definition type. +Valid types: "function", "event", "error"`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidDefinitionTypeError"})}}},67333:function(c,l,et){"use strict";et.d(l,{o:function(){return AccountNotFoundError}});var eo=et(95950);let AccountNotFoundError=class AccountNotFoundError extends eo.G{constructor({docsPath:c}={}){super("Could not find an Account to execute with this Action.\nPlease provide an Account with the `account` argument on the Action, or by supplying an `account` to the WalletClient.",{docsPath:c,docsSlug:"account"}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"AccountNotFoundError"})}}},21485:function(c,l,et){"use strict";et.d(l,{b:function(){return InvalidAddressError}});var eo=et(95950);let InvalidAddressError=class InvalidAddressError extends eo.G{constructor({address:c}){super(`Address "${c}" is invalid.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidAddressError"})}}},95950:function(c,l,et){"use strict";et.d(l,{G:function(){return BaseError}});var eo=et(66291);let BaseError=class BaseError extends Error{constructor(c,l={}){super(),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:"ViemError"}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:(0,eo.bo)()});let et=l.cause instanceof BaseError?l.cause.details:l.cause?.message?l.cause.message:l.details,es=l.cause instanceof BaseError&&l.cause.docsPath||l.docsPath;this.message=[c||"An error occurred.","",...l.metaMessages?[...l.metaMessages,""]:[],...es?[`Docs: https://viem.sh${es}.html${l.docsSlug?`#${l.docsSlug}`:""}`]:[],...et?[`Details: ${et}`]:[],`Version: ${this.version}`].join("\n"),l.cause&&(this.cause=l.cause),this.details=et,this.docsPath=es,this.metaMessages=l.metaMessages,this.shortMessage=c}walk(c){return function walk(c,l){return l?.(c)?c:c&&"object"==typeof c&&"cause"in c?walk(c.cause,l):l?null:c}(this,c)}}},27878:function(c,l,et){"use strict";et.d(l,{Bk:function(){return ChainNotFoundError},Yl:function(){return ChainMismatchError},mm:function(){return ChainDoesNotSupportContract},pZ:function(){return ClientChainNotConfiguredError}});var eo=et(95950);let ChainDoesNotSupportContract=class ChainDoesNotSupportContract extends eo.G{constructor({blockNumber:c,chain:l,contract:et}){super(`Chain "${l.name}" does not support contract "${et.name}".`,{metaMessages:["This could be due to any of the following:",...c&&et.blockCreated&&et.blockCreated>c?[`- The contract "${et.name}" was not deployed until block ${et.blockCreated} (current block ${c}).`]:[`- The chain does not have the contract "${et.name}" configured.`]]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDoesNotSupportContract"})}};let ChainMismatchError=class ChainMismatchError extends eo.G{constructor({chain:c,currentChainId:l}){super(`The current chain of the wallet (id: ${l}) does not match the target chain for the transaction (id: ${c.id} – ${c.name}).`,{metaMessages:[`Current Chain ID: ${l}`,`Expected Chain ID: ${c.id} – ${c.name}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainMismatchError"})}};let ChainNotFoundError=class ChainNotFoundError extends eo.G{constructor(){super("No chain was provided to the request.\nPlease provide a chain with the `chain` argument on the Action, or by supplying a `chain` to WalletClient."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainNotFoundError"})}};let ClientChainNotConfiguredError=class ClientChainNotConfiguredError extends eo.G{constructor(){super("No chain was provided to the Client."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ClientChainNotConfiguredError"})}}},98458:function(c,l,et){"use strict";et.d(l,{cg:function(){return CallExecutionError},uq:function(){return ContractFunctionExecutionError},Lu:function(){return ContractFunctionRevertedError},Dk:function(){return ContractFunctionZeroDataError},VQ:function(){return RawContractError}});var eo=et(4832),es=et(28483),ec=et(49039),el=et(40928),ed=et(71891);function formatAbiItemWithArgs({abiItem:c,args:l,includeFunctionName:et=!0,includeName:eo=!1}){if("name"in c&&"inputs"in c&&c.inputs)return`${et?c.name:""}(${c.inputs.map((c,et)=>`${eo&&c.name?`${c.name}: `:""}${"object"==typeof l[et]?(0,ed.P)(l[et]):l[et]}`).join(", ")})`}var eh=et(77804),ef=et(79352),ep=et(32421),eg=et(71878),em=et(95950),eb=et(44818),ey=et(66291);let CallExecutionError=class CallExecutionError extends em.G{constructor(c,{account:l,docsPath:et,chain:es,data:ec,gas:el,gasPrice:ed,maxFeePerGas:eh,maxPriorityFeePerGas:eg,nonce:em,to:ey,value:e_}){let ew=l?(0,eo.T)(l):void 0,eE=(0,eb.xr)({from:ew?.address,to:ey,value:void 0!==e_&&`${(0,ef.d)(e_)} ${es?.nativeCurrency.symbol||"ETH"}`,data:ec,gas:el,gasPrice:void 0!==ed&&`${(0,ep.o)(ed)} gwei`,maxFeePerGas:void 0!==eh&&`${(0,ep.o)(eh)} gwei`,maxPriorityFeePerGas:void 0!==eg&&`${(0,ep.o)(eg)} gwei`,nonce:em});super(c.shortMessage,{cause:c,docsPath:et,metaMessages:[...c.metaMessages?[...c.metaMessages," "]:[],"Raw Call Arguments:",eE].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"CallExecutionError"}),this.cause=c}};let ContractFunctionExecutionError=class ContractFunctionExecutionError extends em.G{constructor(c,{abi:l,args:et,contractAddress:eo,docsPath:es,functionName:ec,sender:ed}){let ef=(0,eh.m)({abi:l,args:et,name:ec}),ep=ef?formatAbiItemWithArgs({abiItem:ef,args:et,includeFunctionName:!1,includeName:!1}):void 0,eg=ef?(0,el.t)(ef,{includeName:!0}):void 0,em=(0,eb.xr)({address:eo&&(0,ey.CR)(eo),function:eg,args:ep&&"()"!==ep&&`${[...Array(ec?.length??0).keys()].map(()=>" ").join("")}${ep}`,sender:ed});super(c.shortMessage||`An unknown error occurred while executing the contract function "${ec}".`,{cause:c,docsPath:es,metaMessages:[...c.metaMessages?[...c.metaMessages," "]:[],"Contract Call:",em].filter(Boolean)}),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}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionExecutionError"}),this.abi=l,this.args=et,this.cause=c,this.contractAddress=eo,this.functionName=ec,this.sender=ed}};let ContractFunctionRevertedError=class ContractFunctionRevertedError extends em.G{constructor({abi:c,data:l,functionName:et,message:eo}){let ed,eh,ef,ep,em;if(l&&"0x"!==l)try{em=(0,ec.p)({abi:c,data:l});let{abiItem:et,errorName:eo,args:ed}=em;if("Error"===eo)ef=ed[0];else if("Panic"===eo){let[c]=ed;ef=es.$[c]}else{let c=et?(0,el.t)(et,{includeName:!0}):void 0,l=et&&ed?formatAbiItemWithArgs({abiItem:et,args:ed,includeFunctionName:!1,includeName:!1}):void 0;eh=[c?`Error: ${c}`:"",l&&"()"!==l?` ${[...Array(eo?.length??0).keys()].map(()=>" ").join("")}${l}`:""]}}catch(c){ed=c}else eo&&(ef=eo);ed instanceof eg.yP&&(ep=ed.signature,eh=[`Unable to decode signature "${ep}" 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=${ep}.`]),super(ef&&"execution reverted"!==ef||ep?[`The contract function "${et}" reverted with the following ${ep?"signature":"reason"}:`,ef||ep].join("\n"):`The contract function "${et}" reverted.`,{cause:ed,metaMessages:eh}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"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=em,this.reason=ef,this.signature=ep}};let ContractFunctionZeroDataError=class ContractFunctionZeroDataError extends em.G{constructor({functionName:c}){super(`The contract function "${c}" returned no data ("0x").`,{metaMessages:["This could be due to any of the following:",` - The contract does not have the function "${c}",`," - The parameters passed to the contract function may be invalid, or"," - The address is not a contract."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ContractFunctionZeroDataError"})}};let RawContractError=class RawContractError extends em.G{constructor({data:c,message:l}){super(l||""),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RawContractError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=c}}},741:function(c,l,et){"use strict";et.d(l,{$:function(){return SizeExceedsPaddingSizeError},m:function(){return SliceOffsetOutOfBoundsError}});var eo=et(95950);let SliceOffsetOutOfBoundsError=class SliceOffsetOutOfBoundsError extends eo.G{constructor({offset:c,position:l,size:et}){super(`Slice ${"start"===l?"starting":"ending"} at offset "${c}" is out-of-bounds (size: ${et}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SliceOffsetOutOfBoundsError"})}};let SizeExceedsPaddingSizeError=class SizeExceedsPaddingSizeError extends eo.G{constructor({size:c,targetSize:l,type:et}){super(`${et.charAt(0).toUpperCase()}${et.slice(1).toLowerCase()} size (${c}) exceeds padding size (${l}).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeExceedsPaddingSizeError"})}}},86714:function(c,l,et){"use strict";et.d(l,{Cd:function(){return InvalidHexBooleanError},J5:function(){return IntegerOutOfRangeError},M6:function(){return SizeOverflowError}});var eo=et(95950);let IntegerOutOfRangeError=class IntegerOutOfRangeError extends eo.G{constructor({max:c,min:l,signed:et,size:eo,value:es}){super(`Number "${es}" is not in safe ${eo?`${8*eo}-bit ${et?"signed":"unsigned"} `:""}integer range ${c?`(${l} to ${c})`:`(above ${l})`}`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntegerOutOfRangeError"})}};let InvalidHexBooleanError=class InvalidHexBooleanError extends eo.G{constructor(c){super(`Hex value "${c}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidHexBooleanError"})}};let SizeOverflowError=class SizeOverflowError extends eo.G{constructor({givenSize:c,maxSize:l}){super(`Size cannot exceed ${l} bytes. Given size: ${c} bytes.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SizeOverflowError"})}}},84161:function(c,l,et){"use strict";et.d(l,{Fz:function(){return BaseFeeScalarError},e5:function(){return Eip1559FeesNotSupportedError},ld:function(){return MaxFeePerGasTooLowError}});var eo=et(32421),es=et(95950);let BaseFeeScalarError=class BaseFeeScalarError extends es.G{constructor(){super("`baseFeeMultiplier` must be greater than 1."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseFeeScalarError"})}};let Eip1559FeesNotSupportedError=class Eip1559FeesNotSupportedError extends es.G{constructor(){super("Chain does not support EIP-1559 fees."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"Eip1559FeesNotSupportedError"})}};let MaxFeePerGasTooLowError=class MaxFeePerGasTooLowError extends es.G{constructor({maxPriorityFeePerGas:c}){super(`\`maxFeePerGas\` cannot be less than the \`maxPriorityFeePerGas\` (${(0,eo.o)(c)} gwei).`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MaxFeePerGasTooLowError"})}}},40009:function(c,l,et){"use strict";et.d(l,{C_:function(){return InsufficientFundsError},G$:function(){return FeeCapTooLowError},Hh:function(){return FeeCapTooHighError},M_:function(){return ExecutionRevertedError},WF:function(){return IntrinsicGasTooHighError},ZI:function(){return NonceTooHighError},cj:function(){return UnknownNodeError},cs:function(){return TipAboveFeeCapError},dR:function(){return IntrinsicGasTooLowError},pZ:function(){return TransactionTypeNotSupportedError},se:function(){return NonceMaxValueError},vU:function(){return NonceTooLowError}});var eo=et(32421),es=et(95950);let ExecutionRevertedError=class ExecutionRevertedError extends es.G{constructor({cause:c,message:l}={}){let et=l?.replace("execution reverted: ","")?.replace("execution reverted","");super(`Execution reverted ${et?`with reason: ${et}`:"for an unknown reason"}.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ExecutionRevertedError"})}};Object.defineProperty(ExecutionRevertedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:3}),Object.defineProperty(ExecutionRevertedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/execution reverted/});let FeeCapTooHighError=class FeeCapTooHighError extends es.G{constructor({cause:c,maxFeePerGas:l}={}){super(`The fee cap (\`maxFeePerGas\`${l?` = ${(0,eo.o)(l)} gwei`:""}) cannot be higher than the maximum allowed value (2^256-1).`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeCapTooHigh"})}};Object.defineProperty(FeeCapTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max fee per gas higher than 2\^256-1|fee cap higher than 2\^256-1/});let FeeCapTooLowError=class FeeCapTooLowError extends es.G{constructor({cause:c,maxFeePerGas:l}={}){super(`The fee cap (\`maxFeePerGas\`${l?` = ${(0,eo.o)(l)}`:""} gwei) cannot be lower than the block base fee.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeCapTooLow"})}};Object.defineProperty(FeeCapTooLowError,"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/});let NonceTooHighError=class NonceTooHighError extends es.G{constructor({cause:c,nonce:l}={}){super(`Nonce provided for the transaction ${l?`(${l}) `:""}is higher than the next one expected.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooHighError"})}};Object.defineProperty(NonceTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too high/});let NonceTooLowError=class NonceTooLowError extends es.G{constructor({cause:c,nonce:l}={}){super(`Nonce provided for the transaction ${l?`(${l}) `:""}is lower than the current nonce of the account. +Try increasing the nonce or find the latest nonce with \`getTransactionCount\`.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceTooLowError"})}};Object.defineProperty(NonceTooLowError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce too low|transaction already imported|already known/});let NonceMaxValueError=class NonceMaxValueError extends es.G{constructor({cause:c,nonce:l}={}){super(`Nonce provided for the transaction ${l?`(${l}) `:""}exceeds the maximum allowed nonce.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"NonceMaxValueError"})}};Object.defineProperty(NonceMaxValueError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/nonce has max value/});let InsufficientFundsError=class InsufficientFundsError extends es.G{constructor({cause:c}={}){super("The total cost (gas * gas fee + value) of executing this transaction exceeds the balance of the account.",{cause:c,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."]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InsufficientFundsError"})}};Object.defineProperty(InsufficientFundsError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/insufficient funds/});let IntrinsicGasTooHighError=class IntrinsicGasTooHighError extends es.G{constructor({cause:c,gas:l}={}){super(`The amount of gas ${l?`(${l}) `:""}provided for the transaction exceeds the limit allowed for the block.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntrinsicGasTooHighError"})}};Object.defineProperty(IntrinsicGasTooHighError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too high|gas limit reached/});let IntrinsicGasTooLowError=class IntrinsicGasTooLowError extends es.G{constructor({cause:c,gas:l}={}){super(`The amount of gas ${l?`(${l}) `:""}provided for the transaction is too low.`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"IntrinsicGasTooLowError"})}};Object.defineProperty(IntrinsicGasTooLowError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/intrinsic gas too low/});let TransactionTypeNotSupportedError=class TransactionTypeNotSupportedError extends es.G{constructor({cause:c}){super("The transaction type is not supported for this chain.",{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionTypeNotSupportedError"})}};Object.defineProperty(TransactionTypeNotSupportedError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/transaction type not valid/});let TipAboveFeeCapError=class TipAboveFeeCapError extends es.G{constructor({cause:c,maxPriorityFeePerGas:l,maxFeePerGas:et}={}){super(`The provided tip (\`maxPriorityFeePerGas\`${l?` = ${(0,eo.o)(l)} gwei`:""}) cannot be higher than the fee cap (\`maxFeePerGas\`${et?` = ${(0,eo.o)(et)} gwei`:""}).`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TipAboveFeeCapError"})}};Object.defineProperty(TipAboveFeeCapError,"nodeMessage",{enumerable:!0,configurable:!0,writable:!0,value:/max priority fee per gas higher than max fee per gas|tip higher than fee cap/});let UnknownNodeError=class UnknownNodeError extends es.G{constructor({cause:c}){super(`An error occurred while executing: ${c?.shortMessage}`,{cause:c}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownNodeError"})}}},20722:function(c,l,et){"use strict";et.d(l,{Gg:function(){return HttpRequestError},W5:function(){return TimeoutError},bs:function(){return RpcRequestError},c9:function(){return WebSocketRequestError}});var eo=et(71891),es=et(95950),ec=et(66291);let HttpRequestError=class HttpRequestError extends es.G{constructor({body:c,details:l,headers:et,status:es,url:el}){super("HTTP request failed.",{details:l,metaMessages:[es&&`Status: ${es}`,`URL: ${(0,ec.Gr)(el)}`,c&&`Request body: ${(0,eo.P)(c)}`].filter(Boolean)}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"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=c,this.headers=et,this.status=es,this.url=el}};let WebSocketRequestError=class WebSocketRequestError extends es.G{constructor({body:c,details:l,url:et}){super("WebSocket request failed.",{details:l,metaMessages:[`URL: ${(0,ec.Gr)(et)}`,`Request body: ${(0,eo.P)(c)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WebSocketRequestError"})}};let RpcRequestError=class RpcRequestError extends es.G{constructor({body:c,error:l,url:et}){super("RPC Request failed.",{cause:l,details:l.message,metaMessages:[`URL: ${(0,ec.Gr)(et)}`,`Request body: ${(0,eo.P)(c)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RpcRequestError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.code=l.code}};let TimeoutError=class TimeoutError extends es.G{constructor({body:c,url:l}){super("The request took too long to respond.",{details:"The request timed out.",metaMessages:[`URL: ${(0,ec.Gr)(l)}`,`Request body: ${(0,eo.P)(c)}`]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TimeoutError"})}}},48519:function(c,l,et){"use strict";et.d(l,{B:function(){return InvalidRequestRpcError},GD:function(){return JsonRpcVersionUnsupportedError},I0:function(){return ChainDisconnectedError},KB:function(){return TransactionRejectedRpcError},LX:function(){return MethodNotFoundRpcError},Og:function(){return ResourceNotFoundRpcError},PE:function(){return UnauthorizedProviderError},Pv:function(){return LimitExceededRpcError},Ts:function(){return UnsupportedProviderMethodError},XS:function(){return InternalRpcError},ab:function(){return UserRejectedRequestError},gS:function(){return MethodNotSupportedRpcError},ir:function(){return UnknownRpcError},nY:function(){return InvalidParamsRpcError},pT:function(){return ResourceUnavailableRpcError},s7:function(){return ParseRpcError},u5:function(){return ProviderDisconnectedError},x3:function(){return SwitchChainError},yR:function(){return InvalidInputRpcError}});var eo=et(95950),es=et(20722);let RpcError=class RpcError extends eo.G{constructor(c,{code:l,docsPath:et,metaMessages:eo,shortMessage:ec}){super(ec,{cause:c,docsPath:et,metaMessages:eo||c?.metaMessages}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"RpcError"}),Object.defineProperty(this,"code",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.name=c.name,this.code=c instanceof es.bs?c.code:l??-1}};let ProviderRpcError=class ProviderRpcError extends RpcError{constructor(c,l){super(c,l),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderRpcError"}),Object.defineProperty(this,"data",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.data=l.data}};let ParseRpcError=class ParseRpcError extends RpcError{constructor(c){super(c,{code:ParseRpcError.code,shortMessage:"Invalid JSON was received by the server. An error occurred on the server while parsing the JSON text."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ParseRpcError"})}};Object.defineProperty(ParseRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32700});let InvalidRequestRpcError=class InvalidRequestRpcError extends RpcError{constructor(c){super(c,{code:InvalidRequestRpcError.code,shortMessage:"JSON is not a valid request object."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidRequestRpcError"})}};Object.defineProperty(InvalidRequestRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32600});let MethodNotFoundRpcError=class MethodNotFoundRpcError extends RpcError{constructor(c){super(c,{code:MethodNotFoundRpcError.code,shortMessage:"The method does not exist / is not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotFoundRpcError"})}};Object.defineProperty(MethodNotFoundRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32601});let InvalidParamsRpcError=class InvalidParamsRpcError extends RpcError{constructor(c){super(c,{code:InvalidParamsRpcError.code,shortMessage:"Invalid parameters were provided to the RPC method.\nDouble check you have provided the correct parameters."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidParamsRpcError"})}};Object.defineProperty(InvalidParamsRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32602});let InternalRpcError=class InternalRpcError extends RpcError{constructor(c){super(c,{code:InternalRpcError.code,shortMessage:"An internal error was received."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InternalRpcError"})}};Object.defineProperty(InternalRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32603});let InvalidInputRpcError=class InvalidInputRpcError extends RpcError{constructor(c){super(c,{code:InvalidInputRpcError.code,shortMessage:"Missing or invalid parameters.\nDouble check you have provided the correct parameters."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidInputRpcError"})}};Object.defineProperty(InvalidInputRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32e3});let ResourceNotFoundRpcError=class ResourceNotFoundRpcError extends RpcError{constructor(c){super(c,{code:ResourceNotFoundRpcError.code,shortMessage:"Requested resource not found."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceNotFoundRpcError"})}};Object.defineProperty(ResourceNotFoundRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32001});let ResourceUnavailableRpcError=class ResourceUnavailableRpcError extends RpcError{constructor(c){super(c,{code:ResourceUnavailableRpcError.code,shortMessage:"Requested resource not available."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ResourceUnavailableRpcError"})}};Object.defineProperty(ResourceUnavailableRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32002});let TransactionRejectedRpcError=class TransactionRejectedRpcError extends RpcError{constructor(c){super(c,{code:TransactionRejectedRpcError.code,shortMessage:"Transaction creation failed."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionRejectedRpcError"})}};Object.defineProperty(TransactionRejectedRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32003});let MethodNotSupportedRpcError=class MethodNotSupportedRpcError extends RpcError{constructor(c){super(c,{code:MethodNotSupportedRpcError.code,shortMessage:"Method is not implemented."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"MethodNotSupportedRpcError"})}};Object.defineProperty(MethodNotSupportedRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32004});let LimitExceededRpcError=class LimitExceededRpcError extends RpcError{constructor(c){super(c,{code:LimitExceededRpcError.code,shortMessage:"Request exceeds defined limit."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"LimitExceededRpcError"})}};Object.defineProperty(LimitExceededRpcError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32005});let JsonRpcVersionUnsupportedError=class JsonRpcVersionUnsupportedError extends RpcError{constructor(c){super(c,{code:JsonRpcVersionUnsupportedError.code,shortMessage:"Version of JSON-RPC protocol is not supported."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"JsonRpcVersionUnsupportedError"})}};Object.defineProperty(JsonRpcVersionUnsupportedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:-32006});let UserRejectedRequestError=class UserRejectedRequestError extends ProviderRpcError{constructor(c){super(c,{code:UserRejectedRequestError.code,shortMessage:"User rejected the request."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UserRejectedRequestError"})}};Object.defineProperty(UserRejectedRequestError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4001});let UnauthorizedProviderError=class UnauthorizedProviderError extends ProviderRpcError{constructor(c){super(c,{code:UnauthorizedProviderError.code,shortMessage:"The requested method and/or account has not been authorized by the user."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnauthorizedProviderError"})}};Object.defineProperty(UnauthorizedProviderError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4100});let UnsupportedProviderMethodError=class UnsupportedProviderMethodError extends ProviderRpcError{constructor(c){super(c,{code:UnsupportedProviderMethodError.code,shortMessage:"The Provider does not support the requested method."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnsupportedProviderMethodError"})}};Object.defineProperty(UnsupportedProviderMethodError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4200});let ProviderDisconnectedError=class ProviderDisconnectedError extends ProviderRpcError{constructor(c){super(c,{code:ProviderDisconnectedError.code,shortMessage:"The Provider is disconnected from all chains."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ProviderDisconnectedError"})}};Object.defineProperty(ProviderDisconnectedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4900});let ChainDisconnectedError=class ChainDisconnectedError extends ProviderRpcError{constructor(c){super(c,{code:ChainDisconnectedError.code,shortMessage:"The Provider is not connected to the requested chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"ChainDisconnectedError"})}};Object.defineProperty(ChainDisconnectedError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4901});let SwitchChainError=class SwitchChainError extends ProviderRpcError{constructor(c){super(c,{code:SwitchChainError.code,shortMessage:"An error occurred when attempting to switch chain."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"SwitchChainError"})}};Object.defineProperty(SwitchChainError,"code",{enumerable:!0,configurable:!0,writable:!0,value:4902});let UnknownRpcError=class UnknownRpcError extends RpcError{constructor(c){super(c,{shortMessage:"An unknown RPC error occurred."}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"UnknownRpcError"})}}},44818:function(c,l,et){"use strict";et.d(l,{Bh:function(){return TransactionNotFoundError},Yb:function(){return TransactionReceiptNotFoundError},j3:function(){return InvalidSerializableTransactionError},mc:function(){return WaitForTransactionReceiptTimeoutError},mk:function(){return TransactionExecutionError},xY:function(){return FeeConflictError},xr:function(){return prettyPrint}});var eo=et(79352),es=et(32421),ec=et(95950);function prettyPrint(c){let l=Object.entries(c).map(([c,l])=>void 0===l||!1===l?null:[c,l]).filter(Boolean),et=l.reduce((c,[l])=>Math.max(c,l.length),0);return l.map(([c,l])=>` ${`${c}:`.padEnd(et+1)} ${l}`).join("\n")}let FeeConflictError=class FeeConflictError extends ec.G{constructor(){super("Cannot specify both a `gasPrice` and a `maxFeePerGas`/`maxPriorityFeePerGas`.\nUse `maxFeePerGas`/`maxPriorityFeePerGas` for EIP-1559 compatible networks, and `gasPrice` for others."),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"FeeConflictError"})}};let InvalidSerializableTransactionError=class InvalidSerializableTransactionError extends ec.G{constructor({transaction:c}){super("Cannot infer a transaction type from provided transaction.",{metaMessages:["Provided Transaction:","{",prettyPrint(c),"}","","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","- a Legacy Transaction with `gasPrice`"]}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"InvalidSerializableTransactionError"})}};let TransactionExecutionError=class TransactionExecutionError extends ec.G{constructor(c,{account:l,docsPath:et,chain:ec,data:el,gas:ed,gasPrice:eh,maxFeePerGas:ef,maxPriorityFeePerGas:ep,nonce:eg,to:em,value:eb}){let ey=prettyPrint({chain:ec&&`${ec?.name} (id: ${ec?.id})`,from:l?.address,to:em,value:void 0!==eb&&`${(0,eo.d)(eb)} ${ec?.nativeCurrency.symbol||"ETH"}`,data:el,gas:ed,gasPrice:void 0!==eh&&`${(0,es.o)(eh)} gwei`,maxFeePerGas:void 0!==ef&&`${(0,es.o)(ef)} gwei`,maxPriorityFeePerGas:void 0!==ep&&`${(0,es.o)(ep)} gwei`,nonce:eg});super(c.shortMessage,{cause:c,docsPath:et,metaMessages:[...c.metaMessages?[...c.metaMessages," "]:[],"Request Arguments:",ey].filter(Boolean)}),Object.defineProperty(this,"cause",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionExecutionError"}),this.cause=c}};let TransactionNotFoundError=class TransactionNotFoundError extends ec.G{constructor({blockHash:c,blockNumber:l,blockTag:et,hash:eo,index:es}){let ec="Transaction";et&&void 0!==es&&(ec=`Transaction at block time "${et}" at index "${es}"`),c&&void 0!==es&&(ec=`Transaction at block hash "${c}" at index "${es}"`),l&&void 0!==es&&(ec=`Transaction at block number "${l}" at index "${es}"`),eo&&(ec=`Transaction with hash "${eo}"`),super(`${ec} could not be found.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionNotFoundError"})}};let TransactionReceiptNotFoundError=class TransactionReceiptNotFoundError extends ec.G{constructor({hash:c}){super(`Transaction receipt with hash "${c}" could not be found. The Transaction may not be processed on a block yet.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"TransactionReceiptNotFoundError"})}};let WaitForTransactionReceiptTimeoutError=class WaitForTransactionReceiptTimeoutError extends ec.G{constructor({hash:c}){super(`Timed out while waiting for transaction with hash "${c}" to be confirmed.`),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"WaitForTransactionReceiptTimeoutError"})}}},66291:function(c,l,et){"use strict";et.d(l,{CR:function(){return getContractAddress},Gr:function(){return getUrl},bo:function(){return getVersion}});let getContractAddress=c=>c,getUrl=c=>c,getVersion=()=>"viem@1.15.3"},87425:function(c,l,et){"use strict";et.d(l,{r:function(){return decodeAbiParameters}});var eo=et(71878),es=et(39803),ec=et(39868),el=et(72619),ed=et(94973),eh=et(30838),ef=et(90929);function decodeAbiParameters(c,l){if("0x"===l&&c.length>0)throw new eo.wb;if((0,ec.d)(l)&&32>(0,ec.d)(l))throw new eo.xB({data:l,params:c,size:(0,ec.d)(l)});return function({data:c,params:l}){let et=[],ep=0;for(let eg=0;eg=(0,ec.d)(c))throw new eo.xB({data:c,params:l,size:(0,ec.d)(c)});let em=l[eg],{consumed:eb,value:ey}=function decodeParam({data:c,param:l,position:et}){let ec=(0,ef.S)(l.type);if(ec){let[eo,es]=ec;return function(c,{param:l,length:et,position:eo}){if(!et){let et=(0,eh.ly)((0,el.tP)(c,eo,eo+32,{strict:!0})),es=(0,eh.ly)((0,el.tP)(c,et,et+32,{strict:!0})),ec=0,ed=[];for(let eo=0;eo!c),es=eo?[]:{},ec=0;if(hasDynamicChild(l)){let ed=(0,eh.ly)((0,el.tP)(c,et,et+32,{strict:!0}));for(let et=0;et48?(0,eh.y_)(c,{signed:et}):(0,eh.ly)(c,{signed:et})}}(ep,{param:l});if("address"===l.type)return{consumed:32,value:(0,es.x)((0,el.tP)(ep,-20))};if("bool"===l.type)return{consumed:32,value:(0,eh.XA)(ep)};throw new eo.CI(l.type,{docsPath:"/docs/contract/decodeAbiParameters"})}({data:c,param:em,position:ep});et.push(ey),ep+=eb}return et}({data:l,params:c})}function hasDynamicChild(c){let{type:l}=c;if("string"===l||"bytes"===l||l.endsWith("[]"))return!0;if("tuple"===l)return c.components?.some(hasDynamicChild);let et=(0,ef.S)(c.type);return!!(et&&hasDynamicChild({...c,type:et[1]}))}},49039:function(c,l,et){"use strict";et.d(l,{p:function(){return decodeErrorResult}});var eo=et(28483),es=et(71878),ec=et(72619),el=et(33655),ed=et(87425),eh=et(40928);function decodeErrorResult({abi:c,data:l}){let et=(0,ec.tP)(l,0,4);if("0x"===et)throw new es.wb;let ef=[...c||[],eo.Up,eo.hZ],ep=ef.find(c=>"error"===c.type&&et===(0,el.o)((0,eh.t)(c)));if(!ep)throw new es.yP(et,{docsPath:"/docs/contract/decodeErrorResult"});return{abiItem:ep,args:"inputs"in ep&&ep.inputs&&ep.inputs.length>0?(0,ed.r)(ep.inputs,(0,ec.tP)(l,4)):void 0,errorName:ep.name}}},63610:function(c,l,et){"use strict";et.d(l,{F:function(){return decodeEventLog}});var eo=et(71878),es=et(77688),ec=et(87425),el=et(40928);let ed="/docs/contract/decodeEventLog";function decodeEventLog({abi:c,data:l,strict:et,topics:eh}){let ef=et??!0,[ep,...eg]=eh;if(!ep)throw new eo.FM({docsPath:ed});let em=c.find(c=>"event"===c.type&&ep===(0,es.e)((0,el.t)(c)));if(!(em&&"name"in em)||"event"!==em.type)throw new eo.lC(ep,{docsPath:ed});let{name:eb,inputs:ey}=em,e_=ey?.some(c=>!("name"in c&&c.name)),ew=e_?[]:{},eE=ey.filter(c=>"indexed"in c&&c.indexed);if(eg.length>0)for(let c=0;c!("indexed"in c&&c.indexed));if(eS.length>0){if(l&&"0x"!==l)try{let c=(0,ec.r)(eS,l);if(c){if(e_)ew=[...ew,...c];else for(let l=0;l0?ew:void 0}}},3458:function(c,l,et){"use strict";et.d(l,{k:function(){return decodeFunctionResult}});var eo=et(71878),es=et(87425),ec=et(77804);let el="/docs/contract/decodeFunctionResult";function decodeFunctionResult({abi:c,args:l,functionName:et,data:ed}){let eh=c[0];if(et&&!(eh=(0,ec.m)({abi:c,args:l,name:et})))throw new eo.xL(et,{docsPath:el});if("function"!==eh.type)throw new eo.xL(void 0,{docsPath:el});if(!eh.outputs)throw new eo.MX(eh.name,{docsPath:el});let ef=(0,es.r)(eh.outputs,ed);return ef&&ef.length>1?ef:ef&&1===ef.length?ef[0]:void 0}},90929:function(c,l,et){"use strict";et.d(l,{E:function(){return encodeAbiParameters},S:function(){return getArrayComponents}});var eo=et(71878),es=et(21485),ec=et(87364),el=et(69809),ed=et(99725),eh=et(39868),ef=et(72619),ep=et(21693);function encodeAbiParameters(c,l){if(c.length!==l.length)throw new eo.fs({expectedLength:c.length,givenLength:l.length});let et=function({params:c,values:l}){let et=[];for(let eg=0;eg0?(0,el.zo)([l,c]):l}}if(ec)return{dynamic:!0,encoded:c}}return{dynamic:!1,encoded:(0,el.zo)(ed.map(({encoded:c})=>c))}}(l,{length:es,param:{...c,type:ec}})}if("tuple"===c.type)return function(c,{param:l}){let et=!1,eo=[];for(let es=0;esc))}}(l,{param:c});if("address"===c.type)return function(c){if(!(0,ec.U)(c))throw new es.b({address:c});return{dynamic:!1,encoded:(0,ed.gc)(c.toLowerCase())}}(l);if("bool"===c.type)return{dynamic:!1,encoded:(0,ed.gc)((0,ep.C4)(l))};if(c.type.startsWith("uint")||c.type.startsWith("int")){let et=c.type.startsWith("int");return function(c,{signed:l}){return{dynamic:!1,encoded:(0,ep.eC)(c,{size:32,signed:l})}}(l,{signed:et})}if(c.type.startsWith("bytes"))return function(c,{param:l}){let[,et]=l.type.split("bytes"),es=(0,eh.d)(c);if(!et){let l=c;return es%32!=0&&(l=(0,ed.gc)(l,{dir:"right",size:32*Math.ceil((c.length-2)/2/32)})),{dynamic:!0,encoded:(0,el.zo)([(0,ed.gc)((0,ep.eC)(es,{size:32})),l])}}if(es!==parseInt(et))throw new eo.M4({expectedSize:parseInt(et),value:c});return{dynamic:!1,encoded:(0,ed.gc)(c,{dir:"right"})}}(l,{param:c});if("string"===c.type)return function(c){let l=(0,ep.$G)(c),et=Math.ceil((0,eh.d)(l)/32),eo=[];for(let c=0;c"type"in c&&"constructor"===c.type);if(!ed)throw new eo.fM({docsPath:el});if(!("inputs"in ed)||!ed.inputs||0===ed.inputs.length)throw new eo.cO({docsPath:el});let eh=(0,ec.E)(ed.inputs,l);return(0,es.SM)([et,eh])}},53883:function(c,l,et){"use strict";et.d(l,{R:function(){return encodeFunctionData}});var eo=et(71878),es=et(69809),ec=et(33655),el=et(90929),ed=et(40928),eh=et(77804);function encodeFunctionData({abi:c,args:l,functionName:et}){let ef=c[0];if(et&&!(ef=(0,eh.m)({abi:c,args:l,name:et})))throw new eo.xL(et,{docsPath:"/docs/contract/encodeFunctionData"});if("function"!==ef.type)throw new eo.xL(void 0,{docsPath:"/docs/contract/encodeFunctionData"});let ep=(0,ed.t)(ef),eg=(0,ec.o)(ep),em="inputs"in ef&&ef.inputs?(0,el.E)(ef.inputs,l??[]):void 0;return(0,es.SM)([eg,em??"0x"])}},40928:function(c,l,et){"use strict";et.d(l,{h:function(){return formatAbiParams},t:function(){return formatAbiItem}});var eo=et(71878);function formatAbiItem(c,{includeName:l=!1}={}){if("function"!==c.type&&"event"!==c.type&&"error"!==c.type)throw new eo.wM(c.type);return`${c.name}(${formatAbiParams(c.inputs,{includeName:l})})`}function formatAbiParams(c,{includeName:l=!1}={}){return c?c.map(c=>(function(c,{includeName:l}){return c.type.startsWith("tuple")?`(${formatAbiParams(c.components,{includeName:l})})${c.type.slice(5)}`:c.type+(l&&c.name?` ${c.name}`:"")})(c,{includeName:l})).join(l?", ":","):""}},77804:function(c,l,et){"use strict";et.d(l,{m:function(){return getAbiItem}});var eo=et(45008),es=et(77688),ec=et(33655),el=et(87364);function getAbiItem({abi:c,args:l=[],name:et}){let ed=(0,eo.v)(et,{strict:!1}),eh=c.filter(c=>ed?"function"===c.type?(0,ec.o)(c)===et:"event"===c.type&&(0,es.e)(c)===et:"name"in c&&c.name===et);if(0!==eh.length){if(1===eh.length)return eh[0];for(let c of eh){if(!("inputs"in c))continue;if(!l||0===l.length){if(!c.inputs||0===c.inputs.length)return c;continue}if(!c.inputs||0===c.inputs.length||c.inputs.length!==l.length)continue;let et=l.every((l,et)=>{let eo="inputs"in c&&c.inputs[et];return!!eo&&function isArgOfType(c,l){let et=typeof c,eo=l.type;switch(eo){case"address":return(0,el.U)(c);case"bool":return"boolean"===et;case"function":case"string":return"string"===et;default:if("tuple"===eo&&"components"in l)return Object.values(l.components).every((l,et)=>isArgOfType(Object.values(c)[et],l));if(/^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(eo))return"number"===et||"bigint"===et;if(/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/.test(eo))return"string"===et||c instanceof Uint8Array;if(/[a-z]+[1-9]{0,3}(\[[0-9]{0,}\])+$/.test(eo))return Array.isArray(c)&&c.every(c=>isArgOfType(c,{...l,type:eo.replace(/(\[[0-9]{0,}\])$/,"")}));return!1}}(l,eo)});if(et)return c}return eh[0]}}},39803:function(c,l,et){"use strict";et.d(l,{K:function(){return getAddress},x:function(){return checksumAddress}});var eo=et(21485),es=et(56728),ec=et(55852),el=et(87364);function checksumAddress(c,l){let et=l?`${l}${c.toLowerCase()}`:c.substring(2).toLowerCase(),eo=(0,ec.w)((0,es.qX)(et),"bytes"),el=(l?et.substring(`${l}0x`.length):et).split("");for(let c=0;c<40;c+=2)eo[c>>1]>>4>=8&&el[c]&&(el[c]=el[c].toUpperCase()),(15&eo[c>>1])>=8&&el[c+1]&&(el[c+1]=el[c+1].toUpperCase());return`0x${el.join("")}`}function getAddress(c,l){if(!(0,el.U)(c))throw new eo.b({address:c});return checksumAddress(c,l)}},87364:function(c,l,et){"use strict";et.d(l,{U:function(){return isAddress}});let eo=/^0x[a-fA-F0-9]{40}$/;function isAddress(c){return eo.test(c)}},35215:function(c,l,et){"use strict";et.d(l,{n:function(){return buildRequest},y:function(){return isDeterministicError}});var eo=et(95950),es=et(20722),ec=et(48519),el=et(36063);let isDeterministicError=c=>"code"in c?-1!==c.code&&-32004!==c.code&&-32005!==c.code&&-32042!==c.code&&-32603!==c.code:c instanceof es.Gg&&!!c.status&&403!==c.status&&408!==c.status&&413!==c.status&&429!==c.status&&500!==c.status&&502!==c.status&&503!==c.status&&504!==c.status;function buildRequest(c,{retryDelay:l=150,retryCount:et=3}={}){return async ed=>(0,el.J)(async()=>{try{return await c(ed)}catch(c){switch(c.code){case ec.s7.code:throw new ec.s7(c);case ec.B.code:throw new ec.B(c);case ec.LX.code:throw new ec.LX(c);case ec.nY.code:throw new ec.nY(c);case ec.XS.code:throw new ec.XS(c);case ec.yR.code:throw new ec.yR(c);case ec.Og.code:throw new ec.Og(c);case ec.pT.code:throw new ec.pT(c);case ec.KB.code:throw new ec.KB(c);case ec.gS.code:throw new ec.gS(c);case ec.Pv.code:throw new ec.Pv(c);case ec.GD.code:throw new ec.GD(c);case ec.ab.code:throw new ec.ab(c);case ec.PE.code:throw new ec.PE(c);case ec.Ts.code:throw new ec.Ts(c);case ec.u5.code:throw new ec.u5(c);case ec.I0.code:throw new ec.I0(c);case ec.x3.code:throw new ec.x3(c);case 5e3:throw new ec.ab(c);default:if(c instanceof eo.G)throw c;throw new ec.ir(c)}}},{delay:({count:c,error:et})=>{if(et&&et instanceof es.Gg){let c=et?.headers?.get("Retry-After");if(c?.match(/\d/))return 1e3*parseInt(c)}return~~(1<!isDeterministicError(c)})}},42168:function(c,l,et){"use strict";et.d(l,{LI:function(){return getChainContractAddress},ax:function(){return defineChain},qg:function(){return assertCurrentChain}});var eo=et(27878);function assertCurrentChain({chain:c,currentChainId:l}){if(!c)throw new eo.Bk;if(l!==c.id)throw new eo.Yl({chain:c,currentChainId:l})}function defineChain(c,l={}){let{fees:et=c.fees,formatters:eo=c.formatters,serializers:es=c.serializers}=l;return{...c,fees:et,formatters:eo,serializers:es}}function getChainContractAddress({blockNumber:c,chain:l,contract:et}){let es=l?.contracts?.[et];if(!es)throw new eo.mm({chain:l,contract:{name:et}});if(c&&es.blockCreated&&es.blockCreated>c)throw new eo.mm({blockNumber:c,chain:l,contract:{name:et,blockCreated:es.blockCreated}});return es.address}},69809:function(c,l,et){"use strict";function concat(c){return"string"==typeof c[0]?concatHex(c):function(c){let l=0;for(let et of c)l+=et.length;let et=new Uint8Array(l),eo=0;for(let l of c)et.set(l,eo),eo+=l.length;return et}(c)}function concatHex(c){return`0x${c.reduce((c,l)=>c+l.replace("0x",""),"")}`}et.d(l,{SM:function(){return concatHex},zo:function(){return concat}})},45008:function(c,l,et){"use strict";function isHex(c,{strict:l=!0}={}){return!!c&&"string"==typeof c&&(l?/^0x[0-9a-fA-F]*$/.test(c):c.startsWith("0x"))}et.d(l,{v:function(){return isHex}})},99725:function(c,l,et){"use strict";et.d(l,{gc:function(){return padHex},vk:function(){return pad}});var eo=et(741);function pad(c,{dir:l,size:et=32}={}){return"string"==typeof c?padHex(c,{dir:l,size:et}):function(c,{dir:l,size:et=32}={}){if(null===et)return c;if(c.length>et)throw new eo.$({size:c.length,targetSize:et,type:"bytes"});let es=new Uint8Array(et);for(let eo=0;eo2*et)throw new eo.$({size:Math.ceil(es.length/2),targetSize:et,type:"hex"});return`0x${es["right"===l?"padEnd":"padStart"](2*et,"0")}`}},39868:function(c,l,et){"use strict";et.d(l,{d:function(){return size}});var eo=et(45008);function size(c){return(0,eo.v)(c,{strict:!1})?Math.ceil((c.length-2)/2):c.length}},72619:function(c,l,et){"use strict";et.d(l,{tP:function(){return slice}});var eo=et(741),es=et(45008),ec=et(39868);function slice(c,l,et,{strict:eo}={}){return(0,es.v)(c,{strict:!1})?function(c,l,et,{strict:eo}={}){assertStartOffset(c,l);let es=`0x${c.replace("0x","").slice((l??0)*2,(et??c.length)*2)}`;return eo&&assertEndOffset(es,l,et),es}(c,l,et,{strict:eo}):function(c,l,et,{strict:eo}={}){assertStartOffset(c,l);let es=c.slice(l,et);return eo&&assertEndOffset(es,l,et),es}(c,l,et,{strict:eo})}function assertStartOffset(c,l){if("number"==typeof l&&l>0&&l>(0,ec.d)(c)-1)throw new eo.m({offset:l,position:"start",size:(0,ec.d)(c)})}function assertEndOffset(c,l,et){if("number"==typeof l&&"number"==typeof et&&(0,ec.d)(c)!==et-l)throw new eo.m({offset:et,position:"end",size:(0,ec.d)(c)})}},94973:function(c,l,et){"use strict";function trim(c,{dir:l="left"}={}){let et="string"==typeof c?c.replace("0x",""):c,eo=0;for(let c=0;cl)throw new eo.M6({givenSize:(0,es.d)(c),maxSize:l})}function hexToBigInt(c,l={}){let{signed:et}=l;l.size&&assertSize(c,{size:l.size});let eo=BigInt(c);if(!et)return eo;let es=(c.length-2)/2,ec=(1n<<8n*BigInt(es)-1n)-1n;return eo<=ec?eo:eo-BigInt(`0x${"f".padStart(2*es,"f")}`)-1n}function hexToBool(c,l={}){let et=c;if(l.size&&(assertSize(et,{size:l.size}),et=(0,ec.f)(et)),"0x00"===(0,ec.f)(et))return!1;if("0x01"===(0,ec.f)(et))return!0;throw new eo.Cd(et)}function hexToNumber(c,l={}){return Number(hexToBigInt(c,l))}function hexToString(c,l={}){let et=(0,el.nr)(c);return l.size&&(assertSize(et,{size:l.size}),et=(0,ec.f)(et,{dir:"right"})),new TextDecoder().decode(et)}},56728:function(c,l,et){"use strict";et.d(l,{O0:function(){return toBytes},nr:function(){return hexToBytes},qX:function(){return stringToBytes}});var eo=et(95950),es=et(45008),ec=et(99725),el=et(30838),ed=et(21693);let eh=new TextEncoder;function toBytes(c,l={}){return"number"==typeof c||"bigint"==typeof c?function(c,l){let et=(0,ed.eC)(c,l);return hexToBytes(et)}(c,l):"boolean"==typeof c?function(c,l={}){let et=new Uint8Array(1);return(et[0]=Number(c),"number"==typeof l.size)?((0,el.Yf)(et,{size:l.size}),(0,ec.vk)(et,{size:l.size})):et}(c,l):(0,es.v)(c)?hexToBytes(c,l):stringToBytes(c,l)}let ef={zero:48,nine:57,A:65,F:70,a:97,f:102};function charCodeToBase16(c){return c>=ef.zero&&c<=ef.nine?c-ef.zero:c>=ef.A&&c<=ef.F?c-(ef.A-10):c>=ef.a&&c<=ef.f?c-(ef.a-10):void 0}function hexToBytes(c,l={}){let et=c;l.size&&((0,el.Yf)(et,{size:l.size}),et=(0,ec.vk)(et,{dir:"right",size:l.size}));let es=et.slice(2);es.length%2&&(es=`0${es}`);let ed=es.length/2,eh=new Uint8Array(ed);for(let c=0,l=0;cl.toString(16).padStart(2,"0"));function toHex(c,l={}){return"number"==typeof c||"bigint"==typeof c?numberToHex(c,l):"string"==typeof c?stringToHex(c,l):"boolean"==typeof c?boolToHex(c,l):bytesToHex(c,l)}function boolToHex(c,l={}){let et=`0x${Number(c)}`;return"number"==typeof l.size?((0,ec.Yf)(et,{size:l.size}),(0,es.vk)(et,{size:l.size})):et}function bytesToHex(c,l={}){let et="";for(let l=0;let||edc.code===es.M_.code);if(ec instanceof eo.G)return new es.M_({cause:c,message:ec.details});if(es.M_.nodeMessage.test(et))return new es.M_({cause:c,message:c.details});if(es.Hh.nodeMessage.test(et))return new es.Hh({cause:c,maxFeePerGas:l?.maxFeePerGas});if(es.G$.nodeMessage.test(et))return new es.G$({cause:c,maxFeePerGas:l?.maxFeePerGas});if(es.ZI.nodeMessage.test(et))return new es.ZI({cause:c,nonce:l?.nonce});if(es.vU.nodeMessage.test(et))return new es.vU({cause:c,nonce:l?.nonce});if(es.se.nodeMessage.test(et))return new es.se({cause:c,nonce:l?.nonce});else if(es.C_.nodeMessage.test(et))return new es.C_({cause:c});else if(es.WF.nodeMessage.test(et))return new es.WF({cause:c,gas:l?.gas});else if(es.dR.nodeMessage.test(et))return new es.dR({cause:c,gas:l?.gas});else if(es.pZ.nodeMessage.test(et))return new es.pZ({cause:c});else if(es.cs.nodeMessage.test(et))return new es.cs({cause:c,maxFeePerGas:l?.maxFeePerGas,maxPriorityFeePerGas:l?.maxPriorityFeePerGas});return new es.cj({cause:c})}},78723:function(c,l,et){"use strict";et.d(l,{Z:function(){return formatBlock}});var eo=et(52017);function formatBlock(c){let l=c.transactions?.map(c=>"string"==typeof c?c:eo.Tr(c));return{...c,baseFeePerGas:c.baseFeePerGas?BigInt(c.baseFeePerGas):null,difficulty:c.difficulty?BigInt(c.difficulty):void 0,gasLimit:c.gasLimit?BigInt(c.gasLimit):void 0,gasUsed:c.gasUsed?BigInt(c.gasUsed):void 0,hash:c.hash?c.hash:null,logsBloom:c.logsBloom?c.logsBloom:null,nonce:c.nonce?c.nonce:null,number:c.number?BigInt(c.number):null,size:c.size?BigInt(c.size):void 0,timestamp:c.timestamp?BigInt(c.timestamp):void 0,transactions:l,totalDifficulty:c.totalDifficulty?BigInt(c.totalDifficulty):null}}},21028:function(c,l,et){"use strict";function extract(c,{format:l}){if(!l)return{};let et=Object.keys(l({}));return et.reduce((l,et)=>(c?.hasOwnProperty(et)&&(l[et]=c[et]),l),{})}et.d(l,{K:function(){return extract}})},52017:function(c,l,et){"use strict";et.d(l,{Tr:function(){return formatTransaction},c8:function(){return es}});var eo=et(30838);let es={"0x0":"legacy","0x1":"eip2930","0x2":"eip1559"};function formatTransaction(c){let l={...c,blockHash:c.blockHash?c.blockHash:null,blockNumber:c.blockNumber?BigInt(c.blockNumber):null,chainId:c.chainId?(0,eo.ly)(c.chainId):void 0,gas:c.gas?BigInt(c.gas):void 0,gasPrice:c.gasPrice?BigInt(c.gasPrice):void 0,maxFeePerGas:c.maxFeePerGas?BigInt(c.maxFeePerGas):void 0,maxPriorityFeePerGas:c.maxPriorityFeePerGas?BigInt(c.maxPriorityFeePerGas):void 0,nonce:c.nonce?(0,eo.ly)(c.nonce):void 0,to:c.to?c.to:null,transactionIndex:c.transactionIndex?Number(c.transactionIndex):null,type:c.type?es[c.type]:void 0,typeHex:c.type?c.type:void 0,value:c.value?BigInt(c.value):void 0,v:c.v?BigInt(c.v):void 0};return"legacy"===l.type&&(delete l.accessList,delete l.maxFeePerGas,delete l.maxPriorityFeePerGas),"eip2930"===l.type&&(delete l.maxFeePerGas,delete l.maxPriorityFeePerGas),l}},86868:function(c,l,et){"use strict";et.d(l,{tG:function(){return formatTransactionRequest}});var eo=et(21693);let es={legacy:"0x0",eip2930:"0x1",eip1559:"0x2"};function formatTransactionRequest(c){return{...c,gas:void 0!==c.gas?(0,eo.eC)(c.gas):void 0,gasPrice:void 0!==c.gasPrice?(0,eo.eC)(c.gasPrice):void 0,maxFeePerGas:void 0!==c.maxFeePerGas?(0,eo.eC)(c.maxFeePerGas):void 0,maxPriorityFeePerGas:void 0!==c.maxPriorityFeePerGas?(0,eo.eC)(c.maxPriorityFeePerGas):void 0,nonce:void 0!==c.nonce?(0,eo.eC)(c.nonce):void 0,type:void 0!==c.type?es[c.type]:void 0,value:void 0!==c.value?(0,eo.eC)(c.value):void 0}}},77688:function(c,l,et){"use strict";et.d(l,{e:function(){return getEventSelector}});var eo=et(56728),es=et(86933);let getEventSignature=c=>(0,es.r)(c);var ec=et(55852);let hash=c=>(0,ec.w)((0,eo.O0)(c)),getEventSelector=c=>hash(getEventSignature(c))},33655:function(c,l,et){"use strict";et.d(l,{o:function(){return getFunctionSelector}});var eo=et(72619),es=et(56728),ec=et(86933),el=et(55852);let hash=c=>(0,el.w)((0,es.O0)(c)),getFunctionSelector=c=>(0,eo.tP)(hash((0,ec.r)(c)),0,4)},86933:function(c,l,et){"use strict";et.d(l,{r:function(){return getFunctionSignature}});var eo=et(40928);let es=/((function|event)\s)?(.*)(\((.*)\))/;function extractFunctionParts(c){let l=c.match(es),et=l?.[2]||void 0,eo=l?.[3],ec=l?.[5]||void 0;return{type:et,name:eo,params:ec}}let getFunctionSignature=c=>{if("string"==typeof c){let l=extractFunctionParts(c).name,et=function(c){let l=extractFunctionParts(c).params,et=l?.split(",").map(c=>c.trim().split(" "));return et?.map(c=>({type:c[0],name:"indexed"===c[1]?c[2]:c[1],..."indexed"===c[1]?{indexed:!0}:{}}))}(c)||[];return`${l}(${et.map(({type:c})=>c).join(",")})`}return(0,eo.t)(c)}},55852:function(c,l,et){"use strict";function number(c){if(!Number.isSafeInteger(c)||c<0)throw Error(`Wrong positive integer: ${c}`)}function bytes(c,...l){if(!(c instanceof Uint8Array))throw Error("Expected Uint8Array");if(l.length>0&&!l.includes(c.length))throw Error(`Expected Uint8Array of length ${l}, not of length=${c.length}`)}function exists(c,l=!0){if(c.destroyed)throw Error("Hash instance has been destroyed");if(l&&c.finished)throw Error("Hash#digest() has already been called")}et.d(l,{w:function(){return keccak256}});let eo=BigInt(4294967296-1),es=BigInt(32),rotlSH=(c,l,et)=>c<>>32-et,rotlSL=(c,l,et)=>l<>>32-et,rotlBH=(c,l,et)=>l<>>64-et,rotlBL=(c,l,et)=>c<>>64-et,u8a=c=>c instanceof Uint8Array,u32=c=>new Uint32Array(c.buffer,c.byteOffset,Math.floor(c.byteLength/4)),ec=68===new Uint8Array(new Uint32Array([287454020]).buffer)[0];if(!ec)throw Error("Non little-endian hardware is not supported");function toBytes(c){if("string"==typeof c&&(c=function(c){if("string"!=typeof c)throw Error(`utf8ToBytes expected string, got ${typeof c}`);return new Uint8Array(new TextEncoder().encode(c))}(c)),!u8a(c))throw Error(`expected Uint8Array, got ${typeof c}`);return c}let Hash=class Hash{clone(){return this._cloneInto()}};let[el,ed,eh]=[[],[],[]],ef=BigInt(0),ep=BigInt(1),eg=BigInt(2),em=BigInt(7),eb=BigInt(256),ey=BigInt(113);for(let c=0,l=ep,et=1,eo=0;c<24;c++){[et,eo]=[eo,(2*et+3*eo)%5],el.push(2*(5*eo+et)),ed.push((c+1)*(c+2)/2%64);let es=ef;for(let c=0;c<7;c++)(l=(l<>em)*ey)%eb)&eg&&(es^=ep<<(ep<>es&eo)}:{h:0|Number(c>>es&eo),l:0|Number(c&eo)}}(c[el],l);[et[el],ec[el]]=[ed,eh]}return[et,ec]}(eh,!0),rotlH=(c,l,et)=>et>32?rotlBH(c,l,et):rotlSH(c,l,et),rotlL=(c,l,et)=>et>32?rotlBL(c,l,et):rotlSL(c,l,et);let Keccak=class Keccak extends Hash{constructor(c,l,et,eo=!1,es=24){if(super(),this.blockLen=c,this.suffix=l,this.outputLen=et,this.enableXOF=eo,this.rounds=es,this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,number(et),0>=this.blockLen||this.blockLen>=200)throw Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=u32(this.state)}keccak(){!function(c,l=24){let et=new Uint32Array(10);for(let eo=24-l;eo<24;eo++){for(let l=0;l<10;l++)et[l]=c[l]^c[l+10]^c[l+20]^c[l+30]^c[l+40];for(let l=0;l<10;l+=2){let eo=(l+8)%10,es=(l+2)%10,ec=et[es],el=et[es+1],ed=rotlH(ec,el,1)^et[eo],eh=rotlL(ec,el,1)^et[eo+1];for(let et=0;et<50;et+=10)c[l+et]^=ed,c[l+et+1]^=eh}let l=c[2],es=c[3];for(let et=0;et<24;et++){let eo=ed[et],ec=rotlH(l,es,eo),eh=rotlL(l,es,eo),ef=el[et];l=c[ef],es=c[ef+1],c[ef]=ec,c[ef+1]=eh}for(let l=0;l<50;l+=10){for(let eo=0;eo<10;eo++)et[eo]=c[l+eo];for(let eo=0;eo<10;eo++)c[l+eo]^=~et[(eo+2)%10]&et[(eo+4)%10]}c[0]^=e_[eo],c[1]^=ew[eo]}et.fill(0)}(this.state32,this.rounds),this.posOut=0,this.pos=0}update(c){exists(this);let{blockLen:l,state:et}=this;c=toBytes(c);let eo=c.length;for(let es=0;es=et&&this.keccak();let ec=Math.min(et-this.posOut,es-eo);c.set(l.subarray(this.posOut,this.posOut+ec),eo),this.posOut+=ec,eo+=ec}return c}xofInto(c){if(!this.enableXOF)throw Error("XOF is not possible for this instance");return this.writeInto(c)}xof(c){return number(c),this.xofInto(new Uint8Array(c))}digestInto(c){if(!function(c,l){bytes(c);let et=l.outputLen;if(c.lengthc().update(toBytes(l)).digest(),l=c();return hashC.outputLen=l.outputLen,hashC.blockLen=l.blockLen,hashC.create=()=>c(),hashC}(()=>new Keccak(136,1,32));var eS=et(45008),ex=et(56728),ek=et(21693);function keccak256(c,l){let et=eE((0,eS.v)(c,{strict:!1})?(0,ex.O0)(c):c);return"bytes"===(l||"hex")?et:(0,ek.NC)(et)}},33668:function(c,l,et){"use strict";et.d(l,{S:function(){return createBatchScheduler}});let eo=new Map;function createBatchScheduler({fn:c,id:l,shouldSplitBatch:et,wait:es=0}){let exec=async()=>{let l=getScheduler();flush();let et=l.map(({args:c})=>c);0!==et.length&&c(et).then(c=>{l.forEach(({pendingPromise:l},et)=>l.resolve?.([c[et],c]))}).catch(c=>{l.forEach(({pendingPromise:l})=>l.reject?.(c))})},flush=()=>eo.delete(l),getBatchedArgs=()=>getScheduler().map(({args:c})=>c),getScheduler=()=>eo.get(l)||[],setScheduler=c=>eo.set(l,[...getScheduler(),c]);return{flush,async schedule(c){let l={},eo=new Promise((c,et)=>{l.resolve=c,l.reject=et}),ec=et?.([...getBatchedArgs(),c]);ec&&exec();let el=getScheduler().length>0;return el?setScheduler({args:c,pendingPromise:l}):(setScheduler({args:c,pendingPromise:l}),setTimeout(exec,es)),eo}}}},36063:function(c,l,et){"use strict";et.d(l,{J:function(){return withRetry}});var eo=et(21810);function withRetry(c,{delay:l=100,retryCount:et=2,shouldRetry:es=()=>!0}={}){return new Promise((ec,el)=>{let attemptRetry=async({count:ed=0}={})=>{let retry=async({error:c})=>{let et="function"==typeof l?l({count:ed,error:c}):l;et&&await (0,eo.D)(et),attemptRetry({count:ed+1})};try{let l=await c();ec(l)}catch(c){if(edJSON.stringify(c,(c,et)=>{let eo="bigint"==typeof et?et.toString():et;return"function"==typeof l?l(c,eo):eo},et)},2445:function(c,l,et){"use strict";et.d(l,{F:function(){return assertRequest}});var eo=et(4832),es=et(21485),ec=et(40009),el=et(44818),ed=et(87364);function assertRequest(c){let{account:l,gasPrice:et,maxFeePerGas:eh,maxPriorityFeePerGas:ef,to:ep}=c,eg=l?(0,eo.T)(l):void 0;if(eg&&!(0,ed.U)(eg.address))throw new es.b({address:eg.address});if(ep&&!(0,ed.U)(ep))throw new es.b({address:ep});if(void 0!==et&&(void 0!==eh||void 0!==ef))throw new el.xY;if(eh&&eh>2n**256n-1n)throw new ec.Hh({maxFeePerGas:eh});if(ef&&eh&&ef>eh)throw new ec.cs({maxFeePerGas:eh,maxPriorityFeePerGas:ef})}},29578:function(c,l,et){"use strict";et.d(l,{cj:function(){return getTypesForEIP712Domain},iC:function(){return validateTypedData}});var eo=et(71878),es=et(21485),ec=et(87364),el=et(39868),ed=et(21693);let eh=/^bytes([1-9]|1[0-9]|2[0-9]|3[0-2])?$/,ef=/^(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 validateTypedData({domain:c,message:l,primaryType:et,types:ep}){let validateData=(c,l)=>{for(let et of c){let{name:c,type:eg}=et,em=l[c],eb=eg.match(ef);if(eb&&("number"==typeof em||"bigint"==typeof em)){let[c,l,et]=eb;(0,ed.eC)(em,{signed:"int"===l,size:parseInt(et)/8})}if("address"===eg&&"string"==typeof em&&!(0,ec.U)(em))throw new es.b({address:em});let ey=eg.match(eh);if(ey){let[c,l]=ey;if(l&&(0,el.d)(em)!==parseInt(l))throw new eo.KY({expectedSize:parseInt(l),givenSize:(0,el.d)(em)})}let e_=ep[eg];e_&&validateData(e_,em)}};if(ep.EIP712Domain&&c&&validateData(ep.EIP712Domain,c),"EIP712Domain"!==et){let c=ep[et];validateData(c,l)}}function getTypesForEIP712Domain({domain:c}){return["string"==typeof c?.name&&{name:"name",type:"string"},c?.version&&{name:"version",type:"string"},"number"==typeof c?.chainId&&{name:"chainId",type:"uint256"},c?.verifyingContract&&{name:"verifyingContract",type:"address"},c?.salt&&{name:"salt",type:"bytes32"}].filter(Boolean)}},79352:function(c,l,et){"use strict";et.d(l,{d:function(){return formatEther}});var eo=et(36238),es=et(16775);function formatEther(c,l="wei"){return(0,es.b)(c,eo.ez[l])}},32421:function(c,l,et){"use strict";et.d(l,{o:function(){return formatGwei}});var eo=et(36238),es=et(16775);function formatGwei(c,l="wei"){return(0,es.b)(c,eo.Zn[l])}},16775:function(c,l,et){"use strict";function formatUnits(c,l){let et=c.toString(),eo=et.startsWith("-");eo&&(et=et.slice(1));let[es,ec]=[(et=et.padStart(l,"0")).slice(0,et.length-l),et.slice(et.length-l)];return ec=ec.replace(/(0+)$/,""),`${eo?"-":""}${es||"0"}${ec?`.${ec}`:""}`}et.d(l,{b:function(){return formatUnits}})},21810:function(c,l,et){"use strict";async function wait(c){return new Promise(l=>setTimeout(l,c))}et.d(l,{D:function(){return wait}})},56926:function(c,l,et){"use strict";let eo;function noop(){}et.d(l,{eM:function(){return WagmiConfig},_g:function(){return createConfig},do:function(){return useContractRead},GG:function(){return useContractWrite},qL:function(){return useDisconnect},BX:function(){return useWaitForTransaction},py:function(){return useWalletClient}});let es="undefined"==typeof window||"Deno"in window;function utils_noop(){}function isValidTimeout(c){return"number"==typeof c&&c>=0&&c!==1/0}function timeUntilStale(c,l){return Math.max(c+(l||0)-Date.now(),0)}function parseQueryArgs(c,l,et){return isQueryKey(c)?"function"==typeof l?{...et,queryKey:c,queryFn:l}:{...l,queryKey:c}:c}function parseMutationArgs(c,l,et){return isQueryKey(c)?"function"==typeof l?{...et,mutationKey:c,mutationFn:l}:{...l,mutationKey:c}:"function"==typeof c?{...l,mutationFn:c}:{...c}}function parseFilterArgs(c,l,et){return isQueryKey(c)?[{...l,queryKey:c},et]:[c||{},l]}function matchQuery(c,l){let{type:et="all",exact:eo,fetchStatus:es,predicate:ec,queryKey:el,stale:ed}=c;if(isQueryKey(el)){if(eo){if(l.queryHash!==hashQueryKeyByOptions(el,l.options))return!1}else{if(!partialDeepEqual(l.queryKey,el))return!1}}if("all"!==et){let c=l.isActive();if("active"===et&&!c||"inactive"===et&&c)return!1}return("boolean"!=typeof ed||l.isStale()===ed)&&(void 0===es||es===l.state.fetchStatus)&&(!ec||!!ec(l))}function matchMutation(c,l){let{exact:et,fetching:eo,predicate:es,mutationKey:ec}=c;if(isQueryKey(ec)){if(!l.options.mutationKey)return!1;if(et){if(hashQueryKey(l.options.mutationKey)!==hashQueryKey(ec))return!1}else{if(!partialDeepEqual(l.options.mutationKey,ec))return!1}}return("boolean"!=typeof eo||"loading"===l.state.status===eo)&&(!es||!!es(l))}function hashQueryKeyByOptions(c,l){let et=(null==l?void 0:l.queryKeyHashFn)||hashQueryKey;return et(c)}function hashQueryKey(c){return JSON.stringify(c,(c,l)=>isPlainObject(l)?Object.keys(l).sort().reduce((c,et)=>(c[et]=l[et],c),{}):l)}function partialDeepEqual(c,l){return c===l||typeof c==typeof l&&!!c&&!!l&&"object"==typeof c&&"object"==typeof l&&!Object.keys(l).some(et=>!partialDeepEqual(c[et],l[et]))}function utils_replaceEqualDeep(c,l){if(c===l)return c;let et=isPlainArray(c)&&isPlainArray(l);if(et||isPlainObject(c)&&isPlainObject(l)){let eo=et?c.length:Object.keys(c).length,es=et?l:Object.keys(l),ec=es.length,el=et?[]:{},ed=0;for(let eo=0;eo{setTimeout(l,c)})}function scheduleMicrotask(c){sleep(0).then(c)}function replaceData(c,l,et){return null!=et.isDataEqual&&et.isDataEqual(c,l)?c:"function"==typeof et.structuralSharing?et.structuralSharing(c,l):!1!==et.structuralSharing?utils_replaceEqualDeep(c,l):l}let ec=console,el=function(){let c=[],l=0,notifyFn=c=>{c()},batchNotifyFn=c=>{c()},schedule=et=>{l?c.push(et):scheduleMicrotask(()=>{notifyFn(et)})},flush=()=>{let l=c;c=[],l.length&&scheduleMicrotask(()=>{batchNotifyFn(()=>{l.forEach(c=>{notifyFn(c)})})})};return{batch:c=>{let et;l++;try{et=c()}finally{--l||flush()}return et},batchCalls:c=>(...l)=>{schedule(()=>{c(...l)})},schedule,setNotifyFunction:c=>{notifyFn=c},setBatchNotifyFunction:c=>{batchNotifyFn=c}}}();let Subscribable=class Subscribable{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(c){let l={listener:c};return this.listeners.add(l),this.onSubscribe(),()=>{this.listeners.delete(l),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}};let ed=new class extends Subscribable{constructor(){super(),this.setup=c=>{if(!es&&window.addEventListener){let listener=()=>c();return window.addEventListener("visibilitychange",listener,!1),window.addEventListener("focus",listener,!1),()=>{window.removeEventListener("visibilitychange",listener),window.removeEventListener("focus",listener)}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var c;null==(c=this.cleanup)||c.call(this),this.cleanup=void 0}}setEventListener(c){var l;this.setup=c,null==(l=this.cleanup)||l.call(this),this.cleanup=c(c=>{"boolean"==typeof c?this.setFocused(c):this.onFocus()})}setFocused(c){let l=this.focused!==c;l&&(this.focused=c,this.onFocus())}onFocus(){this.listeners.forEach(({listener:c})=>{c()})}isFocused(){return"boolean"==typeof this.focused?this.focused:"undefined"==typeof document||[void 0,"visible","prerender"].includes(document.visibilityState)}},eh=["online","offline"],ef=new class extends Subscribable{constructor(){super(),this.setup=c=>{if(!es&&window.addEventListener){let listener=()=>c();return eh.forEach(c=>{window.addEventListener(c,listener,!1)}),()=>{eh.forEach(c=>{window.removeEventListener(c,listener)})}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var c;null==(c=this.cleanup)||c.call(this),this.cleanup=void 0}}setEventListener(c){var l;this.setup=c,null==(l=this.cleanup)||l.call(this),this.cleanup=c(c=>{"boolean"==typeof c?this.setOnline(c):this.onOnline()})}setOnline(c){let l=this.online!==c;l&&(this.online=c,this.onOnline())}onOnline(){this.listeners.forEach(({listener:c})=>{c()})}isOnline(){return"boolean"==typeof this.online?this.online:"undefined"==typeof navigator||void 0===navigator.onLine||navigator.onLine}};function defaultRetryDelay(c){return Math.min(1e3*2**c,3e4)}function canFetch(c){return(null!=c?c:"online")!=="online"||ef.isOnline()}let CancelledError=class CancelledError{constructor(c){this.revert=null==c?void 0:c.revert,this.silent=null==c?void 0:c.silent}};function isCancelledError(c){return c instanceof CancelledError}function createRetryer(c){let l,et,eo,es=!1,ec=0,el=!1,eh=new Promise((c,l)=>{et=c,eo=l}),shouldPause=()=>!ed.isFocused()||"always"!==c.networkMode&&!ef.isOnline(),resolve=eo=>{el||(el=!0,null==c.onSuccess||c.onSuccess(eo),null==l||l(),et(eo))},reject=et=>{el||(el=!0,null==c.onError||c.onError(et),null==l||l(),eo(et))},pause=()=>new Promise(et=>{l=c=>{let l=el||!shouldPause();return l&&et(c),l},null==c.onPause||c.onPause()}).then(()=>{l=void 0,el||null==c.onContinue||c.onContinue()}),run=()=>{let l;if(!el){try{l=c.fn()}catch(c){l=Promise.reject(c)}Promise.resolve(l).then(resolve).catch(l=>{var et,eo;if(el)return;let ed=null!=(et=c.retry)?et:3,eh=null!=(eo=c.retryDelay)?eo:defaultRetryDelay,ef="function"==typeof eh?eh(ec,l):eh,ep=!0===ed||"number"==typeof ed&&ec{if(shouldPause())return pause()}).then(()=>{es?reject(l):run()})})}};return canFetch(c.networkMode)?run():pause().then(run),{promise:eh,cancel:l=>{el||(reject(new CancelledError(l)),null==c.abort||c.abort())},continue:()=>{let c=null==l?void 0:l();return c?eh:Promise.resolve()},cancelRetry:()=>{es=!0},continueRetry:()=>{es=!1}}}let Removable=class Removable{destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),isValidTimeout(this.cacheTime)&&(this.gcTimeout=setTimeout(()=>{this.optionalRemove()},this.cacheTime))}updateCacheTime(c){this.cacheTime=Math.max(this.cacheTime||0,null!=c?c:es?1/0:3e5)}clearGcTimeout(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)}};let Query=class Query extends Removable{constructor(c){super(),this.abortSignalConsumed=!1,this.defaultOptions=c.defaultOptions,this.setOptions(c.options),this.observers=[],this.cache=c.cache,this.logger=c.logger||ec,this.queryKey=c.queryKey,this.queryHash=c.queryHash,this.initialState=c.state||function(c){let l="function"==typeof c.initialData?c.initialData():c.initialData,et=void 0!==l,eo=et?"function"==typeof c.initialDataUpdatedAt?c.initialDataUpdatedAt():c.initialDataUpdatedAt:0;return{data:l,dataUpdateCount:0,dataUpdatedAt:et?null!=eo?eo:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:et?"success":"loading",fetchStatus:"idle"}}(this.options),this.state=this.initialState,this.scheduleGc()}get meta(){return this.options.meta}setOptions(c){this.options={...this.defaultOptions,...c},this.updateCacheTime(this.options.cacheTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||this.cache.remove(this)}setData(c,l){let et=replaceData(this.state.data,c,this.options);return this.dispatch({data:et,type:"success",dataUpdatedAt:null==l?void 0:l.updatedAt,manual:null==l?void 0:l.manual}),et}setState(c,l){this.dispatch({type:"setState",state:c,setStateOptions:l})}cancel(c){var l;let et=this.promise;return null==(l=this.retryer)||l.cancel(c),et?et.then(utils_noop).catch(utils_noop):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.initialState)}isActive(){return this.observers.some(c=>!1!==c.options.enabled)}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(c=>c.getCurrentResult().isStale)}isStaleByTime(c=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!timeUntilStale(this.state.dataUpdatedAt,c)}onFocus(){var c;let l=this.observers.find(c=>c.shouldFetchOnWindowFocus());l&&l.refetch({cancelRefetch:!1}),null==(c=this.retryer)||c.continue()}onOnline(){var c;let l=this.observers.find(c=>c.shouldFetchOnReconnect());l&&l.refetch({cancelRefetch:!1}),null==(c=this.retryer)||c.continue()}addObserver(c){this.observers.includes(c)||(this.observers.push(c),this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:c}))}removeObserver(c){this.observers.includes(c)&&(this.observers=this.observers.filter(l=>l!==c),this.observers.length||(this.retryer&&(this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.scheduleGc()),this.cache.notify({type:"observerRemoved",query:this,observer:c}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.dispatch({type:"invalidate"})}fetch(c,l){var et,eo,es,ec;if("idle"!==this.state.fetchStatus){if(this.state.dataUpdatedAt&&null!=l&&l.cancelRefetch)this.cancel({silent:!0});else if(this.promise)return null==(es=this.retryer)||es.continueRetry(),this.promise}if(c&&this.setOptions(c),!this.options.queryFn){let c=this.observers.find(c=>c.options.queryFn);c&&this.setOptions(c.options)}let el=function(){if("function"==typeof AbortController)return new AbortController}(),ed={queryKey:this.queryKey,pageParam:void 0,meta:this.meta},addSignalProperty=c=>{Object.defineProperty(c,"signal",{enumerable:!0,get:()=>{if(el)return this.abortSignalConsumed=!0,el.signal}})};addSignalProperty(ed);let eh={fetchOptions:l,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>this.options.queryFn?(this.abortSignalConsumed=!1,this.options.queryFn(ed)):Promise.reject("Missing queryFn for queryKey '"+this.options.queryHash+"'")};addSignalProperty(eh),null==(et=this.options.behavior)||et.onFetch(eh),this.revertState=this.state,("idle"===this.state.fetchStatus||this.state.fetchMeta!==(null==(eo=eh.fetchOptions)?void 0:eo.meta))&&this.dispatch({type:"fetch",meta:null==(ec=eh.fetchOptions)?void 0:ec.meta});let onError=c=>{if(isCancelledError(c)&&c.silent||this.dispatch({type:"error",error:c}),!isCancelledError(c)){var l,et,eo,es;null==(l=(et=this.cache.config).onError)||l.call(et,c,this),null==(eo=(es=this.cache.config).onSettled)||eo.call(es,this.state.data,c,this)}this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.retryer=createRetryer({fn:eh.fetchFn,abort:null==el?void 0:el.abort.bind(el),onSuccess:c=>{var l,et,eo,es;if(void 0===c){onError(Error(this.queryHash+" data is undefined"));return}this.setData(c),null==(l=(et=this.cache.config).onSuccess)||l.call(et,c,this),null==(eo=(es=this.cache.config).onSettled)||eo.call(es,c,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1},onError,onFail:(c,l)=>{this.dispatch({type:"failed",failureCount:c,error:l})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:eh.options.retry,retryDelay:eh.options.retryDelay,networkMode:eh.options.networkMode}),this.promise=this.retryer.promise,this.promise}dispatch(c){this.state=(l=>{var et,eo;switch(c.type){case"failed":return{...l,fetchFailureCount:c.failureCount,fetchFailureReason:c.error};case"pause":return{...l,fetchStatus:"paused"};case"continue":return{...l,fetchStatus:"fetching"};case"fetch":return{...l,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null!=(et=c.meta)?et:null,fetchStatus:canFetch(this.options.networkMode)?"fetching":"paused",...!l.dataUpdatedAt&&{error:null,status:"loading"}};case"success":return{...l,data:c.data,dataUpdateCount:l.dataUpdateCount+1,dataUpdatedAt:null!=(eo=c.dataUpdatedAt)?eo:Date.now(),error:null,isInvalidated:!1,status:"success",...!c.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":let es=c.error;if(isCancelledError(es)&&es.revert&&this.revertState)return{...this.revertState,fetchStatus:"idle"};return{...l,error:es,errorUpdateCount:l.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:l.fetchFailureCount+1,fetchFailureReason:es,fetchStatus:"idle",status:"error"};case"invalidate":return{...l,isInvalidated:!0};case"setState":return{...l,...c.state}}})(this.state),el.batch(()=>{this.observers.forEach(l=>{l.onQueryUpdate(c)}),this.cache.notify({query:this,type:"updated",action:c})})}};let QueryCache=class QueryCache extends Subscribable{constructor(c){super(),this.config=c||{},this.queries=[],this.queriesMap={}}build(c,l,et){var eo;let es=l.queryKey,ec=null!=(eo=l.queryHash)?eo:hashQueryKeyByOptions(es,l),el=this.get(ec);return el||(el=new Query({cache:this,logger:c.getLogger(),queryKey:es,queryHash:ec,options:c.defaultQueryOptions(l),state:et,defaultOptions:c.getQueryDefaults(es)}),this.add(el)),el}add(c){this.queriesMap[c.queryHash]||(this.queriesMap[c.queryHash]=c,this.queries.push(c),this.notify({type:"added",query:c}))}remove(c){let l=this.queriesMap[c.queryHash];l&&(c.destroy(),this.queries=this.queries.filter(l=>l!==c),l===c&&delete this.queriesMap[c.queryHash],this.notify({type:"removed",query:c}))}clear(){el.batch(()=>{this.queries.forEach(c=>{this.remove(c)})})}get(c){return this.queriesMap[c]}getAll(){return this.queries}find(c,l){let[et]=parseFilterArgs(c,l);return void 0===et.exact&&(et.exact=!0),this.queries.find(c=>matchQuery(et,c))}findAll(c,l){let[et]=parseFilterArgs(c,l);return Object.keys(et).length>0?this.queries.filter(c=>matchQuery(et,c)):this.queries}notify(c){el.batch(()=>{this.listeners.forEach(({listener:l})=>{l(c)})})}onFocus(){el.batch(()=>{this.queries.forEach(c=>{c.onFocus()})})}onOnline(){el.batch(()=>{this.queries.forEach(c=>{c.onOnline()})})}};let Mutation=class Mutation extends Removable{constructor(c){super(),this.defaultOptions=c.defaultOptions,this.mutationId=c.mutationId,this.mutationCache=c.mutationCache,this.logger=c.logger||ec,this.observers=[],this.state=c.state||mutation_getDefaultState(),this.setOptions(c.options),this.scheduleGc()}setOptions(c){this.options={...this.defaultOptions,...c},this.updateCacheTime(this.options.cacheTime)}get meta(){return this.options.meta}setState(c){this.dispatch({type:"setState",state:c})}addObserver(c){this.observers.includes(c)||(this.observers.push(c),this.clearGcTimeout(),this.mutationCache.notify({type:"observerAdded",mutation:this,observer:c}))}removeObserver(c){this.observers=this.observers.filter(l=>l!==c),this.scheduleGc(),this.mutationCache.notify({type:"observerRemoved",mutation:this,observer:c})}optionalRemove(){this.observers.length||("loading"===this.state.status?this.scheduleGc():this.mutationCache.remove(this))}continue(){var c,l;return null!=(c=null==(l=this.retryer)?void 0:l.continue())?c:this.execute()}async execute(){var c,l,et,eo,es,ec,el,ed,eh,ef,ep,eg,em,eb,ey,e_,ew,eE,eS,ex;let ek="loading"===this.state.status;try{if(!ek){this.dispatch({type:"loading",variables:this.options.variables}),await (null==(eh=(ef=this.mutationCache.config).onMutate)?void 0:eh.call(ef,this.state.variables,this));let c=await (null==(ep=(eg=this.options).onMutate)?void 0:ep.call(eg,this.state.variables));c!==this.state.context&&this.dispatch({type:"loading",context:c,variables:this.state.variables})}let em=await (()=>{var c;return this.retryer=createRetryer({fn:()=>this.options.mutationFn?this.options.mutationFn(this.state.variables):Promise.reject("No mutationFn found"),onFail:(c,l)=>{this.dispatch({type:"failed",failureCount:c,error:l})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:null!=(c=this.options.retry)?c:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.retryer.promise})();return await (null==(c=(l=this.mutationCache.config).onSuccess)?void 0:c.call(l,em,this.state.variables,this.state.context,this)),await (null==(et=(eo=this.options).onSuccess)?void 0:et.call(eo,em,this.state.variables,this.state.context)),await (null==(es=(ec=this.mutationCache.config).onSettled)?void 0:es.call(ec,em,null,this.state.variables,this.state.context,this)),await (null==(el=(ed=this.options).onSettled)?void 0:el.call(ed,em,null,this.state.variables,this.state.context)),this.dispatch({type:"success",data:em}),em}catch(c){try{throw await (null==(em=(eb=this.mutationCache.config).onError)?void 0:em.call(eb,c,this.state.variables,this.state.context,this)),await (null==(ey=(e_=this.options).onError)?void 0:ey.call(e_,c,this.state.variables,this.state.context)),await (null==(ew=(eE=this.mutationCache.config).onSettled)?void 0:ew.call(eE,void 0,c,this.state.variables,this.state.context,this)),await (null==(eS=(ex=this.options).onSettled)?void 0:eS.call(ex,void 0,c,this.state.variables,this.state.context)),c}finally{this.dispatch({type:"error",error:c})}}}dispatch(c){this.state=(l=>{switch(c.type){case"failed":return{...l,failureCount:c.failureCount,failureReason:c.error};case"pause":return{...l,isPaused:!0};case"continue":return{...l,isPaused:!1};case"loading":return{...l,context:c.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!canFetch(this.options.networkMode),status:"loading",variables:c.variables};case"success":return{...l,data:c.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...l,data:void 0,error:c.error,failureCount:l.failureCount+1,failureReason:c.error,isPaused:!1,status:"error"};case"setState":return{...l,...c.state}}})(this.state),el.batch(()=>{this.observers.forEach(l=>{l.onMutationUpdate(c)}),this.mutationCache.notify({mutation:this,type:"updated",action:c})})}};function mutation_getDefaultState(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0}}let MutationCache=class MutationCache extends Subscribable{constructor(c){super(),this.config=c||{},this.mutations=[],this.mutationId=0}build(c,l,et){let eo=new Mutation({mutationCache:this,logger:c.getLogger(),mutationId:++this.mutationId,options:c.defaultMutationOptions(l),state:et,defaultOptions:l.mutationKey?c.getMutationDefaults(l.mutationKey):void 0});return this.add(eo),eo}add(c){this.mutations.push(c),this.notify({type:"added",mutation:c})}remove(c){this.mutations=this.mutations.filter(l=>l!==c),this.notify({type:"removed",mutation:c})}clear(){el.batch(()=>{this.mutations.forEach(c=>{this.remove(c)})})}getAll(){return this.mutations}find(c){return void 0===c.exact&&(c.exact=!0),this.mutations.find(l=>matchMutation(c,l))}findAll(c){return this.mutations.filter(l=>matchMutation(c,l))}notify(c){el.batch(()=>{this.listeners.forEach(({listener:l})=>{l(c)})})}resumePausedMutations(){var c;return this.resuming=(null!=(c=this.resuming)?c:Promise.resolve()).then(()=>{let c=this.mutations.filter(c=>c.state.isPaused);return el.batch(()=>c.reduce((c,l)=>c.then(()=>l.continue().catch(utils_noop)),Promise.resolve()))}).then(()=>{this.resuming=void 0}),this.resuming}};function getNextPageParam(c,l){return null==c.getNextPageParam?void 0:c.getNextPageParam(l[l.length-1],l)}let QueryClient=class QueryClient{constructor(c={}){this.queryCache=c.queryCache||new QueryCache,this.mutationCache=c.mutationCache||new MutationCache,this.logger=c.logger||ec,this.defaultOptions=c.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[],this.mountCount=0}mount(){this.mountCount++,1===this.mountCount&&(this.unsubscribeFocus=ed.subscribe(()=>{ed.isFocused()&&(this.resumePausedMutations(),this.queryCache.onFocus())}),this.unsubscribeOnline=ef.subscribe(()=>{ef.isOnline()&&(this.resumePausedMutations(),this.queryCache.onOnline())}))}unmount(){var c,l;this.mountCount--,0===this.mountCount&&(null==(c=this.unsubscribeFocus)||c.call(this),this.unsubscribeFocus=void 0,null==(l=this.unsubscribeOnline)||l.call(this),this.unsubscribeOnline=void 0)}isFetching(c,l){let[et]=parseFilterArgs(c,l);return et.fetchStatus="fetching",this.queryCache.findAll(et).length}isMutating(c){return this.mutationCache.findAll({...c,fetching:!0}).length}getQueryData(c,l){var et;return null==(et=this.queryCache.find(c,l))?void 0:et.state.data}ensureQueryData(c,l,et){let eo=parseQueryArgs(c,l,et),es=this.getQueryData(eo.queryKey);return es?Promise.resolve(es):this.fetchQuery(eo)}getQueriesData(c){return this.getQueryCache().findAll(c).map(({queryKey:c,state:l})=>{let et=l.data;return[c,et]})}setQueryData(c,l,et){let eo=this.queryCache.find(c),es=null==eo?void 0:eo.state.data,ec="function"==typeof l?l(es):l;if(void 0===ec)return;let el=parseQueryArgs(c),ed=this.defaultQueryOptions(el);return this.queryCache.build(this,ed).setData(ec,{...et,manual:!0})}setQueriesData(c,l,et){return el.batch(()=>this.getQueryCache().findAll(c).map(({queryKey:c})=>[c,this.setQueryData(c,l,et)]))}getQueryState(c,l){var et;return null==(et=this.queryCache.find(c,l))?void 0:et.state}removeQueries(c,l){let[et]=parseFilterArgs(c,l),eo=this.queryCache;el.batch(()=>{eo.findAll(et).forEach(c=>{eo.remove(c)})})}resetQueries(c,l,et){let[eo,es]=parseFilterArgs(c,l,et),ec=this.queryCache,ed={type:"active",...eo};return el.batch(()=>(ec.findAll(eo).forEach(c=>{c.reset()}),this.refetchQueries(ed,es)))}cancelQueries(c,l,et){let[eo,es={}]=parseFilterArgs(c,l,et);void 0===es.revert&&(es.revert=!0);let ec=el.batch(()=>this.queryCache.findAll(eo).map(c=>c.cancel(es)));return Promise.all(ec).then(utils_noop).catch(utils_noop)}invalidateQueries(c,l,et){let[eo,es]=parseFilterArgs(c,l,et);return el.batch(()=>{var c,l;if(this.queryCache.findAll(eo).forEach(c=>{c.invalidate()}),"none"===eo.refetchType)return Promise.resolve();let et={...eo,type:null!=(c=null!=(l=eo.refetchType)?l:eo.type)?c:"active"};return this.refetchQueries(et,es)})}refetchQueries(c,l,et){let[eo,es]=parseFilterArgs(c,l,et),ec=el.batch(()=>this.queryCache.findAll(eo).filter(c=>!c.isDisabled()).map(c=>{var l;return c.fetch(void 0,{...es,cancelRefetch:null==(l=null==es?void 0:es.cancelRefetch)||l,meta:{refetchPage:eo.refetchPage}})})),ed=Promise.all(ec).then(utils_noop);return null!=es&&es.throwOnError||(ed=ed.catch(utils_noop)),ed}fetchQuery(c,l,et){let eo=parseQueryArgs(c,l,et),es=this.defaultQueryOptions(eo);void 0===es.retry&&(es.retry=!1);let ec=this.queryCache.build(this,es);return ec.isStaleByTime(es.staleTime)?ec.fetch(es):Promise.resolve(ec.state.data)}prefetchQuery(c,l,et){return this.fetchQuery(c,l,et).then(utils_noop).catch(utils_noop)}fetchInfiniteQuery(c,l,et){let eo=parseQueryArgs(c,l,et);return eo.behavior={onFetch:c=>{c.fetchFn=()=>{var l,et,eo,es,ec,el,ed;let eh;let ef=null==(l=c.fetchOptions)?void 0:null==(et=l.meta)?void 0:et.refetchPage,ep=null==(eo=c.fetchOptions)?void 0:null==(es=eo.meta)?void 0:es.fetchMore,eg=null==ep?void 0:ep.pageParam,em=(null==ep?void 0:ep.direction)==="forward",eb=(null==ep?void 0:ep.direction)==="backward",ey=(null==(ec=c.state.data)?void 0:ec.pages)||[],e_=(null==(el=c.state.data)?void 0:el.pageParams)||[],ew=e_,eE=!1,addSignalProperty=l=>{Object.defineProperty(l,"signal",{enumerable:!0,get:()=>{var l,et;return null!=(l=c.signal)&&l.aborted?eE=!0:null==(et=c.signal)||et.addEventListener("abort",()=>{eE=!0}),c.signal}})},eS=c.options.queryFn||(()=>Promise.reject("Missing queryFn for queryKey '"+c.options.queryHash+"'")),buildNewPages=(c,l,et,eo)=>(ew=eo?[l,...ew]:[...ew,l],eo?[et,...c]:[...c,et]),fetchPage=(l,et,eo,es)=>{if(eE)return Promise.reject("Cancelled");if(void 0===eo&&!et&&l.length)return Promise.resolve(l);let ec={queryKey:c.queryKey,pageParam:eo,meta:c.options.meta};addSignalProperty(ec);let el=eS(ec),ed=Promise.resolve(el).then(c=>buildNewPages(l,eo,c,es));return ed};if(ey.length){if(em){let l=void 0!==eg,et=l?eg:getNextPageParam(c.options,ey);eh=fetchPage(ey,l,et)}else if(eb){let l=void 0!==eg,et=l?eg:null==(ed=c.options).getPreviousPageParam?void 0:ed.getPreviousPageParam(ey[0],ey);eh=fetchPage(ey,l,et,!0)}else{ew=[];let l=void 0===c.options.getNextPageParam,et=!ef||!ey[0]||ef(ey[0],0,ey);eh=et?fetchPage([],l,e_[0]):Promise.resolve(buildNewPages([],e_[0],ey[0]));for(let et=1;et{let es=!ef||!ey[et]||ef(ey[et],et,ey);if(es){let es=l?e_[et]:getNextPageParam(c.options,eo);return fetchPage(eo,l,es)}return Promise.resolve(buildNewPages(eo,e_[et],ey[et]))})}}else eh=fetchPage([]);let ex=eh.then(c=>({pages:c,pageParams:ew}));return ex}}},this.fetchQuery(eo)}prefetchInfiniteQuery(c,l,et){return this.fetchInfiniteQuery(c,l,et).then(utils_noop).catch(utils_noop)}resumePausedMutations(){return this.mutationCache.resumePausedMutations()}getQueryCache(){return this.queryCache}getMutationCache(){return this.mutationCache}getLogger(){return this.logger}getDefaultOptions(){return this.defaultOptions}setDefaultOptions(c){this.defaultOptions=c}setQueryDefaults(c,l){let et=this.queryDefaults.find(l=>hashQueryKey(c)===hashQueryKey(l.queryKey));et?et.defaultOptions=l:this.queryDefaults.push({queryKey:c,defaultOptions:l})}getQueryDefaults(c){if(!c)return;let l=this.queryDefaults.find(l=>partialDeepEqual(c,l.queryKey));return null==l?void 0:l.defaultOptions}setMutationDefaults(c,l){let et=this.mutationDefaults.find(l=>hashQueryKey(c)===hashQueryKey(l.mutationKey));et?et.defaultOptions=l:this.mutationDefaults.push({mutationKey:c,defaultOptions:l})}getMutationDefaults(c){if(!c)return;let l=this.mutationDefaults.find(l=>partialDeepEqual(c,l.mutationKey));return null==l?void 0:l.defaultOptions}defaultQueryOptions(c){if(null!=c&&c._defaulted)return c;let l={...this.defaultOptions.queries,...this.getQueryDefaults(null==c?void 0:c.queryKey),...c,_defaulted:!0};return!l.queryHash&&l.queryKey&&(l.queryHash=hashQueryKeyByOptions(l.queryKey,l)),void 0===l.refetchOnReconnect&&(l.refetchOnReconnect="always"!==l.networkMode),void 0===l.useErrorBoundary&&(l.useErrorBoundary=!!l.suspense),l}defaultMutationOptions(c){return null!=c&&c._defaulted?c:{...this.defaultOptions.mutations,...this.getMutationDefaults(null==c?void 0:c.mutationKey),...c,_defaulted:!0}}clear(){this.queryCache.clear(),this.mutationCache.clear()}};function defaultShouldDehydrateMutation(c){return c.state.isPaused}function defaultShouldDehydrateQuery(c){return"success"===c.state.status}let ep=["added","removed","updated"];function isCacheableEventType(c){return ep.includes(c)}async function persistQueryClientRestore({queryClient:c,persister:l,maxAge:et=864e5,buster:eo="",hydrateOptions:es}){try{let ec=await l.restoreClient();if(ec){if(ec.timestamp){let el=Date.now()-ec.timestamp>et,ed=ec.buster!==eo;el||ed?l.removeClient():function(c,l,et){if("object"!=typeof l||null===l)return;let eo=c.getMutationCache(),es=c.getQueryCache(),ec=l.mutations||[],el=l.queries||[];ec.forEach(l=>{var es;eo.build(c,{...null==et?void 0:null==(es=et.defaultOptions)?void 0:es.mutations,mutationKey:l.mutationKey},l.state)}),el.forEach(({queryKey:l,state:eo,queryHash:ec})=>{var el;let ed=es.get(ec);if(ed){if(ed.state.dataUpdatedAt{eo(c)&&et.push({mutationKey:c.options.mutationKey,state:c.state})})}if(!1!==l.dehydrateQueries){let et=l.shouldDehydrateQuery||defaultShouldDehydrateQuery;c.getQueryCache().getAll().forEach(c=>{et(c)&&eo.push({state:c.state,queryKey:c.queryKey,queryHash:c.queryHash})})}return{mutations:et,queries:eo}}(c,eo)};await l.persistClient(es)}var eg=et(36694),em=et(2265);let eb=em.createContext(void 0),ey=em.createContext(!1);function getQueryClientContext(c,l){return c||(l&&"undefined"!=typeof window?(window.ReactQueryClientContext||(window.ReactQueryClientContext=eb),window.ReactQueryClientContext):eb)}let useQueryClient=({context:c}={})=>{let l=em.useContext(getQueryClientContext(c,em.useContext(ey)));if(!l)throw Error("No QueryClient set, use QueryClientProvider to set one");return l},QueryClientProvider=({client:c,children:l,context:et,contextSharing:eo=!1})=>{em.useEffect(()=>(c.mount(),()=>{c.unmount()}),[c]);let es=getQueryClientContext(et,eo);return em.createElement(ey.Provider,{value:!et&&eo},em.createElement(es.Provider,{value:c},l))},e_=em.createContext(!1),useIsRestoring=()=>em.useContext(e_);e_.Provider;let ew=em.createContext((eo=!1,{clearReset:()=>{eo=!1},reset:()=>{eo=!0},isReset:()=>eo})),useQueryErrorResetBoundary=()=>em.useContext(ew);var eE=et(26272);let MutationObserver=class MutationObserver extends Subscribable{constructor(c,l){super(),this.client=c,this.setOptions(l),this.bindMethods(),this.updateResult()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(c){var l;let et=this.options;this.options=this.client.defaultMutationOptions(c),shallowEqualObjects(et,this.options)||this.client.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.currentMutation,observer:this}),null==(l=this.currentMutation)||l.setOptions(this.options)}onUnsubscribe(){if(!this.hasListeners()){var c;null==(c=this.currentMutation)||c.removeObserver(this)}}onMutationUpdate(c){this.updateResult();let l={listeners:!0};"success"===c.type?l.onSuccess=!0:"error"===c.type&&(l.onError=!0),this.notify(l)}getCurrentResult(){return this.currentResult}reset(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})}mutate(c,l){return this.mutateOptions=l,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,{...this.options,variables:void 0!==c?c:this.options.variables}),this.currentMutation.addObserver(this),this.currentMutation.execute()}updateResult(){let c=this.currentMutation?this.currentMutation.state:mutation_getDefaultState(),l={...c,isLoading:"loading"===c.status,isSuccess:"success"===c.status,isError:"error"===c.status,isIdle:"idle"===c.status,mutate:this.mutate,reset:this.reset};this.currentResult=l}notify(c){el.batch(()=>{if(this.mutateOptions&&this.hasListeners()){var l,et,eo,es,ec,el,ed,eh;c.onSuccess?(null==(l=(et=this.mutateOptions).onSuccess)||l.call(et,this.currentResult.data,this.currentResult.variables,this.currentResult.context),null==(eo=(es=this.mutateOptions).onSettled)||eo.call(es,this.currentResult.data,null,this.currentResult.variables,this.currentResult.context)):c.onError&&(null==(ec=(el=this.mutateOptions).onError)||ec.call(el,this.currentResult.error,this.currentResult.variables,this.currentResult.context),null==(ed=(eh=this.mutateOptions).onSettled)||ed.call(eh,void 0,this.currentResult.error,this.currentResult.variables,this.currentResult.context))}c.listeners&&this.listeners.forEach(({listener:c})=>{c(this.currentResult)})})}};let eS=eE.useSyncExternalStore;function useMutation_noop(){}let QueryObserver=class QueryObserver extends Subscribable{constructor(c,l){super(),this.client=c,this.options=l,this.trackedProps=new Set,this.selectError=null,this.bindMethods(),this.setOptions(l)}bindMethods(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(this.currentQuery.addObserver(this),shouldFetchOnMount(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return shouldFetchOn(this.currentQuery,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return shouldFetchOn(this.currentQuery,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.clearStaleTimeout(),this.clearRefetchInterval(),this.currentQuery.removeObserver(this)}setOptions(c,l){let et=this.options,eo=this.currentQuery;if(this.options=this.client.defaultQueryOptions(c),shallowEqualObjects(et,this.options)||this.client.getQueryCache().notify({type:"observerOptionsUpdated",query:this.currentQuery,observer:this}),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled)throw Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=et.queryKey),this.updateQuery();let es=this.hasListeners();es&&shouldFetchOptionally(this.currentQuery,eo,this.options,et)&&this.executeFetch(),this.updateResult(l),es&&(this.currentQuery!==eo||this.options.enabled!==et.enabled||this.options.staleTime!==et.staleTime)&&this.updateStaleTimeout();let ec=this.computeRefetchInterval();es&&(this.currentQuery!==eo||this.options.enabled!==et.enabled||ec!==this.currentRefetchInterval)&&this.updateRefetchInterval(ec)}getOptimisticResult(c){let l=this.client.getQueryCache().build(this.client,c),et=this.createResult(l,c);return c.keepPreviousData||(void 0!==c.placeholderData?!et.isPlaceholderData:shallowEqualObjects(this.getCurrentResult(),et))||(this.currentResult=et,this.currentResultOptions=this.options,this.currentResultState=this.currentQuery.state),et}getCurrentResult(){return this.currentResult}trackResult(c){let l={};return Object.keys(c).forEach(et=>{Object.defineProperty(l,et,{configurable:!1,enumerable:!0,get:()=>(this.trackedProps.add(et),c[et])})}),l}getCurrentQuery(){return this.currentQuery}remove(){this.client.getQueryCache().remove(this.currentQuery)}refetch({refetchPage:c,...l}={}){return this.fetch({...l,meta:{refetchPage:c}})}fetchOptimistic(c){let l=this.client.defaultQueryOptions(c),et=this.client.getQueryCache().build(this.client,l);return et.isFetchingOptimistic=!0,et.fetch().then(()=>this.createResult(et,l))}fetch(c){var l;return this.executeFetch({...c,cancelRefetch:null==(l=c.cancelRefetch)||l}).then(()=>(this.updateResult(),this.currentResult))}executeFetch(c){this.updateQuery();let l=this.currentQuery.fetch(this.options,c);return null!=c&&c.throwOnError||(l=l.catch(utils_noop)),l}updateStaleTimeout(){if(this.clearStaleTimeout(),es||this.currentResult.isStale||!isValidTimeout(this.options.staleTime))return;let c=timeUntilStale(this.currentResult.dataUpdatedAt,this.options.staleTime);this.staleTimeoutId=setTimeout(()=>{this.currentResult.isStale||this.updateResult()},c+1)}computeRefetchInterval(){var c;return"function"==typeof this.options.refetchInterval?this.options.refetchInterval(this.currentResult.data,this.currentQuery):null!=(c=this.options.refetchInterval)&&c}updateRefetchInterval(c){this.clearRefetchInterval(),this.currentRefetchInterval=c,!es&&!1!==this.options.enabled&&isValidTimeout(this.currentRefetchInterval)&&0!==this.currentRefetchInterval&&(this.refetchIntervalId=setInterval(()=>{(this.options.refetchIntervalInBackground||ed.isFocused())&&this.executeFetch()},this.currentRefetchInterval))}updateTimers(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())}clearStaleTimeout(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)}clearRefetchInterval(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)}createResult(c,l){let et;let eo=this.currentQuery,es=this.options,ec=this.currentResult,el=this.currentResultState,ed=this.currentResultOptions,eh=c!==eo,ef=eh?c.state:this.currentQueryInitialState,ep=eh?this.currentResult:this.previousQueryResult,{state:eg}=c,{dataUpdatedAt:em,error:eb,errorUpdatedAt:ey,fetchStatus:e_,status:ew}=eg,eE=!1,eS=!1;if(l._optimisticResults){let et=this.hasListeners(),ec=!et&&shouldFetchOnMount(c,l),el=et&&shouldFetchOptionally(c,eo,l,es);(ec||el)&&(e_=canFetch(c.options.networkMode)?"fetching":"paused",em||(ew="loading")),"isRestoring"===l._optimisticResults&&(e_="idle")}if(l.keepPreviousData&&!eg.dataUpdatedAt&&null!=ep&&ep.isSuccess&&"error"!==ew)et=ep.data,em=ep.dataUpdatedAt,ew=ep.status,eE=!0;else if(l.select&&void 0!==eg.data){if(ec&&eg.data===(null==el?void 0:el.data)&&l.select===this.selectFn)et=this.selectResult;else try{this.selectFn=l.select,et=l.select(eg.data),et=replaceData(null==ec?void 0:ec.data,et,l),this.selectResult=et,this.selectError=null}catch(c){this.selectError=c}}else et=eg.data;if(void 0!==l.placeholderData&&void 0===et&&"loading"===ew){let c;if(null!=ec&&ec.isPlaceholderData&&l.placeholderData===(null==ed?void 0:ed.placeholderData))c=ec.data;else if(c="function"==typeof l.placeholderData?l.placeholderData():l.placeholderData,l.select&&void 0!==c)try{c=l.select(c),this.selectError=null}catch(c){this.selectError=c}void 0!==c&&(ew="success",et=replaceData(null==ec?void 0:ec.data,c,l),eS=!0)}this.selectError&&(eb=this.selectError,et=this.selectResult,ey=Date.now(),ew="error");let ex="fetching"===e_,ek="loading"===ew,eC="error"===ew,eA={status:ew,fetchStatus:e_,isLoading:ek,isSuccess:"success"===ew,isError:eC,isInitialLoading:ek&&ex,data:et,dataUpdatedAt:em,error:eb,errorUpdatedAt:ey,failureCount:eg.fetchFailureCount,failureReason:eg.fetchFailureReason,errorUpdateCount:eg.errorUpdateCount,isFetched:eg.dataUpdateCount>0||eg.errorUpdateCount>0,isFetchedAfterMount:eg.dataUpdateCount>ef.dataUpdateCount||eg.errorUpdateCount>ef.errorUpdateCount,isFetching:ex,isRefetching:ex&&!ek,isLoadingError:eC&&0===eg.dataUpdatedAt,isPaused:"paused"===e_,isPlaceholderData:eS,isPreviousData:eE,isRefetchError:eC&&0!==eg.dataUpdatedAt,isStale:isStale(c,l),refetch:this.refetch,remove:this.remove};return eA}updateResult(c){let l=this.currentResult,et=this.createResult(this.currentQuery,this.options);if(this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,shallowEqualObjects(et,l))return;this.currentResult=et;let eo={cache:!0};(null==c?void 0:c.listeners)!==!1&&(()=>{if(!l)return!0;let{notifyOnChangeProps:c}=this.options,et="function"==typeof c?c():c;if("all"===et||!et&&!this.trackedProps.size)return!0;let eo=new Set(null!=et?et:this.trackedProps);return this.options.useErrorBoundary&&eo.add("error"),Object.keys(this.currentResult).some(c=>{let et=this.currentResult[c]!==l[c];return et&&eo.has(c)})})()&&(eo.listeners=!0),this.notify({...eo,...c})}updateQuery(){let c=this.client.getQueryCache().build(this.client,this.options);if(c===this.currentQuery)return;let l=this.currentQuery;this.currentQuery=c,this.currentQueryInitialState=c.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(null==l||l.removeObserver(this),c.addObserver(this))}onQueryUpdate(c){let l={};"success"===c.type?l.onSuccess=!c.manual:"error"!==c.type||isCancelledError(c.error)||(l.onError=!0),this.updateResult(l),this.hasListeners()&&this.updateTimers()}notify(c){el.batch(()=>{var l,et,eo,es,ec,el,ed,eh;c.onSuccess?(null==(l=(et=this.options).onSuccess)||l.call(et,this.currentResult.data),null==(eo=(es=this.options).onSettled)||eo.call(es,this.currentResult.data,null)):c.onError&&(null==(ec=(el=this.options).onError)||ec.call(el,this.currentResult.error),null==(ed=(eh=this.options).onSettled)||ed.call(eh,void 0,this.currentResult.error)),c.listeners&&this.listeners.forEach(({listener:c})=>{c(this.currentResult)}),c.cache&&this.client.getQueryCache().notify({query:this.currentQuery,type:"observerResultsUpdated"})})}};function shouldFetchOnMount(c,l){return!1!==l.enabled&&!c.state.dataUpdatedAt&&!("error"===c.state.status&&!1===l.retryOnMount)||c.state.dataUpdatedAt>0&&shouldFetchOn(c,l,l.refetchOnMount)}function shouldFetchOn(c,l,et){if(!1!==l.enabled){let eo="function"==typeof et?et(c):et;return"always"===eo||!1!==eo&&isStale(c,l)}return!1}function shouldFetchOptionally(c,l,et,eo){return!1!==et.enabled&&(c!==l||!1===eo.enabled)&&(!et.suspense||"error"!==c.state.status)&&isStale(c,et)}function isStale(c,l){return c.isStaleByTime(l.staleTime)}var ex=et(65401);function createConfig({queryClient:c=new QueryClient({defaultOptions:{queries:{cacheTime:864e5,networkMode:"offlineFirst",refetchOnWindowFocus:!1,retry:0},mutations:{networkMode:"offlineFirst"}}}),storage:l=(0,eg.o6)({storage:"undefined"!=typeof window&&window.localStorage?window.localStorage:eg.wp}),persister:et="undefined"!=typeof window?function({storage:c,key:l="REACT_QUERY_OFFLINE_CACHE",throttleTime:et=1e3,serialize:eo=JSON.stringify,deserialize:es=JSON.parse,retry:ec}){if(c){let trySave=et=>{try{c.setItem(l,eo(et));return}catch(c){return c}};return{persistClient:function(c,l=100){let et,eo=null;return function(...es){et=es,null===eo&&(eo=setTimeout(()=>{c(...et),eo=null},l))}}(c=>{let l=c,et=trySave(l),eo=0;for(;et&&l;)eo++,(l=null==ec?void 0:ec({persistedClient:l,error:et,errorCount:eo}))&&(et=trySave(l))},et),restoreClient:()=>{let et=c.getItem(l);if(et)return es(et)},removeClient:()=>{c.removeItem(l)}}}return{persistClient:noop,restoreClient:()=>void 0,removeClient:noop}}({key:"cache",storage:l,serialize:c=>c,deserialize:c=>c}):void 0,...eo}){let es=(0,eg._g)({...eo,storage:l});return et&&function(c){persistQueryClientRestore(c).then(()=>{(function(c){let l=c.queryClient.getQueryCache().subscribe(l=>{isCacheableEventType(l.type)&&persistQueryClientSave(c)}),et=c.queryClient.getMutationCache().subscribe(l=>{isCacheableEventType(l.type)&&persistQueryClientSave(c)})})(c)})}({queryClient:c,persister:et,dehydrateOptions:{shouldDehydrateQuery:c=>0!==c.cacheTime&&!1!==c.queryKey[0].persist}}),Object.assign(es,{queryClient:c})}var ek=em.createContext(void 0),eC=em.createContext(void 0);function WagmiConfig({children:c,config:l}){return em.createElement(ek.Provider,{children:em.createElement(QueryClientProvider,{children:c,client:l.queryClient,context:eC}),value:l})}var eA=eE.useSyncExternalStore;function dist_hasObjectPrototype(c){return"[object Object]"===Object.prototype.toString.call(c)}function queryKeyHashFn(c){return JSON.stringify(c,(c,l)=>!function(c){if(!dist_hasObjectPrototype(c))return!1;let l=c.constructor;if(void 0===l)return!0;let et=l.prototype;return!!(dist_hasObjectPrototype(et)&&et.hasOwnProperty("isPrototypeOf"))}(l)?"bigint"==typeof l?l.toString():l:Object.keys(l).sort().reduce((c,et)=>(c[et]=l[et],c),{}))}function dist_useMutation(c,l,et){let eo=parseMutationArgs(c,l,et);return function(c,l,et){var eo,es;let ec=parseMutationArgs(c,void 0,void 0),ed=useQueryClient({context:ec.context}),[eh]=em.useState(()=>new MutationObserver(ed,ec));em.useEffect(()=>{eh.setOptions(ec)},[eh,ec]);let ef=eS(em.useCallback(c=>eh.subscribe(el.batchCalls(c)),[eh]),()=>eh.getCurrentResult(),()=>eh.getCurrentResult()),ep=em.useCallback((c,l)=>{eh.mutate(c,l).catch(useMutation_noop)},[eh]);if(ef.error&&(eo=eh.options.useErrorBoundary,es=[ef.error],"function"==typeof eo?eo(...es):!!eo))throw ef.error;return{...ef,mutate:ep,mutateAsync:ef.mutate}}({context:eC,...eo})}function useQuery(c,l,et){let eo=Array.isArray(c)?"function"==typeof l?{...et,queryKey:c,queryFn:l}:{...l,queryKey:c}:c,es=function(c,l){var et,eo;let es=useQueryClient({context:c.context}),ec=useIsRestoring(),ed=useQueryErrorResetBoundary(),eh=es.defaultQueryOptions({...c,queryKeyHashFn});eh._optimisticResults=ec?"isRestoring":"optimistic",eh.onError&&(eh.onError=el.batchCalls(eh.onError)),eh.onSuccess&&(eh.onSuccess=el.batchCalls(eh.onSuccess)),eh.onSettled&&(eh.onSettled=el.batchCalls(eh.onSettled)),eh.suspense&&"number"!=typeof eh.staleTime&&(eh.staleTime=1e3),(eh.suspense||eh.useErrorBoundary)&&!ed.isReset()&&(eh.retryOnMount=!1);let[ef]=em.useState(()=>new l(es,eh)),ep=ef.getOptimisticResult(eh);if(eA(em.useCallback(c=>ec?()=>void 0:ef.subscribe(el.batchCalls(c)),[ef,ec]),()=>ef.getCurrentResult(),()=>ef.getCurrentResult()),em.useEffect(()=>{ed.clearReset()},[ed]),em.useEffect(()=>{ef.setOptions(eh,{listeners:!1})},[eh,ef]),eh.suspense&&ep.isLoading&&ep.isFetching&&!ec)throw ef.fetchOptimistic(eh).then(({data:c})=>{eh.onSuccess?.(c),eh.onSettled?.(c,null)}).catch(c=>{ed.clearReset(),eh.onError?.(c),eh.onSettled?.(void 0,c)});if(ep.isError&&!ed.isReset()&&!ep.isFetching&&(et=eh.useErrorBoundary,eo=[ep.error,ef.getCurrentQuery()],"function"==typeof et?et(...eo):!!et))throw ep.error;let eg="loading"===ep.status&&"idle"===ep.fetchStatus?"idle":ep.status,eb="loading"===eg&&"fetching"===ep.fetchStatus;return{...ep,defaultedOptions:eh,isIdle:"idle"===eg,isLoading:eb,observer:ef,status:eg}}({context:eC,...eo},QueryObserver),ec={data:es.data,error:es.error,fetchStatus:es.fetchStatus,isError:es.isError,isFetched:es.isFetched,isFetchedAfterMount:es.isFetchedAfterMount,isFetching:es.isFetching,isIdle:es.isIdle,isLoading:es.isLoading,isRefetching:es.isRefetching,isSuccess:es.isSuccess,refetch:es.refetch,status:es.status,internal:{dataUpdatedAt:es.dataUpdatedAt,errorUpdatedAt:es.errorUpdatedAt,failureCount:es.failureCount,isFetchedAfterMount:es.isFetchedAfterMount,isLoadingError:es.isLoadingError,isPaused:es.isPaused,isPlaceholderData:es.isPlaceholderData,isPreviousData:es.isPreviousData,isRefetchError:es.isRefetchError,isStale:es.isStale,remove:es.remove}};return es.defaultedOptions.notifyOnChangeProps?ec:function(c,l){let et={};return Object.keys(c).forEach(eo=>{Object.defineProperty(et,eo,{configurable:!1,enumerable:!0,get:()=>(l.trackedProps.add(eo),c[eo])})}),et}(ec,es.observer)}var useQueryClient2=()=>useQueryClient({context:eC});function usePublicClient({chainId:c}={}){return(0,ex.useSyncExternalStoreWithSelector)(l=>(0,eg.pC)({chainId:c},l),()=>(0,eg.uV)({chainId:c}),()=>(0,eg.uV)({chainId:c}),c=>c,(c,l)=>c.uid===l.uid)}function queryKey({chainId:c}){return[{entity:"walletClient",chainId:c,persist:!1}]}function queryFn({queryKey:[{chainId:c}]}){return(0,eg.xz)({chainId:c})}function useWalletClient({chainId:c,suspense:l,onError:et,onSettled:eo,onSuccess:es}={}){let{connector:ec}=function({onConnect:c,onDisconnect:l}={}){let et=function(){let c=em.useContext(ek);if(!c)throw Error("`useConfig` must be used within `WagmiConfig`.\n\nRead more: https://wagmi.sh/react/WagmiConfig");return c}(),eo=em.useCallback(c=>(0,eg.uH)(c),[et]),es=function(c,l,et=l,eo=eg.vZ){let es=em.useRef([]),ec=(0,ex.useSyncExternalStoreWithSelector)(c,l,et,c=>c,(c,l)=>{if(isPlainObject2(c)&&isPlainObject2(l)&&es.current.length){for(let et of es.current){let es=eo(c[et],l[et]);if(!es)return!1}return!0}return eo(c,l)});if(isPlainObject2(ec)){let c={...ec};return Object.defineProperties(c,Object.entries(c).reduce((c,[l,et])=>({...c,[l]:{configurable:!1,enumerable:!0,get:()=>(es.current.includes(l)||es.current.push(l),et)}}),{})),c}return ec}(eo,eg.D0),ec=em.useRef(),el=ec.current;return em.useEffect(()=>{el?.status!=="connected"&&"connected"===es.status&&c?.({address:es.address,connector:es.connector,isReconnected:el?.status==="reconnecting"||el?.status===void 0}),el?.status==="connected"&&"disconnected"===es.status&&l?.(),ec.current=es},[c,l,el,es]),es}(),el=useChainId({chainId:c}),ed=useQuery(queryKey({chainId:el}),queryFn,{cacheTime:0,enabled:!!ec,staleTime:1/0,suspense:l,onError:et,onSettled:eo,onSuccess:es}),eh=useQueryClient2();return em.useEffect(()=>{let c=(0,eg.Tb)({chainId:el},c=>{c?eh.invalidateQueries(queryKey({chainId:el})):eh.removeQueries(queryKey({chainId:el}))});return c},[eh,el]),ed}function useChainId({chainId:c}={}){let l=usePublicClient({chainId:c});return l.chain.id}function queryKey2({chainId:c,scopeKey:l}){return[{entity:"blockNumber",chainId:c,scopeKey:l}]}function queryFn2({queryKey:[{chainId:c}]}){return(0,eg.RQ)({chainId:c})}function useBlockNumber({cacheTime:c=0,chainId:l,enabled:et=!0,scopeKey:eo,staleTime:es,suspense:ec,watch:el=!1,onBlock:ed,onError:eh,onSettled:ef,onSuccess:ep}={}){let eb=useChainId({chainId:l}),ey=usePublicClient({chainId:eb}),e_=function({chainId:c}={}){return(0,ex.useSyncExternalStoreWithSelector)(l=>(0,eg.fq)({chainId:c},l),()=>(0,eg.jr)({chainId:c}),()=>(0,eg.jr)({chainId:c}),c=>c,(c,l)=>c?.uid===l?.uid)}({chainId:eb}),ew=useQueryClient2();return em.useEffect(()=>{if(!et||!el&&!ed)return;let c=e_??ey,l=c.watchBlockNumber({onBlockNumber:c=>{el&&ew.setQueryData(queryKey2({chainId:eb,scopeKey:eo}),c),ed&&ed(c)},emitOnBegin:!0});return l},[eb,eo,ed,ey,ew,el,e_,et]),useQuery(queryKey2({scopeKey:eo,chainId:eb}),queryFn2,{cacheTime:c,enabled:et,staleTime:es,suspense:ec,onError:eh,onSettled:ef,onSuccess:ep})}var isPlainObject2=c=>"object"==typeof c&&!Array.isArray(c),eI=[{entity:"disconnect"}],mutationFn2=()=>(0,eg.zP)();function useDisconnect({onError:c,onMutate:l,onSettled:et,onSuccess:eo}={}){let{error:es,isError:ec,isIdle:el,isLoading:ed,isSuccess:eh,mutate:ef,mutateAsync:ep,reset:eg,status:em}=dist_useMutation(eI,mutationFn2,{...c?{onError(l,et,eo){c(l,eo)}}:{},onMutate:l,...et?{onSettled(c,l,eo,es){et(l,es)}}:{},...eo?{onSuccess(c,l,et){eo(et)}}:{}});return{disconnect:ef,disconnectAsync:ep,error:es,isError:ec,isIdle:el,isLoading:ed,isSuccess:eh,reset:eg,status:em}}function useContractRead({abi:c,address:l,account:et,args:eo,blockNumber:es,blockTag:ec,cacheOnBlock:el=!1,cacheTime:ed,chainId:eh,enabled:ef=!0,functionName:ep,isDataEqual:eb,keepPreviousData:ey,onError:e_,onSettled:ew,onSuccess:eE,scopeKey:eS,select:ex,staleTime:ek,structuralSharing:eC=(c,l)=>(0,eg.vZ)(c,l)?c:utils_replaceEqualDeep(c,l),suspense:eA,watch:eI}={}){let eP=useChainId({chainId:eh}),{data:eR}=useBlockNumber({chainId:eP,enabled:eI||el,scopeKey:eI||el?void 0:"idle",watch:eI}),eO=es??eR,eT=em.useMemo(()=>(function({account:c,address:l,args:et,blockNumber:eo,blockTag:es,chainId:ec,functionName:el,scopeKey:ed}){return[{entity:"readContract",account:c,address:l,args:et,blockNumber:eo,blockTag:es,chainId:ec,functionName:el,scopeKey:ed}]})({account:et,address:l,args:eo,blockNumber:el?eO:void 0,blockTag:ec,chainId:eP,functionName:ep,scopeKey:eS}),[et,l,eo,eO,ec,el,eP,ep,eS]),eN=em.useMemo(()=>{let et=!!(ef&&c&&l&&ep);return el&&(et=!!(et&&eO)),et},[c,l,eO,el,ef,ep]);return!function({chainId:c,enabled:l,queryKey:et}){let eo=useQueryClient2(),es=em.useCallback(()=>eo.invalidateQueries({queryKey:et},{cancelRefetch:!1}),[eo,et]);useBlockNumber({chainId:c,enabled:l,onBlock:l?es:void 0,scopeKey:l?void 0:"idle"})}({chainId:eP,enabled:!!(eN&&eI&&!el),queryKey:eT}),useQuery(eT,function({abi:c}){return async({queryKey:[{account:l,address:et,args:eo,blockNumber:es,blockTag:ec,chainId:el,functionName:ed}]})=>{if(!c)throw Error("abi is required");if(!et)throw Error("address is required");return await (0,eg.a4)({account:l,address:et,args:eo,blockNumber:es,blockTag:ec,chainId:el,abi:c,functionName:ed})??null}}({abi:c}),{cacheTime:ed,enabled:eN,isDataEqual:eb,keepPreviousData:ey,select:ex,staleTime:ek,structuralSharing:eC,suspense:eA,onError:e_,onSettled:ew,onSuccess:eE})}function mutationFn6(c){if("prepared"===c.mode){if(!c.request)throw Error("request is required");return(0,eg.n9)({mode:"prepared",request:c.request})}if(!c.address)throw Error("address is required");if(!c.abi)throw Error("abi is required");if(!c.functionName)throw Error("functionName is required");return(0,eg.n9)({address:c.address,args:c.args,chainId:c.chainId,abi:c.abi,functionName:c.functionName,accessList:c.accessList,account:c.account,gas:c.gas,gasPrice:c.gasPrice,maxFeePerGas:c.maxFeePerGas,maxPriorityFeePerGas:c.maxPriorityFeePerGas,nonce:c.nonce,value:c.value})}function useContractWrite(c){let{address:l,abi:et,args:eo,chainId:es,functionName:ec,mode:el,request:ed}=c,{accessList:eh,account:ef,gas:ep,gasPrice:eb,maxFeePerGas:ey,maxPriorityFeePerGas:e_,nonce:ew,value:eE}=(0,eg.gY)(c),{data:eS,error:ex,isError:ek,isIdle:eC,isLoading:eA,isSuccess:eI,mutate:eP,mutateAsync:eR,reset:eO,status:eT,variables:eN}=dist_useMutation(function({address:c,abi:l,functionName:et,...eo}){let{args:es,accessList:ec,account:el,gas:ed,gasPrice:eh,maxFeePerGas:ef,maxPriorityFeePerGas:ep,nonce:eg,request:em,value:eb}=eo;return[{entity:"writeContract",address:c,args:es,abi:l,accessList:ec,account:el,functionName:et,gas:ed,gasPrice:eh,maxFeePerGas:ef,maxPriorityFeePerGas:ep,nonce:eg,request:em,value:eb}]}({address:l,abi:et,functionName:ec,chainId:es,mode:el,args:eo,accessList:eh,account:ef,gas:ep,gasPrice:eb,maxFeePerGas:ey,maxPriorityFeePerGas:e_,nonce:ew,request:ed,value:eE}),mutationFn6,{onError:c.onError,onMutate:c.onMutate,onSettled:c.onSettled,onSuccess:c.onSuccess}),eM=em.useMemo(()=>{if("prepared"===c.mode){if(!ed)return;return()=>eP({mode:"prepared",request:c.request,chainId:c.chainId})}return c=>eP({address:l,args:eo,abi:et,functionName:ec,chainId:es,accessList:eh,account:ef,gas:ep,gasPrice:eb,maxFeePerGas:ey,maxPriorityFeePerGas:e_,nonce:ew,value:eE,...c})},[eh,ef,et,l,eo,es,c.chainId,c.mode,c.request,ec,ep,eb,ey,e_,eP,ew,ed,eE]),e$=em.useMemo(()=>{if("prepared"===c.mode){if(!ed)return;return()=>eR({mode:"prepared",request:c.request})}return c=>eR({address:l,args:eo,abi:et,chainId:es,functionName:ec,accessList:eh,account:ef,gas:ep,gasPrice:eb,maxFeePerGas:ey,maxPriorityFeePerGas:e_,nonce:ew,value:eE,...c})},[eh,ef,et,l,eo,es,c.mode,c.request,ec,ep,eb,ey,e_,eR,ew,ed,eE]);return{data:eS,error:ex,isError:ek,isIdle:eC,isLoading:eA,isSuccess:eI,reset:eO,status:eT,variables:eN,write:eM,writeAsync:e$}}function useWaitForTransaction({chainId:c,confirmations:l,hash:et,timeout:eo,cacheTime:es,enabled:ec=!0,scopeKey:el,staleTime:ed,suspense:eh,onError:ef,onReplaced:ep,onSettled:em,onSuccess:eb}={}){let ey=useChainId({chainId:c});return useQuery(function({confirmations:c,chainId:l,hash:et,scopeKey:eo,timeout:es}){return[{entity:"waitForTransaction",confirmations:c,chainId:l,hash:et,scopeKey:eo,timeout:es}]}({chainId:ey,confirmations:l,hash:et,scopeKey:el,timeout:eo}),function({onReplaced:c}){return({queryKey:[{chainId:l,confirmations:et,hash:eo,timeout:es}]})=>{if(!eo)throw Error("hash is required");return(0,eg.Mn)({chainId:l,confirmations:et,hash:eo,onReplaced:c,timeout:es})}}({onReplaced:ep}),{cacheTime:es,enabled:!!(ec&&et),staleTime:ed,suspense:eh,onError:ef,onSettled:em,onSuccess:eb})}},6871:function(c){"use strict";c.exports=JSON.parse('{"i8":"3.8.0-beta.3"}')}}]); \ No newline at end of file diff --git a/_next/static/chunks/app/_not-found-da24bb006e0d0c60.js b/_next/static/chunks/app/_not-found-da24bb006e0d0c60.js new file mode 100644 index 0000000..9205dc4 --- /dev/null +++ b/_next/static/chunks/app/_not-found-da24bb006e0d0c60.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[165],{83155:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_not-found",function(){return n(15991)}])},15991:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return NotFound}});let l=n(21024),o=l._(n(2265)),r={error:{fontFamily:'system-ui,"Segoe UI",Roboto,Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji"',height:"100vh",textAlign:"center",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center"},desc:{display:"inline-block"},h1:{display:"inline-block",margin:"0 20px 0 0",padding:"0 23px 0 0",fontSize:24,fontWeight:500,verticalAlign:"top",lineHeight:"49px"},h2:{fontSize:14,fontWeight:400,lineHeight:"49px",margin:0}};function NotFound(){return o.default.createElement(o.default.Fragment,null,o.default.createElement("title",null,"404: This page could not be found."),o.default.createElement("div",{style:r.error},o.default.createElement("div",null,o.default.createElement("style",{dangerouslySetInnerHTML:{__html:"body{color:#000;background:#fff;margin:0}.next-error-h1{border-right:1px solid rgba(0,0,0,.3)}@media (prefers-color-scheme:dark){body{color:#fff;background:#000}.next-error-h1{border-right:1px solid rgba(255,255,255,.3)}}"}}),o.default.createElement("h1",{className:"next-error-h1",style:r.h1},"404"),o.default.createElement("div",{style:r.desc},o.default.createElement("h2",{style:r.h2},"This page could not be found.")))))}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)}},function(e){e.O(0,[971,864,744],function(){return e(e.s=83155)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/app/layout-09059e339eda9f17.js b/_next/static/chunks/app/layout-09059e339eda9f17.js new file mode 100644 index 0000000..b2d6a18 --- /dev/null +++ b/_next/static/chunks/app/layout-09059e339eda9f17.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[185],{35883:function(){},46601:function(){},24654:function(){},52361:function(){},94616:function(){},30666:function(e,n,o){Promise.resolve().then(o.bind(o,69254)),Promise.resolve().then(o.bind(o,1410)),Promise.resolve().then(o.bind(o,82999)),Promise.resolve().then(o.bind(o,46242)),Promise.resolve().then(o.bind(o,68083)),Promise.resolve().then(o.bind(o,36359)),Promise.resolve().then(o.bind(o,57243)),Promise.resolve().then(o.bind(o,67090)),Promise.resolve().then(o.bind(o,64414)),Promise.resolve().then(o.bind(o,70935)),Promise.resolve().then(o.bind(o,44200)),Promise.resolve().then(o.bind(o,87758)),Promise.resolve().then(o.bind(o,1889)),Promise.resolve().then(o.bind(o,22202)),Promise.resolve().then(o.bind(o,71051)),Promise.resolve().then(o.bind(o,37392)),Promise.resolve().then(o.bind(o,24990)),Promise.resolve().then(o.bind(o,59616)),Promise.resolve().then(o.bind(o,36366)),Promise.resolve().then(o.bind(o,13158)),Promise.resolve().then(o.bind(o,71082)),Promise.resolve().then(o.bind(o,10046)),Promise.resolve().then(o.bind(o,41470)),Promise.resolve().then(o.bind(o,77162)),Promise.resolve().then(o.bind(o,22911)),Promise.resolve().then(o.bind(o,75332)),Promise.resolve().then(o.bind(o,78282)),Promise.resolve().then(o.bind(o,38236)),Promise.resolve().then(o.bind(o,67774)),Promise.resolve().then(o.bind(o,22745)),Promise.resolve().then(o.bind(o,81104)),Promise.resolve().then(o.bind(o,13610)),Promise.resolve().then(o.bind(o,74400)),Promise.resolve().then(o.bind(o,74794)),Promise.resolve().then(o.bind(o,1959)),Promise.resolve().then(o.bind(o,14114)),Promise.resolve().then(o.bind(o,3223)),Promise.resolve().then(o.bind(o,12065)),Promise.resolve().then(o.bind(o,67939)),Promise.resolve().then(o.bind(o,38531)),Promise.resolve().then(o.bind(o,71479)),Promise.resolve().then(o.bind(o,12704)),Promise.resolve().then(o.bind(o,92013)),Promise.resolve().then(o.bind(o,77876)),Promise.resolve().then(o.bind(o,67998)),Promise.resolve().then(o.bind(o,33962)),Promise.resolve().then(o.bind(o,90865)),Promise.resolve().then(o.bind(o,23145)),Promise.resolve().then(o.bind(o,58250)),Promise.resolve().then(o.bind(o,57474)),Promise.resolve().then(o.bind(o,15391)),Promise.resolve().then(o.bind(o,82812)),Promise.resolve().then(o.bind(o,71846)),Promise.resolve().then(o.bind(o,91917)),Promise.resolve().then(o.bind(o,92776)),Promise.resolve().then(o.bind(o,3499)),Promise.resolve().then(o.bind(o,42029)),Promise.resolve().then(o.t.bind(o,64671,23)),Promise.resolve().then(o.bind(o,32117)),Promise.resolve().then(o.bind(o,48032))},32117:function(e,n,o){"use strict";o.r(n),o.d(n,{LoginButton:function(){return LoginButton}});var r=o(57437),i=o(26621),s=o(79980),t=o(48433),l=o(7129),d=o(1477),h=o(56926);let LoginButton=()=>{let{wallet:e}=(0,d.fE)(),{connectWallet:n,ready:o,authenticated:v,logout:b}=(0,l.sv)(),{disconnect:P}=(0,h.qL)();return e?(0,r.jsxs)(i.k,{children:[(0,r.jsx)(s.x,{children:e.address}),(0,r.jsx)(t.z,{onClick:()=>{P();try{b(),e.disconnect()}catch(e){console.warn("cant disconnect wallet")}},children:"Logout"})]}):(0,r.jsx)(t.z,{onClick:n,colorScheme:"orange",children:"Login"})}},48032:function(e,n,o){"use strict";o.r(n),o.d(n,{Providers:function(){return Providers}});var r=o(57437),i=o(1647),s=o(13610),t=o(7129),l=o(1477);o(2265);var d=o(36694),h=o(26266),v=o(12005);let Providers=e=>{let{children:n}=e,o=(0,d.QB)([h.ws],[(0,v.$)({apiKey:"d100f9395b3f41c39b8ab23ebc974ba5"})]);return(0,r.jsx)(i.n,{children:(0,r.jsx)(s.ChakraProvider,{children:(0,r.jsx)(t.rr,{appId:"clnghnce405kljq0fhmop9hfh",config:{walletConnectCloudProjectId:"6e1043a965696608e5ae638643d5833c",loginMethods:["wallet"],defaultChain:h.ws,supportedChains:[h.ue,h.J0,h.RJ,h.ws,h.yu,h.v8],appearance:{theme:"dark",accentColor:"#676FFF",showWalletLoginFirst:!0}},children:(0,r.jsx)(l.e,{wagmiChainsConfig:o,children:n})})})})}}},function(e){e.O(0,[269,905,723,971,864,744],function(){return e(e.s=30666)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/app/page-b64dabb8be920e63.js b/_next/static/chunks/app/page-b64dabb8be920e63.js new file mode 100644 index 0000000..a17ca70 --- /dev/null +++ b/_next/static/chunks/app/page-b64dabb8be920e63.js @@ -0,0 +1 @@ +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[931],{35883:function(){},46601:function(){},24654:function(){},52361:function(){},94616:function(){},73158:function(e,n,t){Promise.resolve().then(t.bind(t,98327))},98327:function(e,n,t){"use strict";t.r(n),t.d(n,{default:function(){return Home}});var i=t(57437),u=t(56926);let r=[{type:"event",anonymous:!1,inputs:[{name:"by",internalType:"address",type:"address",indexed:!1},{name:"old",internalType:"uint256",type:"uint256",indexed:!1},{name:"_new",internalType:"uint256",type:"uint256",indexed:!1}],name:"NumberChanged"},{stateMutability:"nonpayable",type:"function",inputs:[{name:"num",internalType:"uint256",type:"uint256"}],name:"store",outputs:[{name:"",internalType:"uint256",type:"uint256"}]},{stateMutability:"view",type:"function",inputs:[],name:"retrieve",outputs:[{name:"",internalType:"uint256",type:"uint256"}]}],a={5:"0xd7f65e5e9d30E02553Fb03AD74B26577FD5bA22f"};var s=t(79980),o=t(26621),c=t(68975),l=t(51091),d=t(48433),f=t(1477),m=t(2265),p=t(63610);function Home(){let{ready:e,wallet:n}=(0,f.fE)(),[t,h]=(0,m.useState)(),[y,b]=(0,m.useState)(),[x,v]=(0,m.useState)(),{data:g,error:j,status:N}=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,u.do)({abi:r,address:a[5],functionName:"retrieve",...e})}(),{writeAsync:w}=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return(0,u.GG)({abi:r,address:a[5],functionName:"store",...e})}(),{data:_,isError:k,isLoading:E}=(0,u.BX)(x);(0,m.useEffect)(()=>{void 0!==g&&(b(Number(g)),h(Number(g)))},[g]),(0,m.useEffect)(()=>{if(!_)return;let e=_.logs.map(e=>(0,p.F)({abi:r,...e})).find(e=>e.eventName="NumberChanged");if(!e){console.warn("couldnt find numberchanged event");return}console.log(e),b(Number(e.args._new))},[_]);let S=(0,m.useCallback)(async()=>{if(void 0!==t)try{let e=await w({args:[BigInt(t||0n)]});console.info(e),v(e)}catch(e){console.error(e)}},[t,w]);return n?(0,i.jsxs)("main",{children:[(0,i.jsxs)(s.x,{children:["current value: ",void 0!==y?y.toString():"not avail"]}),(0,i.jsxs)("form",{onSubmit:e=>(e.preventDefault(),S(),!1),children:[(0,i.jsxs)(o.k,{children:[(0,i.jsx)(c.NI,{children:(0,i.jsx)(l.I,{name:"newVal",type:"number",value:t,onChange:e=>h(e.target.valueAsNumber)})}),(0,i.jsx)(d.z,{colorScheme:"cyan",type:"submit",children:"Store"})]}),x&&(0,i.jsxs)(o.k,{direction:"column",my:6,children:[(0,i.jsxs)(s.x,{children:["Transaction: ",(0,i.jsx)("b",{children:x.hash})]}),_&&(0,i.jsxs)(s.x,{children:["Receipt: ",(0,i.jsx)("b",{children:_.status})]})]})]})]}):(0,i.jsx)(s.x,{children:"Pls connect"})}}},function(e){e.O(0,[269,905,971,864,744],function(){return e(e.s=73158)}),_N_E=e.O()}]); \ No newline at end of file diff --git a/_next/static/chunks/fd9d1056-024209d9649a7d29.js b/_next/static/chunks/fd9d1056-024209d9649a7d29.js new file mode 100644 index 0000000..8310d99 --- /dev/null +++ b/_next/static/chunks/fd9d1056-024209d9649a7d29.js @@ -0,0 +1,9 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[971],{84417:function(n,a,i){/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Meta Platforms, Inc. and affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var o,s=i(2265),m=i(8261),y={usingClientEntryPoint:!1,Events:null,Dispatcher:{current:null}};function t(n){for(var a="https://reactjs.org/docs/error-decoder.html?invariant="+n,i=1;ix||(n.current=C[x],C[x]=null,x--)}function E(n,a){C[++x]=n.current,n.current=a}var z=Symbol.for("react.element"),P=Symbol.for("react.portal"),N=Symbol.for("react.fragment"),L=Symbol.for("react.strict_mode"),_=Symbol.for("react.profiler"),j=Symbol.for("react.provider"),M=Symbol.for("react.context"),F=Symbol.for("react.server_context"),O=Symbol.for("react.forward_ref"),I=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),A=Symbol.for("react.memo"),U=Symbol.for("react.lazy"),H=Symbol.for("react.scope");Symbol.for("react.debug_trace_mode");var Q=Symbol.for("react.offscreen"),$=Symbol.for("react.legacy_hidden"),B=Symbol.for("react.cache");Symbol.for("react.tracing_marker");var Y=Symbol.for("react.default_value"),G=Symbol.iterator;function Ca(n){return null===n||"object"!=typeof n?null:"function"==typeof(n=G&&n[G]||n["@@iterator"])?n:null}var K=ia(null),J=ia(null),X=ia(null);function Ga(n,a){switch(E(X,a),E(J,n),E(K,null),n=a.nodeType){case 9:case 11:a=(a=a.documentElement)&&(a=a.namespaceURI)?Ha(a):0;break;default:if(a=(n=8===n?a.parentNode:a).tagName,n=n.namespaceURI)a=Ia(n=Ha(n),a);else switch(a){case"svg":a=1;break;case"math":a=2;break;default:a=0}}D(K),E(K,a)}function Ja(){D(K),D(J),D(X)}function Ka(n){var a=K.current,i=Ia(a,n.type);a!==i&&(E(J,n),E(K,i))}function La(n){J.current===n&&(D(K),D(J))}var et=m.unstable_scheduleCallback,en=m.unstable_cancelCallback,er=m.unstable_shouldYield,el=m.unstable_requestPaint,ea=m.unstable_now,eo=m.unstable_getCurrentPriorityLevel,eu=m.unstable_ImmediatePriority,ec=m.unstable_UserBlockingPriority,es=m.unstable_NormalPriority,ed=m.unstable_LowPriority,ep=m.unstable_IdlePriority,em=null,eb=null,ey=Math.clz32?Math.clz32:function(n){return 0==(n>>>=0)?32:31-(ev(n)/ew|0)|0},ev=Math.log,ew=Math.LN2,eS=128,eE=8388608;function fb(n){switch(n&-n){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:return 8388480&n;case 8388608:case 16777216:case 33554432:case 67108864:return 125829120&n;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return n}}function gb(n,a){var i=n.pendingLanes;if(0===i)return 0;var o=0,s=n.suspendedLanes,m=n.pingedLanes,y=268435455&i;if(0!==y){var v=y&~s;0!==v?o=fb(v):0!=(m&=y)&&(o=fb(m))}else 0!=(y=i&~s)?o=fb(y):0!==m&&(o=fb(m));if(0===o)return 0;if(0!==a&&a!==o&&0==(a&s)&&((s=o&-o)>=(m=a&-a)||32===s&&0!=(8388480&m)))return a;if(0!=(8&o)&&(o|=32&i),0!==(a=n.entangledLanes))for(n=n.entanglements,a&=o;0i;i++)a.push(n);return a}function mb(n,a){n.pendingLanes|=a,536870912!==a&&(n.suspendedLanes=0,n.pingedLanes=0)}function ob(n,a){var i=n.entangledLanes|=a;for(n=n.entanglements;i;){var o=31-ey(i),s=1<--k||m[v]!==y[k]){var C="\n"+m[v].replace(" at new "," at ");return n.displayName&&C.includes("")&&(C=C.replace("",n.displayName)),C}while(1<=v&&0<=k);break}}}finally{eU=!1,Error.prepareStackTrace=i}return(n=n?n.displayName||n.name:"")?Xb(n):""}function cc(n){switch(typeof n){case"boolean":case"number":case"string":case"undefined":case"object":return n;default:return""}}function dc(n){var a=n.type;return(n=n.nodeName)&&"input"===n.toLowerCase()&&("checkbox"===a||"radio"===a)}function fc(n){n._valueTracker||(n._valueTracker=function(n){var a=dc(n)?"checked":"value",i=Object.getOwnPropertyDescriptor(n.constructor.prototype,a),o=""+n[a];if(!n.hasOwnProperty(a)&&void 0!==i&&"function"==typeof i.get&&"function"==typeof i.set){var s=i.get,m=i.set;return Object.defineProperty(n,a,{configurable:!0,get:function(){return s.call(this)},set:function(n){o=""+n,m.call(this,n)}}),Object.defineProperty(n,a,{enumerable:i.enumerable}),{getValue:function(){return o},setValue:function(n){o=""+n},stopTracking:function(){n._valueTracker=null,delete n[a]}}}}(n))}function gc(n){if(!n)return!1;var a=n._valueTracker;if(!a)return!0;var i=a.getValue(),o="";return n&&(o=dc(n)?n.checked?"true":"false":n.value),(n=o)!==i&&(a.setValue(n),!0)}function hc(n){if(void 0===(n=n||("undefined"!=typeof document?document:void 0)))return null;try{return n.activeElement||n.body}catch(a){return n.body}}var eq=/[\n"\\]/g;function jc(n){return n.replace(eq,function(n){return"\\"+n.charCodeAt(0).toString(16)+" "})}function kc(n,a,i,o,s,m,y,v){n.name="",null!=y&&"function"!=typeof y&&"symbol"!=typeof y&&"boolean"!=typeof y?n.type=y:n.removeAttribute("type"),null!=a?"number"===y?(0===a&&""===n.value||n.value!=a)&&(n.value=""+cc(a)):n.value!==""+cc(a)&&(n.value=""+cc(a)):"submit"!==y&&"reset"!==y||n.removeAttribute("value"),null!=a?lc(n,y,cc(a)):null!=i?lc(n,y,cc(i)):null!=o&&n.removeAttribute("value"),null==s&&null!=m&&(n.defaultChecked=!!m),null!=s&&!!s!==n.checked&&(n.checked=s),null!=v&&"function"!=typeof v&&"symbol"!=typeof v&&"boolean"!=typeof v?n.name=""+cc(v):n.removeAttribute("name")}function mc(n,a,i,o,s,m,y,v){if(null!=m&&"function"!=typeof m&&"symbol"!=typeof m&&"boolean"!=typeof m&&(n.type=m),null!=a||null!=i){if(!("submit"!==m&&"reset"!==m||null!=a))return;i=null!=i?""+cc(i):"",a=null!=a?""+cc(a):i,v||a===n.value||(n.value=a),n.defaultValue=a}o="function"!=typeof(o=null!=o?o:s)&&"symbol"!=typeof o&&!!o,v||(n.checked=!!o),n.defaultChecked=!!o,null!=y&&"function"!=typeof y&&"symbol"!=typeof y&&"boolean"!=typeof y&&(n.name=y)}function lc(n,a,i){"number"===a&&hc(n.ownerDocument)===n||n.defaultValue===""+i||(n.defaultValue=""+i)}var eH=Array.isArray;function oc(n,a,i,o){if(n=n.options,a){a={};for(var s=0;s"+a.valueOf().toString()+"",a=n9.firstChild;n.firstChild;)n.removeChild(n.firstChild);for(;a.firstChild;)n.appendChild(a.firstChild)}}var eQ=sc;"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction&&(eQ=function(n,a){return MSApp.execUnsafeLocalFunction(function(){return sc(n,a)})});var e$=eQ;function vc(n,a){if(a){var i=n.firstChild;if(i&&i===n.lastChild&&3===i.nodeType){i.nodeValue=a;return}}n.textContent=a}var eB=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function xc(n,a,i){var o=0===a.indexOf("--");null==i||"boolean"==typeof i||""===i?o?n.setProperty(a,""):"float"===a?n.cssFloat="":n[a]="":o?n.setProperty(a,i):"number"!=typeof i||0===i||eB.has(a)?"float"===a?n.cssFloat=i:n[a]=(""+i).trim():n[a]=i+"px"}function yc(n,a,i){if(null!=a&&"object"!=typeof a)throw Error(t(62));if(n=n.style,null!=i){for(var o in i)!i.hasOwnProperty(o)||null!=a&&a.hasOwnProperty(o)||(0===o.indexOf("--")?n.setProperty(o,""):"float"===o?n.cssFloat="":n[o]="");for(var s in a)o=a[s],a.hasOwnProperty(s)&&i[s]!==o&&xc(n,s,o)}else for(var m in a)a.hasOwnProperty(m)&&xc(n,m,a[m])}function zc(n){if(-1===n.indexOf("-"))return!1;switch(n){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var eZ=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),eY=null;function Cc(n){return(n=n.target||n.srcElement||window).correspondingUseElement&&(n=n.correspondingUseElement),3===n.nodeType?n.parentNode:n}var eG=null,eK=null;function Fc(n){var a=Fb(n);if(a&&(n=a.stateNode)){var i=Hb(n);switch(n=a.stateNode,a.type){case"input":if(kc(n,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name),a=i.name,"radio"===i.type&&null!=a){for(i=n;i.parentNode;)i=i.parentNode;for(i=i.querySelectorAll('input[name="'+jc(""+a)+'"][type="radio"]'),a=0;a>=y,s-=y,tt=1<<32-ey(a)+s|i<k?(C=v,v=null):C=v.sibling;var x=r(a,v,o[k],s);if(null===x){null===v&&(v=C);break}n&&v&&null===x.alternate&&b(a,v),i=f(x,i,k),null===y?m=x:y.sibling=x,y=x,v=C}if(k===o.length)return c(a,v),to&&jd(a,k),m;if(null===v){for(;kk?(C=v,v=null):C=v.sibling;var z=r(a,v,x.value,s);if(null===z){null===v&&(v=C);break}n&&v&&null===z.alternate&&b(a,v),i=f(z,i,k),null===y?m=z:y.sibling=z,y=z,v=C}if(x.done)return c(a,v),to&&jd(a,k),m;if(null===v){for(;!x.done;k++,x=o.next())null!==(x=w(a,x.value,s))&&(i=f(x,i,k),null===y?m=x:y.sibling=x,y=x);return to&&jd(a,k),m}for(v=d(a,v);!x.done;k++,x=o.next())null!==(x=u(v,a,k,x.value,s))&&(n&&null!==x.alternate&&v.delete(null===x.key?k:x.key),i=f(x,i,k),null===y?m=x:y.sibling=x,y=x);return n&&v.forEach(function(n){return b(a,n)}),to&&jd(a,k),m}(a,i,o,s);if("function"==typeof o.then)return S(a,i,le(o),s);if(o.$$typeof===M||o.$$typeof===F)return S(a,i,ve(a,o,s),s);ne(a,o)}return"string"==typeof o&&""!==o||"number"==typeof o?(o=""+o,null!==i&&6===i.tag?(c(a,i.sibling),(i=e(i,o)).return=a):(c(a,i),(i=re(o,a.mode,s)).return=a),g(a=i)):c(a,i)}(a,i,o,s),tw=null,a}}var tE=pe(!0),tC=pe(!1),tx=ia(null),tz=ia(0);function Ae(n,a){E(tz,n=nR),E(tx,a),nR=n|a.baseLanes}function Ce(){E(tz,nR),E(tx,tx.current)}function De(){nR=tz.current,D(tx),D(tz)}var tP=ia(null),tN=null;function Ge(n){var a=n.alternate;E(tL,1&tL.current),E(tP,n),null===tN&&(null===a||null!==tx.current?tN=n:null!==a.memoizedState&&(tN=n))}function Ie(n){if(22===n.tag){if(E(tL,tL.current),E(tP,n),null===tN){var a=n.alternate;null!==a&&null!==a.memoizedState&&(tN=n)}}else Je(n)}function Je(){E(tL,tL.current),E(tP,tP.current)}function Ke(n){D(tP),tN===n&&(tN=null),D(tL)}var tL=ia(0);function Le(n){for(var a=n;null!==a;){if(13===a.tag){var i=a.memoizedState;if(null!==i&&(null===(i=i.dehydrated)||"$?"===i.data||"$!"===i.data))return a}else if(19===a.tag&&void 0!==a.memoizedProps.revealOrder){if(0!=(128&a.flags))return a}else if(null!==a.child){a.child.return=a,a=a.child;continue}if(a===n)break;for(;null===a.sibling;){if(null===a.return||a.return===n)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}var tT=null,t_=null,tD=!1,tM=!1,tF=!1,tO=0;function Se(n){n!==t_&&null===n.next&&(null===t_?tT=t_=n:t_=t_.next=n),tM=!0,tD||(tD=!0,Te(Ue))}function Ve(n){if(!tF&&tM){var a=n_,i=nM,o=null;tF=!0;do for(var s=!1,m=tT;null!==m;){if((!n||0===m.tag)&&0!=(3&gb(m,m===a?i:0)))try{s=!0;var y=m;if(0!=(6&nT))throw Error(t(327));We();var v=gb(y,0);if(0!=(3&v)){var k=Xe(y,v);if(0!==y.tag&&2===k){var C=v,x=ib(y,C);0!==x&&(v=x,k=Ye(y,C,x))}if(1===k)throw C=nA,$e(y,0),af(y,v),Se(y),C;6===k?af(y,v):(y.finishedWork=y.current.alternate,y.finishedLanes=v,bf(y,nQ,nZ))}Se(y)}catch(n){null===o?o=[n]:o.push(n)}m=m.next}while(s);if(tF=!1,null!==o){if(1m?m:8;var y=tR.transition;tR.transition=null,mg(n,a,i),tR.transition={};try{mg(n,a,o),s()}catch(n){throw n}finally{eC=m,tR.transition=y}}function ng(){return Hf().memoizedState}function og(){return Hf().memoizedState}function pg(n){for(var a=n.return;null!==a;){switch(a.tag){case 24:case 3:var i=qg(a),o=Ud(a,n=Td(i),i);null!==o&&(Yf(o,a,i),Vd(o,a,i)),a={cache:rg()},n.payload=a;return}a=a.return}}function sg(n,a,i){var o=qg(n);i={lane:o,revertLane:0,action:i,hasEagerState:!1,eagerState:null,next:null},tg(n)?ug(a,i):(Ld(n,a,i,o),null!==(i=Nd(n))&&(Yf(i,n,o),vg(i,a,o)))}function mg(n,a,i){var o=qg(n),s={lane:o,revertLane:0,action:i,hasEagerState:!1,eagerState:null,next:null};if(tg(n))ug(a,s);else{var m=n.alternate;if(0===n.lanes&&(null===m||0===m.lanes)&&null!==(m=a.lastRenderedReducer))try{var y=a.lastRenderedState,v=m(y,i);if(s.hasEagerState=!0,s.eagerState=v,e2(v,y)){Ld(n,a,s,0),null===n_&&Jd();return}}catch(n){}finally{}Ld(n,a,s,o),null!==(i=Nd(n))&&(Yf(i,n,o),vg(i,a,o))}}function tg(n){var a=n.alternate;return n===tA||null!==a&&a===tA}function ug(n,a){tH=tq=!0;var i=n.pending;null===i?a.next=a:(a.next=i.next,i.next=a),n.pending=a}function vg(n,a,i){if(0!=(8388480&i)){var o=a.lanes;o&=n.pendingLanes,i|=o,a.lanes=i,ob(n,i)}}rt=function(){return{lastEffect:null,events:null,stores:null}};var tG={readContext:Lf,use:Kf,useCallback:uf,useContext:uf,useEffect:uf,useImperativeHandle:uf,useInsertionEffect:uf,useLayoutEffect:uf,useMemo:uf,useReducer:uf,useRef:uf,useState:uf,useDebugValue:uf,useDeferredValue:uf,useTransition:uf,useSyncExternalStore:uf,useId:uf};tG.useCacheRefresh=uf;var tK={readContext:Lf,use:Kf,useCallback:function(n,a){return Gf().memoizedState=[n,void 0===a?null:a],n},useContext:Lf,useEffect:cg,useImperativeHandle:function(n,a,i){i=null!=i?i.concat([n]):null,ag(4194308,4,fg.bind(null,a,n),i)},useLayoutEffect:function(n,a){return ag(4194308,4,n,a)},useInsertionEffect:function(n,a){ag(4,2,n,a)},useMemo:function(n,a){var i=Gf();return a=void 0===a?null:a,tQ&&n(),n=n(),i.memoizedState=[n,a],n},useReducer:function(n,a,i){var o=Gf();return a=void 0!==i?i(a):a,o.memoizedState=o.baseState=a,n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:n,lastRenderedState:a},o.queue=n,n=n.dispatch=sg.bind(null,tA,n),[o.memoizedState,n]},useRef:function(n){return n={current:n},Gf().memoizedState=n},useState:function(n){var a=(n=Zf(n)).queue,i=mg.bind(null,tA,a);return a.dispatch=i,[n.memoizedState,i]},useDebugValue:hg,useDeferredValue:function(n){return Gf().memoizedState=n},useTransition:function(){var n=Zf(!1);return n=lg.bind(null,tA,n.queue,!0,!1),Gf().memoizedState=n,[!1,n]},useSyncExternalStore:function(n,a,i){var o=tA,s=Gf();if(to){if(void 0===i)throw Error(t(407));i=i()}else{if(i=a(),null===n_)throw Error(t(349));0!=(60&tV)||Vf(o,a,i)}s.memoizedState=i;var m={value:i,getSnapshot:a};return s.queue=m,cg(Sf.bind(null,o,m,n),[n]),o.flags|=2048,Tf(9,Uf.bind(null,o,m,i,a),{destroy:void 0},null),i},useId:function(){var n=Gf(),a=n_.identifierPrefix;if(to){var i=tr,o=tt;a=":"+a+"R"+(i=(o&~(1<<32-ey(o)-1)).toString(32)+i),0<(i=t$++)&&(a+="H"+i.toString(32)),a+=":"}else a=":"+a+"r"+(i=tY++).toString(32)+":";return n.memoizedState=a},useCacheRefresh:function(){return Gf().memoizedState=pg.bind(null,tA)}},tJ={readContext:Lf,use:Kf,useCallback:ig,useContext:Lf,useEffect:Rf,useImperativeHandle:gg,useInsertionEffect:dg,useLayoutEffect:eg,useMemo:jg,useReducer:Nf,useRef:$f,useState:function(){return Nf(Mf)},useDebugValue:hg,useDeferredValue:function(n){return kg(Hf(),tW.memoizedState,n)},useTransition:function(){var n=Nf(Mf)[0],a=Hf().memoizedState;return["boolean"==typeof n?n:Jf(n),a]},useSyncExternalStore:Qf,useId:ng};tJ.useCacheRefresh=og;var tX={readContext:Lf,use:Kf,useCallback:ig,useContext:Lf,useEffect:Rf,useImperativeHandle:gg,useInsertionEffect:dg,useLayoutEffect:eg,useMemo:jg,useReducer:Pf,useRef:$f,useState:function(){return Pf(Mf)},useDebugValue:hg,useDeferredValue:function(n){var a=Hf();return null===tW?a.memoizedState=n:kg(a,tW.memoizedState,n)},useTransition:function(){var n=Pf(Mf)[0],a=Hf().memoizedState;return["boolean"==typeof n?n:Jf(n),a]},useSyncExternalStore:Qf,useId:ng};function wg(n,a){if(n&&n.defaultProps)for(var i in a=v({},a),n=n.defaultProps)void 0===a[i]&&(a[i]=n[i]);return a}function xg(n,a,i,o){i=null==(i=i(o,a=n.memoizedState))?a:v({},a,i),n.memoizedState=i,0===n.lanes&&(n.updateQueue.baseState=i)}tX.useCacheRefresh=og;var t0={isMounted:function(n){return!!(n=n._reactInternals)&&Ic(n)===n},enqueueSetState:function(n,a,i){var o=qg(n=n._reactInternals),s=Td(o);s.payload=a,null!=i&&(s.callback=i),null!==(a=Ud(n,s,o))&&(Yf(a,n,o),Vd(a,n,o))},enqueueReplaceState:function(n,a,i){var o=qg(n=n._reactInternals),s=Td(o);s.tag=1,s.payload=a,null!=i&&(s.callback=i),null!==(a=Ud(n,s,o))&&(Yf(a,n,o),Vd(a,n,o))},enqueueForceUpdate:function(n,a){var i=qg(n=n._reactInternals),o=Td(i);o.tag=2,null!=a&&(o.callback=a),null!==(a=Ud(n,o,i))&&(Yf(a,n,i),Vd(a,n,i))}};function zg(n,a,i,o,s,m,y){return"function"==typeof(n=n.stateNode).shouldComponentUpdate?n.shouldComponentUpdate(o,m,y):!a.prototype||!a.prototype.isPureReactComponent||!ae(i,o)||!ae(s,m)}function Ag(n,a,i){var o=!1,s=eJ,m=a.contextType;return"object"==typeof m&&null!==m?m=Lf(m):(s=Tc(a)?e1:eX.current,m=(o=null!=(o=a.contextTypes))?Sc(n,s):eJ),a=new a(i,m),n.memoizedState=null!==a.state&&void 0!==a.state?a.state:null,a.updater=t0,n.stateNode=a,a._reactInternals=n,o&&((n=n.stateNode).__reactInternalMemoizedUnmaskedChildContext=s,n.__reactInternalMemoizedMaskedChildContext=m),a}function Bg(n,a,i,o){n=a.state,"function"==typeof a.componentWillReceiveProps&&a.componentWillReceiveProps(i,o),"function"==typeof a.UNSAFE_componentWillReceiveProps&&a.UNSAFE_componentWillReceiveProps(i,o),a.state!==n&&t0.enqueueReplaceState(a,a.state,null)}function Cg(n,a,i,o){var s=n.stateNode;s.props=i,s.state=n.memoizedState,s.refs={},Rd(n);var m=a.contextType;"object"==typeof m&&null!==m?s.context=Lf(m):(m=Tc(a)?e1:eX.current,s.context=Sc(n,m)),s.state=n.memoizedState,"function"==typeof(m=a.getDerivedStateFromProps)&&(xg(n,a,m,i),s.state=n.memoizedState),"function"==typeof a.getDerivedStateFromProps||"function"==typeof s.getSnapshotBeforeUpdate||"function"!=typeof s.UNSAFE_componentWillMount&&"function"!=typeof s.componentWillMount||(a=s.state,"function"==typeof s.componentWillMount&&s.componentWillMount(),"function"==typeof s.UNSAFE_componentWillMount&&s.UNSAFE_componentWillMount(),a!==s.state&&t0.enqueueReplaceState(s,s.state,null),Xd(n,i,s,o),s.state=n.memoizedState),"function"==typeof s.componentDidMount&&(n.flags|=4194308)}function Dg(n,a){try{var i="",o=a;do i+=function(n){switch(n.tag){case 26:case 27:case 5:return Xb(n.type);case 16:return Xb("Lazy");case 13:return Xb("Suspense");case 19:return Xb("SuspenseList");case 0:case 2:case 15:return n=Zb(n.type,!1);case 11:return n=Zb(n.type.render,!1);case 1:return n=Zb(n.type,!0);default:return""}}(o),o=o.return;while(o);var s=i}catch(n){s="\nError generating stack: "+n.message+"\n"+n.stack}return{value:n,source:a,stack:s,digest:null}}function Eg(n,a,i){return{value:n,source:null,stack:null!=i?i:null,digest:null!=a?a:null}}function Fg(n,a){try{console.error(a.value)}catch(n){setTimeout(function(){throw n})}}function Gg(n,a,i){(i=Td(i)).tag=3,i.payload={element:null};var o=a.value;return i.callback=function(){nY||(nY=!0,nG=o),Fg(n,a)},i}function Jg(n,a,i){(i=Td(i)).tag=3;var o=n.type.getDerivedStateFromError;if("function"==typeof o){var s=a.value;i.payload=function(){return o(s)},i.callback=function(){Fg(n,a)}}var m=n.stateNode;return null!==m&&"function"==typeof m.componentDidCatch&&(i.callback=function(){Fg(n,a),"function"!=typeof o&&(null===nK?nK=new Set([this]):nK.add(this));var i=a.stack;this.componentDidCatch(a.value,{componentStack:null!==i?i:""})}),i}function Lg(n,a,i,o,s){return 0==(1&n.mode)?n===a?n.flags|=65536:(n.flags|=128,i.flags|=131072,i.flags&=-52805,1===i.tag&&(null===i.alternate?i.tag=17:((a=Td(2)).tag=2,Ud(i,a,2))),i.lanes|=2):(n.flags|=65536,n.lanes=s),n}var t1=k.ReactCurrentOwner,t2=Error(t(461)),t3=!1;function Tg(n,a,i,o){a.child=null===n?tC(a,null,i,o):tE(a,n.child,i,o)}function Ug(n,a,i,o,s){i=i.render;var m=a.ref;return(Vg(a,s),o=wf(n,a,i,o,m,s),i=Df(),null===n||t3)?(to&&i&&ld(a),a.flags|=1,Tg(n,a,o,s),a.child):(Ef(n,a,s),Wg(n,a,s))}function Xg(n,a,i,o,s){if(null===n){var m=i.type;return"function"!=typeof m||Yg(m)||void 0!==m.defaultProps||null!==i.compare||void 0!==i.defaultProps?((n=se(i.type,null,o,null,a,a.mode,s)).ref=a.ref,n.return=a,a.child=n):(a.tag=15,a.type=m,Zg(n,a,m,o,s))}if(m=n.child,0==(n.lanes&s)){var y=m.memoizedProps;if((i=null!==(i=i.compare)?i:ae)(y,o)&&n.ref===a.ref)return Wg(n,a,s)}return a.flags|=1,(n=qe(m,o)).ref=a.ref,n.return=a,a.child=n}function Zg(n,a,i,o,s){if(null!==n){var m=n.memoizedProps;if(ae(m,o)&&n.ref===a.ref){if(t3=!1,a.pendingProps=o=m,0==(n.lanes&s))return a.lanes=n.lanes,Wg(n,a,s);0!=(131072&n.flags)&&(t3=!0)}}return $g(n,a,i,o,s)}function ah(n,a,i){var o=a.pendingProps,s=o.children,m=0!=(2&a.stateNode._pendingVisibility),y=null!==n?n.memoizedState:null;if(bh(n,a),"hidden"===o.mode||m){if(0!=(128&a.flags)){if(i=null!==y?y.baseLanes|i:i,null!==n){for(s=0,o=a.child=n.child;null!==o;)s=s|o.lanes|o.childLanes,o=o.sibling;a.childLanes=s&~i}else a.childLanes=0,a.child=null;return ch(n,a,i)}if(0==(1&a.mode))a.memoizedState={baseLanes:0,cachePool:null},null!==n&&dh(a,null),Ce(),Ie(a);else{if(0==(1073741824&i))return a.lanes=a.childLanes=1073741824,ch(n,a,null!==y?y.baseLanes|i:i);a.memoizedState={baseLanes:0,cachePool:null},null!==n&&dh(a,null!==y?y.cachePool:null),null!==y?Ae(a,y):Ce(),Ie(a)}}else null!==y?(dh(a,y.cachePool),Ae(a,y),Je(a),a.memoizedState=null):(null!==n&&dh(a,null),Ce(),Je(a));return Tg(n,a,s,i),a.child}function ch(n,a,i){var o=eh();return o=null===o?null:{parent:nr._currentValue,pool:o},a.memoizedState={baseLanes:i,cachePool:o},null!==n&&dh(a,null),Ce(),Ie(a),null}function bh(n,a){var i=a.ref;(null===n&&null!==i||null!==n&&n.ref!==i)&&(a.flags|=512,a.flags|=2097152)}function $g(n,a,i,o,s){var m=Tc(i)?e1:eX.current;return(m=Sc(a,m),Vg(a,s),i=wf(n,a,i,o,m,s),o=Df(),null===n||t3)?(to&&o&&ld(a),a.flags|=1,Tg(n,a,i,s),a.child):(Ef(n,a,s),Wg(n,a,s))}function fh(n,a,i,o,s,m){return(Vg(a,m),i=zf(a,o,i,s),Af(),o=Df(),null===n||t3)?(to&&o&&ld(a),a.flags|=1,Tg(n,a,i,m),a.child):(Ef(n,a,m),Wg(n,a,m))}function gh(n,a,i,o,s){if(Tc(i)){var m=!0;Xc(a)}else m=!1;if(Vg(a,s),null===a.stateNode)hh(n,a),Ag(a,i,o),Cg(a,i,o,s),o=!0;else if(null===n){var y=a.stateNode,v=a.memoizedProps;y.props=v;var k=y.context,C=i.contextType;C="object"==typeof C&&null!==C?Lf(C):Sc(a,C=Tc(i)?e1:eX.current);var x=i.getDerivedStateFromProps,z="function"==typeof x||"function"==typeof y.getSnapshotBeforeUpdate;z||"function"!=typeof y.UNSAFE_componentWillReceiveProps&&"function"!=typeof y.componentWillReceiveProps||(v!==o||k!==C)&&Bg(a,y,o,C),tp=!1;var P=a.memoizedState;y.state=P,Xd(a,o,y,s),k=a.memoizedState,v!==o||P!==k||e0.current||tp?("function"==typeof x&&(xg(a,i,x,o),k=a.memoizedState),(v=tp||zg(a,i,v,o,P,k,C))?(z||"function"!=typeof y.UNSAFE_componentWillMount&&"function"!=typeof y.componentWillMount||("function"==typeof y.componentWillMount&&y.componentWillMount(),"function"==typeof y.UNSAFE_componentWillMount&&y.UNSAFE_componentWillMount()),"function"==typeof y.componentDidMount&&(a.flags|=4194308)):("function"==typeof y.componentDidMount&&(a.flags|=4194308),a.memoizedProps=o,a.memoizedState=k),y.props=o,y.state=k,y.context=C,o=v):("function"==typeof y.componentDidMount&&(a.flags|=4194308),o=!1)}else{y=a.stateNode,Sd(n,a),v=a.memoizedProps,C=a.type===a.elementType?v:wg(a.type,v),y.props=C,z=a.pendingProps,P=y.context,k="object"==typeof(k=i.contextType)&&null!==k?Lf(k):Sc(a,k=Tc(i)?e1:eX.current);var N=i.getDerivedStateFromProps;(x="function"==typeof N||"function"==typeof y.getSnapshotBeforeUpdate)||"function"!=typeof y.UNSAFE_componentWillReceiveProps&&"function"!=typeof y.componentWillReceiveProps||(v!==z||P!==k)&&Bg(a,y,o,k),tp=!1,P=a.memoizedState,y.state=P,Xd(a,o,y,s);var L=a.memoizedState;v!==z||P!==L||e0.current||tp?("function"==typeof N&&(xg(a,i,N,o),L=a.memoizedState),(C=tp||zg(a,i,C,o,P,L,k)||!1)?(x||"function"!=typeof y.UNSAFE_componentWillUpdate&&"function"!=typeof y.componentWillUpdate||("function"==typeof y.componentWillUpdate&&y.componentWillUpdate(o,L,k),"function"==typeof y.UNSAFE_componentWillUpdate&&y.UNSAFE_componentWillUpdate(o,L,k)),"function"==typeof y.componentDidUpdate&&(a.flags|=4),"function"==typeof y.getSnapshotBeforeUpdate&&(a.flags|=1024)):("function"!=typeof y.componentDidUpdate||v===n.memoizedProps&&P===n.memoizedState||(a.flags|=4),"function"!=typeof y.getSnapshotBeforeUpdate||v===n.memoizedProps&&P===n.memoizedState||(a.flags|=1024),a.memoizedProps=o,a.memoizedState=L),y.props=o,y.state=L,y.context=k,o=C):("function"!=typeof y.componentDidUpdate||v===n.memoizedProps&&P===n.memoizedState||(a.flags|=4),"function"!=typeof y.getSnapshotBeforeUpdate||v===n.memoizedProps&&P===n.memoizedState||(a.flags|=1024),o=!1)}return ih(n,a,i,o,m,s)}function ih(n,a,i,o,s,m){bh(n,a);var y=0!=(128&a.flags);if(!o&&!y)return s&&Yc(a,i,!1),Wg(n,a,m);o=a.stateNode,t1.current=a;var v=y&&"function"!=typeof i.getDerivedStateFromError?null:o.render();return a.flags|=1,null!==n&&y?(a.child=tE(a,n.child,null,m),a.child=tE(a,null,v,m)):Tg(n,a,v,m),a.memoizedState=o.state,s&&Yc(a,i,!0),a.child}function jh(n){var a=n.stateNode;a.pendingContext?Vc(n,a.pendingContext,a.pendingContext!==a.context):a.context&&Vc(n,a.context,!1),Ga(n,a.containerInfo)}function kh(n,a,i,o,s){return Ed(),Fd(s),a.flags|=256,Tg(n,a,i,o),a.child}var t4={dehydrated:null,treeContext:null,retryLane:0};function mh(n){return{baseLanes:n,cachePool:nh()}}function oh(n,a,i){var o,s=a.pendingProps,m=!1,y=0!=(128&a.flags);if((o=y)||(o=(null===n||null!==n.memoizedState)&&0!=(2&tL.current)),o&&(m=!0,a.flags&=-129),null===n){if(to){if(m?Ge(a):Je(a),to&&((y=n=ta)?xd(a,y)||(yd(a)&&zd(),ta=ud(y.nextSibling),o=tl,ta&&xd(a,ta)?pd(o,y):(rd(tl,a),to=!1,tl=a,ta=n)):(yd(a)&&zd(),rd(tl,a),to=!1,tl=a,ta=n)),null!==(n=a.memoizedState)&&null!==(n=n.dehydrated))return 0==(1&a.mode)?a.lanes=2:"$!"===n.data?a.lanes=16:a.lanes=1073741824,null;Ke(a)}return(y=s.children,n=s.fallback,m)?(Je(a),s=a.mode,m=a.child,y={mode:"hidden",children:y},0==(1&s)&&null!==m?(m.childLanes=0,m.pendingProps=y):m=ph(y,s,0,null),n=ue(n,s,i,null),m.return=a,n.return=a,m.sibling=n,a.child=m,a.child.memoizedState=mh(i),a.memoizedState=t4,n):(Ge(a),qh(a,y))}if(null!==(o=n.memoizedState)){var v=o.dehydrated;if(null!==v)return function(n,a,i,o,s,m,y){if(i)return 256&a.flags?(Ge(a),a.flags&=-257,sh(n,a,y,s=Eg(Error(t(422))))):null!==a.memoizedState?(Je(a),a.child=n.child,a.flags|=128,null):(Je(a),s=o.fallback,m=a.mode,o=ph({mode:"visible",children:o.children},m,0,null),s=ue(s,m,y,null),s.flags|=2,o.return=a,s.return=a,o.sibling=s,a.child=o,0!=(1&a.mode)&&tE(a,n.child,null,y),a.child.memoizedState=mh(y),a.memoizedState=t4,s);if(Ge(a),0==(1&a.mode))return sh(n,a,y,null);if("$!"===s.data){if(s=s.nextSibling&&s.nextSibling.dataset)var v=s.dgst;return s=v,(o=Error(t(419))).digest=s,sh(n,a,y,s=Eg(o,s,void 0))}if(v=0!=(y&n.childLanes),t3||v){if(null!==(o=n_)){switch(y&-y){case 2:v=1;break;case 8:v=4;break;case 32:v=16;break;case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:v=64;break;case 536870912:v=268435456;break;default:v=0}if(0!==(v=0!=(v&(o.suspendedLanes|y))?0:v)&&v!==m.retryLane)throw m.retryLane=v,Md(n,v),Yf(o,n,v),t2}return"$?"!==s.data&&Ng(),sh(n,a,y,null)}return"$?"===s.data?(a.flags|=128,a.child=n.child,a=th.bind(null,n),s._reactRetry=a,null):(n=m.treeContext,ta=ud(s.nextSibling),tl=a,to=!0,tu=null,tc=!1,null!==n&&(e5[e7++]=tt,e5[e7++]=tr,e5[e7++]=e9,tt=n.id,tr=n.overflow,e9=a),a=qh(a,o.children),a.flags|=4096,a)}(n,a,y,s,v,o,i)}if(m){Je(a),m=s.fallback,y=a.mode,v=(o=n.child).sibling;var k={mode:"hidden",children:s.children};return 0==(1&y)&&a.child!==o?((s=a.child).childLanes=0,s.pendingProps=k,a.deletions=null):(s=qe(o,k)).subtreeFlags=31457280&o.subtreeFlags,null!==v?m=qe(v,m):(m=ue(m,y,i,null),m.flags|=2),m.return=a,s.return=a,s.sibling=m,a.child=s,s=m,m=a.child,null===(y=n.child.memoizedState)?y=mh(i):(null!==(o=y.cachePool)?(v=nr._currentValue,o=o.parent!==v?{parent:v,pool:v}:o):o=nh(),y={baseLanes:y.baseLanes|i,cachePool:o}),m.memoizedState=y,m.childLanes=n.childLanes&~i,a.memoizedState=t4,s}return Ge(a),n=(m=n.child).sibling,s=qe(m,{mode:"visible",children:s.children}),0==(1&a.mode)&&(s.lanes=i),s.return=a,s.sibling=null,null!==n&&(null===(i=a.deletions)?(a.deletions=[n],a.flags|=16):i.push(n)),a.child=s,a.memoizedState=null,s}function qh(n,a){return(a=ph({mode:"visible",children:a},n.mode,0,null)).return=n,n.child=a}function sh(n,a,i,o){return null!==o&&Fd(o),tE(a,n.child,null,i),n=qh(a,a.pendingProps.children),n.flags|=2,a.memoizedState=null,n}function uh(n,a,i){n.lanes|=a;var o=n.alternate;null!==o&&(o.lanes|=a),vh(n.return,a,i)}function wh(n,a,i,o,s){var m=n.memoizedState;null===m?n.memoizedState={isBackwards:a,rendering:null,renderingStartTime:0,last:o,tail:i,tailMode:s}:(m.isBackwards=a,m.rendering=null,m.renderingStartTime=0,m.last=o,m.tail=i,m.tailMode=s)}function xh(n,a,i){var o=a.pendingProps,s=o.revealOrder,m=o.tail;if(Tg(n,a,o.children,i),0!=(2&(o=tL.current)))o=1&o|2,a.flags|=128;else{if(null!==n&&0!=(128&n.flags))e:for(n=a.child;null!==n;){if(13===n.tag)null!==n.memoizedState&&uh(n,i,a);else if(19===n.tag)uh(n,i,a);else if(null!==n.child){n.child.return=n,n=n.child;continue}if(n===a)break;for(;null===n.sibling;){if(null===n.return||n.return===a)break e;n=n.return}n.sibling.return=n.return,n=n.sibling}o&=1}if(E(tL,o),0==(1&a.mode))a.memoizedState=null;else switch(s){case"forwards":for(s=null,i=a.child;null!==i;)null!==(n=i.alternate)&&null===Le(n)&&(s=i),i=i.sibling;null===(i=s)?(s=a.child,a.child=null):(s=i.sibling,i.sibling=null),wh(a,!1,s,i,m);break;case"backwards":for(i=null,s=a.child,a.child=null;null!==s;){if(null!==(n=s.alternate)&&null===Le(n)){a.child=s;break}n=s.sibling,s.sibling=i,i=s,s=n}wh(a,!0,i,null,m);break;case"together":wh(a,!1,null,null,void 0);break;default:a.memoizedState=null}return a.child}function hh(n,a){0==(1&a.mode)&&null!==n&&(n.alternate=null,a.alternate=null,a.flags|=2)}function Wg(n,a,i){if(null!==n&&(a.dependencies=n.dependencies),nW|=a.lanes,0==(i&a.childLanes))return null;if(null!==n&&a.child!==n.child)throw Error(t(153));if(null!==a.child){for(i=qe(n=a.child,n.pendingProps),a.child=i,i.return=a;null!==n.sibling;)n=n.sibling,(i=i.sibling=qe(n,n.pendingProps)).return=a;i.sibling=null}return a.child}var t8=ia(null),t6=null,t5=null,t7=null;function Eh(){t7=t5=t6=null}function zh(n,a,i){E(t8,a._currentValue),a._currentValue=i}function Fh(n){var a=t8.current;n._currentValue=a===Y?n._defaultValue:a,D(t8)}function vh(n,a,i){for(;null!==n;){var o=n.alternate;if((n.childLanes&a)!==a?(n.childLanes|=a,null!==o&&(o.childLanes|=a)):null!==o&&(o.childLanes&a)!==a&&(o.childLanes|=a),n===i)break;n=n.return}}function Gh(n,a,i){var o=n.child;for(null!==o&&(o.return=n);null!==o;){var s=o.dependencies;if(null!==s)for(var m=o.child,y=s.firstContext;null!==y;){if(y.context===a){if(1===o.tag){(y=Td(i&-i)).tag=2;var v=o.updateQueue;if(null!==v){var k=(v=v.shared).pending;null===k?y.next=y:(y.next=k.next,k.next=y),v.pending=y}}o.lanes|=i,null!==(y=o.alternate)&&(y.lanes|=i),vh(o.return,i,n),s.lanes|=i;break}y=y.next}else if(10===o.tag)m=o.type===n.type?null:o.child;else if(18===o.tag){if(null===(m=o.return))throw Error(t(341));m.lanes|=i,null!==(s=m.alternate)&&(s.lanes|=i),vh(m,i,n),m=o.sibling}else m=o.child;if(null!==m)m.return=o;else for(m=o;null!==m;){if(m===n){m=null;break}if(null!==(o=m.sibling)){o.return=m.return,m=o;break}m=m.return}o=m}}function Vg(n,a){t6=n,t7=t5=null,null!==(n=n.dependencies)&&null!==n.firstContext&&(0!=(n.lanes&a)&&(t3=!0),n.firstContext=null)}function Lf(n){return Hh(t6,n)}function ve(n,a,i){return null===t6&&Vg(n,i),Hh(n,a)}function Hh(n,a){var i=a._currentValue;if(t7!==a){if(a={context:a,memoizedValue:i,next:null},null===t5){if(null===n)throw Error(t(308));t5=a,n.dependencies={lanes:0,firstContext:a}}else t5=t5.next=a}return i}var t9="undefined"!=typeof AbortController?AbortController:function(){var n=[],a=this.signal={aborted:!1,addEventListener:function(a,i){n.push(i)}};this.abort=function(){a.aborted=!0,n.forEach(function(n){return n()})}},nt=m.unstable_scheduleCallback,nn=m.unstable_NormalPriority,nr={$$typeof:M,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0,_defaultValue:null,_globalName:null};function rg(){return{controller:new t9,data:new Map,refCount:0}}function Lh(n){n.refCount--,0===n.refCount&&nt(nn,function(){n.controller.abort()})}var na=k.ReactCurrentBatchConfig,ni=ia(null);function eh(){var n=ni.current;return null!==n?n:n_.pooledCache}function dh(n,a){null===a?E(ni,ni.current):E(ni,a.pool)}function nh(){var n=eh();return null===n?null:{parent:nr._currentValue,pool:n}}function Oh(n){n.flags|=4}function Ph(n){n.flags|=2097664}function Qh(n,a){if("stylesheet"!==a.type||0!=(4&a.state.loading))n.flags&=-16777217;else if(n.flags|=16777216,0==(42&nM)&&!(a="stylesheet"!==a.type||0!=(3&a.state.loading))){if(Rh())n.flags|=8192;else throw tk=tv,ty}}function Sh(n,a){null!==a?n.flags|=4:16384&n.flags&&(a=22!==n.tag?kb():1073741824,n.lanes|=a)}function Th(n,a){if(!to)switch(n.tailMode){case"hidden":a=n.tail;for(var i=null;null!==a;)null!==a.alternate&&(i=a),a=a.sibling;null===i?n.tail=null:i.sibling=null;break;case"collapsed":i=n.tail;for(var o=null;null!==i;)null!==i.alternate&&(o=i),i=i.sibling;null===o?a||null===n.tail?n.tail=null:n.tail.sibling=null:o.sibling=null}}function V(n){var a=null!==n.alternate&&n.alternate.child===n.child,i=0,o=0;if(a)for(var s=n.child;null!==s;)i|=s.lanes|s.childLanes,o|=31457280&s.subtreeFlags,o|=31457280&s.flags,s.return=n,s=s.sibling;else for(s=n.child;null!==s;)i|=s.lanes|s.childLanes,o|=s.subtreeFlags,o|=s.flags,s.return=n,s=s.sibling;return n.subtreeFlags|=o,n.childLanes=i,a}function ei(n,a){switch(md(a),a.tag){case 1:null!=(n=a.type.childContextTypes)&&Uc();break;case 3:Fh(nr),Ja(),D(e0),D(eX);break;case 26:case 27:case 5:La(a);break;case 4:Ja();break;case 13:Ke(a);break;case 19:D(tL);break;case 10:Fh(a.type._context);break;case 22:case 23:Ke(a),De(),null!==n&&D(ni);break;case 24:Fh(nr)}}function fi(n,a,i){var o=Array.prototype.slice.call(arguments,3);try{a.apply(i,o)}catch(n){this.onError(n)}}var no=!1,nu=null,nc=!1,ns=null,nf={onError:function(n){no=!0,nu=n}};function li(n,a,i,o,s,m,y,v,k){no=!1,nu=null,fi.apply(nf,arguments)}var nd=!1,np=!1,nb="function"==typeof WeakSet?WeakSet:Set,ny=null;function ri(n,a){try{var i=n.ref;if(null!==i){var o=n.stateNode;switch(n.tag){case 26:case 27:case 5:var s=o;break;default:s=o}"function"==typeof i?n.refCleanup=i(s):i.current=s}}catch(i){W(n,a,i)}}function si(n,a){var i=n.ref,o=n.refCleanup;if(null!==i){if("function"==typeof o)try{o()}catch(i){W(n,a,i)}finally{n.refCleanup=null,null!=(n=n.alternate)&&(n.refCleanup=null)}else if("function"==typeof i)try{i(null)}catch(i){W(n,a,i)}else i.current=null}}function ti(n,a,i){try{i()}catch(i){W(n,a,i)}}var nv=!1;function Ci(n,a,i){var o=a.updateQueue;if(null!==(o=null!==o?o.lastEffect:null)){var s=o=o.next;do{if((s.tag&n)===n){var m=s.inst,y=m.destroy;void 0!==y&&(m.destroy=void 0,ti(a,i,y))}s=s.next}while(s!==o)}}function Di(n,a){if(null!==(a=null!==(a=a.updateQueue)?a.lastEffect:null)){var i=a=a.next;do{if((i.tag&n)===n){var o=i.create,s=i.inst;o=o(),s.destroy=o}i=i.next}while(i!==a)}}function Ei(n,a){try{Di(a,n)}catch(a){W(n,n.return,a)}}function Fi(n){var a=n.updateQueue;if(null!==a){var i=n.stateNode;try{$d(a,i)}catch(a){W(n,n.return,a)}}}function Gi(n){var a=n.type,i=n.memoizedProps,o=n.stateNode;try{switch(a){case"button":case"input":case"select":case"textarea":i.autoFocus&&o.focus();break;case"img":i.src&&(o.src=i.src)}}catch(a){W(n,n.return,a)}}function Hi(n,a,i){var o=i.flags;switch(i.tag){case 0:case 11:case 15:Ii(n,i),4&o&&Ei(i,5);break;case 1:if(Ii(n,i),4&o){if(n=i.stateNode,null===a)try{n.componentDidMount()}catch(n){W(i,i.return,n)}else{var s=i.elementType===i.type?a.memoizedProps:wg(i.type,a.memoizedProps);a=a.memoizedState;try{n.componentDidUpdate(s,a,n.__reactInternalSnapshotBeforeUpdate)}catch(n){W(i,i.return,n)}}}64&o&&Fi(i),512&o&&ri(i,i.return);break;case 3:if(Ii(n,i),64&o&&null!==(o=i.updateQueue)){if(n=null,null!==i.child)switch(i.child.tag){case 27:case 5:case 1:n=i.child.stateNode}try{$d(o,n)}catch(n){W(i,i.return,n)}}break;case 26:Ii(n,i),512&o&&ri(i,i.return);break;case 27:case 5:Ii(n,i),null===a&&4&o&&Gi(i),512&o&&ri(i,i.return);break;case 12:default:Ii(n,i);break;case 13:Ii(n,i),4&o&&Ji(n,i);break;case 22:if(0!=(1&i.mode)){if(!(s=null!==i.memoizedState||nd)){a=null!==a&&null!==a.memoizedState||np;var m=nd,y=np;nd=s,(np=a)&&!y?function Ki(n,a,i){for(i=i&&0!=(8772&a.subtreeFlags),a=a.child;null!==a;){var o=a.alternate,s=n,m=a,y=m.flags;switch(m.tag){case 0:case 11:case 15:Ki(s,m,i),Ei(m,4);break;case 1:if(Ki(s,m,i),"function"==typeof(s=m.stateNode).componentDidMount)try{s.componentDidMount()}catch(n){W(m,m.return,n)}if(null!==(o=m.updateQueue)){var v=o.shared.hiddenCallbacks;if(null!==v)for(o.shared.hiddenCallbacks=null,o=0;o title"))),Zh(s,i,o),s[eP]=n,Jb(s),i=s;break e;case"link":var m=cj("link","href",a).get(i+(o.href||""));if(m){for(var y=0;y",n=n.removeChild(n.firstChild);break;case"select":n="string"==typeof o.is?s.createElement("select",{is:o.is}):s.createElement("select"),o.multiple?n.multiple=!0:o.size&&(n.size=o.size);break;default:n="string"==typeof o.is?s.createElement(i,{is:o.is}):s.createElement(i)}}n[eP]=a,n[eN]=o;e:for(s=a.child;null!==s;){if(5===s.tag||6===s.tag)n.appendChild(s.stateNode);else if(4!==s.tag&&27!==s.tag&&null!==s.child){s.child.return=s,s=s.child;continue}if(s===a)break;for(;null===s.sibling;){if(null===s.return||s.return===a)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}switch(a.stateNode=n,Zh(n,i,o),i){case"button":case"input":case"select":case"textarea":n=!!o.autoFocus;break;case"img":n=!0;break;default:n=!1}n&&Oh(a)}null!==a.ref&&Ph(a)}return V(a),a.flags&=-16777217,null;case 6:if(n&&null!=a.stateNode)n.memoizedProps!==o&&Oh(a);else{if("string"!=typeof o&&null===a.stateNode)throw Error(t(166));if(n=X.current,Bd(a)){e:{if(n=a.stateNode,i=a.memoizedProps,n[eP]=a,(o=n.nodeValue!==i)&&null!==(s=tl))switch(s.tag){case 3:if(s=0!=(1&s.mode),$h(n.nodeValue,i,s),s){n=!1;break e}break;case 27:case 5:var m=0!=(1&s.mode);if(!0!==s.memoizedProps.suppressHydrationWarning&&$h(n.nodeValue,i,m),m){n=!1;break e}}n=o}n&&Oh(a)}else(n=Yh(n).createTextNode(o))[eP]=a,a.stateNode=n}return V(a),null;case 13:if(Ke(a),o=a.memoizedState,null===n||null!==n.memoizedState&&null!==n.memoizedState.dehydrated){if(to&&null!==ta&&0!=(1&a.mode)&&0==(128&a.flags))Dd(),Ed(),a.flags|=384,s=!1;else if(s=Bd(a),null!==o&&null!==o.dehydrated){if(null===n){if(!s)throw Error(t(318));if(!(s=null!==(s=a.memoizedState)?s.dehydrated:null))throw Error(t(317));s[eP]=a}else Ed(),0==(128&a.flags)&&(a.memoizedState=null),a.flags|=4;V(a),s=!1}else null!==tu&&(Vh(tu),tu=null),s=!0;if(!s)return 256&a.flags?a:null}if(0!=(128&a.flags))return a.lanes=i,a;return i=null!==o,n=null!==n&&null!==n.memoizedState,i&&(o=a.child,s=null,null!==o.alternate&&null!==o.alternate.memoizedState&&null!==o.alternate.memoizedState.cachePool&&(s=o.alternate.memoizedState.cachePool.pool),m=null,null!==o.memoizedState&&null!==o.memoizedState.cachePool&&(m=o.memoizedState.cachePool.pool),m!==s&&(o.flags|=2048)),i!==n&&i&&(a.child.flags|=8192),Sh(a,a.updateQueue),V(a),null;case 4:return Ja(),null===n&&ai(a.stateNode.containerInfo),V(a),null;case 10:return Fh(a.type._context),V(a),null;case 19:if(D(tL),null===(s=a.memoizedState))return V(a),null;if(o=0!=(128&a.flags),null===(m=s.rendering)){if(o)Th(s,!1);else{if(0!==nV||null!==n&&0!=(128&n.flags))for(n=a.child;null!==n;){if(null!==(m=Le(n))){for(a.flags|=128,Th(s,!1),n=m.updateQueue,a.updateQueue=n,Sh(a,n),a.subtreeFlags=0,n=i,i=a.child;null!==i;)bi(i,n),i=i.sibling;return E(tL,1&tL.current|2),a.child}n=n.sibling}null!==s.tail&&ea()>nB&&(a.flags|=128,o=!0,Th(s,!1),a.lanes=8388608)}}else{if(!o){if(null!==(n=Le(m))){if(a.flags|=128,o=!0,n=n.updateQueue,a.updateQueue=n,Sh(a,n),Th(s,!0),null===s.tail&&"hidden"===s.tailMode&&!m.alternate&&!to)return V(a),null}else 2*ea()-s.renderingStartTime>nB&&1073741824!==i&&(a.flags|=128,o=!0,Th(s,!1),a.lanes=8388608)}s.isBackwards?(m.sibling=a.child,a.child=m):(null!==(n=s.last)?n.sibling=m:a.child=m,s.last=m)}if(null!==s.tail)return a=s.tail,s.rendering=a,s.tail=a.sibling,s.renderingStartTime=ea(),a.sibling=null,n=tL.current,E(tL,o?1&n|2:1&n),a;return V(a),null;case 22:case 23:return Ke(a),De(),o=null!==a.memoizedState,null!==n?null!==n.memoizedState!==o&&(a.flags|=8192):o&&(a.flags|=8192),o&&0!=(1&a.mode)?0!=(1073741824&i)&&0==(128&a.flags)&&(V(a),6&a.subtreeFlags&&(a.flags|=8192)):V(a),null!==(i=a.updateQueue)&&Sh(a,i.retryQueue),i=null,null!==n&&null!==n.memoizedState&&null!==n.memoizedState.cachePool&&(i=n.memoizedState.cachePool.pool),o=null,null!==a.memoizedState&&null!==a.memoizedState.cachePool&&(o=a.memoizedState.cachePool.pool),o!==i&&(a.flags|=2048),null!==n&&D(ni),null;case 24:return i=null,null!==n&&(i=n.memoizedState.cache),a.memoizedState.cache!==i&&(a.flags|=2048),Fh(nr),V(a),null;case 25:return null}throw Error(t(156,a.tag))}(a.alternate,a,nR);if(null!==i){nD=i;return}if(null!==(a=a.sibling)){nD=a;return}nD=a=n}while(null!==a);0===nV&&(nV=5)}function bf(n,a,i){var o=eC,s=nL.transition;try{nL.transition=null,eC=2,function(n,a,i,o){do We();while(null!==nX);if(0!=(6&nT))throw Error(t(327));var s=n.finishedWork,m=n.finishedLanes;if(null!==s){if(n.finishedWork=null,n.finishedLanes=0,s===n.current)throw Error(t(177));n.callbackNode=null,n.callbackPriority=0,n.cancelPendingCommit=null;var y=s.lanes|s.childLanes;if(function(n,a){var i=n.pendingLanes&~a;n.pendingLanes=a,n.suspendedLanes=0,n.pingedLanes=0,n.expiredLanes&=a,n.entangledLanes&=a,n.errorRecoveryDisabledLanes&=a,n.shellSuspendCounter=0,a=n.entanglements;var o=n.expirationTimes;for(n=n.hiddenUpdates;0o&&(s=o,o=m,m=s),s=Gm(i,m);var y=Gm(i,o);s&&y&&(1!==n.rangeCount||n.anchorNode!==s.node||n.anchorOffset!==s.offset||n.focusNode!==y.node||n.focusOffset!==y.offset)&&((a=a.createRange()).setStart(s.node,s.offset),n.removeAllRanges(),m>o?(n.addRange(a),n.extend(y.node,y.offset)):(a.setEnd(y.node,y.offset),n.addRange(a)))}}for(a=[],n=i;n=n.parentNode;)1===n.nodeType&&a.push({element:n,left:n.scrollLeft,top:n.scrollTop});for("function"==typeof i.focus&&i.focus(),i=0;ii?32:i;i=nL.transition;var s=eC;try{if(nL.transition=null,eC=o,null===nX)var m=!1;else{o=n2,n2=null;var y=nX,v=n0;if(nX=null,n0=0,0!=(6&nT))throw Error(t(331));var k=nT;if(nT|=4,yj(y.current),oj(y,y.current,v,o),nT=k,Ve(!1),eb&&"function"==typeof eb.onPostCommitFiberRoot)try{eb.onPostCommitFiberRoot(em,y)}catch(n){}m=!0}return m}finally{eC=s,nL.transition=i,ok(n,a)}}return!1}function pk(n,a,i){a=Gg(n,a=Dg(i,a),2),null!==(n=Ud(n,a,2))&&(mb(n,2),Se(n))}function W(n,a,i){if(3===n.tag)pk(n,n,i);else for(;null!==a;){if(3===a.tag){pk(a,n,i);break}if(1===a.tag){var o=a.stateNode;if("function"==typeof a.type.getDerivedStateFromError||"function"==typeof o.componentDidCatch&&(null===nK||!nK.has(o))){n=Jg(a,n=Dg(i,n),2),null!==(a=Ud(a,n,2))&&(mb(a,2),Se(a));break}}a=a.return}}function Pg(n,a,i){var o=n.pingCache;if(null===o){o=n.pingCache=new nx;var s=new Set;o.set(a,s)}else void 0===(s=o.get(a))&&(s=new Set,o.set(a,s));s.has(i)||(nI=!0,s.add(i),n=qk.bind(null,n,a,i),a.then(n,n))}function qk(n,a,i){var o=n.pingCache;null!==o&&o.delete(a),n.pingedLanes|=n.suspendedLanes&i,n_===n&&(nM&i)===i&&(4===nV||3===nV&&(125829120&nM)===nM&&300>ea()-n$?0==(2&nT)&&$e(n,0):nq|=i),Se(n)}function rk(n,a){0===a&&(a=0==(1&n.mode)?2:kb()),null!==(n=Md(n,a))&&(mb(n,a),Se(n))}function th(n){var a=n.memoizedState,i=0;null!==a&&(i=a.retryLane),rk(n,i)}function Yi(n,a){var i=0;switch(n.tag){case 13:var o=n.stateNode,s=n.memoizedState;null!==s&&(i=s.retryLane);break;case 19:o=n.stateNode;break;case 22:o=n.stateNode._retryCache;break;default:throw Error(t(314))}null!==o&&o.delete(a),rk(n,i)}function uk(n,a,i,o){this.tag=n,this.key=i,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function qd(n,a,i,o){return new uk(n,a,i,o)}function Yg(n){return!(!(n=n.prototype)||!n.isReactComponent)}function qe(n,a){var i=n.alternate;return null===i?((i=qd(n.tag,a,n.key,n.mode)).elementType=n.elementType,i.type=n.type,i.stateNode=n.stateNode,i.alternate=n,n.alternate=i):(i.pendingProps=a,i.type=n.type,i.flags=0,i.subtreeFlags=0,i.deletions=null),i.flags=31457280&n.flags,i.childLanes=n.childLanes,i.lanes=n.lanes,i.child=n.child,i.memoizedProps=n.memoizedProps,i.memoizedState=n.memoizedState,i.updateQueue=n.updateQueue,a=n.dependencies,i.dependencies=null===a?null:{lanes:a.lanes,firstContext:a.firstContext},i.sibling=n.sibling,i.index=n.index,i.ref=n.ref,i.refCleanup=n.refCleanup,i}function bi(n,a){n.flags&=31457282;var i=n.alternate;return null===i?(n.childLanes=0,n.lanes=a,n.child=null,n.subtreeFlags=0,n.memoizedProps=null,n.memoizedState=null,n.updateQueue=null,n.dependencies=null,n.stateNode=null):(n.childLanes=i.childLanes,n.lanes=i.lanes,n.child=i.child,n.subtreeFlags=0,n.deletions=null,n.memoizedProps=i.memoizedProps,n.memoizedState=i.memoizedState,n.updateQueue=i.updateQueue,n.type=i.type,a=i.dependencies,n.dependencies=null===a?null:{lanes:a.lanes,firstContext:a.firstContext}),n}function se(n,a,i,o,s,m,y){if(s=2,o=n,"function"==typeof n)Yg(n)&&(s=1);else if("string"==typeof n)s=!function(n,a,i){if(1===i||null!=a.itemProp)return!1;switch(n){case"meta":case"title":return!0;case"style":if("string"!=typeof a.precedence||"string"!=typeof a.href||""===a.href)break;return!0;case"link":if("string"!=typeof a.rel||"string"!=typeof a.href||""===a.href||a.onLoad||a.onError)break;if("stylesheet"===a.rel)return n=a.disabled,"string"==typeof a.precedence&&null==n;return!0;case"script":if(!0===a.async&&!a.onLoad&&!a.onError&&"string"==typeof a.src&&a.src)return!0}return!1}(n,i,K.current)?"html"===n||"head"===n||"body"===n?27:5:26;else e:switch(n){case N:return ue(i.children,m,y,a);case L:s=8,0!=(1&(m|=8))&&(m|=16);break;case _:return(n=qd(12,i,a,2|m)).elementType=_,n.lanes=y,n;case I:return(n=qd(13,i,a,m)).elementType=I,n.lanes=y,n;case R:return(n=qd(19,i,a,m)).elementType=R,n.lanes=y,n;case Q:return ph(i,m,y,a);case $:case H:case B:return(n=qd(24,i,a,m)).elementType=B,n.lanes=y,n;default:if("object"==typeof n&&null!==n)switch(n.$$typeof){case j:s=10;break e;case M:s=9;break e;case O:s=11;break e;case A:s=14;break e;case U:s=16,o=null;break e}throw Error(t(130,null==n?n:typeof n,""))}return(a=qd(s,i,a,m)).elementType=n,a.type=o,a.lanes=y,a}function ue(n,a,i,o){return(n=qd(7,n,o,a)).lanes=i,n}function ph(n,a,i,o){(n=qd(22,n,o,a)).elementType=Q,n.lanes=i;var s={_visibility:1,_pendingVisibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null,_current:null,detach:function(){var n=s._current;if(null===n)throw Error(t(456));if(0==(2&s._pendingVisibility)){var a=Md(n,2);null!==a&&(s._pendingVisibility|=2,Yf(a,n,2))}},attach:function(){var n=s._current;if(null===n)throw Error(t(456));if(0!=(2&s._pendingVisibility)){var a=Md(n,2);null!==a&&(s._pendingVisibility&=-3,Yf(a,n,2))}}};return n.stateNode=s,n}function re(n,a,i){return(n=qd(6,n,null,a)).lanes=i,n}function te(n,a,i){return(a=qd(4,null!==n.children?n.children:[],n.key,a)).lanes=i,a.stateNode={containerInfo:n.containerInfo,pendingChildren:null,implementation:n.implementation},a}function wk(n,a,i,o,s,m){this.tag=a,this.containerInfo=n,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=lb(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.finishedLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=lb(0),this.hiddenUpdates=lb(null),this.identifierPrefix=o,this.onRecoverableError=s,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=m,this.incompleteTransitions=new Map}function xk(n,a,i,o,s,m,y,v,k,C,x){return n=new wk(n,a,i,v,k,x),1===a?(a=1,!0===m&&(a|=24)):a=0,m=qd(3,null,null,a),n.current=m,m.stateNode=n,a=rg(),a.refCount++,n.pooledCache=a,a.refCount++,m.memoizedState={element:o,isDehydrated:i,cache:a},Rd(m),n}function zk(n){if(!n)return eJ;n=n._reactInternals;e:{if(Ic(n)!==n||1!==n.tag)throw Error(t(170));var a=n;do{switch(a.tag){case 3:a=a.stateNode.context;break e;case 1:if(Tc(a.type)){a=a.stateNode.__reactInternalMemoizedMergedChildContext;break e}}a=a.return}while(null!==a);throw Error(t(171))}if(1===n.tag){var i=n.type;if(Tc(i))return Wc(n,i,a)}return a}function Ak(n,a,i,o,s,m,y,v,k,C,x){return(n=xk(i,o,!0,n,s,m,y,v,k,C,x)).context=zk(null),(s=Td(o=qg(i=n.current))).callback=null!=a?a:null,Ud(i,s,o),n.current.lanes=o,mb(n,o),Se(n),n}function Bk(n,a,i,o){var s=a.current,m=qg(s);return i=zk(i),null===a.context?a.context=i:a.pendingContext=i,(a=Td(m)).payload={element:n},null!==(o=void 0===o?null:o)&&(a.callback=o),null!==(n=Ud(s,a,m))&&(Yf(n,s,m),Vd(n,s,m)),m}function Ck(n){return(n=n.current).child?(n.child.tag,n.child.stateNode):null}function Fk(n,a){if(null!==(n=n.memoizedState)&&null!==n.dehydrated){var i=n.retryLane;n.retryLane=0!==i&&i=rB),rG=!1;function fm(n,a){switch(n){case"keyup":return -1!==rQ.indexOf(a.keyCode);case"keydown":return 229!==a.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function hm(n){return"object"==typeof(n=n.detail)&&"data"in n?n.data:null}var rK=!1,rJ={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function mm(n){var a=n&&n.nodeName&&n.nodeName.toLowerCase();return"input"===a?!!rJ[n.type]:"textarea"===a}function nm(n,a,i,o){Gc(o),0<(a=om(a,"onChange")).length&&(i=new rc("onChange","change",null,i,o),n.push({event:i,listeners:a}))}var rX=null,r0=null;function rm(n){sm(n,0)}function tm(n){if(gc(Gb(n)))return n}function um(n,a){if("change"===n)return a}var r1=!1;if(eR){if(eR){var r2="oninput"in document;if(!r2){var r3=document.createElement("div");r3.setAttribute("oninput","return;"),r2="function"==typeof r3.oninput}o=r2}else o=!1;r1=o&&(!document.documentMode||9=a)return{node:o,offset:a-n};n=i}e:{for(;o;){if(o.nextSibling){o=o.nextSibling;break e}o=o.parentNode}o=void 0}o=Fm(o)}}function yi(){for(var n=window,a=hc();a instanceof n.HTMLIFrameElement;){try{var i="string"==typeof a.contentWindow.location.href}catch(n){i=!1}if(i)n=a.contentWindow;else break;a=hc(n.document)}return a}function zi(n){var a=n&&n.nodeName&&n.nodeName.toLowerCase();return a&&("input"===a&&("text"===n.type||"search"===n.type||"tel"===n.type||"url"===n.type||"password"===n.type)||"textarea"===a||"true"===n.contentEditable)}var r4=eR&&"documentMode"in document&&11>=document.documentMode,r8=null,r6=null,r5=null,r7=!1;function Nm(n,a,i){var o=i.window===i?i.document:9===i.nodeType?i:i.ownerDocument;r7||null==r8||r8!==hc(o)||(o="selectionStart"in(o=r8)&&zi(o)?{start:o.selectionStart,end:o.selectionEnd}:{anchorNode:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset},r5&&ae(r5,o)||(r5=o,0<(o=om(r6,"onSelect")).length&&(a=new rc("onSelect","select",null,a,i),n.push({event:a,listeners:o}),a.target=r8)))}function Om(n,a){var i={};return i[n.toLowerCase()]=a.toLowerCase(),i["Webkit"+n]="webkit"+a,i["Moz"+n]="moz"+a,i}var r9={animationend:Om("Animation","AnimationEnd"),animationiteration:Om("Animation","AnimationIteration"),animationstart:Om("Animation","AnimationStart"),transitionend:Om("Transition","TransitionEnd")},lt={},lr={};function Sm(n){if(lt[n])return lt[n];if(!r9[n])return n;var a,i=r9[n];for(a in i)if(i.hasOwnProperty(a)&&a in lr)return lt[n]=i[a];return n}eR&&(lr=document.createElement("div").style,"AnimationEvent"in window||(delete r9.animationend.animation,delete r9.animationiteration.animation,delete r9.animationstart.animation),"TransitionEvent"in window||delete r9.transitionend.transition);var ll=Sm("animationend"),la=Sm("animationiteration"),lo=Sm("animationstart"),lu=Sm("transitionend"),ls=new Map,lf="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Zm(n,a){ls.set(n,a),Mb(a,[n])}for(var lp=0;lp title"):null)}var lD=null;function Vj(){}function Pn(){if(this.count--,0===this.count){if(this.stylesheets)Qn(this,this.stylesheets);else if(this.unsuspend){var n=this.unsuspend;this.unsuspend=null,n()}}}var lM=null;function Qn(n,a){n.stylesheets=null,null!==n.unsuspend&&(n.count++,lM=new Map,a.forEach(Sn,n),lM=null,Pn.call(n))}function Sn(n,a){if(!(4&a.state.loading)){var i=lM.get(n);if(i)var o=i.get("last");else{i=new Map,lM.set(n,i);for(var s=n.querySelectorAll("link[data-precedence],style[data-precedence]"),m=0;m