PageSourceSearch

https://ztx.io/_next/static/chunks/88989-232e06c83515b1a7.js

js ztx.io collected 2026-10-01 15:57:57 UTC 16,831 bytes, 3 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[88989],{4711:function(e,t,n){function r(e){if(!e)return!1;let t=("string"==typeof e?e:e?.message||e?.data?.message||"").toLowerCase();return t.includes("insufficient funds")||t.includes("insufficient balance")||t.includes("insufficient")&&(t.includes("native")||t.includes("gas"))||e?.code==="INSUFFICIENT_FUNDS"||e?.reason==="insufficient funds"}function i(e){if(!e)return{message:"Unknown error"};let t="string"==typeof e?e:e?.message||e?.data?.message||String(e);return{code:e?.code||e?.reason,message:t}}n.d(t,{T:function(){return i},e:function(){return r}})},10793:function(e,t,n){n.d(t,{c:function(){return u},y:function(){return o}});var r=n(27677),i=n(4711),s=n(97514);async function o(e){var t;return t={...e,action:"transaction:sent"},(0,s.j)({client:t.client,data:{action:t.action,chainId:t.chainId,clientId:t.client.clientId,contractAddress:t.contractAddress,errorCode:(0,r.stringify)(t.error),functionName:t.functionName,gasPrice:t.gasPrice,transactionHash:t.transactionHash,walletAddress:t.walletAddress,walletType:t.walletType},ecosystem:t.ecosystem})}async function u(e){let t=(0,i.T)(e.error);return(0,s.j)({client:e.client,data:{action:"transaction:insufficient_funds",chainId:e.chainId,clientId:e.client.clientId,contractAddress:e.contractAddress,errorCode:t.code?(0,r.stringify)(t.code):void 0,errorMessage:t.message,functionName:e.functionName,requiredAmount:e.requiredAmount?.toString(),transactionValue:e.transactionValue?.toString(),userBalance:e.userBalance?.toString(),walletAddress:e.walletAddress},ecosystem:e.ecosystem})}},25250:function(e,t,n){n.r(t),n.d(t,{getRpcClient:function(){return a}});var r=n(10115),i=n(27677),s=n(66017);async function o(e,t,n){let r=await (0,s.getClientFetch)(t)(e,{body:(0,i.stringify)(n.requests),headers:{...t.config?.rpc?.fetch?.headers,"Content-Type":"application/json"},keepalive:t.config?.rpc?.fetch?.keepalive,method:"POST",requestTimeoutMs:n.requestTimeoutMs??t.config?.rpc?.fetch?.requestTimeoutMs});if(!r.ok){let e=await r.text().catch(()=>null);throw Error(`RPC request failed with status ${r.status} - ${r.statusText}: ${e||"unknown error"}`)}return await r.json()}async function u(e,t,n){let r=await (0,s.getClientFetch)(t)(e,{body:(0,i.stringify)(n.request),headers:{...t.config?.rpc?.fetch?.headers||{},"Content-Type":"application/json"},keepalive:t.config?.rpc?.fetch?.keepalive,method:"POST",requestTimeoutMs:n.requestTimeoutMs??t.config?.rpc?.fetch?.requestTimeoutMs});if(!r.ok){let e=await r.text().catch(()=>null);throw Error(`RPC request failed with status ${r.status} - ${r.statusText}: ${e||"unknown error"}`)}return await r.json()}let c=new WeakMap;function a(e){let t=function(e){if(c.has(e))return c.get(e);let t=new Map;return c.set(e,t),t}(e.client),n=e.chain.rpc;if(t.has(n))return t.get(n);let s=(()=>{let t=(0,r.GO)({chain:e.chain,client:e.client}),n=e.config?.maxBatchSize??e.client.config?.rpc?.maxBatchSize??100,s=e.config?.batchTimeoutMs??e.client.config?.rpc?.batchTimeoutMs??0,c=new Map,a=[],l=null;function f(){l&&(clearTimeout(l),l=null);let n=Array(a.length),r=a.slice().map((e,t)=>(e.request.id=t,e.request.jsonrpc="2.0",n[t]=e.request,e));a=[],o(t,e.client,{requests:n,requestTimeoutMs:e.config?.requestTimeoutMs}).then(e=>{r.forEach((r,s)=>{let o=e[s];o?o instanceof Error?r.reject(o):"error"in o?r.reject(o.error):"string"==typeof o?r.reject(Error(o)):"eth_subscription"===o.method?r.reject("Subscriptions not supported yet"):r.resolve(o.result):r.reject(Error(`RPC Error from ${t}:
2requests: ${(0,i.stringify)(n)}
3responses: ${(0,i.stringify)(e)}`))})}).catch(e=>{for(let t of r)t.reject(e)}).finally(()=>{c.clear()})}return 1===n?async n=>{n.id=1,n.jsonrpc="2.0";let r=await u(t,e.client,{request:n,requestTimeoutMs:e.config?.requestTimeoutMs});if(!r)throw Error("No response");if("error"in r)throw r.error;return r.result}:async e=>{let t,r;let o=`${e.method}:${(0,i.stringify)(e.params)}`;if(c.has(o))return c.get(o);let u=new Promise((e,n)=>{t=e,r=n});return c.set(o,u),a.push({reject:r,request:e,requestKey:o,resolve:t}),n>1?(l||(l=setTimeout(f,s)),a.length>=n&&f()):f(),u}})();return t.set(n,s),s}},114:function(e,t,n){n.d(t,{Kn:function(){return l},UJ:function(){return c},Xn:function(){return f},pm:function(){return h},xs:function(){return a}});var r=n(88445),i=n(16512),s=n(76375);let o=/^0x[a-fA-F0-9]{40}$/,u=new r.k(4096);function c(e){if(u.has(e))return u.get(e);
3let t=o.test(e)&&(e.toLowerCase()===e||a(e)===e);return u.set(e,t),t}function a(e){let t=e.substring(2).toLowerCase(),n=(0,s.w)((0,i.qX)(t),"bytes"),r=t.split("");for(let t=0;t<40;t+=2)n[t>>1]>>4>=8&&e[t]&&(r[t]=r[t].toUpperCase()),(15&n[t>>1])>=8&&e[t+1]&&(r[t+1]=r[t+1].toUpperCase());return`0x${r.join("")}`}function l(e){if(!c(e))throw Error(`Invalid address: ${e}`);return a(e)}function f(e,t=4){return h(l(e),t)}function h(e,t=4){return`${e.slice(0,t+2)}...${e.slice(-t)}`}},76375:function(e,t,n){n.d(t,{w:function(){return T}});var r=n(94572);let i=BigInt(4294967296-1),s=BigInt(32),o=(e,t,n)=>e<<n|t>>>32-n,u=(e,t,n)=>t<<n|e>>>32-n,c=(e,t,n)=>t<<n-32|e>>>64-n,a=(e,t,n)=>e<<n-32|t>>>64-n;var l=n(77184);let f=[],h=[],d=[],g=BigInt(0),p=BigInt(1),m=BigInt(2),y=BigInt(7),b=BigInt(256),w=BigInt(113);for(let e=0,t=p,n=1,r=0;e<24;e++){[n,r]=[r,(2*n+3*r)%5],f.push(2*(5*r+n)),h.push((e+1)*(e+2)/2%64);let i=g;for(let e=0;e<7;e++)(t=(t<<p^(t>>y)*w)%b)&m&&(i^=p<<(p<<BigInt(e))-p);d.push(i)}let[v,$]=function(e,t=!1){let n=new Uint32Array(e.length),r=new 
3Uint32Array(e.length);for(let o=0;o<e.length;o++){let{h:u,l:c}=function(e,t=!1){return t?{h:Number(e&i),l:Number(e>>s&i)}:{h:0|Number(e>>s&i),l:0|Number(e&i)}}(e[o],t);[n[o],r[o]]=[u,c]}return[n,r]}(d,!0),x=(e,t,n)=>n>32?c(e,t,n):o(e,t,n),z=(e,t,n)=>n>32?a(e,t,n):u(e,t,n);class k extends l.kb{constructor(e,t,n,i=!1,s=24){if(super(),this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,this.enableXOF=!1,this.blockLen=e,this.suffix=t,this.outputLen=n,this.enableXOF=i,this.rounds=s,(0,r.k8)(n),0>=this.blockLen||this.blockLen>=200)throw Error("Sha3 supports only keccak-f1600 function");this.state=new Uint8Array(200),this.state32=(0,l.Jq)(this.state)}keccak(){l.iA||(0,l.l1)(this.state32),function(e,t=24){let n=new Uint32Array(10);for(let r=24-t;r<24;r++){for(let t=0;t<10;t++)n[t]=e[t]^e[t+10]^e[t+20]^e[t+30]^e[t+40];for(let t=0;t<10;t+=2){let r=(t+8)%10,i=(t+2)%10,s=n[i],o=n[i+1],u=x(s,o,1)^n[r],c=z(s,o,1)^n[r+1];for(let n=0;n<50;n+=10)e[t+n]^=u,e[t+n+1]^=c}let t=e[2],i=e[3];for(let n=0;n<24;n++){let r=h[n],s=x(t,i,r),o=z(t,i,r),u=f[n];t=e[u],i=e[u+1],e[u]=s,e[u+1]=o}for(let t=0;t<50;t+=10){for(let r=0;r<10;r++)n[r]=e[t+r];for(let r=0;r<10;r++)e[t+r]^=~n[(r+2)%10]&n[(r+4)%10]}e[0]^=v[r],e[1]^=$[r]}n.fill(0)}(this.state32,this.rounds),l.iA||(0,l.l1)(this.state32),this.posOut=0,this.pos=0}update(e){(0,r.$h)(this);let{blockLen:t,state:n}=this,i=(e=(0,l.O0)(e)).length;for(let r=0;r<i;){let s=Math.min(t-this.pos,i-r);for(let t=0;t<s;t++)n[this.pos++]^=e[r++];this.pos===t&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;let{state:e,suffix:t,pos:n,blockLen:r}=this;e[n]^=t,(128&t)!=0&&n===r-1&&this.keccak(),e[r-1]^=128,this.keccak()}writeInto(e){(0,r.$h)(this,!1),(0,r.gk)(e),this.finish();let t=this.state,{blockLen:n}=this;for(let r=0,i=e.length;r<i;){this.posOut>=n&&this.keccak();let s=Math.min(n-this.posOut,i-r);e.set(t.subarray(this.posOut,this.posOut+s),r),this.posOut+=s,r+=s}return e}xofInto(e){if(!this.enableXOF)throw Error("XOF is not possible for this instance");return this.writeInto(e)}xof(e){return(0,r.k8)(e),this.xofInto(new Uint8Array(e))}digestInto(e){if((0,r.eB)(e,this),this.finished)throw Error("digest() was already called");return this.writeInto(e),this.destroy(),e}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,this.state.fill(0)}_cloneInto(e){let{blockLen:t,suffix:n,outputLen:r,rounds:i,enableXOF:s}=this;return e||(e=new k(t,n,r,s,i)),e.state32.set(this.state32),e.pos=this.pos,e.posOut=this.posOut,e.finished=this.finished,e.rounds=i,e.suffix=n,e.outputLen=r,e.enableXOF=s,e.destroyed=this.destroyed,e}}let I=(0,l.hE)(()=>new k(136,1,32));var A=n(9270),E=n(38323);function T(e,t){let n=I((0,A.v)(e,{strict:!1})?(0,E.GZ)(e):e);return"bytes"===t?n:(0,E.dg)(n)}},67949:function(e,t,n){n.d(t,{e:function(){return i}});var r=n(38323);function i(e=32){return(0,r.dg)(function(e=32){return globalThis.crypto.getRandomValues(new Uint8Array(e))}(e))}},56175:function(e,t,n){n.d(t,{D:function(){return r},L:function(){return i}});let r=["google","apple","facebook","discord","line","x","tiktok","epic","coinbase","farcaster","telegram","github","twitch","steam"],i=[...r,"guest","backend","email","phone","passkey","wallet"]},49688:function(e,t,n){n.d(t,{G:function(){return o},M:function(){return s}});let r="2.39.0",i={getDocsUrl:({docsBaseUrl:e,docsPath:t="",docsSlug:n})=>t?`${e??"https://viem.sh"}${t}${n?`#${n}`:""}`:void 0,version:`viem@${r}`};function s(e){i=e}class o extends Error{constructor(e,t={}){let n=t.cause instanceof o?t.cause.details:t.cause?.message?t.cause.message:t.details,s=t.cause instanceof o&&t.cause.docsPath||t.docsPath,u=i.getDocsUrl?.({...t,docsPath:s});super([e||"An error occurred.","",...t.metaMessages?[...t.metaMessages,""]:[],...u?[`Docs: ${u}`]:[],...n?[`Details: ${n}`]:[],...i.version?[`Version: ${i.version}`]:[]].join("\n"),t.cause?{cause:t.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.details=n,this.docsPath=s,this.metaMessages=t.metaMessages,this.name=t.name??this.name,this.shortMessage=e,this.version=r}walk(e){return function e(t,n){return n?.(t)?t:t&&"object"==typeof t&&"cause"in t&&void 0!==t.cause?e(t.cause,n):n?null:t}(this,e)}}},68452:function(e,t,n){n.d(t,{$s:function(){return s},W_:function(){return o},mV:function(){return i}});var r=n(49688);class i extends r.G{constructor({offset:e,position:t,size:n}){super(`Slice ${"start"===t?"starting":"ending"} at offset "${e}" is out-of-bounds (size: ${n}).`,{name:"SliceOffsetOutOfBoundsError"})}}class s extends r.G{constructor({size:e,targetSize:t,type:n}){super(`${n.charAt(0).toUpperCase()}${n.slice(1).toLowerCase()} size (${e}) exceeds padding size (${t}).`,{name:"SizeExceedsPaddingSizeError"})}}class o extends r.G{constructor({size:e,targetSize:t,type:n}){super(`${n.charAt(0).toUpperCase()}${n.slice(1).toLowerCase()} is expected to be ${t} ${n} long, but is ${e} ${n} long.`,{name:"InvalidBytesLengthError"})}}}
3,91682:function(e,t,n){n.d(t,{Cd:function(){return o},J5:function(){return i},M6:function(){return c},P9:function(){return u},yr:function(){return s}});var r=n(49688);class i extends r.G{constructor({max:e,min:t,signed:n,size:r,value:i}){super(`Number "${i}" is not in safe ${r?`${8*r}-bit ${n?"signed":"unsigned"} `:""}integer range ${e?`(${t} to ${e})`:`(above ${t})`}`,{name:"IntegerOutOfRangeError"})}}class s extends r.G{constructor(e){super(`Bytes value "${e}" is not a valid boolean. The bytes array must contain a single byte of either a 0 or 1 value.`,{name:"InvalidBytesBooleanError"})}}class o extends r.G{constructor(e){super(`Hex value "${e}" is not a valid boolean. The hex value must be "0x0" (false) or "0x1" (true).`,{name:"InvalidHexBooleanError"})}}class u extends r.G{constructor(e){super(`Hex value "${e}" is an odd length (${e.length}). It must be an even length.`,{name:"InvalidHexValueError"})}}class c extends r.G{constructor({givenSize:e,maxSize:t}){super(`Size cannot exceed ${t} bytes. Given size: ${e} bytes.`,{name:"SizeOverflowError"})}}},11255:function(e,t,n){n.d(t,{v:function(){return r}});function r(e,{strict:t=!0}={}){return!!e&&"string"==typeof e&&(t?/^0x[0-9a-fA-F]*$/.test(e):e.startsWith("0x"))}},42309:function(e,t,n){n.d(t,{gc:function(){return s},i3:function(){return o},vk:function(){return i}});var r=n(68452);function i(e,{dir:t,size:n=32}={}){return"string"==typeof e?s(e,{dir:t,size:n}):o(e,{dir:t,size:n})}function s(e,{dir:t,size:n=32}={}){if(null===n)return e;let i=e.replace("0x","");if(i.length>2*n)throw new r.$s({size:Math.ceil(i.length/2),targetSize:n,type:"hex"});return`0x${i["right"===t?"padEnd":"padStart"](2*n,"0")}`}function o(e,{dir:t,size:n=32}={}){if(null===n)return e;if(e.length>n)throw new r.$s({size:e.length,targetSize:n,type:"bytes"});let i=new Uint8Array(n);for(let r=0;r<n;r++){let s="right"===t;i[s?r:n-r-1]=e[s?r:e.length-r-1]}return i}},55715:function(e,t,n){n.d(t,{d:function(){return i}});var r=n(11255);function i(e){return(0,r.v)(e,{strict:!1})?Math.ceil((e.length-2)/2):e.length}},25416:function(e,t,n){n.d(t,{f:function(){return r}});function r(e,{dir:t="left"}={}){let n="string"==typeof e?e.replace("0x",""):e,r=0;for(let e=0;e<n.length-1&&"0"===n["left"===t?e:n.length-e-1].toString();e++)r++;return(n="left"===t?n.slice(r):n.slice(0,n.length-r),"string"==typeof e)?(1===n.length&&"right"===t&&(n=`${n}0`),`0x${n.length%2==1?`0${n}`:n}`):n}},7331:function(e,t,n){n.d(t,{H_:function(){return c},XA:function(){return l},Yf:function(){return u},ly:function(){return f},rR:function(){return h},y_:function(){return a}});var r=n(91682),i=n(55715),s=n(25416),o=n(15030);function u(e,{size:t}){if((0,i.d)(e)>t)throw new r.M6({givenSize:(0,i.d)(e),maxSize:t})}function c(e,t){let n="string"==typeof t?{to:t}:t,r=n.to;return"number"===r?f(e,n):"bigint"===r?a(e,n):"string"===r?h(e,n):"boolean"===r?l(e,n):(0,o.nr)(e,n)}function a(e,t={}){let{signed:n}=t;t.size&&u(e,{size:t.size});let r=BigInt(e);if(!n)return r;let i=(e.length-2)/2;return r<=(1n<<8n*BigInt(i)-1n)-1n?r:r-BigInt(`0x${"f".padStart(2*i,"f")}`)-1n}function l(e,t={}){let n=e;if(t.size&&(u(n,{size:t.size}),n=(0,s.f)(n)),"0x00"===(0,s.f)(n))return!1;if("0x01"===(0,s.f)(n))return!0;throw new r.Cd(n)}function f(e,t={}){return Number(a(e,t))}function h(e,t={}){let n=(0,o.nr)(e);return t.size&&(u(n,{size:t.size}),n=(0,s.f)(n,{dir:"right"})),new TextDecoder().decode(n)}},15030:function(e,t,n){n.d(t,{Cu:function(){return l},O0:function(){return a},hL:function(){return g},nr:function(){return d},qX:function(){return p}});var r=n(49688),i=n(11255),s=n(42309),o=n(7331),u=n(19810);let c=new TextEncoder;function a(e,t={}){return"number"==typeof e||"bigint"==typeof e?g(e,t):"boolean"==typeof e?l(e,t):(0,i.v)(e)?d(e,t):p(e,t)}function l(e,t={}){let n=new Uint8Array(1);return(n[0]=Number(e),"number"==typeof t.size)?((0,o.Yf)(n,{size:t.size}),(0,s.vk)(n,{size:t.size})):n}let f={zero:48,nine:57,A:65,F:70,a:97,f:102};function h(e){return e>=f.zero&&e<=f.nine?e-f.zero:e>=f.A&&e<=f.F?e-(f.A-10):e>=f.a&&e<=f.f?e-(f.a-10):void 0}function d(e,t={}){let n=e;t.size&&((0,o.Yf)(n,{size:t.size}),n=(0,s.vk)(n,{dir:"right",size:t.size}));let i=n.slice(2);i.length%2&&(i=`0${i}`);let u=i.length/2,c=new Uint8Array(u);for(let e=0,t=0;e<u;e++){let n=h(i.charCodeAt(t++)),s=h(i.charCodeAt(t++));if(void 0===n||void 0===s)throw new r.G(`Invalid byte sequence ("${i[t-2]}${i[t-1]}" in "${i}").`);c[e]=16*n+s}return c}function g(e,t){return d((0,u.eC)(e,t))}function p(e,t={}){let n=c.encode(e);return"number"==typeof t.size?((0,o.Yf)(n,{size:t.size}),(0,s.vk)(n,{dir:"right",size:t.size})):n}},19810:function(e,t,n){n.d(t,{$G:function(){return h},C4:function(){return c},NC:function(){return u},ci:function(){return a},eC:function(){return l}});var r=n(91682),i=n(42309),s=n(7331);let o=Array.from({length:256},(e,t)=>t.toString(16).padStart(2,"0"));function u(e,t={}){return"number"==typeof e||"bigint"==typeof e?l(e,t):"string"==typeof e?h(e,t):"boolean"==typeof e?c(e,t):a(e,t)}function c(e,t={}){let n=`0x${Number(e)}`;return"number"==typeof t.size?((0,s.Yf)(n,{size:t.size}),(0,i.vk)(n,{size:t.size})):n}function a(e,t={}){let n="";for(let t=0;t<e.length;t++)n+=o[e[t]];let r=`0x${n}`;return"number"==typeof t.size?((0,s.Yf)(r,{size:t.size}),(0,i.vk)(r,{dir:"right",size:t.size})):r}function l(e,t={}){let n;let{signed:s,size:o}=t,u=BigInt(e);o?n=s?(1n<<8n*BigInt(o)-1n)-1n:2n**(8n*BigInt(o))-1n:"number"==typeof e&&(n=BigInt(Number.MAX_SAFE_INTEGER));let c="bigint"==typeof n&&s?-n-1n:0;if(n&&u>n||u<c){let t="bigint"==typeof e?"n":"";throw new r.J5({max:n?`${n}${t}`:void 0,min:`${c}${t}`,signed:s,size:o,value:`${e}${t}`})}let a=`0x${(s&&u<0?(1n<<BigInt(8*o))+BigInt(u):u).toString(16)}`;return o?(0,i.vk)(a,{size:o}):a}let f=new TextEncoder;function h(e,t={}){return a(f.encode(e),t)}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.