@cartridge/controller 0.7.10 → 0.7.11
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/.turbo/turbo-build$colon$deps.log +15 -15
- package/.turbo/turbo-build.log +11 -11
- package/dist/index.js +51 -49
- package/dist/index.js.map +1 -1
- package/dist/node/index.cjs +1 -1
- package/dist/node/index.cjs.map +1 -1
- package/dist/node/index.js +1 -1
- package/dist/node/index.js.map +1 -1
- package/dist/{provider-Dr912mPw.js → provider-CyO7_h7r.js} +39 -38
- package/dist/provider-CyO7_h7r.js.map +1 -0
- package/dist/session.js +29 -28
- package/dist/session.js.map +1 -1
- package/dist/stats.html +1 -1
- package/dist/types.d.ts +7 -1
- package/package.json +3 -3
- package/src/account.ts +1 -0
- package/src/iframe/base.ts +1 -0
- package/src/types.ts +8 -1
- package/dist/provider-Dr912mPw.js.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
|
|
2
|
-
> @cartridge/controller@0.7.
|
|
2
|
+
> @cartridge/controller@0.7.11 build:deps /home/runner/work/controller/controller/packages/controller
|
|
3
3
|
> pnpm build
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
> @cartridge/controller@0.7.
|
|
6
|
+
> @cartridge/controller@0.7.11 build /home/runner/work/controller/controller/packages/controller
|
|
7
7
|
> pnpm build:browser && pnpm build:node
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
> @cartridge/controller@0.7.
|
|
10
|
+
> @cartridge/controller@0.7.11 build:browser /home/runner/work/controller/controller/packages/controller
|
|
11
11
|
> vite build
|
|
12
12
|
|
|
13
13
|
[36mvite v6.1.0 [32mbuilding for production...[36m[39m
|
|
@@ -18,14 +18,14 @@ rendering chunks...
|
|
|
18
18
|
|
|
19
19
|
[vite:dts] Start generate declaration files...
|
|
20
20
|
computing gzip size...
|
|
21
|
-
[2mdist/[22m[36msession.js [39m[1m[2m 10.
|
|
22
|
-
[2mdist/[22m[36mprovider-
|
|
23
|
-
[2mdist/[22m[36mindex.js [39m[1m[2m135.
|
|
24
|
-
[vite:dts] Declaration files built in
|
|
21
|
+
[2mdist/[22m[36msession.js [39m[1m[2m 10.84 kB[22m[1m[22m[2m │ gzip: 3.38 kB[22m[2m │ map: 56.54 kB[22m
|
|
22
|
+
[2mdist/[22m[36mprovider-CyO7_h7r.js [39m[1m[2m 23.30 kB[22m[1m[22m[2m │ gzip: 13.58 kB[22m[2m │ map: 40.95 kB[22m
|
|
23
|
+
[2mdist/[22m[36mindex.js [39m[1m[2m135.90 kB[22m[1m[22m[2m │ gzip: 24.37 kB[22m[2m │ map: 258.64 kB[22m
|
|
24
|
+
[vite:dts] Declaration files built in 3359ms.
|
|
25
25
|
|
|
26
|
-
[32m✓ built in 4.
|
|
26
|
+
[32m✓ built in 4.17s[39m
|
|
27
27
|
|
|
28
|
-
> @cartridge/controller@0.7.
|
|
28
|
+
> @cartridge/controller@0.7.11 build:node /home/runner/work/controller/controller/packages/controller
|
|
29
29
|
> tsup --config tsup.node.config.ts
|
|
30
30
|
|
|
31
31
|
[34mCLI[39m Building entry: src/node/index.ts
|
|
@@ -36,16 +36,16 @@ computing gzip size...
|
|
|
36
36
|
[34mCLI[39m Cleaning output folder
|
|
37
37
|
[34mESM[39m Build start
|
|
38
38
|
[34mCJS[39m Build start
|
|
39
|
-
"constants", "getChecksumAddress", "Provider" and "shortString" are imported from external module "starknet" but never used in "dist/node/index.js".
|
|
40
39
|
"constants", "getChecksumAddress", "Provider" and "shortString" are imported from external module "starknet" but never used in "dist/node/index.cjs".
|
|
41
40
|
Entry module "dist/node/index.cjs" is using named and default exports together. Consumers of your bundle will have to use `chunk.default` to access the default export, which may not be what you want. Use `output.exports: "named"` to disable this warning.
|
|
42
|
-
|
|
43
|
-
[32mESM[39m [1mdist/node/index.js.map [22m[32m58.58 KB[39m
|
|
44
|
-
[32mESM[39m ⚡️ Build success in 395ms
|
|
41
|
+
"constants", "getChecksumAddress", "Provider" and "shortString" are imported from external module "starknet" but never used in "dist/node/index.js".
|
|
45
42
|
[32mCJS[39m [1mdist/node/index.cjs [22m[32m31.90 KB[39m
|
|
46
43
|
[32mCJS[39m [1mdist/node/index.cjs.map [22m[32m58.78 KB[39m
|
|
47
|
-
[32mCJS[39m ⚡️ Build success in
|
|
44
|
+
[32mCJS[39m ⚡️ Build success in 389ms
|
|
45
|
+
[32mESM[39m [1mdist/node/index.js [22m[32m31.14 KB[39m
|
|
46
|
+
[32mESM[39m [1mdist/node/index.js.map [22m[32m58.58 KB[39m
|
|
47
|
+
[32mESM[39m ⚡️ Build success in 389ms
|
|
48
48
|
[34mDTS[39m Build start
|
|
49
|
-
[32mDTS[39m ⚡️ Build success in
|
|
49
|
+
[32mDTS[39m ⚡️ Build success in 3222ms
|
|
50
50
|
[32mDTS[39m [1mdist/node/index.d.ts [22m[32m5.09 KB[39m
|
|
51
51
|
[32mDTS[39m [1mdist/node/index.d.cts [22m[32m5.09 KB[39m
|
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
> @cartridge/controller@0.7.
|
|
2
|
+
> @cartridge/controller@0.7.11 build /home/runner/work/controller/controller/packages/controller
|
|
3
3
|
> pnpm build:browser && pnpm build:node
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
> @cartridge/controller@0.7.
|
|
6
|
+
> @cartridge/controller@0.7.11 build:browser /home/runner/work/controller/controller/packages/controller
|
|
7
7
|
> vite build
|
|
8
8
|
|
|
9
9
|
[36mvite v6.1.0 [32mbuilding for production...[36m[39m
|
|
@@ -14,14 +14,14 @@ rendering chunks...
|
|
|
14
14
|
|
|
15
15
|
[vite:dts] Start generate declaration files...
|
|
16
16
|
computing gzip size...
|
|
17
|
-
[2mdist/[22m[36msession.js [39m[1m[2m 10.
|
|
18
|
-
[2mdist/[22m[36mprovider-
|
|
19
|
-
[2mdist/[22m[36mindex.js [39m[1m[2m135.
|
|
20
|
-
[vite:dts] Declaration files built in
|
|
17
|
+
[2mdist/[22m[36msession.js [39m[1m[2m 10.84 kB[22m[1m[22m[2m │ gzip: 3.38 kB[22m[2m │ map: 56.54 kB[22m
|
|
18
|
+
[2mdist/[22m[36mprovider-CyO7_h7r.js [39m[1m[2m 23.30 kB[22m[1m[22m[2m │ gzip: 13.58 kB[22m[2m │ map: 40.95 kB[22m
|
|
19
|
+
[2mdist/[22m[36mindex.js [39m[1m[2m135.90 kB[22m[1m[22m[2m │ gzip: 24.37 kB[22m[2m │ map: 258.64 kB[22m
|
|
20
|
+
[vite:dts] Declaration files built in 3354ms.
|
|
21
21
|
|
|
22
|
-
[32m✓ built in 4.
|
|
22
|
+
[32m✓ built in 4.32s[39m
|
|
23
23
|
|
|
24
|
-
> @cartridge/controller@0.7.
|
|
24
|
+
> @cartridge/controller@0.7.11 build:node /home/runner/work/controller/controller/packages/controller
|
|
25
25
|
> tsup --config tsup.node.config.ts
|
|
26
26
|
|
|
27
27
|
[34mCLI[39m Building entry: src/node/index.ts
|
|
@@ -37,11 +37,11 @@ computing gzip size...
|
|
|
37
37
|
Entry module "dist/node/index.cjs" is using named and default exports together. Consumers of your bundle will have to use `chunk.default` to access the default export, which may not be what you want. Use `output.exports: "named"` to disable this warning.
|
|
38
38
|
[32mESM[39m [1mdist/node/index.js [22m[32m31.14 KB[39m
|
|
39
39
|
[32mESM[39m [1mdist/node/index.js.map [22m[32m58.58 KB[39m
|
|
40
|
-
[32mESM[39m ⚡️ Build success in
|
|
40
|
+
[32mESM[39m ⚡️ Build success in 325ms
|
|
41
41
|
[32mCJS[39m [1mdist/node/index.cjs [22m[32m31.90 KB[39m
|
|
42
42
|
[32mCJS[39m [1mdist/node/index.cjs.map [22m[32m58.78 KB[39m
|
|
43
|
-
[32mCJS[39m ⚡️ Build success in
|
|
43
|
+
[32mCJS[39m ⚡️ Build success in 325ms
|
|
44
44
|
[34mDTS[39m Build start
|
|
45
|
-
[32mDTS[39m ⚡️ Build success in
|
|
45
|
+
[32mDTS[39m ⚡️ Build success in 3307ms
|
|
46
46
|
[32mDTS[39m [1mdist/node/index.d.ts [22m[32m5.09 KB[39m
|
|
47
47
|
[32mDTS[39m [1mdist/node/index.d.cts [22m[32m5.09 KB[39m
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { WalletAccount as L, shortString as M, num as O } from "starknet";
|
|
2
|
-
import { R as A, t as Y, K as $, P as W, B as H, N as u, p as K, A as q } from "./provider-
|
|
3
|
-
import {
|
|
2
|
+
import { R as A, t as Y, K as $, P as W, B as H, N as u, p as K, A as q } from "./provider-CyO7_h7r.js";
|
|
3
|
+
import { F as Oe, h as Ye, n as $e, a as We, b as He } from "./provider-CyO7_h7r.js";
|
|
4
4
|
import { MetaMaskSDK as G } from "@metamask/sdk";
|
|
5
5
|
import { Transaction as V } from "@solana/web3.js";
|
|
6
6
|
import { connect as J } from "starknetkit";
|
|
@@ -31,7 +31,8 @@ class z extends L {
|
|
|
31
31
|
e,
|
|
32
32
|
void 0,
|
|
33
33
|
void 0,
|
|
34
|
-
!1
|
|
34
|
+
!1,
|
|
35
|
+
this.options?.feeSource
|
|
35
36
|
);
|
|
36
37
|
if (r.code === A.SUCCESS) {
|
|
37
38
|
t(r);
|
|
@@ -116,7 +117,7 @@ const Z = (o, e) => {
|
|
|
116
117
|
"http:": "80",
|
|
117
118
|
"https:": "443"
|
|
118
119
|
}, ne = /^(https?:)?\/\/([^/:]+)?(:(\d+))?/, oe = ["file:", "data:"], re = (o) => {
|
|
119
|
-
if (o && oe.find((
|
|
120
|
+
if (o && oe.find((s) => o.startsWith(s)))
|
|
120
121
|
return "null";
|
|
121
122
|
const e = document.location, t = ne.exec(o);
|
|
122
123
|
let n, r, a;
|
|
@@ -131,19 +132,19 @@ const Z = (o, e) => {
|
|
|
131
132
|
const e = new Error();
|
|
132
133
|
return Object.keys(o).forEach((t) => e[t] = o[t]), e;
|
|
133
134
|
}, ie = (o, e, t) => {
|
|
134
|
-
const { localName: n, local: r, remote: a, originForSending: c, originForReceiving:
|
|
135
|
-
let
|
|
135
|
+
const { localName: n, local: r, remote: a, originForSending: c, originForReceiving: s } = o;
|
|
136
|
+
let i = !1;
|
|
136
137
|
const l = (d) => {
|
|
137
138
|
if (d.source !== a || d.data.penpal !== y.Call)
|
|
138
139
|
return;
|
|
139
|
-
if (
|
|
140
|
-
t(`${n} received message from origin ${d.origin} which did not match expected origin ${
|
|
140
|
+
if (s !== "*" && d.origin !== s) {
|
|
141
|
+
t(`${n} received message from origin ${d.origin} which did not match expected origin ${s}`);
|
|
141
142
|
return;
|
|
142
143
|
}
|
|
143
144
|
const p = d.data, { methodName: h, args: g, id: f } = p;
|
|
144
145
|
t(`${n}: Received ${h}() call`);
|
|
145
146
|
const w = (b) => (k) => {
|
|
146
|
-
if (t(`${n}: Sending ${h}() reply`),
|
|
147
|
+
if (t(`${n}: Sending ${h}() reply`), i) {
|
|
147
148
|
t(`${n}: Unable to send ${h}() reply due to destroyed connection`);
|
|
148
149
|
return;
|
|
149
150
|
}
|
|
@@ -173,7 +174,7 @@ const Z = (o, e) => {
|
|
|
173
174
|
new Promise((b) => b(e[h].call(e, d.origin).apply(e, g))).then(w(C.Fulfilled), w(C.Rejected));
|
|
174
175
|
};
|
|
175
176
|
return r.addEventListener(_.Message, l), () => {
|
|
176
|
-
|
|
177
|
+
i = !0, r.removeEventListener(_.Message, l);
|
|
177
178
|
};
|
|
178
179
|
};
|
|
179
180
|
let se = 0;
|
|
@@ -195,14 +196,14 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
195
196
|
le(e, t, o[t]);
|
|
196
197
|
return e;
|
|
197
198
|
}, me = (o, e, t, n, r) => {
|
|
198
|
-
const { localName: a, local: c, remote:
|
|
199
|
+
const { localName: a, local: c, remote: s, originForSending: i, originForReceiving: l } = e;
|
|
199
200
|
let d = !1;
|
|
200
201
|
r(`${a}: Connecting call sender`);
|
|
201
202
|
const p = (g) => (...f) => {
|
|
202
203
|
r(`${a}: Sending ${g}() call`);
|
|
203
204
|
let w;
|
|
204
205
|
try {
|
|
205
|
-
|
|
206
|
+
s.closed && (w = !0);
|
|
206
207
|
} catch {
|
|
207
208
|
w = !0;
|
|
208
209
|
}
|
|
@@ -212,16 +213,16 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
212
213
|
}
|
|
213
214
|
return new Promise((b, k) => {
|
|
214
215
|
const v = ce(), m = (x) => {
|
|
215
|
-
if (x.source !==
|
|
216
|
+
if (x.source !== s || x.data.penpal !== y.Reply || x.data.id !== v)
|
|
216
217
|
return;
|
|
217
218
|
if (l !== "*" && x.origin !== l) {
|
|
218
219
|
r(`${a} received message from origin ${x.origin} which did not match expected origin ${l}`);
|
|
219
220
|
return;
|
|
220
221
|
}
|
|
221
|
-
const
|
|
222
|
+
const R = x.data;
|
|
222
223
|
r(`${a}: Received ${g}() reply`), c.removeEventListener(_.Message, m);
|
|
223
|
-
let P =
|
|
224
|
-
|
|
224
|
+
let P = R.returnValue;
|
|
225
|
+
R.returnValueIsError && (P = ae(P)), (R.resolution === C.Fulfilled ? b : k)(P);
|
|
225
226
|
};
|
|
226
227
|
c.addEventListener(_.Message, m);
|
|
227
228
|
const I = {
|
|
@@ -230,7 +231,7 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
230
231
|
methodName: g,
|
|
231
232
|
args: f
|
|
232
233
|
};
|
|
233
|
-
|
|
234
|
+
s.postMessage(I, i);
|
|
234
235
|
});
|
|
235
236
|
}, h = t.reduce((g, f) => (g[f] = p(f), g), {});
|
|
236
237
|
return Object.assign(o, ge(h)), () => {
|
|
@@ -238,7 +239,7 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
238
239
|
};
|
|
239
240
|
}, he = (o, e, t, n, r) => {
|
|
240
241
|
const { destroy: a, onDestroy: c } = n;
|
|
241
|
-
let
|
|
242
|
+
let s, i;
|
|
242
243
|
const l = {};
|
|
243
244
|
return (d) => {
|
|
244
245
|
if (e !== "*" && d.origin !== e) {
|
|
@@ -253,10 +254,10 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
253
254
|
originForSending: t,
|
|
254
255
|
originForReceiving: e
|
|
255
256
|
};
|
|
256
|
-
|
|
257
|
+
s && s(), s = ie(p, o, r), c(s), i && i.forEach((g) => {
|
|
257
258
|
delete l[g];
|
|
258
|
-
}),
|
|
259
|
-
const h = me(l, p,
|
|
259
|
+
}), i = d.data.methodNames;
|
|
260
|
+
const h = me(l, p, i, a, r);
|
|
260
261
|
return c(h), l;
|
|
261
262
|
};
|
|
262
263
|
}, fe = (o, e, t, n) => (r) => {
|
|
@@ -294,9 +295,9 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
294
295
|
}
|
|
295
296
|
}, we = (o) => {
|
|
296
297
|
let { iframe: e, methods: t = {}, childOrigin: n, timeout: r, debug: a = !1 } = o;
|
|
297
|
-
const c = ee(a),
|
|
298
|
+
const c = ee(a), s = Z("Parent", c), { onDestroy: i, destroy: l } = s;
|
|
298
299
|
n || (ve(e), n = re(e.src));
|
|
299
|
-
const d = n === "null" ? "*" : n, p = T(t), h = fe(c, p, n, d), g = he(p, n, d,
|
|
300
|
+
const d = n === "null" ? "*" : n, p = T(t), h = fe(c, p, n, d), g = he(p, n, d, s, c);
|
|
300
301
|
return {
|
|
301
302
|
promise: new Promise((w, b) => {
|
|
302
303
|
const k = ye(r, l), v = (m) => {
|
|
@@ -312,7 +313,7 @@ const ce = () => ++se, j = ".", B = (o) => o ? o.split(j) : [], de = (o) => o.jo
|
|
|
312
313
|
}
|
|
313
314
|
}
|
|
314
315
|
};
|
|
315
|
-
window.addEventListener(_.Message, v), c("Parent: Awaiting handshake"), ue(e,
|
|
316
|
+
window.addEventListener(_.Message, v), c("Parent: Awaiting handshake"), ue(e, s), i((m) => {
|
|
316
317
|
window.removeEventListener(_.Message, v), m && b(m);
|
|
317
318
|
});
|
|
318
319
|
}),
|
|
@@ -337,10 +338,10 @@ class Q {
|
|
|
337
338
|
if (typeof document > "u")
|
|
338
339
|
return;
|
|
339
340
|
n && t.searchParams.set("preset", n), this.url = t;
|
|
340
|
-
const
|
|
341
|
-
|
|
342
|
-
const
|
|
343
|
-
|
|
341
|
+
const s = document.createElement("iframe");
|
|
342
|
+
s.src = t.toString(), s.id = e, s.style.border = "none", s.sandbox.add("allow-forms"), s.sandbox.add("allow-popups"), s.sandbox.add("allow-scripts"), s.sandbox.add("allow-same-origin"), s.allow = "publickey-credentials-create *; publickey-credentials-get *; clipboard-write", document.hasStorageAccess && s.sandbox.add("allow-storage-access-by-user-activation");
|
|
343
|
+
const i = document.createElement("div");
|
|
344
|
+
i.id = "controller", i.style.position = "fixed", i.style.height = "100%", i.style.width = "100%", i.style.top = "0", i.style.left = "0", i.style.zIndex = "10000", i.style.backgroundColor = "rgba(0,0,0,0.6)", i.style.display = "flex", i.style.alignItems = "center", i.style.justifyContent = "center", i.style.visibility = "hidden", i.style.opacity = "0", i.style.transition = "opacity 0.2s ease", i.style.pointerEvents = "auto", i.appendChild(s), this.iframe = s, this.container = i, we({
|
|
344
345
|
iframe: this.iframe,
|
|
345
346
|
methods: {
|
|
346
347
|
close: (p) => () => this.close(),
|
|
@@ -358,14 +359,14 @@ class Q {
|
|
|
358
359
|
}).promise.then(a), this.resize(), window.addEventListener("resize", () => this.resize());
|
|
359
360
|
const l = new MutationObserver(() => {
|
|
360
361
|
const p = document.getElementById("controller");
|
|
361
|
-
document.body && (e === "controller-keychain" && !p || e === "controller-profile") && (document.body.appendChild(
|
|
362
|
+
document.body && (e === "controller-keychain" && !p || e === "controller-profile") && (document.body.appendChild(i), l.disconnect());
|
|
362
363
|
});
|
|
363
364
|
l.observe(document.documentElement, {
|
|
364
365
|
childList: !0,
|
|
365
366
|
subtree: !0
|
|
366
367
|
});
|
|
367
368
|
const d = document.getElementById("controller");
|
|
368
|
-
document.body && (e === "controller-keychain" && !d || e === "controller-profile") && document.body.appendChild(
|
|
369
|
+
document.body && (e === "controller-keychain" && !d || e === "controller-profile") && document.body.appendChild(i), this.onClose = r;
|
|
369
370
|
}
|
|
370
371
|
open() {
|
|
371
372
|
this.container && (document.body.style.overflow = "hidden", this.container.style.visibility = "visible", this.container.style.opacity = "1");
|
|
@@ -838,19 +839,19 @@ class xe extends Q {
|
|
|
838
839
|
username: r,
|
|
839
840
|
slot: a,
|
|
840
841
|
namespace: c,
|
|
841
|
-
tokens:
|
|
842
|
-
policies:
|
|
842
|
+
tokens: s,
|
|
843
|
+
policies: i,
|
|
843
844
|
...l
|
|
844
845
|
}) {
|
|
845
846
|
const d = (e || W).replace(/\/$/, "");
|
|
846
847
|
let p = new URL(
|
|
847
848
|
a ? `${d}/account/${r}/slot/${a}` : `${d}/account/${r}`
|
|
848
849
|
);
|
|
849
|
-
if (a && p.searchParams.set("ps", encodeURIComponent(a)), c && p.searchParams.set("ns", encodeURIComponent(c)), n && p.searchParams.set("v", encodeURIComponent(n)), p.searchParams.set("rpcUrl", encodeURIComponent(t)),
|
|
850
|
+
if (a && p.searchParams.set("ps", encodeURIComponent(a)), c && p.searchParams.set("ns", encodeURIComponent(c)), n && p.searchParams.set("v", encodeURIComponent(n)), p.searchParams.set("rpcUrl", encodeURIComponent(t)), s?.erc20 && p.searchParams.set(
|
|
850
851
|
"erc20",
|
|
851
|
-
encodeURIComponent(
|
|
852
|
-
),
|
|
853
|
-
const h = Object.values(
|
|
852
|
+
encodeURIComponent(s.erc20.toString())
|
|
853
|
+
), i?.contracts) {
|
|
854
|
+
const h = Object.values(i.contracts).flatMap(
|
|
854
855
|
(g) => g.methods
|
|
855
856
|
);
|
|
856
857
|
p.searchParams.set(
|
|
@@ -1101,7 +1102,7 @@ class Ne extends H {
|
|
|
1101
1102
|
});
|
|
1102
1103
|
}
|
|
1103
1104
|
}
|
|
1104
|
-
const
|
|
1105
|
+
const S = /* @__PURE__ */ new Map();
|
|
1105
1106
|
async function F(o) {
|
|
1106
1107
|
if (!o.addresses?.length && !o.usernames?.length)
|
|
1107
1108
|
return { results: [] };
|
|
@@ -1117,22 +1118,22 @@ async function F(o) {
|
|
|
1117
1118
|
return e.json();
|
|
1118
1119
|
}
|
|
1119
1120
|
async function je(o) {
|
|
1120
|
-
const e = o.filter((t) => !
|
|
1121
|
+
const e = o.filter((t) => !S.has(t));
|
|
1121
1122
|
return e.length > 0 && (await F({ usernames: e })).results.forEach((n) => {
|
|
1122
|
-
|
|
1123
|
+
S.set(n.username, n.addresses[0]);
|
|
1123
1124
|
}), new Map(
|
|
1124
|
-
o.map((t) => [t,
|
|
1125
|
+
o.map((t) => [t, S.get(t)]).filter((t) => t[1] !== void 0)
|
|
1125
1126
|
);
|
|
1126
1127
|
}
|
|
1127
1128
|
async function Be(o) {
|
|
1128
1129
|
o = o.map(O.toHex);
|
|
1129
|
-
const e = o.filter((t) => !
|
|
1130
|
+
const e = o.filter((t) => !S.has(t));
|
|
1130
1131
|
return e.length > 0 && (await F({
|
|
1131
1132
|
addresses: e
|
|
1132
1133
|
})).results.forEach((n) => {
|
|
1133
|
-
|
|
1134
|
+
S.set(n.addresses[0], n.username);
|
|
1134
1135
|
}), new Map(
|
|
1135
|
-
o.map((t) => [t,
|
|
1136
|
+
o.map((t) => [t, S.get(t)]).filter((t) => t[1] !== void 0)
|
|
1136
1137
|
);
|
|
1137
1138
|
}
|
|
1138
1139
|
var U = {
|
|
@@ -3814,7 +3815,7 @@ var U = {
|
|
|
3814
3815
|
}
|
|
3815
3816
|
}
|
|
3816
3817
|
}
|
|
3817
|
-
},
|
|
3818
|
+
}, Se = [
|
|
3818
3819
|
{
|
|
3819
3820
|
name: "Wrapped BTC",
|
|
3820
3821
|
symbol: "WBTC",
|
|
@@ -4360,9 +4361,10 @@ var U = {
|
|
|
4360
4361
|
hidden: !0,
|
|
4361
4362
|
logo_url: "https://imagedelivery.net/0xPAQaDtnQhBs8IzYRIlNg/6deef27f-df40-4248-4e1b-ed1d79a3f000/logo"
|
|
4362
4363
|
}
|
|
4363
|
-
], Te = U, Qe =
|
|
4364
|
+
], Te = U, Qe = Se, Fe = U.cartridge.theme;
|
|
4364
4365
|
export {
|
|
4365
4366
|
Ae as ArgentWallet,
|
|
4367
|
+
Oe as FeeSource,
|
|
4366
4368
|
_e as MetaMaskWallet,
|
|
4367
4369
|
u as NotReadyToConnect,
|
|
4368
4370
|
ke as PhantomWallet,
|
|
@@ -4372,13 +4374,13 @@ export {
|
|
|
4372
4374
|
Ne as default,
|
|
4373
4375
|
Fe as defaultTheme,
|
|
4374
4376
|
Qe as erc20Metadata,
|
|
4375
|
-
|
|
4377
|
+
Ye as humanizeString,
|
|
4376
4378
|
Be as lookupAddresses,
|
|
4377
4379
|
je as lookupUsernames,
|
|
4378
|
-
|
|
4380
|
+
$e as normalizeCalls,
|
|
4379
4381
|
K as parseChainId,
|
|
4380
4382
|
Y as toArray,
|
|
4381
|
-
|
|
4382
|
-
|
|
4383
|
+
We as toSessionPolicies,
|
|
4384
|
+
He as toWasmPolicies
|
|
4383
4385
|
};
|
|
4384
4386
|
//# sourceMappingURL=index.js.map
|