@cartridge/controller-wasm 0.7.14-0df5a4c → 0.7.14-24e7b0f

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.
@@ -5,6 +5,43 @@ export function __wbg_set_wasm(val) {
5
5
  wasm = val;
6
6
  }
7
7
 
8
+
9
+ let cachedUint8ArrayMemory0 = null;
10
+
11
+ function getUint8ArrayMemory0() {
12
+ if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
13
+ cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
14
+ }
15
+ return cachedUint8ArrayMemory0;
16
+ }
17
+
18
+ let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
19
+
20
+ cachedTextDecoder.decode();
21
+
22
+ const MAX_SAFARI_DECODE_BYTES = 2146435072;
23
+ let numBytesDecoded = 0;
24
+ function decodeText(ptr, len) {
25
+ numBytesDecoded += len;
26
+ if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
27
+ cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
28
+ cachedTextDecoder.decode();
29
+ numBytesDecoded = len;
30
+ }
31
+ return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
32
+ }
33
+
34
+ function getStringFromWasm0(ptr, len) {
35
+ ptr = ptr >>> 0;
36
+ return decodeText(ptr, len);
37
+ }
38
+
39
+ let heap = new Array(128).fill(undefined);
40
+
41
+ heap.push(undefined, null, true, false);
42
+
43
+ let heap_next = heap.length;
44
+
8
45
  function addHeapObject(obj) {
9
46
  if (heap_next === heap.length) heap.push(heap.length + 1);
10
47
  const idx = heap_next;
@@ -14,15 +51,74 @@ function addHeapObject(obj) {
14
51
  return idx;
15
52
  }
16
53
 
17
- function _assertClass(instance, klass) {
18
- if (!(instance instanceof klass)) {
19
- throw new Error(`expected instance of ${klass.name}`);
54
+ function getObject(idx) { return heap[idx]; }
55
+
56
+ let WASM_VECTOR_LEN = 0;
57
+
58
+ const cachedTextEncoder = new TextEncoder();
59
+
60
+ if (!('encodeInto' in cachedTextEncoder)) {
61
+ cachedTextEncoder.encodeInto = function (arg, view) {
62
+ const buf = cachedTextEncoder.encode(arg);
63
+ view.set(buf);
64
+ return {
65
+ read: arg.length,
66
+ written: buf.length
67
+ };
20
68
  }
21
69
  }
22
70
 
23
- const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
24
- ? { register: () => {}, unregister: () => {} }
25
- : new FinalizationRegistry(state => state.dtor(state.a, state.b));
71
+ function passStringToWasm0(arg, malloc, realloc) {
72
+
73
+ if (realloc === undefined) {
74
+ const buf = cachedTextEncoder.encode(arg);
75
+ const ptr = malloc(buf.length, 1) >>> 0;
76
+ getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
77
+ WASM_VECTOR_LEN = buf.length;
78
+ return ptr;
79
+ }
80
+
81
+ let len = arg.length;
82
+ let ptr = malloc(len, 1) >>> 0;
83
+
84
+ const mem = getUint8ArrayMemory0();
85
+
86
+ let offset = 0;
87
+
88
+ for (; offset < len; offset++) {
89
+ const code = arg.charCodeAt(offset);
90
+ if (code > 0x7F) break;
91
+ mem[ptr + offset] = code;
92
+ }
93
+
94
+ if (offset !== len) {
95
+ if (offset !== 0) {
96
+ arg = arg.slice(offset);
97
+ }
98
+ ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
99
+ const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
100
+ const ret = cachedTextEncoder.encodeInto(arg, view);
101
+
102
+ offset += ret.written;
103
+ ptr = realloc(ptr, len, offset, 1) >>> 0;
104
+ }
105
+
106
+ WASM_VECTOR_LEN = offset;
107
+ return ptr;
108
+ }
109
+
110
+ let cachedDataViewMemory0 = null;
111
+
112
+ function getDataViewMemory0() {
113
+ if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
114
+ cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
115
+ }
116
+ return cachedDataViewMemory0;
117
+ }
118
+
119
+ function isLikeNone(x) {
120
+ return x === undefined || x === null;
121
+ }
26
122
 
27
123
  function debugString(val) {
28
124
  // primitive types
@@ -89,20 +185,24 @@ function debugString(val) {
89
185
  return className;
90
186
  }
91
187
 
188
+ function handleError(f, args) {
189
+ try {
190
+ return f.apply(this, args);
191
+ } catch (e) {
192
+ wasm.__wbindgen_export3(addHeapObject(e));
193
+ }
194
+ }
195
+
92
196
  function dropObject(idx) {
93
197
  if (idx < 132) return;
94
198
  heap[idx] = heap_next;
95
199
  heap_next = idx;
96
200
  }
97
201
 
98
- function getArrayJsValueFromWasm0(ptr, len) {
99
- ptr = ptr >>> 0;
100
- const mem = getDataViewMemory0();
101
- const result = [];
102
- for (let i = ptr; i < ptr + 4 * len; i += 4) {
103
- result.push(takeObject(mem.getUint32(i, true)));
104
- }
105
- return result;
202
+ function takeObject(idx) {
203
+ const ret = getObject(idx);
204
+ dropObject(idx);
205
+ return ret;
106
206
  }
107
207
 
108
208
  function getArrayU8FromWasm0(ptr, len) {
@@ -110,45 +210,9 @@ function getArrayU8FromWasm0(ptr, len) {
110
210
  return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
111
211
  }
112
212
 
113
- let cachedDataViewMemory0 = null;
114
- function getDataViewMemory0() {
115
- if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
116
- cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
117
- }
118
- return cachedDataViewMemory0;
119
- }
120
-
121
- function getStringFromWasm0(ptr, len) {
122
- ptr = ptr >>> 0;
123
- return decodeText(ptr, len);
124
- }
125
-
126
- let cachedUint8ArrayMemory0 = null;
127
- function getUint8ArrayMemory0() {
128
- if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
129
- cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
130
- }
131
- return cachedUint8ArrayMemory0;
132
- }
133
-
134
- function getObject(idx) { return heap[idx]; }
135
-
136
- function handleError(f, args) {
137
- try {
138
- return f.apply(this, args);
139
- } catch (e) {
140
- wasm.__wbindgen_export3(addHeapObject(e));
141
- }
142
- }
143
-
144
- let heap = new Array(128).fill(undefined);
145
- heap.push(undefined, null, true, false);
146
-
147
- let heap_next = heap.length;
148
-
149
- function isLikeNone(x) {
150
- return x === undefined || x === null;
151
- }
213
+ const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
214
+ ? { register: () => {}, unregister: () => {} }
215
+ : new FinalizationRegistry(state => state.dtor(state.a, state.b));
152
216
 
153
217
  function makeClosure(arg0, arg1, dtor, f) {
154
218
  const state = { a: arg0, b: arg1, cnt: 1, dtor };
@@ -212,95 +276,184 @@ function passArrayJsValueToWasm0(array, malloc) {
212
276
  WASM_VECTOR_LEN = array.length;
213
277
  return ptr;
214
278
  }
215
-
216
- function passStringToWasm0(arg, malloc, realloc) {
217
- if (realloc === undefined) {
218
- const buf = cachedTextEncoder.encode(arg);
219
- const ptr = malloc(buf.length, 1) >>> 0;
220
- getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
221
- WASM_VECTOR_LEN = buf.length;
222
- return ptr;
223
- }
224
-
225
- let len = arg.length;
226
- let ptr = malloc(len, 1) >>> 0;
227
-
228
- const mem = getUint8ArrayMemory0();
229
-
230
- let offset = 0;
231
-
232
- for (; offset < len; offset++) {
233
- const code = arg.charCodeAt(offset);
234
- if (code > 0x7F) break;
235
- mem[ptr + offset] = code;
236
- }
237
- if (offset !== len) {
238
- if (offset !== 0) {
239
- arg = arg.slice(offset);
279
+ /**
280
+ * Computes the Starknet contract address for a controller account without needing a full instance.
281
+ *
282
+ * # Arguments
283
+ *
284
+ * * `class_hash` - The class hash of the account contract (JsFelt).
285
+ * * `owner` - The owner configuration for the account.
286
+ * * `salt` - The salt used for address calculation (JsFelt).
287
+ *
288
+ * # Returns
289
+ *
290
+ * The computed Starknet contract address as a `JsFelt`.
291
+ * @param {JsFelt} class_hash
292
+ * @param {Owner} owner
293
+ * @param {JsFelt} salt
294
+ * @returns {JsFelt}
295
+ */
296
+ export function computeAccountAddress(class_hash, owner, salt) {
297
+ try {
298
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
299
+ wasm.computeAccountAddress(retptr, addHeapObject(class_hash), addHeapObject(owner), addHeapObject(salt));
300
+ var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
301
+ var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
302
+ var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
303
+ if (r2) {
304
+ throw takeObject(r1);
240
305
  }
241
- ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
242
- const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
243
- const ret = cachedTextEncoder.encodeInto(arg, view);
244
-
245
- offset += ret.written;
246
- ptr = realloc(ptr, len, offset, 1) >>> 0;
306
+ return takeObject(r0);
307
+ } finally {
308
+ wasm.__wbindgen_add_to_stack_pointer(16);
247
309
  }
248
-
249
- WASM_VECTOR_LEN = offset;
250
- return ptr;
251
310
  }
252
311
 
253
- function takeObject(idx) {
254
- const ret = getObject(idx);
255
- dropObject(idx);
256
- return ret;
312
+ function _assertClass(instance, klass) {
313
+ if (!(instance instanceof klass)) {
314
+ throw new Error(`expected instance of ${klass.name}`);
315
+ }
257
316
  }
258
317
 
259
- let cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
260
- cachedTextDecoder.decode();
261
- const MAX_SAFARI_DECODE_BYTES = 2146435072;
262
- let numBytesDecoded = 0;
263
- function decodeText(ptr, len) {
264
- numBytesDecoded += len;
265
- if (numBytesDecoded >= MAX_SAFARI_DECODE_BYTES) {
266
- cachedTextDecoder = new TextDecoder('utf-8', { ignoreBOM: true, fatal: true });
267
- cachedTextDecoder.decode();
268
- numBytesDecoded = len;
318
+ function getArrayJsValueFromWasm0(ptr, len) {
319
+ ptr = ptr >>> 0;
320
+ const mem = getDataViewMemory0();
321
+ const result = [];
322
+ for (let i = ptr; i < ptr + 4 * len; i += 4) {
323
+ result.push(takeObject(mem.getUint32(i, true)));
269
324
  }
270
- return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
325
+ return result;
326
+ }
327
+ /**
328
+ * Subscribes to the creation of a session for a given controller, session_key_guid and cartridge api url.
329
+ * The goal of this function is to know from any place when the register session flow has been completed, and to
330
+ * get the authorization.
331
+ * @param {JsFelt} session_key_guid
332
+ * @param {string} cartridge_api_url
333
+ * @returns {Promise<JsSubscribeSessionResult>}
334
+ */
335
+ export function subscribeCreateSession(session_key_guid, cartridge_api_url) {
336
+ const ptr0 = passStringToWasm0(cartridge_api_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
337
+ const len0 = WASM_VECTOR_LEN;
338
+ const ret = wasm.subscribeCreateSession(addHeapObject(session_key_guid), ptr0, len0);
339
+ return takeObject(ret);
271
340
  }
272
341
 
273
- const cachedTextEncoder = new TextEncoder();
274
-
275
- if (!('encodeInto' in cachedTextEncoder)) {
276
- cachedTextEncoder.encodeInto = function (arg, view) {
277
- const buf = cachedTextEncoder.encode(arg);
278
- view.set(buf);
279
- return {
280
- read: arg.length,
281
- written: buf.length
282
- };
342
+ /**
343
+ * @param {Signer} signer
344
+ * @returns {JsFelt}
345
+ */
346
+ export function signerToGuid(signer) {
347
+ try {
348
+ const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
349
+ wasm.signerToGuid(retptr, addHeapObject(signer));
350
+ var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
351
+ var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
352
+ var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
353
+ if (r2) {
354
+ throw takeObject(r1);
355
+ }
356
+ return takeObject(r0);
357
+ } finally {
358
+ wasm.__wbindgen_add_to_stack_pointer(16);
283
359
  }
284
360
  }
285
361
 
286
- let WASM_VECTOR_LEN = 0;
287
-
288
- function __wasm_bindgen_func_elem_8857(arg0, arg1, arg2) {
289
- wasm.__wasm_bindgen_func_elem_8857(arg0, arg1, addHeapObject(arg2));
362
+ function __wasm_bindgen_func_elem_3186(arg0, arg1, arg2) {
363
+ wasm.__wasm_bindgen_func_elem_3186(arg0, arg1, addHeapObject(arg2));
290
364
  }
291
365
 
292
- function __wasm_bindgen_func_elem_3187(arg0, arg1, arg2) {
293
- wasm.__wasm_bindgen_func_elem_3187(arg0, arg1, addHeapObject(arg2));
366
+ function __wasm_bindgen_func_elem_8834(arg0, arg1, arg2) {
367
+ wasm.__wasm_bindgen_func_elem_8834(arg0, arg1, addHeapObject(arg2));
294
368
  }
295
369
 
296
- function __wasm_bindgen_func_elem_8709(arg0, arg1) {
297
- wasm.__wasm_bindgen_func_elem_8709(arg0, arg1);
370
+ function __wasm_bindgen_func_elem_8690(arg0, arg1) {
371
+ wasm.__wasm_bindgen_func_elem_8690(arg0, arg1);
298
372
  }
299
373
 
300
- function __wasm_bindgen_func_elem_10966(arg0, arg1, arg2, arg3) {
301
- wasm.__wasm_bindgen_func_elem_10966(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
374
+ function __wasm_bindgen_func_elem_10962(arg0, arg1, arg2, arg3) {
375
+ wasm.__wasm_bindgen_func_elem_10962(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
302
376
  }
303
377
 
378
+ /**
379
+ * @enum {1 | 20 | 24 | 27 | 28 | 29 | 31 | 32 | 33 | 34 | 40 | 41 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 10 | 64 | 65 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146}
380
+ */
381
+ export const ErrorCode = Object.freeze({
382
+ StarknetFailedToReceiveTransaction: 1, "1": "StarknetFailedToReceiveTransaction",
383
+ StarknetContractNotFound: 20, "20": "StarknetContractNotFound",
384
+ StarknetBlockNotFound: 24, "24": "StarknetBlockNotFound",
385
+ StarknetInvalidTransactionIndex: 27, "27": "StarknetInvalidTransactionIndex",
386
+ StarknetClassHashNotFound: 28, "28": "StarknetClassHashNotFound",
387
+ StarknetTransactionHashNotFound: 29, "29": "StarknetTransactionHashNotFound",
388
+ StarknetPageSizeTooBig: 31, "31": "StarknetPageSizeTooBig",
389
+ StarknetNoBlocks: 32, "32": "StarknetNoBlocks",
390
+ StarknetInvalidContinuationToken: 33, "33": "StarknetInvalidContinuationToken",
391
+ StarknetTooManyKeysInFilter: 34, "34": "StarknetTooManyKeysInFilter",
392
+ StarknetContractError: 40, "40": "StarknetContractError",
393
+ StarknetTransactionExecutionError: 41, "41": "StarknetTransactionExecutionError",
394
+ StarknetClassAlreadyDeclared: 51, "51": "StarknetClassAlreadyDeclared",
395
+ StarknetInvalidTransactionNonce: 52, "52": "StarknetInvalidTransactionNonce",
396
+ StarknetInsufficientMaxFee: 53, "53": "StarknetInsufficientMaxFee",
397
+ StarknetInsufficientAccountBalance: 54, "54": "StarknetInsufficientAccountBalance",
398
+ StarknetValidationFailure: 55, "55": "StarknetValidationFailure",
399
+ StarknetCompilationFailed: 56, "56": "StarknetCompilationFailed",
400
+ StarknetContractClassSizeIsTooLarge: 57, "57": "StarknetContractClassSizeIsTooLarge",
401
+ StarknetNonAccount: 58, "58": "StarknetNonAccount",
402
+ StarknetDuplicateTx: 59, "59": "StarknetDuplicateTx",
403
+ StarknetCompiledClassHashMismatch: 60, "60": "StarknetCompiledClassHashMismatch",
404
+ StarknetUnsupportedTxVersion: 61, "61": "StarknetUnsupportedTxVersion",
405
+ StarknetUnsupportedContractClassVersion: 62, "62": "StarknetUnsupportedContractClassVersion",
406
+ StarknetUnexpectedError: 63, "63": "StarknetUnexpectedError",
407
+ StarknetNoTraceAvailable: 10, "10": "StarknetNoTraceAvailable",
408
+ StarknetReplacementTransactionUnderpriced: 64, "64": "StarknetReplacementTransactionUnderpriced",
409
+ StarknetFeeBelowMinimum: 65, "65": "StarknetFeeBelowMinimum",
410
+ SignError: 101, "101": "SignError",
411
+ StorageError: 102, "102": "StorageError",
412
+ AccountFactoryError: 103, "103": "AccountFactoryError",
413
+ PaymasterExecutionTimeNotReached: 104, "104": "PaymasterExecutionTimeNotReached",
414
+ PaymasterExecutionTimePassed: 105, "105": "PaymasterExecutionTimePassed",
415
+ PaymasterInvalidCaller: 106, "106": "PaymasterInvalidCaller",
416
+ PaymasterRateLimitExceeded: 107, "107": "PaymasterRateLimitExceeded",
417
+ PaymasterNotSupported: 108, "108": "PaymasterNotSupported",
418
+ PaymasterHttp: 109, "109": "PaymasterHttp",
419
+ PaymasterExcecution: 110, "110": "PaymasterExcecution",
420
+ PaymasterSerialization: 111, "111": "PaymasterSerialization",
421
+ CartridgeControllerNotDeployed: 112, "112": "CartridgeControllerNotDeployed",
422
+ InsufficientBalance: 113, "113": "InsufficientBalance",
423
+ OriginError: 114, "114": "OriginError",
424
+ EncodingError: 115, "115": "EncodingError",
425
+ SerdeWasmBindgenError: 116, "116": "SerdeWasmBindgenError",
426
+ CairoSerdeError: 117, "117": "CairoSerdeError",
427
+ CairoShortStringToFeltError: 118, "118": "CairoShortStringToFeltError",
428
+ DeviceCreateCredential: 119, "119": "DeviceCreateCredential",
429
+ DeviceGetAssertion: 120, "120": "DeviceGetAssertion",
430
+ DeviceBadAssertion: 121, "121": "DeviceBadAssertion",
431
+ DeviceChannel: 122, "122": "DeviceChannel",
432
+ DeviceOrigin: 123, "123": "DeviceOrigin",
433
+ AccountSigning: 124, "124": "AccountSigning",
434
+ AccountProvider: 125, "125": "AccountProvider",
435
+ AccountClassHashCalculation: 126, "126": "AccountClassHashCalculation",
436
+ AccountFeeOutOfRange: 128, "128": "AccountFeeOutOfRange",
437
+ ProviderRateLimited: 129, "129": "ProviderRateLimited",
438
+ ProviderArrayLengthMismatch: 130, "130": "ProviderArrayLengthMismatch",
439
+ ProviderOther: 131, "131": "ProviderOther",
440
+ SessionAlreadyRegistered: 132, "132": "SessionAlreadyRegistered",
441
+ UrlParseError: 133, "133": "UrlParseError",
442
+ Base64DecodeError: 134, "134": "Base64DecodeError",
443
+ CoseError: 135, "135": "CoseError",
444
+ PolicyChainIdMismatch: 136, "136": "PolicyChainIdMismatch",
445
+ InvalidOwner: 137, "137": "InvalidOwner",
446
+ GasPriceTooHigh: 138, "138": "GasPriceTooHigh",
447
+ TransactionTimeout: 139, "139": "TransactionTimeout",
448
+ ConversionError: 140, "140": "ConversionError",
449
+ InvalidChainId: 141, "141": "InvalidChainId",
450
+ SessionRefreshRequired: 142, "142": "SessionRefreshRequired",
451
+ ManualExecutionRequired: 143, "143": "ManualExecutionRequired",
452
+ ForbiddenEntrypoint: 144, "144": "ForbiddenEntrypoint",
453
+ GasAmountTooHigh: 145, "145": "GasAmountTooHigh",
454
+ ApproveExecutionRequired: 146, "146": "ApproveExecutionRequired",
455
+ });
456
+
304
457
  const __wbindgen_enum_RequestCache = ["default", "no-store", "reload", "no-cache", "force-cache", "only-if-cached"];
305
458
 
306
459
  const __wbindgen_enum_RequestCredentials = ["omit", "same-origin", "include"];
@@ -311,39 +464,8 @@ const CartridgeAccountFinalization = (typeof FinalizationRegistry === 'undefined
311
464
  ? { register: () => {}, unregister: () => {} }
312
465
  : new FinalizationRegistry(ptr => wasm.__wbg_cartridgeaccount_free(ptr >>> 0, 1));
313
466
 
314
- const CartridgeAccountMetaFinalization = (typeof FinalizationRegistry === 'undefined')
315
- ? { register: () => {}, unregister: () => {} }
316
- : new FinalizationRegistry(ptr => wasm.__wbg_cartridgeaccountmeta_free(ptr >>> 0, 1));
317
-
318
- const CartridgeAccountWithMetaFinalization = (typeof FinalizationRegistry === 'undefined')
319
- ? { register: () => {}, unregister: () => {} }
320
- : new FinalizationRegistry(ptr => wasm.__wbg_cartridgeaccountwithmeta_free(ptr >>> 0, 1));
321
-
322
- const ControllerFactoryFinalization = (typeof FinalizationRegistry === 'undefined')
323
- ? { register: () => {}, unregister: () => {} }
324
- : new FinalizationRegistry(ptr => wasm.__wbg_controllerfactory_free(ptr >>> 0, 1));
325
-
326
- const JsChainConfigFinalization = (typeof FinalizationRegistry === 'undefined')
327
- ? { register: () => {}, unregister: () => {} }
328
- : new FinalizationRegistry(ptr => wasm.__wbg_jschainconfig_free(ptr >>> 0, 1));
329
-
330
- const JsControllerErrorFinalization = (typeof FinalizationRegistry === 'undefined')
331
- ? { register: () => {}, unregister: () => {} }
332
- : new FinalizationRegistry(ptr => wasm.__wbg_jscontrollererror_free(ptr >>> 0, 1));
333
-
334
- const LoginResultFinalization = (typeof FinalizationRegistry === 'undefined')
335
- ? { register: () => {}, unregister: () => {} }
336
- : new FinalizationRegistry(ptr => wasm.__wbg_loginresult_free(ptr >>> 0, 1));
337
-
338
- const MultiChainAccountFinalization = (typeof FinalizationRegistry === 'undefined')
339
- ? { register: () => {}, unregister: () => {} }
340
- : new FinalizationRegistry(ptr => wasm.__wbg_multichainaccount_free(ptr >>> 0, 1));
341
-
342
- const MultiChainAccountMetaFinalization = (typeof FinalizationRegistry === 'undefined')
343
- ? { register: () => {}, unregister: () => {} }
344
- : new FinalizationRegistry(ptr => wasm.__wbg_multichainaccountmeta_free(ptr >>> 0, 1));
345
-
346
467
  export class CartridgeAccount {
468
+
347
469
  static __wrap(ptr) {
348
470
  ptr = ptr >>> 0;
349
471
  const obj = Object.create(CartridgeAccount.prototype);
@@ -351,12 +473,14 @@ export class CartridgeAccount {
351
473
  CartridgeAccountFinalization.register(obj, obj.__wbg_ptr, obj);
352
474
  return obj;
353
475
  }
476
+
354
477
  __destroy_into_raw() {
355
478
  const ptr = this.__wbg_ptr;
356
479
  this.__wbg_ptr = 0;
357
480
  CartridgeAccountFinalization.unregister(this);
358
481
  return ptr;
359
482
  }
483
+
360
484
  free() {
361
485
  const ptr = this.__destroy_into_raw();
362
486
  wasm.__wbg_cartridgeaccount_free(ptr, 0);
@@ -724,6 +848,9 @@ export class CartridgeAccount {
724
848
  }
725
849
  if (Symbol.dispose) CartridgeAccount.prototype[Symbol.dispose] = CartridgeAccount.prototype.free;
726
850
 
851
+ const CartridgeAccountMetaFinalization = (typeof FinalizationRegistry === 'undefined')
852
+ ? { register: () => {}, unregister: () => {} }
853
+ : new FinalizationRegistry(ptr => wasm.__wbg_cartridgeaccountmeta_free(ptr >>> 0, 1));
727
854
  /**
728
855
  * A type for accessing fixed attributes of `CartridgeAccount`.
729
856
  *
@@ -738,6 +865,7 @@ if (Symbol.dispose) CartridgeAccount.prototype[Symbol.dispose] = CartridgeAccoun
738
865
  * be needed.
739
866
  */
740
867
  export class CartridgeAccountMeta {
868
+
741
869
  static __wrap(ptr) {
742
870
  ptr = ptr >>> 0;
743
871
  const obj = Object.create(CartridgeAccountMeta.prototype);
@@ -745,12 +873,14 @@ export class CartridgeAccountMeta {
745
873
  CartridgeAccountMetaFinalization.register(obj, obj.__wbg_ptr, obj);
746
874
  return obj;
747
875
  }
876
+
748
877
  __destroy_into_raw() {
749
878
  const ptr = this.__wbg_ptr;
750
879
  this.__wbg_ptr = 0;
751
880
  CartridgeAccountMetaFinalization.unregister(this);
752
881
  return ptr;
753
882
  }
883
+
754
884
  free() {
755
885
  const ptr = this.__destroy_into_raw();
756
886
  wasm.__wbg_cartridgeaccountmeta_free(ptr, 0);
@@ -867,6 +997,9 @@ export class CartridgeAccountMeta {
867
997
  }
868
998
  if (Symbol.dispose) CartridgeAccountMeta.prototype[Symbol.dispose] = CartridgeAccountMeta.prototype.free;
869
999
 
1000
+ const CartridgeAccountWithMetaFinalization = (typeof FinalizationRegistry === 'undefined')
1001
+ ? { register: () => {}, unregister: () => {} }
1002
+ : new FinalizationRegistry(ptr => wasm.__wbg_cartridgeaccountwithmeta_free(ptr >>> 0, 1));
870
1003
  /**
871
1004
  * A type used as the return type for constructing `CartridgeAccount` to provide an extra,
872
1005
  * separately borrowable `meta` field for synchronously accessing fixed fields.
@@ -875,6 +1008,7 @@ if (Symbol.dispose) CartridgeAccountMeta.prototype[Symbol.dispose] = CartridgeAc
875
1008
  * don't implement `IntoWasmAbi` which is needed for crossing JS-WASM boundary.
876
1009
  */
877
1010
  export class CartridgeAccountWithMeta {
1011
+
878
1012
  static __wrap(ptr) {
879
1013
  ptr = ptr >>> 0;
880
1014
  const obj = Object.create(CartridgeAccountWithMeta.prototype);
@@ -882,12 +1016,14 @@ export class CartridgeAccountWithMeta {
882
1016
  CartridgeAccountWithMetaFinalization.register(obj, obj.__wbg_ptr, obj);
883
1017
  return obj;
884
1018
  }
1019
+
885
1020
  __destroy_into_raw() {
886
1021
  const ptr = this.__wbg_ptr;
887
1022
  this.__wbg_ptr = 0;
888
1023
  CartridgeAccountWithMetaFinalization.unregister(this);
889
1024
  return ptr;
890
1025
  }
1026
+
891
1027
  free() {
892
1028
  const ptr = this.__destroy_into_raw();
893
1029
  wasm.__wbg_cartridgeaccountwithmeta_free(ptr, 0);
@@ -910,13 +1046,19 @@ export class CartridgeAccountWithMeta {
910
1046
  }
911
1047
  if (Symbol.dispose) CartridgeAccountWithMeta.prototype[Symbol.dispose] = CartridgeAccountWithMeta.prototype.free;
912
1048
 
1049
+ const ControllerFactoryFinalization = (typeof FinalizationRegistry === 'undefined')
1050
+ ? { register: () => {}, unregister: () => {} }
1051
+ : new FinalizationRegistry(ptr => wasm.__wbg_controllerfactory_free(ptr >>> 0, 1));
1052
+
913
1053
  export class ControllerFactory {
1054
+
914
1055
  __destroy_into_raw() {
915
1056
  const ptr = this.__wbg_ptr;
916
1057
  this.__wbg_ptr = 0;
917
1058
  ControllerFactoryFinalization.unregister(this);
918
1059
  return ptr;
919
1060
  }
1061
+
920
1062
  free() {
921
1063
  const ptr = this.__destroy_into_raw();
922
1064
  wasm.__wbg_controllerfactory_free(ptr, 0);
@@ -942,164 +1084,91 @@ export class ControllerFactory {
942
1084
  *
943
1085
  * # Returns
944
1086
  *
945
- * Returns a `LoginResult` containing:
946
- * * `account` - The controller account
947
- * * `session` - Optional session (Some if `create_wildcard_session` is true, None otherwise)
948
- *
949
- * # Testing
950
- *
951
- * The core logic is tested in the SDK layer:
952
- * * `account_sdk::tests::session_test::test_wildcard_session_creation` - Tests session creation
953
- * * `account_sdk::tests::session_test::test_login_with_wildcard_session_and_execute` - Tests login with session + execution
954
- * * `account_sdk::tests::session_test::test_login_without_session_can_still_execute` - Tests login without session + execution
955
- *
956
- * The WASM layer is a thin wrapper that:
957
- * 1. Converts WASM types to SDK types
958
- * 2. Calls `Controller::new` and optionally `create_wildcard_session`
959
- * 3. Handles WebAuthn signer updates when multiple signers are present
960
- * 4. Registers the session with Cartridge API if requested
961
- * @param {string} username
962
- * @param {JsFelt} class_hash
963
- * @param {string} rpc_url
964
- * @param {JsFelt} address
965
- * @param {Owner} owner
966
- * @param {string} cartridge_api_url
967
- * @param {bigint} session_expires_at_s
968
- * @param {boolean | null} [is_controller_registered]
969
- * @param {boolean | null} [create_wildcard_session]
970
- * @param {string | null} [app_id]
971
- * @returns {Promise<LoginResult>}
972
- */
973
- static login(username, class_hash, rpc_url, address, owner, cartridge_api_url, session_expires_at_s, is_controller_registered, create_wildcard_session, app_id) {
974
- const ptr0 = passStringToWasm0(username, wasm.__wbindgen_export, wasm.__wbindgen_export2);
975
- const len0 = WASM_VECTOR_LEN;
976
- const ptr1 = passStringToWasm0(rpc_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
977
- const len1 = WASM_VECTOR_LEN;
978
- const ptr2 = passStringToWasm0(cartridge_api_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
979
- const len2 = WASM_VECTOR_LEN;
980
- var ptr3 = isLikeNone(app_id) ? 0 : passStringToWasm0(app_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
981
- var len3 = WASM_VECTOR_LEN;
982
- const ret = wasm.controllerfactory_login(ptr0, len0, addHeapObject(class_hash), ptr1, len1, addHeapObject(address), addHeapObject(owner), ptr2, len2, session_expires_at_s, isLikeNone(is_controller_registered) ? 0xFFFFFF : is_controller_registered ? 1 : 0, isLikeNone(create_wildcard_session) ? 0xFFFFFF : create_wildcard_session ? 1 : 0, ptr3, len3);
983
- return takeObject(ret);
984
- }
985
- /**
986
- * This should only be used with webauthn signers
987
- * @param {string} username
988
- * @param {JsFelt} class_hash
989
- * @param {string} rpc_url
990
- * @param {JsFelt} address
991
- * @param {Owner} owner
992
- * @param {string} cartridge_api_url
993
- * @returns {Promise<CartridgeAccountWithMeta>}
994
- */
995
- static apiLogin(username, class_hash, rpc_url, address, owner, cartridge_api_url) {
996
- const ptr0 = passStringToWasm0(username, wasm.__wbindgen_export, wasm.__wbindgen_export2);
997
- const len0 = WASM_VECTOR_LEN;
998
- const ptr1 = passStringToWasm0(rpc_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
999
- const len1 = WASM_VECTOR_LEN;
1000
- const ptr2 = passStringToWasm0(cartridge_api_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1001
- const len2 = WASM_VECTOR_LEN;
1002
- const ret = wasm.controllerfactory_apiLogin(ptr0, len0, addHeapObject(class_hash), ptr1, len1, addHeapObject(address), addHeapObject(owner), ptr2, len2);
1003
- return takeObject(ret);
1004
- }
1005
- }
1006
- if (Symbol.dispose) ControllerFactory.prototype[Symbol.dispose] = ControllerFactory.prototype.free;
1007
-
1008
- /**
1009
- * @enum {1 | 20 | 24 | 27 | 28 | 29 | 31 | 32 | 33 | 34 | 40 | 41 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 10 | 64 | 65 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146}
1010
- */
1011
- export const ErrorCode = Object.freeze({
1012
- StarknetFailedToReceiveTransaction: 1, "1": "StarknetFailedToReceiveTransaction",
1013
- StarknetContractNotFound: 20, "20": "StarknetContractNotFound",
1014
- StarknetBlockNotFound: 24, "24": "StarknetBlockNotFound",
1015
- StarknetInvalidTransactionIndex: 27, "27": "StarknetInvalidTransactionIndex",
1016
- StarknetClassHashNotFound: 28, "28": "StarknetClassHashNotFound",
1017
- StarknetTransactionHashNotFound: 29, "29": "StarknetTransactionHashNotFound",
1018
- StarknetPageSizeTooBig: 31, "31": "StarknetPageSizeTooBig",
1019
- StarknetNoBlocks: 32, "32": "StarknetNoBlocks",
1020
- StarknetInvalidContinuationToken: 33, "33": "StarknetInvalidContinuationToken",
1021
- StarknetTooManyKeysInFilter: 34, "34": "StarknetTooManyKeysInFilter",
1022
- StarknetContractError: 40, "40": "StarknetContractError",
1023
- StarknetTransactionExecutionError: 41, "41": "StarknetTransactionExecutionError",
1024
- StarknetClassAlreadyDeclared: 51, "51": "StarknetClassAlreadyDeclared",
1025
- StarknetInvalidTransactionNonce: 52, "52": "StarknetInvalidTransactionNonce",
1026
- StarknetInsufficientMaxFee: 53, "53": "StarknetInsufficientMaxFee",
1027
- StarknetInsufficientAccountBalance: 54, "54": "StarknetInsufficientAccountBalance",
1028
- StarknetValidationFailure: 55, "55": "StarknetValidationFailure",
1029
- StarknetCompilationFailed: 56, "56": "StarknetCompilationFailed",
1030
- StarknetContractClassSizeIsTooLarge: 57, "57": "StarknetContractClassSizeIsTooLarge",
1031
- StarknetNonAccount: 58, "58": "StarknetNonAccount",
1032
- StarknetDuplicateTx: 59, "59": "StarknetDuplicateTx",
1033
- StarknetCompiledClassHashMismatch: 60, "60": "StarknetCompiledClassHashMismatch",
1034
- StarknetUnsupportedTxVersion: 61, "61": "StarknetUnsupportedTxVersion",
1035
- StarknetUnsupportedContractClassVersion: 62, "62": "StarknetUnsupportedContractClassVersion",
1036
- StarknetUnexpectedError: 63, "63": "StarknetUnexpectedError",
1037
- StarknetNoTraceAvailable: 10, "10": "StarknetNoTraceAvailable",
1038
- StarknetReplacementTransactionUnderpriced: 64, "64": "StarknetReplacementTransactionUnderpriced",
1039
- StarknetFeeBelowMinimum: 65, "65": "StarknetFeeBelowMinimum",
1040
- SignError: 101, "101": "SignError",
1041
- StorageError: 102, "102": "StorageError",
1042
- AccountFactoryError: 103, "103": "AccountFactoryError",
1043
- PaymasterExecutionTimeNotReached: 104, "104": "PaymasterExecutionTimeNotReached",
1044
- PaymasterExecutionTimePassed: 105, "105": "PaymasterExecutionTimePassed",
1045
- PaymasterInvalidCaller: 106, "106": "PaymasterInvalidCaller",
1046
- PaymasterRateLimitExceeded: 107, "107": "PaymasterRateLimitExceeded",
1047
- PaymasterNotSupported: 108, "108": "PaymasterNotSupported",
1048
- PaymasterHttp: 109, "109": "PaymasterHttp",
1049
- PaymasterExcecution: 110, "110": "PaymasterExcecution",
1050
- PaymasterSerialization: 111, "111": "PaymasterSerialization",
1051
- CartridgeControllerNotDeployed: 112, "112": "CartridgeControllerNotDeployed",
1052
- InsufficientBalance: 113, "113": "InsufficientBalance",
1053
- OriginError: 114, "114": "OriginError",
1054
- EncodingError: 115, "115": "EncodingError",
1055
- SerdeWasmBindgenError: 116, "116": "SerdeWasmBindgenError",
1056
- CairoSerdeError: 117, "117": "CairoSerdeError",
1057
- CairoShortStringToFeltError: 118, "118": "CairoShortStringToFeltError",
1058
- DeviceCreateCredential: 119, "119": "DeviceCreateCredential",
1059
- DeviceGetAssertion: 120, "120": "DeviceGetAssertion",
1060
- DeviceBadAssertion: 121, "121": "DeviceBadAssertion",
1061
- DeviceChannel: 122, "122": "DeviceChannel",
1062
- DeviceOrigin: 123, "123": "DeviceOrigin",
1063
- AccountSigning: 124, "124": "AccountSigning",
1064
- AccountProvider: 125, "125": "AccountProvider",
1065
- AccountClassHashCalculation: 126, "126": "AccountClassHashCalculation",
1066
- AccountFeeOutOfRange: 128, "128": "AccountFeeOutOfRange",
1067
- ProviderRateLimited: 129, "129": "ProviderRateLimited",
1068
- ProviderArrayLengthMismatch: 130, "130": "ProviderArrayLengthMismatch",
1069
- ProviderOther: 131, "131": "ProviderOther",
1070
- SessionAlreadyRegistered: 132, "132": "SessionAlreadyRegistered",
1071
- UrlParseError: 133, "133": "UrlParseError",
1072
- Base64DecodeError: 134, "134": "Base64DecodeError",
1073
- CoseError: 135, "135": "CoseError",
1074
- PolicyChainIdMismatch: 136, "136": "PolicyChainIdMismatch",
1075
- InvalidOwner: 137, "137": "InvalidOwner",
1076
- GasPriceTooHigh: 138, "138": "GasPriceTooHigh",
1077
- TransactionTimeout: 139, "139": "TransactionTimeout",
1078
- ConversionError: 140, "140": "ConversionError",
1079
- InvalidChainId: 141, "141": "InvalidChainId",
1080
- SessionRefreshRequired: 142, "142": "SessionRefreshRequired",
1081
- ManualExecutionRequired: 143, "143": "ManualExecutionRequired",
1082
- ForbiddenEntrypoint: 144, "144": "ForbiddenEntrypoint",
1083
- GasAmountTooHigh: 145, "145": "GasAmountTooHigh",
1084
- ApproveExecutionRequired: 146, "146": "ApproveExecutionRequired",
1085
- });
1087
+ * Returns a `LoginResult` containing:
1088
+ * * `account` - The controller account
1089
+ * * `session` - Optional session (Some if `create_wildcard_session` is true, None otherwise)
1090
+ *
1091
+ * # Testing
1092
+ *
1093
+ * The core logic is tested in the SDK layer:
1094
+ * * `account_sdk::tests::session_test::test_wildcard_session_creation` - Tests session creation
1095
+ * * `account_sdk::tests::session_test::test_login_with_wildcard_session_and_execute` - Tests login with session + execution
1096
+ * * `account_sdk::tests::session_test::test_login_without_session_can_still_execute` - Tests login without session + execution
1097
+ *
1098
+ * The WASM layer is a thin wrapper that:
1099
+ * 1. Converts WASM types to SDK types
1100
+ * 2. Calls `Controller::new` and optionally `create_wildcard_session`
1101
+ * 3. Handles WebAuthn signer updates when multiple signers are present
1102
+ * 4. Registers the session with Cartridge API if requested
1103
+ * @param {string} username
1104
+ * @param {JsFelt} class_hash
1105
+ * @param {string} rpc_url
1106
+ * @param {JsFelt} address
1107
+ * @param {Owner} owner
1108
+ * @param {string} cartridge_api_url
1109
+ * @param {bigint} session_expires_at_s
1110
+ * @param {boolean | null} [is_controller_registered]
1111
+ * @param {boolean | null} [create_wildcard_session]
1112
+ * @param {string | null} [app_id]
1113
+ * @returns {Promise<LoginResult>}
1114
+ */
1115
+ static login(username, class_hash, rpc_url, address, owner, cartridge_api_url, session_expires_at_s, is_controller_registered, create_wildcard_session, app_id) {
1116
+ const ptr0 = passStringToWasm0(username, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1117
+ const len0 = WASM_VECTOR_LEN;
1118
+ const ptr1 = passStringToWasm0(rpc_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1119
+ const len1 = WASM_VECTOR_LEN;
1120
+ const ptr2 = passStringToWasm0(cartridge_api_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1121
+ const len2 = WASM_VECTOR_LEN;
1122
+ var ptr3 = isLikeNone(app_id) ? 0 : passStringToWasm0(app_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1123
+ var len3 = WASM_VECTOR_LEN;
1124
+ const ret = wasm.controllerfactory_login(ptr0, len0, addHeapObject(class_hash), ptr1, len1, addHeapObject(address), addHeapObject(owner), ptr2, len2, session_expires_at_s, isLikeNone(is_controller_registered) ? 0xFFFFFF : is_controller_registered ? 1 : 0, isLikeNone(create_wildcard_session) ? 0xFFFFFF : create_wildcard_session ? 1 : 0, ptr3, len3);
1125
+ return takeObject(ret);
1126
+ }
1127
+ /**
1128
+ * This should only be used with webauthn signers
1129
+ * @param {string} username
1130
+ * @param {JsFelt} class_hash
1131
+ * @param {string} rpc_url
1132
+ * @param {JsFelt} address
1133
+ * @param {Owner} owner
1134
+ * @param {string} cartridge_api_url
1135
+ * @returns {Promise<CartridgeAccountWithMeta>}
1136
+ */
1137
+ static apiLogin(username, class_hash, rpc_url, address, owner, cartridge_api_url) {
1138
+ const ptr0 = passStringToWasm0(username, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1139
+ const len0 = WASM_VECTOR_LEN;
1140
+ const ptr1 = passStringToWasm0(rpc_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1141
+ const len1 = WASM_VECTOR_LEN;
1142
+ const ptr2 = passStringToWasm0(cartridge_api_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1143
+ const len2 = WASM_VECTOR_LEN;
1144
+ const ret = wasm.controllerfactory_apiLogin(ptr0, len0, addHeapObject(class_hash), ptr1, len1, addHeapObject(address), addHeapObject(owner), ptr2, len2);
1145
+ return takeObject(ret);
1146
+ }
1147
+ }
1148
+ if (Symbol.dispose) ControllerFactory.prototype[Symbol.dispose] = ControllerFactory.prototype.free;
1086
1149
 
1150
+ const JsChainConfigFinalization = (typeof FinalizationRegistry === 'undefined')
1151
+ ? { register: () => {}, unregister: () => {} }
1152
+ : new FinalizationRegistry(ptr => wasm.__wbg_jschainconfig_free(ptr >>> 0, 1));
1087
1153
  /**
1088
1154
  * JavaScript-friendly chain configuration
1089
1155
  */
1090
1156
  export class JsChainConfig {
1157
+
1091
1158
  static __unwrap(jsValue) {
1092
1159
  if (!(jsValue instanceof JsChainConfig)) {
1093
1160
  return 0;
1094
1161
  }
1095
1162
  return jsValue.__destroy_into_raw();
1096
1163
  }
1164
+
1097
1165
  __destroy_into_raw() {
1098
1166
  const ptr = this.__wbg_ptr;
1099
1167
  this.__wbg_ptr = 0;
1100
1168
  JsChainConfigFinalization.unregister(this);
1101
1169
  return ptr;
1102
1170
  }
1171
+
1103
1172
  free() {
1104
1173
  const ptr = this.__destroy_into_raw();
1105
1174
  wasm.__wbg_jschainconfig_free(ptr, 0);
@@ -1161,7 +1230,12 @@ export class JsChainConfig {
1161
1230
  }
1162
1231
  if (Symbol.dispose) JsChainConfig.prototype[Symbol.dispose] = JsChainConfig.prototype.free;
1163
1232
 
1233
+ const JsControllerErrorFinalization = (typeof FinalizationRegistry === 'undefined')
1234
+ ? { register: () => {}, unregister: () => {} }
1235
+ : new FinalizationRegistry(ptr => wasm.__wbg_jscontrollererror_free(ptr >>> 0, 1));
1236
+
1164
1237
  export class JsControllerError {
1238
+
1165
1239
  static __wrap(ptr) {
1166
1240
  ptr = ptr >>> 0;
1167
1241
  const obj = Object.create(JsControllerError.prototype);
@@ -1169,12 +1243,14 @@ export class JsControllerError {
1169
1243
  JsControllerErrorFinalization.register(obj, obj.__wbg_ptr, obj);
1170
1244
  return obj;
1171
1245
  }
1246
+
1172
1247
  __destroy_into_raw() {
1173
1248
  const ptr = this.__wbg_ptr;
1174
1249
  this.__wbg_ptr = 0;
1175
1250
  JsControllerErrorFinalization.unregister(this);
1176
1251
  return ptr;
1177
1252
  }
1253
+
1178
1254
  free() {
1179
1255
  const ptr = this.__destroy_into_raw();
1180
1256
  wasm.__wbg_jscontrollererror_free(ptr, 0);
@@ -1249,7 +1325,12 @@ export class JsControllerError {
1249
1325
  }
1250
1326
  if (Symbol.dispose) JsControllerError.prototype[Symbol.dispose] = JsControllerError.prototype.free;
1251
1327
 
1328
+ const LoginResultFinalization = (typeof FinalizationRegistry === 'undefined')
1329
+ ? { register: () => {}, unregister: () => {} }
1330
+ : new FinalizationRegistry(ptr => wasm.__wbg_loginresult_free(ptr >>> 0, 1));
1331
+
1252
1332
  export class LoginResult {
1333
+
1253
1334
  static __wrap(ptr) {
1254
1335
  ptr = ptr >>> 0;
1255
1336
  const obj = Object.create(LoginResult.prototype);
@@ -1257,12 +1338,14 @@ export class LoginResult {
1257
1338
  LoginResultFinalization.register(obj, obj.__wbg_ptr, obj);
1258
1339
  return obj;
1259
1340
  }
1341
+
1260
1342
  __destroy_into_raw() {
1261
1343
  const ptr = this.__wbg_ptr;
1262
1344
  this.__wbg_ptr = 0;
1263
1345
  LoginResultFinalization.unregister(this);
1264
1346
  return ptr;
1265
1347
  }
1348
+
1266
1349
  free() {
1267
1350
  const ptr = this.__destroy_into_raw();
1268
1351
  wasm.__wbg_loginresult_free(ptr, 0);
@@ -1278,10 +1361,14 @@ export class LoginResult {
1278
1361
  }
1279
1362
  if (Symbol.dispose) LoginResult.prototype[Symbol.dispose] = LoginResult.prototype.free;
1280
1363
 
1364
+ const MultiChainAccountFinalization = (typeof FinalizationRegistry === 'undefined')
1365
+ ? { register: () => {}, unregister: () => {} }
1366
+ : new FinalizationRegistry(ptr => wasm.__wbg_multichainaccount_free(ptr >>> 0, 1));
1281
1367
  /**
1282
1368
  * WASM bindings for MultiChainController
1283
1369
  */
1284
1370
  export class MultiChainAccount {
1371
+
1285
1372
  static __wrap(ptr) {
1286
1373
  ptr = ptr >>> 0;
1287
1374
  const obj = Object.create(MultiChainAccount.prototype);
@@ -1289,12 +1376,14 @@ export class MultiChainAccount {
1289
1376
  MultiChainAccountFinalization.register(obj, obj.__wbg_ptr, obj);
1290
1377
  return obj;
1291
1378
  }
1379
+
1292
1380
  __destroy_into_raw() {
1293
1381
  const ptr = this.__wbg_ptr;
1294
1382
  this.__wbg_ptr = 0;
1295
1383
  MultiChainAccountFinalization.unregister(this);
1296
1384
  return ptr;
1297
1385
  }
1386
+
1298
1387
  free() {
1299
1388
  const ptr = this.__destroy_into_raw();
1300
1389
  wasm.__wbg_multichainaccount_free(ptr, 0);
@@ -1359,16 +1448,21 @@ export class MultiChainAccount {
1359
1448
  }
1360
1449
  if (Symbol.dispose) MultiChainAccount.prototype[Symbol.dispose] = MultiChainAccount.prototype.free;
1361
1450
 
1451
+ const MultiChainAccountMetaFinalization = (typeof FinalizationRegistry === 'undefined')
1452
+ ? { register: () => {}, unregister: () => {} }
1453
+ : new FinalizationRegistry(ptr => wasm.__wbg_multichainaccountmeta_free(ptr >>> 0, 1));
1362
1454
  /**
1363
1455
  * Metadata for displaying multi-chain information
1364
1456
  */
1365
1457
  export class MultiChainAccountMeta {
1458
+
1366
1459
  __destroy_into_raw() {
1367
1460
  const ptr = this.__wbg_ptr;
1368
1461
  this.__wbg_ptr = 0;
1369
1462
  MultiChainAccountMetaFinalization.unregister(this);
1370
1463
  return ptr;
1371
1464
  }
1465
+
1372
1466
  free() {
1373
1467
  const ptr = this.__destroy_into_raw();
1374
1468
  wasm.__wbg_multichainaccountmeta_free(ptr, 0);
@@ -1411,75 +1505,7 @@ export class MultiChainAccountMeta {
1411
1505
  }
1412
1506
  if (Symbol.dispose) MultiChainAccountMeta.prototype[Symbol.dispose] = MultiChainAccountMeta.prototype.free;
1413
1507
 
1414
- /**
1415
- * Computes the Starknet contract address for a controller account without needing a full instance.
1416
- *
1417
- * # Arguments
1418
- *
1419
- * * `class_hash` - The class hash of the account contract (JsFelt).
1420
- * * `owner` - The owner configuration for the account.
1421
- * * `salt` - The salt used for address calculation (JsFelt).
1422
- *
1423
- * # Returns
1424
- *
1425
- * The computed Starknet contract address as a `JsFelt`.
1426
- * @param {JsFelt} class_hash
1427
- * @param {Owner} owner
1428
- * @param {JsFelt} salt
1429
- * @returns {JsFelt}
1430
- */
1431
- export function computeAccountAddress(class_hash, owner, salt) {
1432
- try {
1433
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1434
- wasm.computeAccountAddress(retptr, addHeapObject(class_hash), addHeapObject(owner), addHeapObject(salt));
1435
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
1436
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
1437
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
1438
- if (r2) {
1439
- throw takeObject(r1);
1440
- }
1441
- return takeObject(r0);
1442
- } finally {
1443
- wasm.__wbindgen_add_to_stack_pointer(16);
1444
- }
1445
- }
1446
-
1447
- /**
1448
- * @param {Signer} signer
1449
- * @returns {JsFelt}
1450
- */
1451
- export function signerToGuid(signer) {
1452
- try {
1453
- const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
1454
- wasm.signerToGuid(retptr, addHeapObject(signer));
1455
- var r0 = getDataViewMemory0().getInt32(retptr + 4 * 0, true);
1456
- var r1 = getDataViewMemory0().getInt32(retptr + 4 * 1, true);
1457
- var r2 = getDataViewMemory0().getInt32(retptr + 4 * 2, true);
1458
- if (r2) {
1459
- throw takeObject(r1);
1460
- }
1461
- return takeObject(r0);
1462
- } finally {
1463
- wasm.__wbindgen_add_to_stack_pointer(16);
1464
- }
1465
- }
1466
-
1467
- /**
1468
- * Subscribes to the creation of a session for a given controller, session_key_guid and cartridge api url.
1469
- * The goal of this function is to know from any place when the register session flow has been completed, and to
1470
- * get the authorization.
1471
- * @param {JsFelt} session_key_guid
1472
- * @param {string} cartridge_api_url
1473
- * @returns {Promise<JsSubscribeSessionResult>}
1474
- */
1475
- export function subscribeCreateSession(session_key_guid, cartridge_api_url) {
1476
- const ptr0 = passStringToWasm0(cartridge_api_url, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1477
- const len0 = WASM_VECTOR_LEN;
1478
- const ret = wasm.subscribeCreateSession(addHeapObject(session_key_guid), ptr0, len0);
1479
- return takeObject(ret);
1480
- }
1481
-
1482
- export function __wbg_Error_52673b7de5a0ca89(arg0, arg1) {
1508
+ export function __wbg_Error_e83987f665cf5504(arg0, arg1) {
1483
1509
  const ret = Error(getStringFromWasm0(arg0, arg1));
1484
1510
  return addHeapObject(ret);
1485
1511
  };
@@ -1492,13 +1518,13 @@ export function __wbg_String_8f0eb39a4a4c2f66(arg0, arg1) {
1492
1518
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1493
1519
  };
1494
1520
 
1495
- export function __wbg___wbindgen_boolean_get_dea25b33882b895b(arg0) {
1521
+ export function __wbg___wbindgen_boolean_get_6d5a1ee65bab5f68(arg0) {
1496
1522
  const v = getObject(arg0);
1497
1523
  const ret = typeof(v) === 'boolean' ? v : undefined;
1498
1524
  return isLikeNone(ret) ? 0xFFFFFF : ret ? 1 : 0;
1499
1525
  };
1500
1526
 
1501
- export function __wbg___wbindgen_debug_string_adfb662ae34724b6(arg0, arg1) {
1527
+ export function __wbg___wbindgen_debug_string_df47ffb5e35e6763(arg0, arg1) {
1502
1528
  const ret = debugString(getObject(arg1));
1503
1529
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1504
1530
  const len1 = WASM_VECTOR_LEN;
@@ -1506,45 +1532,45 @@ export function __wbg___wbindgen_debug_string_adfb662ae34724b6(arg0, arg1) {
1506
1532
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1507
1533
  };
1508
1534
 
1509
- export function __wbg___wbindgen_in_0d3e1e8f0c669317(arg0, arg1) {
1535
+ export function __wbg___wbindgen_in_bb933bd9e1b3bc0f(arg0, arg1) {
1510
1536
  const ret = getObject(arg0) in getObject(arg1);
1511
1537
  return ret;
1512
1538
  };
1513
1539
 
1514
- export function __wbg___wbindgen_is_function_8d400b8b1af978cd(arg0) {
1540
+ export function __wbg___wbindgen_is_function_ee8a6c5833c90377(arg0) {
1515
1541
  const ret = typeof(getObject(arg0)) === 'function';
1516
1542
  return ret;
1517
1543
  };
1518
1544
 
1519
- export function __wbg___wbindgen_is_object_ce774f3490692386(arg0) {
1545
+ export function __wbg___wbindgen_is_object_c818261d21f283a4(arg0) {
1520
1546
  const val = getObject(arg0);
1521
1547
  const ret = typeof(val) === 'object' && val !== null;
1522
1548
  return ret;
1523
1549
  };
1524
1550
 
1525
- export function __wbg___wbindgen_is_string_704ef9c8fc131030(arg0) {
1551
+ export function __wbg___wbindgen_is_string_fbb76cb2940daafd(arg0) {
1526
1552
  const ret = typeof(getObject(arg0)) === 'string';
1527
1553
  return ret;
1528
1554
  };
1529
1555
 
1530
- export function __wbg___wbindgen_is_undefined_f6b95eab589e0269(arg0) {
1556
+ export function __wbg___wbindgen_is_undefined_2d472862bd29a478(arg0) {
1531
1557
  const ret = getObject(arg0) === undefined;
1532
1558
  return ret;
1533
1559
  };
1534
1560
 
1535
- export function __wbg___wbindgen_jsval_loose_eq_766057600fdd1b0d(arg0, arg1) {
1561
+ export function __wbg___wbindgen_jsval_loose_eq_b664b38a2f582147(arg0, arg1) {
1536
1562
  const ret = getObject(arg0) == getObject(arg1);
1537
1563
  return ret;
1538
1564
  };
1539
1565
 
1540
- export function __wbg___wbindgen_number_get_9619185a74197f95(arg0, arg1) {
1566
+ export function __wbg___wbindgen_number_get_a20bf9b85341449d(arg0, arg1) {
1541
1567
  const obj = getObject(arg1);
1542
1568
  const ret = typeof(obj) === 'number' ? obj : undefined;
1543
1569
  getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
1544
1570
  getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
1545
1571
  };
1546
1572
 
1547
- export function __wbg___wbindgen_string_get_a2a31e16edf96e42(arg0, arg1) {
1573
+ export function __wbg___wbindgen_string_get_e4f06c90489ad01b(arg0, arg1) {
1548
1574
  const obj = getObject(arg1);
1549
1575
  const ret = typeof(obj) === 'string' ? obj : undefined;
1550
1576
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
@@ -1553,41 +1579,41 @@ export function __wbg___wbindgen_string_get_a2a31e16edf96e42(arg0, arg1) {
1553
1579
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1554
1580
  };
1555
1581
 
1556
- export function __wbg___wbindgen_throw_dd24417ed36fc46e(arg0, arg1) {
1582
+ export function __wbg___wbindgen_throw_b855445ff6a94295(arg0, arg1) {
1557
1583
  throw new Error(getStringFromWasm0(arg0, arg1));
1558
1584
  };
1559
1585
 
1560
- export function __wbg__wbg_cb_unref_87dfb5aaa0cbcea7(arg0) {
1586
+ export function __wbg__wbg_cb_unref_2454a539ea5790d9(arg0) {
1561
1587
  getObject(arg0)._wbg_cb_unref();
1562
1588
  };
1563
1589
 
1564
- export function __wbg_abort_07646c894ebbf2bd(arg0) {
1565
- getObject(arg0).abort();
1590
+ export function __wbg_abort_28ad55c5825b004d(arg0, arg1) {
1591
+ getObject(arg0).abort(getObject(arg1));
1566
1592
  };
1567
1593
 
1568
- export function __wbg_abort_399ecbcfd6ef3c8e(arg0, arg1) {
1569
- getObject(arg0).abort(getObject(arg1));
1594
+ export function __wbg_abort_e7eb059f72f9ed0c(arg0) {
1595
+ getObject(arg0).abort();
1570
1596
  };
1571
1597
 
1572
- export function __wbg_addEventListener_6a82629b3d430a48() { return handleError(function (arg0, arg1, arg2, arg3) {
1598
+ export function __wbg_addEventListener_7a418931447b2eae() { return handleError(function (arg0, arg1, arg2, arg3) {
1573
1599
  getObject(arg0).addEventListener(getStringFromWasm0(arg1, arg2), getObject(arg3));
1574
1600
  }, arguments) };
1575
1601
 
1576
- export function __wbg_append_c5cbdf46455cc776() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1602
+ export function __wbg_append_b577eb3a177bc0fa() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1577
1603
  getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
1578
1604
  }, arguments) };
1579
1605
 
1580
- export function __wbg_arrayBuffer_c04af4fce566092d() { return handleError(function (arg0) {
1606
+ export function __wbg_arrayBuffer_b375eccb84b4ddf3() { return handleError(function (arg0) {
1581
1607
  const ret = getObject(arg0).arrayBuffer();
1582
1608
  return addHeapObject(ret);
1583
1609
  }, arguments) };
1584
1610
 
1585
- export function __wbg_call_3020136f7a2d6e44() { return handleError(function (arg0, arg1, arg2) {
1611
+ export function __wbg_call_525440f72fbfc0ea() { return handleError(function (arg0, arg1, arg2) {
1586
1612
  const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
1587
1613
  return addHeapObject(ret);
1588
1614
  }, arguments) };
1589
1615
 
1590
- export function __wbg_call_abb4ff46ce38be40() { return handleError(function (arg0, arg1) {
1616
+ export function __wbg_call_e762c39fa8ea36bf() { return handleError(function (arg0, arg1) {
1591
1617
  const ret = getObject(arg0).call(getObject(arg1));
1592
1618
  return addHeapObject(ret);
1593
1619
  }, arguments) };
@@ -1602,21 +1628,21 @@ export function __wbg_cartridgeaccountwithmeta_new(arg0) {
1602
1628
  return addHeapObject(ret);
1603
1629
  };
1604
1630
 
1605
- export function __wbg_clearTimeout_b716ecb44bea14ed(arg0) {
1631
+ export function __wbg_clearTimeout_7a42b49784aea641(arg0) {
1606
1632
  const ret = clearTimeout(takeObject(arg0));
1607
1633
  return addHeapObject(ret);
1608
1634
  };
1609
1635
 
1610
- export function __wbg_clear_9fc28ed354d59d5e() { return handleError(function (arg0) {
1636
+ export function __wbg_clear_cb2a4a548aeda3df() { return handleError(function (arg0) {
1611
1637
  getObject(arg0).clear();
1612
1638
  }, arguments) };
1613
1639
 
1614
- export function __wbg_create_07d71296a0909e61() { return handleError(function (arg0, arg1) {
1640
+ export function __wbg_create_00dd406d2e274297() { return handleError(function (arg0, arg1) {
1615
1641
  const ret = getObject(arg0).create(getObject(arg1));
1616
1642
  return addHeapObject(ret);
1617
1643
  }, arguments) };
1618
1644
 
1619
- export function __wbg_credentials_36e0572b476d4883(arg0) {
1645
+ export function __wbg_credentials_8cadf6cea6a4f922(arg0) {
1620
1646
  const ret = getObject(arg0).credentials;
1621
1647
  return addHeapObject(ret);
1622
1648
  };
@@ -1626,41 +1652,41 @@ export function __wbg_crypto_574e78ad8b13b65f(arg0) {
1626
1652
  return addHeapObject(ret);
1627
1653
  };
1628
1654
 
1629
- export function __wbg_data_8bf4ae669a78a688(arg0) {
1655
+ export function __wbg_data_ee4306d069f24f2d(arg0) {
1630
1656
  const ret = getObject(arg0).data;
1631
1657
  return addHeapObject(ret);
1632
1658
  };
1633
1659
 
1634
- export function __wbg_done_62ea16af4ce34b24(arg0) {
1660
+ export function __wbg_done_2042aa2670fb1db1(arg0) {
1635
1661
  const ret = getObject(arg0).done;
1636
1662
  return ret;
1637
1663
  };
1638
1664
 
1639
- export function __wbg_error_7bc7d576a6aaf855(arg0) {
1665
+ export function __wbg_error_a7f8fbb0523dae15(arg0) {
1640
1666
  console.error(getObject(arg0));
1641
1667
  };
1642
1668
 
1643
- export function __wbg_fetch_7fb7602a1bf647ec(arg0) {
1669
+ export function __wbg_fetch_74a3e84ebd2c9a0e(arg0) {
1644
1670
  const ret = fetch(getObject(arg0));
1645
1671
  return addHeapObject(ret);
1646
1672
  };
1647
1673
 
1648
- export function __wbg_fetch_90447c28cc0b095e(arg0, arg1) {
1649
- const ret = getObject(arg0).fetch(getObject(arg1));
1674
+ export function __wbg_fetch_f1856afdb49415d1(arg0) {
1675
+ const ret = fetch(getObject(arg0));
1650
1676
  return addHeapObject(ret);
1651
1677
  };
1652
1678
 
1653
- export function __wbg_fetch_f1856afdb49415d1(arg0) {
1654
- const ret = fetch(getObject(arg0));
1679
+ export function __wbg_fetch_f8ba0e29a9d6de0d(arg0, arg1) {
1680
+ const ret = getObject(arg0).fetch(getObject(arg1));
1655
1681
  return addHeapObject(ret);
1656
1682
  };
1657
1683
 
1658
- export function __wbg_getClientExtensionResults_8668622b21a5eef7(arg0) {
1684
+ export function __wbg_getClientExtensionResults_3fbb568c5f7347cf(arg0) {
1659
1685
  const ret = getObject(arg0).getClientExtensionResults();
1660
1686
  return addHeapObject(ret);
1661
1687
  };
1662
1688
 
1663
- export function __wbg_getItem_1340bfc9a10d5991() { return handleError(function (arg0, arg1, arg2, arg3) {
1689
+ export function __wbg_getItem_89f57d6acc51a876() { return handleError(function (arg0, arg1, arg2, arg3) {
1664
1690
  const ret = getObject(arg1).getItem(getStringFromWasm0(arg2, arg3));
1665
1691
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1666
1692
  var len1 = WASM_VECTOR_LEN;
@@ -1672,17 +1698,17 @@ export function __wbg_getRandomValues_b8f5dbd5f3995a9e() { return handleError(fu
1672
1698
  getObject(arg0).getRandomValues(getObject(arg1));
1673
1699
  }, arguments) };
1674
1700
 
1675
- export function __wbg_getTime_ad1e9878a735af08(arg0) {
1701
+ export function __wbg_getTime_14776bfb48a1bff9(arg0) {
1676
1702
  const ret = getObject(arg0).getTime();
1677
1703
  return ret;
1678
1704
  };
1679
1705
 
1680
- export function __wbg_get_29726a9b608aea28() { return handleError(function (arg0, arg1) {
1706
+ export function __wbg_get_de97927282f5fc02() { return handleError(function (arg0, arg1) {
1681
1707
  const ret = getObject(arg0).get(getObject(arg1));
1682
1708
  return addHeapObject(ret);
1683
1709
  }, arguments) };
1684
1710
 
1685
- export function __wbg_get_af9dab7e9603ea93() { return handleError(function (arg0, arg1) {
1711
+ export function __wbg_get_efcb449f58ec27c2() { return handleError(function (arg0, arg1) {
1686
1712
  const ret = Reflect.get(getObject(arg0), getObject(arg1));
1687
1713
  return addHeapObject(ret);
1688
1714
  }, arguments) };
@@ -1692,17 +1718,17 @@ export function __wbg_get_with_ref_key_1dc361bd10053bfe(arg0, arg1) {
1692
1718
  return addHeapObject(ret);
1693
1719
  };
1694
1720
 
1695
- export function __wbg_has_0e670569d65d3a45() { return handleError(function (arg0, arg1) {
1721
+ export function __wbg_has_787fafc980c3ccdb() { return handleError(function (arg0, arg1) {
1696
1722
  const ret = Reflect.has(getObject(arg0), getObject(arg1));
1697
1723
  return ret;
1698
1724
  }, arguments) };
1699
1725
 
1700
- export function __wbg_headers_654c30e1bcccc552(arg0) {
1726
+ export function __wbg_headers_b87d7eaba61c3278(arg0) {
1701
1727
  const ret = getObject(arg0).headers;
1702
1728
  return addHeapObject(ret);
1703
1729
  };
1704
1730
 
1705
- export function __wbg_instanceof_ArrayBuffer_f3320d2419cd0355(arg0) {
1731
+ export function __wbg_instanceof_ArrayBuffer_70beb1189ca63b38(arg0) {
1706
1732
  let result;
1707
1733
  try {
1708
1734
  result = getObject(arg0) instanceof ArrayBuffer;
@@ -1713,7 +1739,7 @@ export function __wbg_instanceof_ArrayBuffer_f3320d2419cd0355(arg0) {
1713
1739
  return ret;
1714
1740
  };
1715
1741
 
1716
- export function __wbg_instanceof_Object_577e21051f7bcb79(arg0) {
1742
+ export function __wbg_instanceof_Object_10bb762262230c68(arg0) {
1717
1743
  let result;
1718
1744
  try {
1719
1745
  result = getObject(arg0) instanceof Object;
@@ -1724,7 +1750,7 @@ export function __wbg_instanceof_Object_577e21051f7bcb79(arg0) {
1724
1750
  return ret;
1725
1751
  };
1726
1752
 
1727
- export function __wbg_instanceof_Response_cd74d1c2ac92cb0b(arg0) {
1753
+ export function __wbg_instanceof_Response_f4f3e87e07f3135c(arg0) {
1728
1754
  let result;
1729
1755
  try {
1730
1756
  result = getObject(arg0) instanceof Response;
@@ -1735,7 +1761,7 @@ export function __wbg_instanceof_Response_cd74d1c2ac92cb0b(arg0) {
1735
1761
  return ret;
1736
1762
  };
1737
1763
 
1738
- export function __wbg_instanceof_Uint8Array_da54ccc9d3e09434(arg0) {
1764
+ export function __wbg_instanceof_Uint8Array_20c8e73002f7af98(arg0) {
1739
1765
  let result;
1740
1766
  try {
1741
1767
  result = getObject(arg0) instanceof Uint8Array;
@@ -1746,7 +1772,7 @@ export function __wbg_instanceof_Uint8Array_da54ccc9d3e09434(arg0) {
1746
1772
  return ret;
1747
1773
  };
1748
1774
 
1749
- export function __wbg_instanceof_Window_b5cf7783caa68180(arg0) {
1775
+ export function __wbg_instanceof_Window_4846dbb3de56c84c(arg0) {
1750
1776
  let result;
1751
1777
  try {
1752
1778
  result = getObject(arg0) instanceof Window;
@@ -1757,7 +1783,7 @@ export function __wbg_instanceof_Window_b5cf7783caa68180(arg0) {
1757
1783
  return ret;
1758
1784
  };
1759
1785
 
1760
- export function __wbg_instanceof_WorkerGlobalScope_9a3411db21c65a54(arg0) {
1786
+ export function __wbg_instanceof_WorkerGlobalScope_e31f49b6d33fcadd(arg0) {
1761
1787
  let result;
1762
1788
  try {
1763
1789
  result = getObject(arg0) instanceof WorkerGlobalScope;
@@ -1768,13 +1794,13 @@ export function __wbg_instanceof_WorkerGlobalScope_9a3411db21c65a54(arg0) {
1768
1794
  return ret;
1769
1795
  };
1770
1796
 
1771
- export function __wbg_iterator_27b7c8b35ab3e86b() {
1797
+ export function __wbg_iterator_e5822695327a3c39() {
1772
1798
  const ret = Symbol.iterator;
1773
1799
  return addHeapObject(ret);
1774
1800
  };
1775
1801
 
1776
1802
  export function __wbg_jschainconfig_unwrap(arg0) {
1777
- const ret = JsChainConfig.__unwrap(getObject(arg0));
1803
+ const ret = JsChainConfig.__unwrap(takeObject(arg0));
1778
1804
  return ret;
1779
1805
  };
1780
1806
 
@@ -1783,22 +1809,22 @@ export function __wbg_jscontrollererror_new(arg0) {
1783
1809
  return addHeapObject(ret);
1784
1810
  };
1785
1811
 
1786
- export function __wbg_length_22ac23eaec9d8053(arg0) {
1812
+ export function __wbg_length_69bca3cb64fc8748(arg0) {
1787
1813
  const ret = getObject(arg0).length;
1788
1814
  return ret;
1789
1815
  };
1790
1816
 
1791
- export function __wbg_localStorage_e7a9e9fee8fc608d() { return handleError(function (arg0) {
1817
+ export function __wbg_localStorage_3034501cd2b3da3f() { return handleError(function (arg0) {
1792
1818
  const ret = getObject(arg0).localStorage;
1793
1819
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
1794
1820
  }, arguments) };
1795
1821
 
1796
- export function __wbg_location_962e75c1c1b3ebed(arg0) {
1822
+ export function __wbg_location_ef1665506d996dd9(arg0) {
1797
1823
  const ret = getObject(arg0).location;
1798
1824
  return addHeapObject(ret);
1799
1825
  };
1800
1826
 
1801
- export function __wbg_log_1d990106d99dacb7(arg0) {
1827
+ export function __wbg_log_8cec76766b8c0e33(arg0) {
1802
1828
  console.log(getObject(arg0));
1803
1829
  };
1804
1830
 
@@ -1817,59 +1843,39 @@ export function __wbg_multichainaccount_new(arg0) {
1817
1843
  return addHeapObject(ret);
1818
1844
  };
1819
1845
 
1820
- export function __wbg_navigator_b49edef831236138(arg0) {
1846
+ export function __wbg_navigator_971384882e8ea23a(arg0) {
1821
1847
  const ret = getObject(arg0).navigator;
1822
1848
  return addHeapObject(ret);
1823
1849
  };
1824
1850
 
1825
- export function __wbg_new_0_23cedd11d9b40c9d() {
1851
+ export function __wbg_new_0_f9740686d739025c() {
1826
1852
  const ret = new Date();
1827
1853
  return addHeapObject(ret);
1828
1854
  };
1829
1855
 
1830
- export function __wbg_new_1ba21ce319a06297() {
1856
+ export function __wbg_new_1acc0b6eea89d040() {
1831
1857
  const ret = new Object();
1832
1858
  return addHeapObject(ret);
1833
1859
  };
1834
1860
 
1835
- export function __wbg_new_25f239778d6112b9() {
1836
- const ret = new Array();
1837
- return addHeapObject(ret);
1838
- };
1839
-
1840
- export function __wbg_new_2658d63118834d8e() {
1841
- const ret = new Mutex();
1842
- return addHeapObject(ret);
1843
- };
1844
-
1845
- export function __wbg_new_3c79b3bb1b32b7d3() { return handleError(function () {
1846
- const ret = new Headers();
1847
- return addHeapObject(ret);
1848
- }, arguments) };
1849
-
1850
- export function __wbg_new_6421f6084cc5bc5a(arg0) {
1851
- const ret = new Uint8Array(getObject(arg0));
1852
- return addHeapObject(ret);
1853
- };
1854
-
1855
- export function __wbg_new_881a222c65f168fc() { return handleError(function () {
1861
+ export function __wbg_new_2531773dac38ebb3() { return handleError(function () {
1856
1862
  const ret = new AbortController();
1857
1863
  return addHeapObject(ret);
1858
1864
  }, arguments) };
1859
1865
 
1860
- export function __wbg_new_b546ae120718850e() {
1861
- const ret = new Map();
1866
+ export function __wbg_new_2658d63118834d8e() {
1867
+ const ret = new Mutex();
1862
1868
  return addHeapObject(ret);
1863
1869
  };
1864
1870
 
1865
- export function __wbg_new_ff12d2b041fb48f1(arg0, arg1) {
1871
+ export function __wbg_new_3c3d849046688a66(arg0, arg1) {
1866
1872
  try {
1867
1873
  var state0 = {a: arg0, b: arg1};
1868
1874
  var cb0 = (arg0, arg1) => {
1869
1875
  const a = state0.a;
1870
1876
  state0.a = 0;
1871
1877
  try {
1872
- return __wasm_bindgen_func_elem_10966(a, state0.b, arg0, arg1);
1878
+ return __wasm_bindgen_func_elem_10962(a, state0.b, arg0, arg1);
1873
1879
  } finally {
1874
1880
  state0.a = a;
1875
1881
  }
@@ -1881,42 +1887,62 @@ export function __wbg_new_ff12d2b041fb48f1(arg0, arg1) {
1881
1887
  }
1882
1888
  };
1883
1889
 
1884
- export function __wbg_new_from_slice_f9c22b9153b26992(arg0, arg1) {
1890
+ export function __wbg_new_5a79be3ab53b8aa5(arg0) {
1891
+ const ret = new Uint8Array(getObject(arg0));
1892
+ return addHeapObject(ret);
1893
+ };
1894
+
1895
+ export function __wbg_new_68651c719dcda04e() {
1896
+ const ret = new Map();
1897
+ return addHeapObject(ret);
1898
+ };
1899
+
1900
+ export function __wbg_new_9edf9838a2def39c() { return handleError(function () {
1901
+ const ret = new Headers();
1902
+ return addHeapObject(ret);
1903
+ }, arguments) };
1904
+
1905
+ export function __wbg_new_e17d9f43105b08be() {
1906
+ const ret = new Array();
1907
+ return addHeapObject(ret);
1908
+ };
1909
+
1910
+ export function __wbg_new_from_slice_92f4d78ca282a2d2(arg0, arg1) {
1885
1911
  const ret = new Uint8Array(getArrayU8FromWasm0(arg0, arg1));
1886
1912
  return addHeapObject(ret);
1887
1913
  };
1888
1914
 
1889
- export function __wbg_new_no_args_cb138f77cf6151ee(arg0, arg1) {
1915
+ export function __wbg_new_no_args_ee98eee5275000a4(arg0, arg1) {
1890
1916
  const ret = new Function(getStringFromWasm0(arg0, arg1));
1891
1917
  return addHeapObject(ret);
1892
1918
  };
1893
1919
 
1894
- export function __wbg_new_with_length_aa5eaf41d35235e5(arg0) {
1920
+ export function __wbg_new_with_length_01aa0dc35aa13543(arg0) {
1895
1921
  const ret = new Uint8Array(arg0 >>> 0);
1896
1922
  return addHeapObject(ret);
1897
1923
  };
1898
1924
 
1899
- export function __wbg_new_with_str_and_init_c5748f76f5108934() { return handleError(function (arg0, arg1, arg2) {
1925
+ export function __wbg_new_with_str_and_init_0ae7728b6ec367b1() { return handleError(function (arg0, arg1, arg2) {
1900
1926
  const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));
1901
1927
  return addHeapObject(ret);
1902
1928
  }, arguments) };
1903
1929
 
1904
- export function __wbg_next_138a17bbf04e926c(arg0) {
1905
- const ret = getObject(arg0).next;
1906
- return addHeapObject(ret);
1907
- };
1908
-
1909
- export function __wbg_next_3cfe5c0fe2a4cc53() { return handleError(function (arg0) {
1930
+ export function __wbg_next_020810e0ae8ebcb0() { return handleError(function (arg0) {
1910
1931
  const ret = getObject(arg0).next();
1911
1932
  return addHeapObject(ret);
1912
1933
  }, arguments) };
1913
1934
 
1935
+ export function __wbg_next_2c826fe5dfec6b6a(arg0) {
1936
+ const ret = getObject(arg0).next;
1937
+ return addHeapObject(ret);
1938
+ };
1939
+
1914
1940
  export function __wbg_node_905d3e251edff8a2(arg0) {
1915
1941
  const ret = getObject(arg0).node;
1916
1942
  return addHeapObject(ret);
1917
1943
  };
1918
1944
 
1919
- export function __wbg_now_69d776cd24f5215b() {
1945
+ export function __wbg_now_793306c526e2e3b6() {
1920
1946
  const ret = Date.now();
1921
1947
  return ret;
1922
1948
  };
@@ -1926,28 +1952,28 @@ export function __wbg_obtain_a9626b3b96e6dc2c(arg0) {
1926
1952
  return addHeapObject(ret);
1927
1953
  };
1928
1954
 
1929
- export function __wbg_open_1611d5d1a9d8cf79() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5, arg6) {
1955
+ export function __wbg_open_fb2ffe46992a06d3() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5, arg6) {
1930
1956
  const ret = getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), getStringFromWasm0(arg5, arg6));
1931
1957
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
1932
1958
  }, arguments) };
1933
1959
 
1934
- export function __wbg_origin_4ab782e7fd21eede(arg0, arg1) {
1960
+ export function __wbg_origin_2b5e7986f349f4f3() { return handleError(function (arg0, arg1) {
1935
1961
  const ret = getObject(arg1).origin;
1936
1962
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1937
1963
  const len1 = WASM_VECTOR_LEN;
1938
1964
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
1939
1965
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1940
- };
1966
+ }, arguments) };
1941
1967
 
1942
- export function __wbg_origin_c4ac149104b9ebad() { return handleError(function (arg0, arg1) {
1968
+ export function __wbg_origin_fe3e49d24e97a343(arg0, arg1) {
1943
1969
  const ret = getObject(arg1).origin;
1944
1970
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
1945
1971
  const len1 = WASM_VECTOR_LEN;
1946
1972
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
1947
1973
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
1948
- }, arguments) };
1974
+ };
1949
1975
 
1950
- export function __wbg_parse_7ff95c018af680b3(arg0, arg1) {
1976
+ export function __wbg_parse_41503dcdc1dc43f2(arg0, arg1) {
1951
1977
  let deferred0_0;
1952
1978
  let deferred0_1;
1953
1979
  try {
@@ -1965,21 +1991,21 @@ export function __wbg_process_dc0fbacc7c1c06f7(arg0) {
1965
1991
  return addHeapObject(ret);
1966
1992
  };
1967
1993
 
1968
- export function __wbg_prototypesetcall_dfe9b766cdc1f1fd(arg0, arg1, arg2) {
1994
+ export function __wbg_prototypesetcall_2a6620b6922694b2(arg0, arg1, arg2) {
1969
1995
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
1970
1996
  };
1971
1997
 
1972
- export function __wbg_push_7d9be8f38fc13975(arg0, arg1) {
1998
+ export function __wbg_push_df81a39d04db858c(arg0, arg1) {
1973
1999
  const ret = getObject(arg0).push(getObject(arg1));
1974
2000
  return ret;
1975
2001
  };
1976
2002
 
1977
- export function __wbg_queueMicrotask_9b549dfce8865860(arg0) {
2003
+ export function __wbg_queueMicrotask_34d692c25c47d05b(arg0) {
1978
2004
  const ret = getObject(arg0).queueMicrotask;
1979
2005
  return addHeapObject(ret);
1980
2006
  };
1981
2007
 
1982
- export function __wbg_queueMicrotask_fca69f5bfad613a5(arg0) {
2008
+ export function __wbg_queueMicrotask_9d76cacb20c84d58(arg0) {
1983
2009
  queueMicrotask(getObject(arg0));
1984
2010
  };
1985
2011
 
@@ -1987,11 +2013,11 @@ export function __wbg_randomFillSync_ac0988aba3254290() { return handleError(fun
1987
2013
  getObject(arg0).randomFillSync(takeObject(arg1));
1988
2014
  }, arguments) };
1989
2015
 
1990
- export function __wbg_removeEventListener_565e273024b68b75() { return handleError(function (arg0, arg1, arg2, arg3) {
2016
+ export function __wbg_removeEventListener_aa21ef619e743518() { return handleError(function (arg0, arg1, arg2, arg3) {
1991
2017
  getObject(arg0).removeEventListener(getStringFromWasm0(arg1, arg2), getObject(arg3));
1992
2018
  }, arguments) };
1993
2019
 
1994
- export function __wbg_removeItem_33ed1aeb2dc68e96() { return handleError(function (arg0, arg1, arg2) {
2020
+ export function __wbg_removeItem_0e1e70f1687b5304() { return handleError(function (arg0, arg1, arg2) {
1995
2021
  getObject(arg0).removeItem(getStringFromWasm0(arg1, arg2));
1996
2022
  }, arguments) };
1997
2023
 
@@ -2000,30 +2026,30 @@ export function __wbg_require_60cc747a6bc5215a() { return handleError(function (
2000
2026
  return addHeapObject(ret);
2001
2027
  }, arguments) };
2002
2028
 
2003
- export function __wbg_resolve_fd5bfbaa4ce36e1e(arg0) {
2029
+ export function __wbg_resolve_caf97c30b83f7053(arg0) {
2004
2030
  const ret = Promise.resolve(getObject(arg0));
2005
2031
  return addHeapObject(ret);
2006
2032
  };
2007
2033
 
2008
- export function __wbg_setItem_1167ad38996d6426() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2034
+ export function __wbg_setItem_64dfb54d7b20d84c() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2009
2035
  getObject(arg0).setItem(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
2010
2036
  }, arguments) };
2011
2037
 
2012
- export function __wbg_setTimeout_06477c23d31efef1() { return handleError(function (arg0, arg1, arg2) {
2013
- const ret = getObject(arg0).setTimeout(getObject(arg1), arg2);
2014
- return ret;
2015
- }, arguments) };
2016
-
2017
- export function __wbg_setTimeout_425032fd8860bd1e() { return handleError(function (arg0, arg1, arg2) {
2038
+ export function __wbg_setTimeout_780ac15e3df4c663() { return handleError(function (arg0, arg1, arg2) {
2018
2039
  const ret = getObject(arg0).setTimeout(getObject(arg1), arg2);
2019
2040
  return ret;
2020
2041
  }, arguments) };
2021
2042
 
2022
- export function __wbg_setTimeout_4302406184dcc5be(arg0, arg1) {
2043
+ export function __wbg_setTimeout_7bb3429662ab1e70(arg0, arg1) {
2023
2044
  const ret = setTimeout(getObject(arg0), arg1);
2024
2045
  return addHeapObject(ret);
2025
2046
  };
2026
2047
 
2048
+ export function __wbg_setTimeout_d673afe2a3649259() { return handleError(function (arg0, arg1, arg2) {
2049
+ const ret = getObject(arg0).setTimeout(getObject(arg1), arg2);
2050
+ return ret;
2051
+ }, arguments) };
2052
+
2027
2053
  export function __wbg_set_3f1d0b984ed272ed(arg0, arg1, arg2) {
2028
2054
  getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
2029
2055
  };
@@ -2032,45 +2058,45 @@ export function __wbg_set_3fda3bac07393de4(arg0, arg1, arg2) {
2032
2058
  getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
2033
2059
  };
2034
2060
 
2035
- export function __wbg_set_781438a03c0c3c81() { return handleError(function (arg0, arg1, arg2) {
2036
- const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));
2037
- return ret;
2038
- }, arguments) };
2039
-
2040
- export function __wbg_set_7df433eea03a5c14(arg0, arg1, arg2) {
2041
- getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
2061
+ export function __wbg_set_907fb406c34a251d(arg0, arg1, arg2) {
2062
+ const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
2063
+ return addHeapObject(ret);
2042
2064
  };
2043
2065
 
2044
- export function __wbg_set_body_8e743242d6076a4f(arg0, arg1) {
2066
+ export function __wbg_set_body_3c365989753d61f4(arg0, arg1) {
2045
2067
  getObject(arg0).body = getObject(arg1);
2046
2068
  };
2047
2069
 
2048
- export function __wbg_set_cache_0e437c7c8e838b9b(arg0, arg1) {
2049
- getObject(arg0).cache = __wbindgen_enum_RequestCache[arg1];
2070
+ export function __wbg_set_c213c871859d6500(arg0, arg1, arg2) {
2071
+ getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
2050
2072
  };
2051
2073
 
2052
- export function __wbg_set_credentials_55ae7c3c106fd5be(arg0, arg1) {
2053
- getObject(arg0).credentials = __wbindgen_enum_RequestCredentials[arg1];
2074
+ export function __wbg_set_c2abbebe8b9ebee1() { return handleError(function (arg0, arg1, arg2) {
2075
+ const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));
2076
+ return ret;
2077
+ }, arguments) };
2078
+
2079
+ export function __wbg_set_cache_2f9deb19b92b81e3(arg0, arg1) {
2080
+ getObject(arg0).cache = __wbindgen_enum_RequestCache[arg1];
2054
2081
  };
2055
2082
 
2056
- export function __wbg_set_efaaf145b9377369(arg0, arg1, arg2) {
2057
- const ret = getObject(arg0).set(getObject(arg1), getObject(arg2));
2058
- return addHeapObject(ret);
2083
+ export function __wbg_set_credentials_f621cd2d85c0c228(arg0, arg1) {
2084
+ getObject(arg0).credentials = __wbindgen_enum_RequestCredentials[arg1];
2059
2085
  };
2060
2086
 
2061
- export function __wbg_set_headers_5671cf088e114d2b(arg0, arg1) {
2087
+ export function __wbg_set_headers_6926da238cd32ee4(arg0, arg1) {
2062
2088
  getObject(arg0).headers = getObject(arg1);
2063
2089
  };
2064
2090
 
2065
- export function __wbg_set_method_76c69e41b3570627(arg0, arg1, arg2) {
2091
+ export function __wbg_set_method_c02d8cbbe204ac2d(arg0, arg1, arg2) {
2066
2092
  getObject(arg0).method = getStringFromWasm0(arg1, arg2);
2067
2093
  };
2068
2094
 
2069
- export function __wbg_set_mode_611016a6818fc690(arg0, arg1) {
2095
+ export function __wbg_set_mode_52ef73cfa79639cb(arg0, arg1) {
2070
2096
  getObject(arg0).mode = __wbindgen_enum_RequestMode[arg1];
2071
2097
  };
2072
2098
 
2073
- export function __wbg_set_signal_e89be862d0091009(arg0, arg1) {
2099
+ export function __wbg_set_signal_dda2cf7ccb6bee0f(arg0, arg1) {
2074
2100
  getObject(arg0).signal = getObject(arg1);
2075
2101
  };
2076
2102
 
@@ -2092,37 +2118,37 @@ export function __wbg_signMessage_c732ea9d998cac79() { return handleError(functi
2092
2118
  }
2093
2119
  }, arguments) };
2094
2120
 
2095
- export function __wbg_signal_3c14fbdc89694b39(arg0) {
2121
+ export function __wbg_signal_4db5aa055bf9eb9a(arg0) {
2096
2122
  const ret = getObject(arg0).signal;
2097
2123
  return addHeapObject(ret);
2098
2124
  };
2099
2125
 
2100
- export function __wbg_static_accessor_GLOBAL_769e6b65d6557335() {
2126
+ export function __wbg_static_accessor_GLOBAL_89e1d9ac6a1b250e() {
2101
2127
  const ret = typeof global === 'undefined' ? null : global;
2102
2128
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2103
2129
  };
2104
2130
 
2105
- export function __wbg_static_accessor_GLOBAL_THIS_60cf02db4de8e1c1() {
2131
+ export function __wbg_static_accessor_GLOBAL_THIS_8b530f326a9e48ac() {
2106
2132
  const ret = typeof globalThis === 'undefined' ? null : globalThis;
2107
2133
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2108
2134
  };
2109
2135
 
2110
- export function __wbg_static_accessor_SELF_08f5a74c69739274() {
2136
+ export function __wbg_static_accessor_SELF_6fdf4b64710cc91b() {
2111
2137
  const ret = typeof self === 'undefined' ? null : self;
2112
2138
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2113
2139
  };
2114
2140
 
2115
- export function __wbg_static_accessor_WINDOW_a8924b26aa92d024() {
2141
+ export function __wbg_static_accessor_WINDOW_b45bfc5a37f6cfa2() {
2116
2142
  const ret = typeof window === 'undefined' ? null : window;
2117
2143
  return isLikeNone(ret) ? 0 : addHeapObject(ret);
2118
2144
  };
2119
2145
 
2120
- export function __wbg_status_9bfc680efca4bdfd(arg0) {
2146
+ export function __wbg_status_de7eed5a7a5bfd5d(arg0) {
2121
2147
  const ret = getObject(arg0).status;
2122
2148
  return ret;
2123
2149
  };
2124
2150
 
2125
- export function __wbg_stringify_56d3c6664110414f(arg0, arg1) {
2151
+ export function __wbg_stringify_404baa47f2ce77aa(arg0, arg1) {
2126
2152
  const ret = JSON.stringify(getObject(arg1));
2127
2153
  var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2128
2154
  var len1 = WASM_VECTOR_LEN;
@@ -2130,32 +2156,32 @@ export function __wbg_stringify_56d3c6664110414f(arg0, arg1) {
2130
2156
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
2131
2157
  };
2132
2158
 
2133
- export function __wbg_stringify_655a6390e1f5eb6b() { return handleError(function (arg0) {
2159
+ export function __wbg_stringify_b5fb28f6465d9c3e() { return handleError(function (arg0) {
2134
2160
  const ret = JSON.stringify(getObject(arg0));
2135
2161
  return addHeapObject(ret);
2136
2162
  }, arguments) };
2137
2163
 
2138
- export function __wbg_subarray_845f2f5bce7d061a(arg0, arg1, arg2) {
2164
+ export function __wbg_subarray_480600f3d6a9f26c(arg0, arg1, arg2) {
2139
2165
  const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);
2140
2166
  return addHeapObject(ret);
2141
2167
  };
2142
2168
 
2143
- export function __wbg_text_51046bb33d257f63() { return handleError(function (arg0) {
2169
+ export function __wbg_text_dc33c15c17bdfb52() { return handleError(function (arg0) {
2144
2170
  const ret = getObject(arg0).text();
2145
2171
  return addHeapObject(ret);
2146
2172
  }, arguments) };
2147
2173
 
2148
- export function __wbg_then_429f7caf1026411d(arg0, arg1, arg2) {
2149
- const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));
2174
+ export function __wbg_then_4f46f6544e6b4a28(arg0, arg1) {
2175
+ const ret = getObject(arg0).then(getObject(arg1));
2150
2176
  return addHeapObject(ret);
2151
2177
  };
2152
2178
 
2153
- export function __wbg_then_4f95312d68691235(arg0, arg1) {
2154
- const ret = getObject(arg0).then(getObject(arg1));
2179
+ export function __wbg_then_70d05cf780a18d77(arg0, arg1, arg2) {
2180
+ const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));
2155
2181
  return addHeapObject(ret);
2156
2182
  };
2157
2183
 
2158
- export function __wbg_url_b6d11838a4f95198(arg0, arg1) {
2184
+ export function __wbg_url_b36d2a5008eb056f(arg0, arg1) {
2159
2185
  const ret = getObject(arg1).url;
2160
2186
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2161
2187
  const len1 = WASM_VECTOR_LEN;
@@ -2163,7 +2189,7 @@ export function __wbg_url_b6d11838a4f95198(arg0, arg1) {
2163
2189
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
2164
2190
  };
2165
2191
 
2166
- export function __wbg_userAgent_e18bc0cc9ad38ec1() { return handleError(function (arg0, arg1) {
2192
+ export function __wbg_userAgent_b20949aa6be940a6() { return handleError(function (arg0, arg1) {
2167
2193
  const ret = getObject(arg1).userAgent;
2168
2194
  const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
2169
2195
  const len1 = WASM_VECTOR_LEN;
@@ -2171,7 +2197,7 @@ export function __wbg_userAgent_e18bc0cc9ad38ec1() { return handleError(function
2171
2197
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
2172
2198
  }, arguments) };
2173
2199
 
2174
- export function __wbg_value_57b7b035e117f7ee(arg0) {
2200
+ export function __wbg_value_692627309814bb8c(arg0) {
2175
2201
  const ret = getObject(arg0).value;
2176
2202
  return addHeapObject(ret);
2177
2203
  };
@@ -2181,12 +2207,6 @@ export function __wbg_versions_c01dfd4722a88165(arg0) {
2181
2207
  return addHeapObject(ret);
2182
2208
  };
2183
2209
 
2184
- export function __wbindgen_cast_049472464cf157cc(arg0, arg1) {
2185
- // Cast intrinsic for `Closure(Closure { dtor_idx: 970, function: Function { arguments: [], shim_idx: 971, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2186
- const ret = makeMutClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_8700, __wasm_bindgen_func_elem_8709);
2187
- return addHeapObject(ret);
2188
- };
2189
-
2190
2210
  export function __wbindgen_cast_2241b6af4c4b2941(arg0, arg1) {
2191
2211
  // Cast intrinsic for `Ref(String) -> Externref`.
2192
2212
  const ret = getStringFromWasm0(arg0, arg1);
@@ -2195,13 +2215,13 @@ export function __wbindgen_cast_2241b6af4c4b2941(arg0, arg1) {
2195
2215
 
2196
2216
  export function __wbindgen_cast_4082834687a71a5d(arg0, arg1) {
2197
2217
  // Cast intrinsic for `Closure(Closure { dtor_idx: 1, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 2, ret: Unit, inner_ret: Some(Unit) }, mutable: false }) -> Externref`.
2198
- const ret = makeClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_225, __wasm_bindgen_func_elem_3187);
2218
+ const ret = makeClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_225, __wasm_bindgen_func_elem_3186);
2199
2219
  return addHeapObject(ret);
2200
2220
  };
2201
2221
 
2202
- export function __wbindgen_cast_74f525bc4433b335(arg0, arg1) {
2203
- // Cast intrinsic for `Closure(Closure { dtor_idx: 1003, function: Function { arguments: [Externref], shim_idx: 1004, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2204
- const ret = makeMutClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_8842, __wasm_bindgen_func_elem_8857);
2222
+ export function __wbindgen_cast_838747baf6b6553b(arg0, arg1) {
2223
+ // Cast intrinsic for `Closure(Closure { dtor_idx: 1004, function: Function { arguments: [Externref], shim_idx: 1005, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2224
+ const ret = makeMutClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_8819, __wasm_bindgen_func_elem_8834);
2205
2225
  return addHeapObject(ret);
2206
2226
  };
2207
2227
 
@@ -2211,6 +2231,12 @@ export function __wbindgen_cast_9ae0607507abb057(arg0) {
2211
2231
  return addHeapObject(ret);
2212
2232
  };
2213
2233
 
2234
+ export function __wbindgen_cast_a572ca3f1306512c(arg0, arg1) {
2235
+ // Cast intrinsic for `Closure(Closure { dtor_idx: 971, function: Function { arguments: [], shim_idx: 972, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2236
+ const ret = makeMutClosure(arg0, arg1, wasm.__wasm_bindgen_func_elem_8681, __wasm_bindgen_func_elem_8690);
2237
+ return addHeapObject(ret);
2238
+ };
2239
+
2214
2240
  export function __wbindgen_cast_cb9088102bce6b30(arg0, arg1) {
2215
2241
  // Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
2216
2242
  const ret = getArrayU8FromWasm0(arg0, arg1);
@@ -2231,3 +2257,4 @@ export function __wbindgen_object_clone_ref(arg0) {
2231
2257
  export function __wbindgen_object_drop_ref(arg0) {
2232
2258
  takeObject(arg0);
2233
2259
  };
2260
+