@gardenfi/utils 2.5.2 → 2.5.3-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +37 -36
- package/dist/index10.cjs +1 -1
- package/dist/index10.js +4 -4
- package/dist/index11.cjs +1 -1
- package/dist/index11.js +16 -20
- package/dist/index112.cjs +1 -1
- package/dist/index112.js +15 -15
- package/dist/index121.cjs +1 -1
- package/dist/index121.js +1 -1
- package/dist/index130.cjs +1 -1
- package/dist/index130.js +1 -1
- package/dist/index16.cjs +1 -1
- package/dist/index16.js +4 -4
- package/dist/index18.cjs +1 -1
- package/dist/index18.js +20 -9
- package/dist/index197.cjs +1 -1
- package/dist/index197.js +17 -30
- package/dist/index22.cjs +1 -1
- package/dist/index22.js +84 -51
- package/dist/index226.cjs +1 -1
- package/dist/index226.js +2 -2
- package/dist/index229.cjs +1 -1
- package/dist/index229.js +2 -2
- package/dist/index230.cjs +1 -1
- package/dist/index230.js +1 -1
- package/dist/index234.cjs +1 -1
- package/dist/index234.js +7 -8
- package/dist/index235.cjs +1 -1
- package/dist/index235.js +1 -1
- package/dist/index236.cjs +1 -1
- package/dist/index236.js +1 -1
- package/dist/index237.cjs +1 -1
- package/dist/index237.js +2 -2
- package/dist/index24.cjs +1 -1
- package/dist/index24.js +30 -13
- package/dist/index249.cjs +1 -1
- package/dist/index249.js +3 -3
- package/dist/index25.cjs +1 -1
- package/dist/index25.js +30 -58
- package/dist/index250.cjs +1 -1
- package/dist/index250.js +3 -3
- package/dist/index256.cjs +1 -1
- package/dist/index256.js +17 -12
- package/dist/index26.cjs +1 -16
- package/dist/index26.js +11 -113
- package/dist/index269.cjs +1 -1
- package/dist/index269.js +4 -4
- package/dist/index27.cjs +1 -1
- package/dist/index27.js +58 -32
- package/dist/index270.cjs +1 -1
- package/dist/index270.js +5 -5
- package/dist/index271.cjs +1 -1
- package/dist/index271.js +27 -21
- package/dist/index272.cjs +1 -1
- package/dist/index272.js +54 -20
- package/dist/index273.cjs +1 -1
- package/dist/index273.js +18 -54
- package/dist/index274.cjs +1 -1
- package/dist/index274.js +10 -34
- package/dist/index275.cjs +1 -1
- package/dist/index275.js +7 -10
- package/dist/index276.cjs +1 -1
- package/dist/index276.js +12 -13
- package/dist/index277.cjs +1 -1
- package/dist/index277.js +11 -12
- package/dist/index28.cjs +1 -1
- package/dist/index28.js +13 -31
- package/dist/index280.cjs +1 -1
- package/dist/index280.js +103 -11
- package/dist/index281.cjs +1 -1
- package/dist/index281.js +6 -103
- package/dist/index282.cjs +1 -1
- package/dist/index282.js +243 -5
- package/dist/index283.cjs +1 -1
- package/dist/index283.js +6 -224
- package/dist/index284.cjs +1 -1
- package/dist/index284.js +7 -7
- package/dist/index285.cjs +1 -1
- package/dist/index285.js +27 -7
- package/dist/index286.cjs +1 -1
- package/dist/index286.js +18 -25
- package/dist/index287.cjs +1 -1
- package/dist/index287.js +145 -18
- package/dist/index288.cjs +1 -1
- package/dist/index288.js +3 -146
- package/dist/index289.cjs +1 -1
- package/dist/index289.js +155 -3
- package/dist/index29.cjs +16 -1
- package/dist/index29.js +113 -11
- package/dist/index290.cjs +1 -1
- package/dist/index290.js +7 -138
- package/dist/index291.cjs +1 -1
- package/dist/index291.js +128 -143
- package/dist/index292.cjs +1 -1
- package/dist/index292.js +111 -7
- package/dist/index293.cjs +2 -1
- package/dist/index293.js +116 -95
- package/dist/index294.cjs +1 -2
- package/dist/index294.js +35 -127
- package/dist/index295.cjs +1 -1
- package/dist/index295.js +66 -30
- package/dist/index296.cjs +1 -1
- package/dist/index296.js +2 -79
- package/dist/index297.cjs +1 -1
- package/dist/index297.js +12 -2
- package/dist/index298.cjs +1 -1
- package/dist/index298.js +19 -11
- package/dist/index299.cjs +1 -1
- package/dist/index299.js +68 -19
- package/dist/index3.cjs +1 -1
- package/dist/index3.js +10 -8
- package/dist/index300.cjs +1 -1
- package/dist/index300.js +786 -66
- package/dist/index301.cjs +1 -1
- package/dist/index301.js +134 -684
- package/dist/index302.cjs +1 -1
- package/dist/index302.js +185 -124
- package/dist/index303.cjs +2 -1
- package/dist/index303.js +63 -198
- package/dist/index304.cjs +1 -2
- package/dist/index304.js +7 -66
- package/dist/index305.cjs +1 -1
- package/dist/index305.js +62 -4
- package/dist/index306.cjs +1 -1
- package/dist/index306.js +22 -40
- package/dist/index307.cjs +1 -1
- package/dist/index307.js +5 -7
- package/dist/index308.cjs +1 -1
- package/dist/index308.js +72 -57
- package/dist/index309.cjs +1 -1
- package/dist/index309.js +4 -78
- package/dist/index310.cjs +1 -1
- package/dist/index310.js +195 -4
- package/dist/index311.cjs +1 -1
- package/dist/index311.js +4 -194
- package/dist/index312.cjs +1 -1
- package/dist/index312.js +35 -58
- package/dist/index313.cjs +2 -1
- package/dist/index313.js +40 -43
- package/dist/index314.cjs +1 -1
- package/dist/index314.js +2 -5
- package/dist/index315.cjs +1 -1
- package/dist/index315.js +11 -5
- package/dist/index316.cjs +1 -1
- package/dist/index316.js +20 -2
- package/dist/index317.cjs +1 -1
- package/dist/index317.js +8 -21
- package/dist/index318.cjs +1 -0
- package/dist/index318.js +45 -0
- package/dist/index319.cjs +1 -0
- package/dist/index319.js +69 -0
- package/dist/index320.cjs +1 -0
- package/dist/index320.js +68 -0
- package/dist/index321.cjs +1 -0
- package/dist/index321.js +191 -0
- package/dist/index322.cjs +1 -0
- package/dist/index322.js +79 -0
- package/dist/index323.cjs +1 -0
- package/dist/index323.js +43 -0
- package/dist/index324.cjs +1 -0
- package/dist/index324.js +19 -0
- package/dist/index325.cjs +1 -0
- package/dist/index325.js +16 -0
- package/dist/index326.cjs +1 -0
- package/dist/index326.js +7 -0
- package/dist/index327.cjs +1 -0
- package/dist/index327.js +66 -0
- package/dist/index328.cjs +1 -0
- package/dist/index328.js +7 -0
- package/dist/index329.cjs +1 -0
- package/dist/index329.js +47 -0
- package/dist/index330.cjs +1 -0
- package/dist/index330.js +71 -0
- package/dist/index331.cjs +1 -0
- package/dist/index331.js +4 -0
- package/dist/index332.cjs +1 -0
- package/dist/index332.js +24 -0
- package/dist/index55.cjs +1 -1
- package/dist/index55.js +1 -1
- package/dist/index58.cjs +1 -1
- package/dist/index58.js +35 -34
- package/dist/index60.cjs +1 -1
- package/dist/index60.js +26 -30
- package/dist/index61.cjs +1 -1
- package/dist/index61.js +13 -9
- package/dist/index62.cjs +1 -1
- package/dist/index62.js +19 -19
- package/dist/index89.cjs +1 -1
- package/dist/index89.js +31 -30
- package/dist/index9.cjs +1 -1
- package/dist/index9.js +2 -2
- package/dist/index95.cjs +1 -1
- package/dist/index95.js +73 -73
- package/dist/src/lib/auth/apikey/apikey.d.ts +1 -1
- package/dist/src/lib/auth/auth.types.d.ts +1 -1
- package/dist/src/lib/fetcher/fetcher.d.ts +2 -0
- package/dist/src/lib/utils.d.ts +1 -0
- package/package.json +2 -2
package/dist/index22.js
CHANGED
|
@@ -92,24 +92,53 @@ const t = [
|
|
|
92
92
|
}
|
|
93
93
|
], e = [
|
|
94
94
|
{
|
|
95
|
-
inputs: [
|
|
96
|
-
|
|
95
|
+
inputs: [
|
|
96
|
+
{
|
|
97
|
+
name: "dns",
|
|
98
|
+
type: "bytes"
|
|
99
|
+
}
|
|
100
|
+
],
|
|
101
|
+
name: "DNSDecodingFailed",
|
|
102
|
+
type: "error"
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
inputs: [
|
|
106
|
+
{
|
|
107
|
+
name: "ens",
|
|
108
|
+
type: "string"
|
|
109
|
+
}
|
|
110
|
+
],
|
|
111
|
+
name: "DNSEncodingFailed",
|
|
97
112
|
type: "error"
|
|
98
113
|
},
|
|
99
114
|
{
|
|
100
115
|
inputs: [],
|
|
101
|
-
name: "
|
|
116
|
+
name: "EmptyAddress",
|
|
117
|
+
type: "error"
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
inputs: [
|
|
121
|
+
{
|
|
122
|
+
name: "status",
|
|
123
|
+
type: "uint16"
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
name: "message",
|
|
127
|
+
type: "string"
|
|
128
|
+
}
|
|
129
|
+
],
|
|
130
|
+
name: "HttpError",
|
|
102
131
|
type: "error"
|
|
103
132
|
},
|
|
104
133
|
{
|
|
105
134
|
inputs: [],
|
|
106
|
-
name: "
|
|
135
|
+
name: "InvalidBatchGatewayResponse",
|
|
107
136
|
type: "error"
|
|
108
137
|
},
|
|
109
138
|
{
|
|
110
139
|
inputs: [
|
|
111
140
|
{
|
|
112
|
-
name: "
|
|
141
|
+
name: "errorData",
|
|
113
142
|
type: "bytes"
|
|
114
143
|
}
|
|
115
144
|
],
|
|
@@ -119,40 +148,56 @@ const t = [
|
|
|
119
148
|
{
|
|
120
149
|
inputs: [
|
|
121
150
|
{
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
name: "message",
|
|
129
|
-
type: "string"
|
|
130
|
-
}
|
|
131
|
-
],
|
|
132
|
-
name: "errors",
|
|
133
|
-
type: "tuple[]"
|
|
151
|
+
name: "name",
|
|
152
|
+
type: "bytes"
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
name: "resolver",
|
|
156
|
+
type: "address"
|
|
134
157
|
}
|
|
135
158
|
],
|
|
136
|
-
name: "
|
|
159
|
+
name: "ResolverNotContract",
|
|
137
160
|
type: "error"
|
|
138
|
-
}
|
|
139
|
-
], a = [
|
|
140
|
-
...e,
|
|
161
|
+
},
|
|
141
162
|
{
|
|
142
|
-
name: "resolve",
|
|
143
|
-
type: "function",
|
|
144
|
-
stateMutability: "view",
|
|
145
163
|
inputs: [
|
|
146
|
-
{
|
|
147
|
-
|
|
164
|
+
{
|
|
165
|
+
name: "name",
|
|
166
|
+
type: "bytes"
|
|
167
|
+
}
|
|
148
168
|
],
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
169
|
+
name: "ResolverNotFound",
|
|
170
|
+
type: "error"
|
|
171
|
+
},
|
|
172
|
+
{
|
|
173
|
+
inputs: [
|
|
174
|
+
{
|
|
175
|
+
name: "primary",
|
|
176
|
+
type: "string"
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
name: "primaryAddress",
|
|
180
|
+
type: "bytes"
|
|
181
|
+
}
|
|
182
|
+
],
|
|
183
|
+
name: "ReverseAddressMismatch",
|
|
184
|
+
type: "error"
|
|
153
185
|
},
|
|
154
186
|
{
|
|
155
|
-
|
|
187
|
+
inputs: [
|
|
188
|
+
{
|
|
189
|
+
internalType: "bytes4",
|
|
190
|
+
name: "selector",
|
|
191
|
+
type: "bytes4"
|
|
192
|
+
}
|
|
193
|
+
],
|
|
194
|
+
name: "UnsupportedResolverProfile",
|
|
195
|
+
type: "error"
|
|
196
|
+
}
|
|
197
|
+
], a = [
|
|
198
|
+
...e,
|
|
199
|
+
{
|
|
200
|
+
name: "resolveWithGateways",
|
|
156
201
|
type: "function",
|
|
157
202
|
stateMutability: "view",
|
|
158
203
|
inputs: [
|
|
@@ -168,30 +213,18 @@ const t = [
|
|
|
168
213
|
], s = [
|
|
169
214
|
...e,
|
|
170
215
|
{
|
|
171
|
-
name: "
|
|
172
|
-
type: "function",
|
|
173
|
-
stateMutability: "view",
|
|
174
|
-
inputs: [{ type: "bytes", name: "reverseName" }],
|
|
175
|
-
outputs: [
|
|
176
|
-
{ type: "string", name: "resolvedName" },
|
|
177
|
-
{ type: "address", name: "resolvedAddress" },
|
|
178
|
-
{ type: "address", name: "reverseResolver" },
|
|
179
|
-
{ type: "address", name: "resolver" }
|
|
180
|
-
]
|
|
181
|
-
},
|
|
182
|
-
{
|
|
183
|
-
name: "reverse",
|
|
216
|
+
name: "reverseWithGateways",
|
|
184
217
|
type: "function",
|
|
185
218
|
stateMutability: "view",
|
|
186
219
|
inputs: [
|
|
187
220
|
{ type: "bytes", name: "reverseName" },
|
|
221
|
+
{ type: "uint256", name: "coinType" },
|
|
188
222
|
{ type: "string[]", name: "gateways" }
|
|
189
223
|
],
|
|
190
224
|
outputs: [
|
|
191
225
|
{ type: "string", name: "resolvedName" },
|
|
192
|
-
{ type: "address", name: "
|
|
193
|
-
{ type: "address", name: "reverseResolver" }
|
|
194
|
-
{ type: "address", name: "resolver" }
|
|
226
|
+
{ type: "address", name: "resolver" },
|
|
227
|
+
{ type: "address", name: "reverseResolver" }
|
|
195
228
|
]
|
|
196
229
|
}
|
|
197
230
|
], p = [
|
|
@@ -223,7 +256,7 @@ const t = [
|
|
|
223
256
|
],
|
|
224
257
|
outputs: [{ name: "", type: "bytes" }]
|
|
225
258
|
}
|
|
226
|
-
],
|
|
259
|
+
], y = [
|
|
227
260
|
{
|
|
228
261
|
inputs: [
|
|
229
262
|
{
|
|
@@ -266,7 +299,7 @@ const t = [
|
|
|
266
299
|
type: "function",
|
|
267
300
|
name: "isValidSig"
|
|
268
301
|
}
|
|
269
|
-
],
|
|
302
|
+
], r = [
|
|
270
303
|
{
|
|
271
304
|
type: "event",
|
|
272
305
|
name: "Approval",
|
|
@@ -457,10 +490,10 @@ const t = [
|
|
|
457
490
|
export {
|
|
458
491
|
i as addressResolverAbi,
|
|
459
492
|
n as batchGatewayAbi,
|
|
460
|
-
|
|
493
|
+
r as erc20Abi,
|
|
461
494
|
t as multicall3Abi,
|
|
462
495
|
p as textResolverAbi,
|
|
463
496
|
a as universalResolverResolveAbi,
|
|
464
497
|
s as universalResolverReverseAbi,
|
|
465
|
-
|
|
498
|
+
y as universalSignatureValidatorAbi
|
|
466
499
|
};
|
package/dist/index226.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index283.cjs"),r=require("./index284.cjs");function n(t){return e.hashSignature(r.toSignature(t))}exports.toSignatureHash=n;
|
package/dist/index226.js
CHANGED
package/dist/index229.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const f=require("./index286.cjs"),c=require("./index287.cjs"),A=BigInt(0),u=BigInt(1),H=BigInt(2),L=BigInt(7),S=BigInt(256),T=BigInt(113),O=[],y=[],w=[];for(let n=0,t=u,s=1,i=0;n<24;n++){[s,i]=[i,(2*s+3*i)%5],O.push(2*(5*i+s)),y.push((n+1)*(n+2)/2%64);let o=A;for(let r=0;r<7;r++)t=(t<<u^(t>>L)*T)%S,t&H&&(o^=u<<(u<<BigInt(r))-u);w.push(o)}const _=f.split(w,!0),F=_[0],X=_[1],I=(n,t,s)=>s>32?f.rotlBH(n,t,s):f.rotlSH(n,t,s),x=(n,t,s)=>s>32?f.rotlBL(n,t,s):f.rotlSL(n,t,s);function b(n,t=24){const s=new Uint32Array(10);for(let i=24-t;i<24;i++){for(let e=0;e<10;e++)s[e]=n[e]^n[e+10]^n[e+20]^n[e+30]^n[e+40];for(let e=0;e<10;e+=2){const h=(e+8)%10,l=(e+2)%10,p=s[l],a=s[l+1],g=I(p,a,1)^s[h],B=x(p,a,1)^s[h+1];for(let d=0;d<50;d+=10)n[e+d]^=g,n[e+d+1]^=B}let o=n[2],r=n[3];for(let e=0;e<24;e++){const h=y[e],l=I(o,r,h),p=x(o,r,h),a=O[e];o=n[a],r=n[a+1],n[a]=l,n[a+1]=p}for(let e=0;e<50;e+=10){for(let h=0;h<10;h++)s[h]=n[e+h];for(let h=0;h<10;h++)n[e+h]^=~s[(h+2)%10]&s[(h+4)%10]}n[0]^=F[i],n[1]^=X[i]}c.clean(s)}class k extends c.Hash{constructor(t,s,i,o=!1,r=24){if(super(),this.pos=0,this.posOut=0,this.finished=!1,this.destroyed=!1,this.enableXOF=!1,this.blockLen=t,this.suffix=s,this.outputLen=i,this.enableXOF=o,this.rounds=r,c.anumber(i),!(0<t&&t<200))throw new Error("only keccak-f1600 function is supported");this.state=new Uint8Array(200),this.state32=c.u32(this.state)}clone(){return this._cloneInto()}keccak(){c.swap32IfBE(this.state32),b(this.state32,this.rounds),c.swap32IfBE(this.state32),this.posOut=0,this.pos=0}update(t){c.aexists(this),t=c.toBytes(t),c.abytes(t);const{blockLen:s,state:i}=this,o=t.length;for(let r=0;r<o;){const e=Math.min(s-this.pos,o-r);for(let h=0;h<e;h++)i[this.pos++]^=t[r++];this.pos===s&&this.keccak()}return this}finish(){if(this.finished)return;this.finished=!0;const{state:t,suffix:s,pos:i,blockLen:o}=this;t[i]^=s,s&128&&i===o-1&&this.keccak(),t[o-1]^=128,this.keccak()}writeInto(t){c.aexists(this,!1),c.abytes(t),this.finish();const s=this.state,{blockLen:i}=this;for(let o=0,r=t.length;o<r;){this.posOut>=i&&this.keccak();const e=Math.min(i-this.posOut,r-o);t.set(s.subarray(this.posOut,this.posOut+e),o),this.posOut+=e,o+=e}return t}xofInto(t){if(!this.enableXOF)throw new Error("XOF is not possible for this instance");return this.writeInto(t)}xof(t){return c.anumber(t),this.xofInto(new Uint8Array(t))}digestInto(t){if(c.aoutput(t,this),this.finished)throw new Error("digest() was already called");return this.writeInto(t),this.destroy(),t}digest(){return this.digestInto(new Uint8Array(this.outputLen))}destroy(){this.destroyed=!0,c.clean(this.state)}_cloneInto(t){const{blockLen:s,suffix:i,outputLen:o,rounds:r,enableXOF:e}=this;return t||(t=new k(s,i,o,e,r)),t.state32.set(this.state32),t.pos=this.pos,t.posOut=this.posOut,t.finished=this.finished,t.rounds=r,t.suffix=i,t.outputLen=o,t.enableXOF=e,t.destroyed=this.destroyed,t}}const m=(n,t,s)=>c.createHasher(()=>new k(t,n,s)),E=m(1,136,256/8);exports.Keccak=k;exports.keccakP=b;exports.keccak_256=E;
|
package/dist/index229.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { split as L, rotlSH as T, rotlSL as S, rotlBH as m, rotlBL as F } from "./
|
|
2
|
-
import { createHasher as X, Hash as E, anumber as d, u32 as U, swap32IfBE as I, aexists as x, toBytes as P, abytes as k, aoutput as M, clean as y } from "./
|
|
1
|
+
import { split as L, rotlSH as T, rotlSL as S, rotlBH as m, rotlBL as F } from "./index286.js";
|
|
2
|
+
import { createHasher as X, Hash as E, anumber as d, u32 as U, swap32IfBE as I, aexists as x, toBytes as P, abytes as k, aoutput as M, clean as y } from "./index287.js";
|
|
3
3
|
const R = BigInt(0), f = BigInt(1), j = BigInt(2), q = BigInt(7), v = BigInt(256), z = BigInt(113), _ = [], g = [], B = [];
|
|
4
4
|
for (let n = 0, t = f, s = 1, i = 0; n < 24; n++) {
|
|
5
5
|
[s, i] = [i, (2 * s + 3 * i) % 5], _.push(2 * (5 * i + s)), g.push((n + 1) * (n + 2) / 2 % 64);
|
package/dist/index230.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index280.cjs"),s=e.sha256;exports.sha256=s;
|
package/dist/index230.js
CHANGED
package/dist/index234.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index41.cjs"),i=require("./index132.cjs");function f(e){var t,o,a,n,s,u;if(!(e instanceof c.BaseError))return!1;const r=e.walk(l=>l instanceof i.ContractFunctionRevertedError);return r instanceof i.ContractFunctionRevertedError?((t=r.data)==null?void 0:t.errorName)==="HttpError"||((o=r.data)==null?void 0:o.errorName)==="ResolverError"||((a=r.data)==null?void 0:a.errorName)==="ResolverNotContract"||((n=r.data)==null?void 0:n.errorName)==="ResolverNotFound"||((s=r.data)==null?void 0:s.errorName)==="ReverseAddressMismatch"||((u=r.data)==null?void 0:u.errorName)==="UnsupportedResolverProfile":!1}exports.isNullUniversalResolverError=f;
|
package/dist/index234.js
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { BaseError as c } from "./index41.js";
|
|
1
|
+
import { BaseError as l } from "./index41.js";
|
|
3
2
|
import { ContractFunctionRevertedError as i } from "./index132.js";
|
|
4
|
-
function
|
|
5
|
-
var t, o,
|
|
6
|
-
if (!(e instanceof
|
|
3
|
+
function c(e) {
|
|
4
|
+
var t, o, a, n, s, u;
|
|
5
|
+
if (!(e instanceof l))
|
|
7
6
|
return !1;
|
|
8
|
-
const r = e.walk((
|
|
9
|
-
return r instanceof i ?
|
|
7
|
+
const r = e.walk((f) => f instanceof i);
|
|
8
|
+
return r instanceof i ? ((t = r.data) == null ? void 0 : t.errorName) === "HttpError" || ((o = r.data) == null ? void 0 : o.errorName) === "ResolverError" || ((a = r.data) == null ? void 0 : a.errorName) === "ResolverNotContract" || ((n = r.data) == null ? void 0 : n.errorName) === "ResolverNotFound" || ((s = r.data) == null ? void 0 : s.errorName) === "ReverseAddressMismatch" || ((u = r.data) == null ? void 0 : u.errorName) === "UnsupportedResolverProfile" : !1;
|
|
10
9
|
}
|
|
11
10
|
export {
|
|
12
|
-
|
|
11
|
+
c as isNullUniversalResolverError
|
|
13
12
|
};
|
package/dist/index235.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./index154.cjs"),a=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./index154.cjs"),a=require("./index288.cjs"),c=require("./index153.cjs");function h(i){const r=i.replace(/^\.|\.$/gm,"");if(r.length===0)return new Uint8Array(1);const e=new Uint8Array(l.stringToBytes(r).byteLength+2);let t=0;const o=r.split(".");for(let s=0;s<o.length;s++){let n=l.stringToBytes(o[s]);n.byteLength>255&&(n=l.stringToBytes(a.encodeLabelhash(c.labelhash(o[s])))),e[t]=n.length,e.set(n,t+1),t+=n.length+1}return e.byteLength!==t+1?e.slice(0,t+1):e}exports.packetToBytes=h;
|
package/dist/index235.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { stringToBytes as i } from "./index154.js";
|
|
2
|
-
import { encodeLabelhash as h } from "./
|
|
2
|
+
import { encodeLabelhash as h } from "./index288.js";
|
|
3
3
|
import { labelhash as f } from "./index153.js";
|
|
4
4
|
function y(s) {
|
|
5
5
|
const o = s.replace(/^\.|\.$/gm, "");
|
package/dist/index236.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index291.cjs");async function f(i,{gatewayUrls:t,record:r}){return/eip155:/i.test(r)?l(i,{gatewayUrls:t,record:r}):e.parseAvatarUri({uri:r,gatewayUrls:t})}async function l(i,{gatewayUrls:t,record:r}){const n=e.parseNftUri(r),o=await e.getNftTokenUri(i,{nft:n}),{uri:a,isOnChain:c,isEncoded:p}=e.resolveAvatarUri({uri:o,gatewayUrls:t});if(c&&(a.includes("data:application/json;base64,")||a.startsWith("{"))){const u=p?atob(a.replace("data:application/json;base64,","")):a,d=JSON.parse(u);return e.parseAvatarUri({uri:e.getJsonImage(d),gatewayUrls:t})}let s=n.tokenID;return n.namespace==="erc1155"&&(s=s.replace("0x","").padStart(64,"0")),e.getMetadataAvatarUri({gatewayUrls:t,uri:a.replace(/(?:0x)?{id}/,s)})}exports.parseAvatarRecord=f;
|
package/dist/index236.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { parseAvatarUri as o, parseNftUri as f, getNftTokenUri as v, resolveAvatarUri as l, getJsonImage as A, getMetadataAvatarUri as N } from "./
|
|
1
|
+
import { parseAvatarUri as o, parseNftUri as f, getNftTokenUri as v, resolveAvatarUri as l, getJsonImage as A, getMetadataAvatarUri as N } from "./index291.js";
|
|
2
2
|
async function b(r, { gatewayUrls: t, record: e }) {
|
|
3
3
|
return /eip155:/i.test(e) ? U(r, { gatewayUrls: t, record: e }) : o({ uri: e, gatewayUrls: t });
|
|
4
4
|
}
|
package/dist/index237.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index289.cjs"),a=require("./index290.cjs");function i(t){return{...typeof t.baseFeePerGas=="bigint"&&{baseFeePerGas:e.fromNumber(t.baseFeePerGas)},...typeof t.blobBaseFee=="bigint"&&{blobBaseFee:e.fromNumber(t.blobBaseFee)},...typeof t.feeRecipient=="string"&&{feeRecipient:t.feeRecipient},...typeof t.gasLimit=="bigint"&&{gasLimit:e.fromNumber(t.gasLimit)},...typeof t.number=="bigint"&&{number:e.fromNumber(t.number)},...typeof t.prevRandao=="bigint"&&{prevRandao:e.fromNumber(t.prevRandao)},...typeof t.time=="bigint"&&{time:e.fromNumber(t.time)},...t.withdrawals&&{withdrawals:t.withdrawals.map(a.toRpc)}}}exports.toRpc=i;
|
package/dist/index237.js
CHANGED
package/dist/index24.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index218.cjs"),a=e.defineChain({id:11155111,name:"Sepolia",nativeCurrency:{name:"Sepolia Ether",symbol:"ETH",decimals:18},rpcUrls:{default:{http:["https://sepolia.drpc.org"]}},blockExplorers:{default:{name:"Etherscan",url:"https://sepolia.etherscan.io",apiUrl:"https://api-sepolia.etherscan.io/api"}},contracts:{multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:751532},ensUniversalResolver:{address:"0xeeeeeeee14d718c2b47d9923deab1335e144eeee",blockCreated:8928790}},testnet:!0});exports.sepolia=a;
|
package/dist/index24.js
CHANGED
|
@@ -1,15 +1,32 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
import { defineChain as e } from "./index218.js";
|
|
2
|
+
const t = /* @__PURE__ */ e({
|
|
3
|
+
id: 11155111,
|
|
4
|
+
name: "Sepolia",
|
|
5
|
+
nativeCurrency: { name: "Sepolia Ether", symbol: "ETH", decimals: 18 },
|
|
6
|
+
rpcUrls: {
|
|
7
|
+
default: {
|
|
8
|
+
http: ["https://sepolia.drpc.org"]
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
blockExplorers: {
|
|
12
|
+
default: {
|
|
13
|
+
name: "Etherscan",
|
|
14
|
+
url: "https://sepolia.etherscan.io",
|
|
15
|
+
apiUrl: "https://api-sepolia.etherscan.io/api"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
contracts: {
|
|
19
|
+
multicall3: {
|
|
20
|
+
address: "0xca11bde05977b3631167028862be2a173976ca11",
|
|
21
|
+
blockCreated: 751532
|
|
22
|
+
},
|
|
23
|
+
ensUniversalResolver: {
|
|
24
|
+
address: "0xeeeeeeee14d718c2b47d9923deab1335e144eeee",
|
|
25
|
+
blockCreated: 8928790
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
testnet: !0
|
|
29
|
+
});
|
|
13
30
|
export {
|
|
14
|
-
|
|
31
|
+
t as sepolia
|
|
15
32
|
};
|
package/dist/index249.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index292.cjs"),i=require("./index293.cjs"),u=require("./index289.cjs");function s(e,o){var n;const{bytecode:r,args:t}=o;return u.concat(r,(n=e.inputs)!=null&&n.length&&(t!=null&&t.length)?i.encode(e.inputs,t):"0x")}function d(e){return c.from(e)}exports.encode=s;exports.from=d;
|
package/dist/index249.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { from as m } from "./
|
|
2
|
-
import { encode as c } from "./
|
|
3
|
-
import { concat as f } from "./
|
|
1
|
+
import { from as m } from "./index292.js";
|
|
2
|
+
import { encode as c } from "./index293.js";
|
|
3
|
+
import { concat as f } from "./index289.js";
|
|
4
4
|
function d(o, t) {
|
|
5
5
|
var e;
|
|
6
6
|
const { bytecode: r, args: n } = t;
|
package/dist/index25.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index218.cjs"),t=e.defineChain({id:1,name:"Ethereum",nativeCurrency:{name:"Ether",symbol:"ETH",decimals:18},blockTime:12e3,rpcUrls:{default:{http:["https://eth.merkle.io"]}},blockExplorers:{default:{name:"Etherscan",url:"https://etherscan.io",apiUrl:"https://api.etherscan.io/api"}},contracts:{ensUniversalResolver:{address:"0xeeeeeeee14d718c2b47d9923deab1335e144eeee",blockCreated:23085558},multicall3:{address:"0xca11bde05977b3631167028862be2a173976ca11",blockCreated:14353601}}});exports.mainnet=t;
|
package/dist/index25.js
CHANGED
|
@@ -1,60 +1,32 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
body: t
|
|
31
|
-
}),
|
|
32
|
-
sort: (t, H) => t.id - H.id
|
|
33
|
-
}), F = async (t) => o ? E(t) : [
|
|
34
|
-
await p.request({
|
|
35
|
-
body: t
|
|
36
|
-
})
|
|
37
|
-
], [{ error: s, result: l }] = await F(i);
|
|
38
|
-
if (R)
|
|
39
|
-
return { error: s, result: l };
|
|
40
|
-
if (s)
|
|
41
|
-
throw new O({
|
|
42
|
-
body: i,
|
|
43
|
-
error: s,
|
|
44
|
-
url: r
|
|
45
|
-
});
|
|
46
|
-
return l;
|
|
47
|
-
},
|
|
48
|
-
retryCount: b,
|
|
49
|
-
retryDelay: d,
|
|
50
|
-
timeout: c,
|
|
51
|
-
type: "http"
|
|
52
|
-
}, {
|
|
53
|
-
fetchOptions: u,
|
|
54
|
-
url: r
|
|
55
|
-
});
|
|
56
|
-
};
|
|
57
|
-
}
|
|
1
|
+
import { defineChain as e } from "./index218.js";
|
|
2
|
+
const t = /* @__PURE__ */ e({
|
|
3
|
+
id: 1,
|
|
4
|
+
name: "Ethereum",
|
|
5
|
+
nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 },
|
|
6
|
+
blockTime: 12e3,
|
|
7
|
+
rpcUrls: {
|
|
8
|
+
default: {
|
|
9
|
+
http: ["https://eth.merkle.io"]
|
|
10
|
+
}
|
|
11
|
+
},
|
|
12
|
+
blockExplorers: {
|
|
13
|
+
default: {
|
|
14
|
+
name: "Etherscan",
|
|
15
|
+
url: "https://etherscan.io",
|
|
16
|
+
apiUrl: "https://api.etherscan.io/api"
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
contracts: {
|
|
20
|
+
ensUniversalResolver: {
|
|
21
|
+
address: "0xeeeeeeee14d718c2b47d9923deab1335e144eeee",
|
|
22
|
+
blockCreated: 23085558
|
|
23
|
+
},
|
|
24
|
+
multicall3: {
|
|
25
|
+
address: "0xca11bde05977b3631167028862be2a173976ca11",
|
|
26
|
+
blockCreated: 14353601
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
});
|
|
58
30
|
export {
|
|
59
|
-
|
|
31
|
+
t as mainnet
|
|
60
32
|
};
|
package/dist/index250.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./index292.cjs"),s=require("./index293.cjs"),m=require("./index289.cjs");function d(e,...t){const{overloads:r}=e,o=r?u([e,...r],e.name,{args:t[0]}):e,c=f(o),i=t.length>0?s.encode(o.inputs,t[0]):void 0;return i?m.concat(c,i):c}function l(e,t={}){return n.from(e,t)}function u(e,t,r){const o=n.fromAbi(e,t,r);if(o.type!=="function")throw new n.NotFoundError({name:t,type:"function"});return o}function f(e){return n.getSelector(e)}exports.encodeData=d;exports.from=l;exports.fromAbi=u;exports.getSelector=f;
|
package/dist/index250.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { from as c, fromAbi as m, NotFoundError as i, getSelector as s } from "./
|
|
2
|
-
import { encode as u } from "./
|
|
3
|
-
import { concat as d } from "./
|
|
1
|
+
import { from as c, fromAbi as m, NotFoundError as i, getSelector as s } from "./index292.js";
|
|
2
|
+
import { encode as u } from "./index293.js";
|
|
3
|
+
import { concat as d } from "./index289.js";
|
|
4
4
|
function S(o, ...t) {
|
|
5
5
|
const { overloads: r } = o, e = r ? p([o, ...r], o.name, {
|
|
6
6
|
args: t[0]
|
package/dist/index256.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./index197.cjs"),l=require("./index190.cjs"),y=require("./index154.cjs"),i=require("./index155.cjs"),x=require("./index198.cjs");let r=!1;async function g({hash:n,privateKey:o,to:e="object"}){const{r:c,s:u,recovery:t}=a.secp256k1.sign(n.slice(2),o.slice(2),{lowS:!0,extraEntropy:l.isHex(r,{strict:!1})?y.hexToBytes(r):r}),s={r:i.numberToHex(c,{size:32}),s:i.numberToHex(u,{size:32}),v:t?28n:27n,yParity:t};return e==="bytes"||e==="hex"?x.serializeSignature({...s,to:e}):s}exports.sign=g;
|
package/dist/index256.js
CHANGED
|
@@ -1,16 +1,21 @@
|
|
|
1
|
-
import { secp256k1 as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
1
|
+
import { secp256k1 as a } from "./index197.js";
|
|
2
|
+
import { isHex as f } from "./index190.js";
|
|
3
|
+
import { hexToBytes as p } from "./index154.js";
|
|
4
|
+
import { numberToHex as s } from "./index155.js";
|
|
5
|
+
import { serializeSignature as u } from "./index198.js";
|
|
6
|
+
let e = !1;
|
|
7
|
+
async function z({ hash: o, privateKey: n, to: r = "object" }) {
|
|
8
|
+
const { r: m, s: c, recovery: t } = a.sign(o.slice(2), n.slice(2), {
|
|
9
|
+
lowS: !0,
|
|
10
|
+
extraEntropy: f(e, { strict: !1 }) ? p(e) : e
|
|
11
|
+
}), i = {
|
|
12
|
+
r: s(m, { size: 32 }),
|
|
13
|
+
s: s(c, { size: 32 }),
|
|
14
|
+
v: t ? 28n : 27n,
|
|
15
|
+
yParity: t
|
|
11
16
|
};
|
|
12
|
-
return r === "bytes" || r === "hex" ?
|
|
17
|
+
return r === "bytes" || r === "hex" ? u({ ...i, to: r }) : i;
|
|
13
18
|
}
|
|
14
19
|
export {
|
|
15
|
-
|
|
20
|
+
z as sign
|
|
16
21
|
};
|
package/dist/index26.cjs
CHANGED
|
@@ -1,16 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
2
|
-
`))throw new e.SiweInvalidMessageFieldError({field:"statement",metaMessages:["- Statement must not include '\\n'.","",`Provided value: ${t}`]})}const $=M.getAddress(r.address),v=i?`${i}://${s}`:s,I=r.statement?`${r.statement}
|
|
3
|
-
`:"",S=`${v} wants you to sign in with your Ethereum account:
|
|
4
|
-
${$}
|
|
5
|
-
|
|
6
|
-
${I}`;let n=`URI: ${c}
|
|
7
|
-
Version: ${d}
|
|
8
|
-
Chain ID: ${o}
|
|
9
|
-
Nonce: ${a}
|
|
10
|
-
Issued At: ${m.toISOString()}`;if(l&&(n+=`
|
|
11
|
-
Expiration Time: ${l.toISOString()}`),f&&(n+=`
|
|
12
|
-
Not Before: ${f.toISOString()}`),w&&(n+=`
|
|
13
|
-
Request ID: ${w}`),g){let t=`
|
|
14
|
-
Resources:`;for(const u of g){if(!h.isUri(u))throw new e.SiweInvalidMessageFieldError({field:"resources",metaMessages:["- Every resource must be a RFC 3986 URI.","- See https://www.rfc-editor.org/rfc/rfc3986","",`Provided value: ${u}`]});t+=`
|
|
15
|
-
- ${u}`}n+=t}return`${S}
|
|
16
|
-
${n}`}const E=/^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}(:[0-9]{1,5})?$/,F=/^(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)(:[0-9]{1,5})?$/,b=/^localhost(:[0-9]{1,5})?$/,A=/^[a-zA-Z0-9]{8,}$/,P=/^([a-zA-Z][a-zA-Z0-9+-.]*)$/;exports.createSiweMessage=R;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("./index49.cjs"),n=require("./index57.cjs");function l(e){const{key:t="public",name:i="Public Client"}=e;return c.createClient({...e,key:t,name:i,type:"publicClient"}).extend(n.publicActions)}exports.createPublicClient=l;
|