bitmask-core 1.0.0-beta.9 → 1.0.1-beta
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/bitcoin.js +31 -16
- package/bitmask_core.d.ts +79 -79
- package/bitmask_core.js +445 -441
- package/bitmask_core_bg.js +1701 -1378
- package/bitmask_core_bg.wasm +0 -0
- package/bitmask_core_bg.wasm.d.ts +42 -42
- package/bp.js +17 -7
- package/carbonado.js +17 -7
- package/constants.d.ts +8 -3
- package/constants.js +42 -15
- package/index.js +17 -7
- package/lightning.js +17 -7
- package/nostr.js +17 -7
- package/package.json +47 -107
- package/rgb.d.ts +1 -1
- package/rgb.js +17 -7
- package/wallet.js +17 -7
- package/bitcoin.d.ts.map +0 -1
- package/bitcoin.ts +0 -317
- package/bp.d.ts.map +0 -1
- package/bp.ts +0 -72
- package/carbonado.d.ts.map +0 -1
- package/carbonado.ts +0 -34
- package/constants.d.ts.map +0 -1
- package/constants.ts +0 -112
- package/index.d.ts.map +0 -1
- package/index.ts +0 -33
- package/lightning.d.ts.map +0 -1
- package/lightning.ts +0 -165
- package/nostr.d.ts.map +0 -1
- package/nostr.ts +0 -19
- package/rgb.d.ts.map +0 -1
- package/rgb.ts +0 -710
- package/wallet.d.ts.map +0 -1
- package/wallet.ts +0 -46
package/bitmask_core_bg.js
CHANGED
|
@@ -4,45 +4,17 @@ export function __wbg_set_wasm(val) {
|
|
|
4
4
|
}
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
let cachedTextDecoder = new lTextDecoder('utf-8', { ignoreBOM: true, fatal: true });
|
|
10
|
-
|
|
11
|
-
cachedTextDecoder.decode();
|
|
7
|
+
let WASM_VECTOR_LEN = 0;
|
|
12
8
|
|
|
13
|
-
let
|
|
9
|
+
let cachedUint8ArrayMemory0 = null;
|
|
14
10
|
|
|
15
|
-
function
|
|
16
|
-
if (
|
|
17
|
-
|
|
11
|
+
function getUint8ArrayMemory0() {
|
|
12
|
+
if (cachedUint8ArrayMemory0 === null || cachedUint8ArrayMemory0.byteLength === 0) {
|
|
13
|
+
cachedUint8ArrayMemory0 = new Uint8Array(wasm.memory.buffer);
|
|
18
14
|
}
|
|
19
|
-
return
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
function getStringFromWasm0(ptr, len) {
|
|
23
|
-
ptr = ptr >>> 0;
|
|
24
|
-
return cachedTextDecoder.decode(getUint8Memory0().subarray(ptr, ptr + len));
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
const heap = new Array(128).fill(undefined);
|
|
28
|
-
|
|
29
|
-
heap.push(undefined, null, true, false);
|
|
30
|
-
|
|
31
|
-
let heap_next = heap.length;
|
|
32
|
-
|
|
33
|
-
function addHeapObject(obj) {
|
|
34
|
-
if (heap_next === heap.length) heap.push(heap.length + 1);
|
|
35
|
-
const idx = heap_next;
|
|
36
|
-
heap_next = heap[idx];
|
|
37
|
-
|
|
38
|
-
heap[idx] = obj;
|
|
39
|
-
return idx;
|
|
15
|
+
return cachedUint8ArrayMemory0;
|
|
40
16
|
}
|
|
41
17
|
|
|
42
|
-
function getObject(idx) { return heap[idx]; }
|
|
43
|
-
|
|
44
|
-
let WASM_VECTOR_LEN = 0;
|
|
45
|
-
|
|
46
18
|
const lTextEncoder = typeof TextEncoder === 'undefined' ? (0, module.require)('util').TextEncoder : TextEncoder;
|
|
47
19
|
|
|
48
20
|
let cachedTextEncoder = new lTextEncoder('utf-8');
|
|
@@ -65,7 +37,7 @@ function passStringToWasm0(arg, malloc, realloc) {
|
|
|
65
37
|
if (realloc === undefined) {
|
|
66
38
|
const buf = cachedTextEncoder.encode(arg);
|
|
67
39
|
const ptr = malloc(buf.length, 1) >>> 0;
|
|
68
|
-
|
|
40
|
+
getUint8ArrayMemory0().subarray(ptr, ptr + buf.length).set(buf);
|
|
69
41
|
WASM_VECTOR_LEN = buf.length;
|
|
70
42
|
return ptr;
|
|
71
43
|
}
|
|
@@ -73,7 +45,7 @@ function passStringToWasm0(arg, malloc, realloc) {
|
|
|
73
45
|
let len = arg.length;
|
|
74
46
|
let ptr = malloc(len, 1) >>> 0;
|
|
75
47
|
|
|
76
|
-
const mem =
|
|
48
|
+
const mem = getUint8ArrayMemory0();
|
|
77
49
|
|
|
78
50
|
let offset = 0;
|
|
79
51
|
|
|
@@ -88,57 +60,101 @@ function passStringToWasm0(arg, malloc, realloc) {
|
|
|
88
60
|
arg = arg.slice(offset);
|
|
89
61
|
}
|
|
90
62
|
ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;
|
|
91
|
-
const view =
|
|
63
|
+
const view = getUint8ArrayMemory0().subarray(ptr + offset, ptr + len);
|
|
92
64
|
const ret = encodeString(arg, view);
|
|
93
65
|
|
|
94
66
|
offset += ret.written;
|
|
67
|
+
ptr = realloc(ptr, len, offset, 1) >>> 0;
|
|
95
68
|
}
|
|
96
69
|
|
|
97
70
|
WASM_VECTOR_LEN = offset;
|
|
98
71
|
return ptr;
|
|
99
72
|
}
|
|
100
73
|
|
|
101
|
-
|
|
102
|
-
return x === undefined || x === null;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
let cachedInt32Memory0 = null;
|
|
74
|
+
let cachedDataViewMemory0 = null;
|
|
106
75
|
|
|
107
|
-
function
|
|
108
|
-
if (
|
|
109
|
-
|
|
76
|
+
function getDataViewMemory0() {
|
|
77
|
+
if (cachedDataViewMemory0 === null || cachedDataViewMemory0.buffer.detached === true || (cachedDataViewMemory0.buffer.detached === undefined && cachedDataViewMemory0.buffer !== wasm.memory.buffer)) {
|
|
78
|
+
cachedDataViewMemory0 = new DataView(wasm.memory.buffer);
|
|
110
79
|
}
|
|
111
|
-
return
|
|
80
|
+
return cachedDataViewMemory0;
|
|
112
81
|
}
|
|
113
82
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
83
|
+
const lTextDecoder = typeof TextDecoder === 'undefined' ? (0, module.require)('util').TextDecoder : TextDecoder;
|
|
84
|
+
|
|
85
|
+
let cachedTextDecoder = new lTextDecoder('utf-8', { ignoreBOM: true, fatal: true });
|
|
86
|
+
|
|
87
|
+
cachedTextDecoder.decode();
|
|
88
|
+
|
|
89
|
+
function getStringFromWasm0(ptr, len) {
|
|
90
|
+
ptr = ptr >>> 0;
|
|
91
|
+
return cachedTextDecoder.decode(getUint8ArrayMemory0().subarray(ptr, ptr + len));
|
|
118
92
|
}
|
|
119
93
|
|
|
120
|
-
function
|
|
121
|
-
const
|
|
122
|
-
|
|
123
|
-
return
|
|
94
|
+
function addToExternrefTable0(obj) {
|
|
95
|
+
const idx = wasm.__externref_table_alloc();
|
|
96
|
+
wasm.__wbindgen_export_4.set(idx, obj);
|
|
97
|
+
return idx;
|
|
124
98
|
}
|
|
125
99
|
|
|
126
|
-
|
|
100
|
+
function handleError(f, args) {
|
|
101
|
+
try {
|
|
102
|
+
return f.apply(this, args);
|
|
103
|
+
} catch (e) {
|
|
104
|
+
const idx = addToExternrefTable0(e);
|
|
105
|
+
wasm.__wbindgen_exn_store(idx);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
127
108
|
|
|
128
|
-
function
|
|
129
|
-
|
|
130
|
-
|
|
109
|
+
function getArrayJsValueFromWasm0(ptr, len) {
|
|
110
|
+
ptr = ptr >>> 0;
|
|
111
|
+
const mem = getDataViewMemory0();
|
|
112
|
+
const result = [];
|
|
113
|
+
for (let i = ptr; i < ptr + 4 * len; i += 4) {
|
|
114
|
+
result.push(wasm.__wbindgen_export_4.get(mem.getUint32(i, true)));
|
|
131
115
|
}
|
|
132
|
-
|
|
116
|
+
wasm.__externref_drop_slice(ptr, len);
|
|
117
|
+
return result;
|
|
133
118
|
}
|
|
134
119
|
|
|
135
|
-
|
|
120
|
+
function isLikeNone(x) {
|
|
121
|
+
return x === undefined || x === null;
|
|
122
|
+
}
|
|
136
123
|
|
|
137
|
-
function
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
124
|
+
function getArrayU8FromWasm0(ptr, len) {
|
|
125
|
+
ptr = ptr >>> 0;
|
|
126
|
+
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
const CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')
|
|
130
|
+
? { register: () => {}, unregister: () => {} }
|
|
131
|
+
: new FinalizationRegistry(state => {
|
|
132
|
+
wasm.__wbindgen_export_7.get(state.dtor)(state.a, state.b)
|
|
133
|
+
});
|
|
134
|
+
|
|
135
|
+
function makeMutClosure(arg0, arg1, dtor, f) {
|
|
136
|
+
const state = { a: arg0, b: arg1, cnt: 1, dtor };
|
|
137
|
+
const real = (...args) => {
|
|
138
|
+
// First up with a closure we increment the internal reference
|
|
139
|
+
// count. This ensures that the Rust closure environment won't
|
|
140
|
+
// be deallocated while we're invoking it.
|
|
141
|
+
state.cnt++;
|
|
142
|
+
const a = state.a;
|
|
143
|
+
state.a = 0;
|
|
144
|
+
try {
|
|
145
|
+
return f(a, state.b, ...args);
|
|
146
|
+
} finally {
|
|
147
|
+
if (--state.cnt === 0) {
|
|
148
|
+
wasm.__wbindgen_export_7.get(state.dtor)(a, state.b);
|
|
149
|
+
CLOSURE_DTORS.unregister(state);
|
|
150
|
+
} else {
|
|
151
|
+
state.a = a;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
};
|
|
155
|
+
real.original = state;
|
|
156
|
+
CLOSURE_DTORS.register(real, state, state);
|
|
157
|
+
return real;
|
|
142
158
|
}
|
|
143
159
|
|
|
144
160
|
function debugString(val) {
|
|
@@ -182,7 +198,7 @@ function debugString(val) {
|
|
|
182
198
|
// Test for built-in
|
|
183
199
|
const builtInMatches = /\[object ([^\]]+)\]/.exec(toString.call(val));
|
|
184
200
|
let className;
|
|
185
|
-
if (builtInMatches.length > 1) {
|
|
201
|
+
if (builtInMatches && builtInMatches.length > 1) {
|
|
186
202
|
className = builtInMatches[1];
|
|
187
203
|
} else {
|
|
188
204
|
// Failed to match the standard '[object ClassName]'
|
|
@@ -206,1404 +222,1422 @@ function debugString(val) {
|
|
|
206
222
|
return className;
|
|
207
223
|
}
|
|
208
224
|
|
|
209
|
-
function
|
|
210
|
-
const
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
// be deallocated while we're invoking it.
|
|
215
|
-
state.cnt++;
|
|
216
|
-
const a = state.a;
|
|
217
|
-
state.a = 0;
|
|
218
|
-
try {
|
|
219
|
-
return f(a, state.b, ...args);
|
|
220
|
-
} finally {
|
|
221
|
-
if (--state.cnt === 0) {
|
|
222
|
-
wasm.__wbindgen_export_2.get(state.dtor)(a, state.b);
|
|
223
|
-
|
|
224
|
-
} else {
|
|
225
|
-
state.a = a;
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
};
|
|
229
|
-
real.original = state;
|
|
230
|
-
|
|
231
|
-
return real;
|
|
232
|
-
}
|
|
233
|
-
function __wbg_adapter_50(arg0, arg1, arg2) {
|
|
234
|
-
wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hb4bbeda2256a529d(arg0, arg1, addHeapObject(arg2));
|
|
225
|
+
function passArray8ToWasm0(arg, malloc) {
|
|
226
|
+
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
227
|
+
getUint8ArrayMemory0().set(arg, ptr / 1);
|
|
228
|
+
WASM_VECTOR_LEN = arg.length;
|
|
229
|
+
return ptr;
|
|
235
230
|
}
|
|
236
|
-
|
|
237
231
|
/**
|
|
238
|
-
* @param {string}
|
|
239
|
-
* @param {string}
|
|
240
|
-
* @
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
232
|
+
* @param {string} secret_key
|
|
233
|
+
* @param {string} name
|
|
234
|
+
* @param {Uint8Array} data
|
|
235
|
+
* @param {boolean} force
|
|
236
|
+
* @param {Uint8Array | null} [metadata]
|
|
237
|
+
* @returns {Promise<any>}
|
|
238
|
+
*/
|
|
239
|
+
export function store(secret_key, name, data, force, metadata) {
|
|
240
|
+
const ptr0 = passStringToWasm0(secret_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
244
241
|
const len0 = WASM_VECTOR_LEN;
|
|
245
|
-
const ptr1 = passStringToWasm0(
|
|
242
|
+
const ptr1 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
246
243
|
const len1 = WASM_VECTOR_LEN;
|
|
247
|
-
const
|
|
248
|
-
|
|
244
|
+
const ptr2 = passArray8ToWasm0(data, wasm.__wbindgen_malloc);
|
|
245
|
+
const len2 = WASM_VECTOR_LEN;
|
|
246
|
+
var ptr3 = isLikeNone(metadata) ? 0 : passArray8ToWasm0(metadata, wasm.__wbindgen_malloc);
|
|
247
|
+
var len3 = WASM_VECTOR_LEN;
|
|
248
|
+
const ret = wasm.store(ptr0, len0, ptr1, len1, ptr2, len2, force, ptr3, len3);
|
|
249
|
+
return ret;
|
|
249
250
|
}
|
|
250
251
|
|
|
251
252
|
/**
|
|
252
|
-
* @param {string}
|
|
253
|
-
* @param {string}
|
|
254
|
-
* @returns {Promise<any>}
|
|
255
|
-
*/
|
|
256
|
-
export function
|
|
257
|
-
const ptr0 = passStringToWasm0(
|
|
253
|
+
* @param {string} secret_key
|
|
254
|
+
* @param {string} name
|
|
255
|
+
* @returns {Promise<any>}
|
|
256
|
+
*/
|
|
257
|
+
export function retrieve(secret_key, name) {
|
|
258
|
+
const ptr0 = passStringToWasm0(secret_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
258
259
|
const len0 = WASM_VECTOR_LEN;
|
|
259
|
-
const ptr1 = passStringToWasm0(
|
|
260
|
+
const ptr1 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
260
261
|
const len1 = WASM_VECTOR_LEN;
|
|
261
|
-
const ret = wasm.
|
|
262
|
-
return
|
|
262
|
+
const ret = wasm.retrieve(ptr0, len0, ptr1, len1);
|
|
263
|
+
return ret;
|
|
263
264
|
}
|
|
264
265
|
|
|
265
266
|
/**
|
|
266
|
-
* @param {string}
|
|
267
|
-
* @param {
|
|
268
|
-
* @returns {Promise<any>}
|
|
269
|
-
*/
|
|
270
|
-
export function
|
|
271
|
-
const ptr0 = passStringToWasm0(
|
|
267
|
+
* @param {string} secret_key
|
|
268
|
+
* @param {string} name
|
|
269
|
+
* @returns {Promise<any>}
|
|
270
|
+
*/
|
|
271
|
+
export function retrieve_metadata(secret_key, name) {
|
|
272
|
+
const ptr0 = passStringToWasm0(secret_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
272
273
|
const len0 = WASM_VECTOR_LEN;
|
|
273
|
-
const
|
|
274
|
-
|
|
274
|
+
const ptr1 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
275
|
+
const len1 = WASM_VECTOR_LEN;
|
|
276
|
+
const ret = wasm.retrieve_metadata(ptr0, len0, ptr1, len1);
|
|
277
|
+
return ret;
|
|
275
278
|
}
|
|
276
279
|
|
|
277
280
|
/**
|
|
278
|
-
* @param {
|
|
279
|
-
* @
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
281
|
+
* @param {Uint8Array} bytes
|
|
282
|
+
* @returns {string}
|
|
283
|
+
*/
|
|
284
|
+
export function encode_hex(bytes) {
|
|
285
|
+
let deferred2_0;
|
|
286
|
+
let deferred2_1;
|
|
287
|
+
try {
|
|
288
|
+
const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);
|
|
289
|
+
const len0 = WASM_VECTOR_LEN;
|
|
290
|
+
const ret = wasm.encode_hex(ptr0, len0);
|
|
291
|
+
deferred2_0 = ret[0];
|
|
292
|
+
deferred2_1 = ret[1];
|
|
293
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
294
|
+
} finally {
|
|
295
|
+
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
296
|
+
}
|
|
289
297
|
}
|
|
290
298
|
|
|
291
299
|
/**
|
|
292
|
-
* @param {
|
|
293
|
-
* @
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
300
|
+
* @param {Uint8Array} bytes
|
|
301
|
+
* @returns {string}
|
|
302
|
+
*/
|
|
303
|
+
export function encode_base64(bytes) {
|
|
304
|
+
let deferred2_0;
|
|
305
|
+
let deferred2_1;
|
|
306
|
+
try {
|
|
307
|
+
const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);
|
|
308
|
+
const len0 = WASM_VECTOR_LEN;
|
|
309
|
+
const ret = wasm.encode_base64(ptr0, len0);
|
|
310
|
+
deferred2_0 = ret[0];
|
|
311
|
+
deferred2_1 = ret[1];
|
|
312
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
313
|
+
} finally {
|
|
314
|
+
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
315
|
+
}
|
|
303
316
|
}
|
|
304
317
|
|
|
318
|
+
function takeFromExternrefTable0(idx) {
|
|
319
|
+
const value = wasm.__wbindgen_export_4.get(idx);
|
|
320
|
+
wasm.__externref_table_dealloc(idx);
|
|
321
|
+
return value;
|
|
322
|
+
}
|
|
305
323
|
/**
|
|
306
|
-
* @param {string}
|
|
307
|
-
* @
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
324
|
+
* @param {string} string
|
|
325
|
+
* @returns {Uint8Array}
|
|
326
|
+
*/
|
|
327
|
+
export function decode_hex(string) {
|
|
328
|
+
const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
312
329
|
const len0 = WASM_VECTOR_LEN;
|
|
313
|
-
const ret = wasm.
|
|
314
|
-
|
|
330
|
+
const ret = wasm.decode_hex(ptr0, len0);
|
|
331
|
+
if (ret[3]) {
|
|
332
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
333
|
+
}
|
|
334
|
+
var v2 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
335
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
336
|
+
return v2;
|
|
315
337
|
}
|
|
316
338
|
|
|
317
339
|
/**
|
|
318
|
-
* @param {string}
|
|
319
|
-
* @
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
340
|
+
* @param {string} string
|
|
341
|
+
* @returns {Uint8Array}
|
|
342
|
+
*/
|
|
343
|
+
export function decode_base64(string) {
|
|
344
|
+
const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
324
345
|
const len0 = WASM_VECTOR_LEN;
|
|
325
|
-
const ret = wasm.
|
|
326
|
-
|
|
346
|
+
const ret = wasm.decode_base64(ptr0, len0);
|
|
347
|
+
if (ret[3]) {
|
|
348
|
+
throw takeFromExternrefTable0(ret[2]);
|
|
349
|
+
}
|
|
350
|
+
var v2 = getArrayU8FromWasm0(ret[0], ret[1]).slice();
|
|
351
|
+
wasm.__wbindgen_free(ret[0], ret[1] * 1, 1);
|
|
352
|
+
return v2;
|
|
327
353
|
}
|
|
328
354
|
|
|
329
355
|
/**
|
|
330
|
-
* @param {string} nostr_hex_sk
|
|
331
|
-
* @param {any} request
|
|
332
|
-
* @returns {Promise<any>}
|
|
333
|
-
*/
|
|
334
|
-
export function
|
|
356
|
+
* @param {string} nostr_hex_sk
|
|
357
|
+
* @param {any} request
|
|
358
|
+
* @returns {Promise<any>}
|
|
359
|
+
*/
|
|
360
|
+
export function create_watcher(nostr_hex_sk, request) {
|
|
335
361
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
336
362
|
const len0 = WASM_VECTOR_LEN;
|
|
337
|
-
const ret = wasm.
|
|
338
|
-
return
|
|
363
|
+
const ret = wasm.create_watcher(ptr0, len0, request);
|
|
364
|
+
return ret;
|
|
339
365
|
}
|
|
340
366
|
|
|
341
367
|
/**
|
|
342
|
-
* @param {string} nostr_hex_sk
|
|
343
|
-
* @param {
|
|
344
|
-
* @returns {Promise<any>}
|
|
345
|
-
*/
|
|
346
|
-
export function
|
|
368
|
+
* @param {string} nostr_hex_sk
|
|
369
|
+
* @param {any} request
|
|
370
|
+
* @returns {Promise<any>}
|
|
371
|
+
*/
|
|
372
|
+
export function recover_watcher(nostr_hex_sk, request) {
|
|
347
373
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
348
374
|
const len0 = WASM_VECTOR_LEN;
|
|
349
|
-
const
|
|
350
|
-
|
|
351
|
-
const ret = wasm.remove_rgb_invoice(ptr0, len0, ptr1, len1);
|
|
352
|
-
return takeObject(ret);
|
|
375
|
+
const ret = wasm.recover_watcher(ptr0, len0, request);
|
|
376
|
+
return ret;
|
|
353
377
|
}
|
|
354
378
|
|
|
355
379
|
/**
|
|
356
|
-
* @param {string} nostr_hex_sk
|
|
357
|
-
* @returns {Promise<any>}
|
|
358
|
-
*/
|
|
359
|
-
export function
|
|
380
|
+
* @param {string} nostr_hex_sk
|
|
381
|
+
* @returns {Promise<any>}
|
|
382
|
+
*/
|
|
383
|
+
export function destroy_watcher(nostr_hex_sk) {
|
|
360
384
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
361
385
|
const len0 = WASM_VECTOR_LEN;
|
|
362
|
-
const ret = wasm.
|
|
363
|
-
return
|
|
386
|
+
const ret = wasm.destroy_watcher(ptr0, len0);
|
|
387
|
+
return ret;
|
|
364
388
|
}
|
|
365
389
|
|
|
366
390
|
/**
|
|
367
|
-
* @param {string} nostr_hex_sk
|
|
368
|
-
* @
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
export function can_create_transfer_contract(nostr_hex_sk, request) {
|
|
391
|
+
* @param {string} nostr_hex_sk
|
|
392
|
+
* @returns {Promise<any>}
|
|
393
|
+
*/
|
|
394
|
+
export function destroy_recover_watcher(nostr_hex_sk) {
|
|
372
395
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
373
396
|
const len0 = WASM_VECTOR_LEN;
|
|
374
|
-
const ret = wasm.
|
|
375
|
-
return
|
|
397
|
+
const ret = wasm.destroy_recover_watcher(ptr0, len0);
|
|
398
|
+
return ret;
|
|
376
399
|
}
|
|
377
400
|
|
|
378
401
|
/**
|
|
379
|
-
* @param {string} nostr_hex_sk
|
|
380
|
-
* @
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
export function create_rgb_transfer(nostr_hex_sk, request) {
|
|
402
|
+
* @param {string} nostr_hex_sk
|
|
403
|
+
* @returns {Promise<any>}
|
|
404
|
+
*/
|
|
405
|
+
export function check_watcher(nostr_hex_sk) {
|
|
384
406
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
385
407
|
const len0 = WASM_VECTOR_LEN;
|
|
386
|
-
const ret = wasm.
|
|
387
|
-
return
|
|
408
|
+
const ret = wasm.check_watcher(ptr0, len0);
|
|
409
|
+
return ret;
|
|
388
410
|
}
|
|
389
411
|
|
|
390
412
|
/**
|
|
391
|
-
* @param {string} nostr_hex_sk
|
|
392
|
-
* @param {
|
|
393
|
-
* @
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
export function create_and_publish_rgb_transfer(nostr_hex_sk, request, secrets) {
|
|
413
|
+
* @param {string} nostr_hex_sk
|
|
414
|
+
* @param {string} request
|
|
415
|
+
* @returns {Promise<any>}
|
|
416
|
+
*/
|
|
417
|
+
export function watcher_next_address(nostr_hex_sk, request) {
|
|
397
418
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
398
419
|
const len0 = WASM_VECTOR_LEN;
|
|
399
|
-
const
|
|
400
|
-
|
|
420
|
+
const ptr1 = passStringToWasm0(request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
421
|
+
const len1 = WASM_VECTOR_LEN;
|
|
422
|
+
const ret = wasm.watcher_next_address(ptr0, len0, ptr1, len1);
|
|
423
|
+
return ret;
|
|
401
424
|
}
|
|
402
425
|
|
|
403
426
|
/**
|
|
404
|
-
* @param {string} nostr_hex_sk
|
|
405
|
-
* @param {
|
|
406
|
-
* @returns {Promise<any>}
|
|
407
|
-
*/
|
|
408
|
-
export function
|
|
427
|
+
* @param {string} nostr_hex_sk
|
|
428
|
+
* @param {string} request
|
|
429
|
+
* @returns {Promise<any>}
|
|
430
|
+
*/
|
|
431
|
+
export function watcher_next_utxo(nostr_hex_sk, request) {
|
|
409
432
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
410
433
|
const len0 = WASM_VECTOR_LEN;
|
|
411
|
-
const
|
|
412
|
-
|
|
434
|
+
const ptr1 = passStringToWasm0(request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
435
|
+
const len1 = WASM_VECTOR_LEN;
|
|
436
|
+
const ret = wasm.watcher_next_utxo(ptr0, len0, ptr1, len1);
|
|
437
|
+
return ret;
|
|
413
438
|
}
|
|
414
439
|
|
|
415
440
|
/**
|
|
416
|
-
* @param {string} nostr_hex_sk
|
|
417
|
-
* @param {string} request
|
|
418
|
-
* @returns {Promise<any>}
|
|
419
|
-
*/
|
|
420
|
-
export function
|
|
441
|
+
* @param {string} nostr_hex_sk
|
|
442
|
+
* @param {string} request
|
|
443
|
+
* @returns {Promise<any>}
|
|
444
|
+
*/
|
|
445
|
+
export function watcher_unspent_utxos(nostr_hex_sk, request) {
|
|
421
446
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
422
447
|
const len0 = WASM_VECTOR_LEN;
|
|
423
448
|
const ptr1 = passStringToWasm0(request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
424
449
|
const len1 = WASM_VECTOR_LEN;
|
|
425
|
-
const ret = wasm.
|
|
426
|
-
return
|
|
450
|
+
const ret = wasm.watcher_unspent_utxos(ptr0, len0, ptr1, len1);
|
|
451
|
+
return ret;
|
|
427
452
|
}
|
|
428
453
|
|
|
429
454
|
/**
|
|
430
|
-
* @
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
455
|
+
* @returns {string}
|
|
456
|
+
*/
|
|
457
|
+
export function get_rgb_version() {
|
|
458
|
+
let deferred1_0;
|
|
459
|
+
let deferred1_1;
|
|
460
|
+
try {
|
|
461
|
+
const ret = wasm.get_rgb_version();
|
|
462
|
+
deferred1_0 = ret[0];
|
|
463
|
+
deferred1_1 = ret[1];
|
|
464
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
465
|
+
} finally {
|
|
466
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
467
|
+
}
|
|
438
468
|
}
|
|
439
469
|
|
|
440
470
|
/**
|
|
441
|
-
* @param {string} nostr_hex_sk
|
|
442
|
-
* @returns {Promise<any>}
|
|
443
|
-
*/
|
|
444
|
-
export function
|
|
471
|
+
* @param {string} nostr_hex_sk
|
|
472
|
+
* @returns {Promise<any>}
|
|
473
|
+
*/
|
|
474
|
+
export function get_rgb_wallet(nostr_hex_sk) {
|
|
445
475
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
446
476
|
const len0 = WASM_VECTOR_LEN;
|
|
447
|
-
const ret = wasm.
|
|
448
|
-
return
|
|
477
|
+
const ret = wasm.get_rgb_wallet(ptr0, len0);
|
|
478
|
+
return ret;
|
|
449
479
|
}
|
|
450
480
|
|
|
451
481
|
/**
|
|
452
|
-
* @param {string} nostr_hex_sk
|
|
453
|
-
* @param {
|
|
454
|
-
* @returns {Promise<any>}
|
|
455
|
-
*/
|
|
456
|
-
export function
|
|
482
|
+
* @param {string} nostr_hex_sk
|
|
483
|
+
* @param {string} request
|
|
484
|
+
* @returns {Promise<any>}
|
|
485
|
+
*/
|
|
486
|
+
export function get_contract(nostr_hex_sk, request) {
|
|
457
487
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
458
488
|
const len0 = WASM_VECTOR_LEN;
|
|
459
|
-
const
|
|
460
|
-
|
|
489
|
+
const ptr1 = passStringToWasm0(request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
490
|
+
const len1 = WASM_VECTOR_LEN;
|
|
491
|
+
const ret = wasm.get_contract(ptr0, len0, ptr1, len1);
|
|
492
|
+
return ret;
|
|
461
493
|
}
|
|
462
494
|
|
|
463
495
|
/**
|
|
464
|
-
* @param {string} nostr_hex_sk
|
|
465
|
-
* @
|
|
466
|
-
|
|
467
|
-
|
|
496
|
+
* @param {string} nostr_hex_sk
|
|
497
|
+
* @param {boolean} arg1
|
|
498
|
+
* @returns {Promise<any>}
|
|
499
|
+
*/
|
|
500
|
+
export function list_contracts(nostr_hex_sk, arg1) {
|
|
468
501
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
469
502
|
const len0 = WASM_VECTOR_LEN;
|
|
470
|
-
const ret = wasm.
|
|
471
|
-
return
|
|
503
|
+
const ret = wasm.list_contracts(ptr0, len0, arg1);
|
|
504
|
+
return ret;
|
|
472
505
|
}
|
|
473
506
|
|
|
474
507
|
/**
|
|
475
|
-
* @param {string} nostr_hex_sk
|
|
476
|
-
* @
|
|
477
|
-
|
|
478
|
-
|
|
508
|
+
* @param {string} nostr_hex_sk
|
|
509
|
+
* @param {string} request
|
|
510
|
+
* @returns {Promise<any>}
|
|
511
|
+
*/
|
|
512
|
+
export function import_contract(nostr_hex_sk, request) {
|
|
479
513
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
480
514
|
const len0 = WASM_VECTOR_LEN;
|
|
481
|
-
const
|
|
482
|
-
|
|
515
|
+
const ptr1 = passStringToWasm0(request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
516
|
+
const len1 = WASM_VECTOR_LEN;
|
|
517
|
+
const ret = wasm.import_contract(ptr0, len0, ptr1, len1);
|
|
518
|
+
return ret;
|
|
483
519
|
}
|
|
484
520
|
|
|
485
521
|
/**
|
|
486
|
-
* @param {string} nostr_hex_sk
|
|
487
|
-
* @
|
|
488
|
-
|
|
489
|
-
|
|
522
|
+
* @param {string} nostr_hex_sk
|
|
523
|
+
* @param {any} request
|
|
524
|
+
* @returns {Promise<any>}
|
|
525
|
+
*/
|
|
526
|
+
export function issue_contract(nostr_hex_sk, request) {
|
|
490
527
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
491
528
|
const len0 = WASM_VECTOR_LEN;
|
|
492
|
-
const ret = wasm.
|
|
493
|
-
return
|
|
529
|
+
const ret = wasm.issue_contract(ptr0, len0, request);
|
|
530
|
+
return ret;
|
|
494
531
|
}
|
|
495
532
|
|
|
496
533
|
/**
|
|
497
|
-
* @param {string} nostr_hex_sk
|
|
498
|
-
* @param {any} request
|
|
499
|
-
* @returns {Promise<any>}
|
|
500
|
-
*/
|
|
501
|
-
export function
|
|
534
|
+
* @param {string} nostr_hex_sk
|
|
535
|
+
* @param {any} request
|
|
536
|
+
* @returns {Promise<any>}
|
|
537
|
+
*/
|
|
538
|
+
export function issue_contract_proxy(nostr_hex_sk, request) {
|
|
502
539
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
503
540
|
const len0 = WASM_VECTOR_LEN;
|
|
504
|
-
const ret = wasm.
|
|
505
|
-
return
|
|
541
|
+
const ret = wasm.issue_contract_proxy(ptr0, len0, request);
|
|
542
|
+
return ret;
|
|
506
543
|
}
|
|
507
544
|
|
|
508
545
|
/**
|
|
509
|
-
* @param {string} nostr_hex_sk
|
|
510
|
-
* @param {any} request
|
|
511
|
-
* @
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
export function create_hotswap_bid(nostr_hex_sk, request, secrets) {
|
|
546
|
+
* @param {string} nostr_hex_sk
|
|
547
|
+
* @param {any} request
|
|
548
|
+
* @returns {Promise<any>}
|
|
549
|
+
*/
|
|
550
|
+
export function create_rgb_invoice(nostr_hex_sk, request) {
|
|
515
551
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
516
552
|
const len0 = WASM_VECTOR_LEN;
|
|
517
|
-
const ret = wasm.
|
|
518
|
-
return
|
|
553
|
+
const ret = wasm.create_rgb_invoice(ptr0, len0, request);
|
|
554
|
+
return ret;
|
|
519
555
|
}
|
|
520
556
|
|
|
521
557
|
/**
|
|
522
|
-
* @param {string} nostr_hex_sk
|
|
523
|
-
* @param {
|
|
524
|
-
* @
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
export function can_create_p2p_offer(nostr_hex_sk, request, secrets) {
|
|
558
|
+
* @param {string} nostr_hex_sk
|
|
559
|
+
* @param {string} request
|
|
560
|
+
* @returns {Promise<any>}
|
|
561
|
+
*/
|
|
562
|
+
export function remove_rgb_invoice(nostr_hex_sk, request) {
|
|
528
563
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
529
564
|
const len0 = WASM_VECTOR_LEN;
|
|
530
|
-
const
|
|
531
|
-
|
|
565
|
+
const ptr1 = passStringToWasm0(request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
566
|
+
const len1 = WASM_VECTOR_LEN;
|
|
567
|
+
const ret = wasm.remove_rgb_invoice(ptr0, len0, ptr1, len1);
|
|
568
|
+
return ret;
|
|
532
569
|
}
|
|
533
570
|
|
|
534
571
|
/**
|
|
535
|
-
* @param {string} nostr_hex_sk
|
|
536
|
-
* @
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
*/
|
|
540
|
-
export function create_p2p_offer(nostr_hex_sk, request, secrets) {
|
|
572
|
+
* @param {string} nostr_hex_sk
|
|
573
|
+
* @returns {Promise<any>}
|
|
574
|
+
*/
|
|
575
|
+
export function list_rgb_invoices(nostr_hex_sk) {
|
|
541
576
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
542
577
|
const len0 = WASM_VECTOR_LEN;
|
|
543
|
-
const ret = wasm.
|
|
544
|
-
return
|
|
578
|
+
const ret = wasm.list_rgb_invoices(ptr0, len0);
|
|
579
|
+
return ret;
|
|
545
580
|
}
|
|
546
581
|
|
|
547
582
|
/**
|
|
548
|
-
* @param {string}
|
|
549
|
-
* @
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
583
|
+
* @param {string} invoice
|
|
584
|
+
* @returns {Promise<any>}
|
|
585
|
+
*/
|
|
586
|
+
export function decode_rgb_invoice(invoice) {
|
|
587
|
+
const ptr0 = passStringToWasm0(invoice, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
554
588
|
const len0 = WASM_VECTOR_LEN;
|
|
555
|
-
const ret = wasm.
|
|
556
|
-
return
|
|
589
|
+
const ret = wasm.decode_rgb_invoice(ptr0, len0);
|
|
590
|
+
return ret;
|
|
557
591
|
}
|
|
558
592
|
|
|
559
593
|
/**
|
|
560
|
-
* @param {string} nostr_hex_sk
|
|
561
|
-
* @param {any} request
|
|
562
|
-
* @
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
export function can_create_p2p_bid(nostr_hex_sk, request, secrets) {
|
|
594
|
+
* @param {string} nostr_hex_sk
|
|
595
|
+
* @param {any} request
|
|
596
|
+
* @returns {Promise<any>}
|
|
597
|
+
*/
|
|
598
|
+
export function can_create_transfer_contract(nostr_hex_sk, request) {
|
|
566
599
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
567
600
|
const len0 = WASM_VECTOR_LEN;
|
|
568
|
-
const ret = wasm.
|
|
569
|
-
return
|
|
601
|
+
const ret = wasm.can_create_transfer_contract(ptr0, len0, request);
|
|
602
|
+
return ret;
|
|
570
603
|
}
|
|
571
604
|
|
|
572
605
|
/**
|
|
573
|
-
* @param {string} nostr_hex_sk
|
|
574
|
-
* @param {any} request
|
|
575
|
-
* @
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
export function create_p2p_bid(nostr_hex_sk, request, secrets) {
|
|
606
|
+
* @param {string} nostr_hex_sk
|
|
607
|
+
* @param {any} request
|
|
608
|
+
* @returns {Promise<any>}
|
|
609
|
+
*/
|
|
610
|
+
export function create_rgb_transfer(nostr_hex_sk, request) {
|
|
579
611
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
580
612
|
const len0 = WASM_VECTOR_LEN;
|
|
581
|
-
const ret = wasm.
|
|
582
|
-
return
|
|
613
|
+
const ret = wasm.create_rgb_transfer(ptr0, len0, request);
|
|
614
|
+
return ret;
|
|
583
615
|
}
|
|
584
616
|
|
|
585
617
|
/**
|
|
586
|
-
* @param {string} nostr_hex_sk
|
|
587
|
-
* @param {any} request
|
|
588
|
-
* @
|
|
589
|
-
|
|
590
|
-
|
|
618
|
+
* @param {string} nostr_hex_sk
|
|
619
|
+
* @param {any} request
|
|
620
|
+
* @param {any} secrets
|
|
621
|
+
* @returns {Promise<any>}
|
|
622
|
+
*/
|
|
623
|
+
export function create_and_publish_rgb_transfer(nostr_hex_sk, request, secrets) {
|
|
591
624
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
592
625
|
const len0 = WASM_VECTOR_LEN;
|
|
593
|
-
const ret = wasm.
|
|
594
|
-
return
|
|
626
|
+
const ret = wasm.create_and_publish_rgb_transfer(ptr0, len0, request, secrets);
|
|
627
|
+
return ret;
|
|
595
628
|
}
|
|
596
629
|
|
|
597
630
|
/**
|
|
598
|
-
* @param {string}
|
|
599
|
-
* @param {any} request
|
|
600
|
-
* @
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
631
|
+
* @param {string} _nostr_hex_sk
|
|
632
|
+
* @param {any} request
|
|
633
|
+
* @returns {Promise<any>}
|
|
634
|
+
*/
|
|
635
|
+
export function psbt_sign_file(_nostr_hex_sk, request) {
|
|
636
|
+
const ptr0 = passStringToWasm0(_nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
605
637
|
const len0 = WASM_VECTOR_LEN;
|
|
606
|
-
const ret = wasm.
|
|
607
|
-
return
|
|
638
|
+
const ret = wasm.psbt_sign_file(ptr0, len0, request);
|
|
639
|
+
return ret;
|
|
608
640
|
}
|
|
609
641
|
|
|
610
642
|
/**
|
|
611
|
-
* @param {string} nostr_hex_sk
|
|
612
|
-
* @param {any} request
|
|
613
|
-
* @
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
export function create_auction_bid(nostr_hex_sk, request, secrets) {
|
|
643
|
+
* @param {string} nostr_hex_sk
|
|
644
|
+
* @param {any} request
|
|
645
|
+
* @returns {Promise<any>}
|
|
646
|
+
*/
|
|
647
|
+
export function accept_transfer(nostr_hex_sk, request) {
|
|
617
648
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
618
649
|
const len0 = WASM_VECTOR_LEN;
|
|
619
|
-
const ret = wasm.
|
|
620
|
-
return
|
|
650
|
+
const ret = wasm.accept_transfer(ptr0, len0, request);
|
|
651
|
+
return ret;
|
|
621
652
|
}
|
|
622
653
|
|
|
623
654
|
/**
|
|
624
|
-
* @param {string} nostr_hex_sk
|
|
625
|
-
* @param {any} request
|
|
626
|
-
* @returns {Promise<any>}
|
|
627
|
-
*/
|
|
628
|
-
export function
|
|
655
|
+
* @param {string} nostr_hex_sk
|
|
656
|
+
* @param {any} request
|
|
657
|
+
* @returns {Promise<any>}
|
|
658
|
+
*/
|
|
659
|
+
export function save_transfer(nostr_hex_sk, request) {
|
|
629
660
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
630
661
|
const len0 = WASM_VECTOR_LEN;
|
|
631
|
-
const ret = wasm.
|
|
632
|
-
return
|
|
662
|
+
const ret = wasm.save_transfer(ptr0, len0, request);
|
|
663
|
+
return ret;
|
|
633
664
|
}
|
|
634
665
|
|
|
635
666
|
/**
|
|
636
|
-
* @param {string} nostr_hex_sk
|
|
637
|
-
* @
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
* @param {string} max_claim
|
|
641
|
-
* @returns {Promise<any>}
|
|
642
|
-
*/
|
|
643
|
-
export function create_airdrop_offer(nostr_hex_sk, request, secrets, fee, max_claim) {
|
|
667
|
+
* @param {string} nostr_hex_sk
|
|
668
|
+
* @returns {Promise<any>}
|
|
669
|
+
*/
|
|
670
|
+
export function list_transfers(nostr_hex_sk) {
|
|
644
671
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
645
672
|
const len0 = WASM_VECTOR_LEN;
|
|
646
|
-
const
|
|
647
|
-
|
|
648
|
-
const ret = wasm.create_airdrop_offer(ptr0, len0, addHeapObject(request), addHeapObject(secrets), fee, ptr1, len1);
|
|
649
|
-
return takeObject(ret);
|
|
673
|
+
const ret = wasm.list_transfers(ptr0, len0);
|
|
674
|
+
return ret;
|
|
650
675
|
}
|
|
651
676
|
|
|
652
677
|
/**
|
|
653
|
-
* @param {string} nostr_hex_sk
|
|
654
|
-
* @
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
export function create_airdrop_bid(nostr_hex_sk, request) {
|
|
678
|
+
* @param {string} nostr_hex_sk
|
|
679
|
+
* @returns {Promise<any>}
|
|
680
|
+
*/
|
|
681
|
+
export function verify_transfers(nostr_hex_sk) {
|
|
658
682
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
659
683
|
const len0 = WASM_VECTOR_LEN;
|
|
660
|
-
const ret = wasm.
|
|
661
|
-
return
|
|
684
|
+
const ret = wasm.verify_transfers(ptr0, len0);
|
|
685
|
+
return ret;
|
|
662
686
|
}
|
|
663
687
|
|
|
664
688
|
/**
|
|
665
|
-
* @param {string} nostr_hex_sk
|
|
666
|
-
* @
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
export function close_airdrop_offer(nostr_hex_sk, request) {
|
|
689
|
+
* @param {string} nostr_hex_sk
|
|
690
|
+
* @returns {Promise<any>}
|
|
691
|
+
*/
|
|
692
|
+
export function list_offers(nostr_hex_sk) {
|
|
670
693
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
671
694
|
const len0 = WASM_VECTOR_LEN;
|
|
672
|
-
const ret = wasm.
|
|
673
|
-
return
|
|
695
|
+
const ret = wasm.list_offers(ptr0, len0);
|
|
696
|
+
return ret;
|
|
674
697
|
}
|
|
675
698
|
|
|
676
699
|
/**
|
|
677
|
-
* @param {string} nostr_hex_sk
|
|
678
|
-
* @
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
export function create_watcher(nostr_hex_sk, request) {
|
|
700
|
+
* @param {string} nostr_hex_sk
|
|
701
|
+
* @returns {Promise<any>}
|
|
702
|
+
*/
|
|
703
|
+
export function offers(nostr_hex_sk) {
|
|
682
704
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
683
705
|
const len0 = WASM_VECTOR_LEN;
|
|
684
|
-
const ret = wasm.
|
|
685
|
-
return
|
|
706
|
+
const ret = wasm.offers(ptr0, len0);
|
|
707
|
+
return ret;
|
|
686
708
|
}
|
|
687
709
|
|
|
688
710
|
/**
|
|
689
|
-
* @param {string} nostr_hex_sk
|
|
690
|
-
* @returns {Promise<any>}
|
|
691
|
-
*/
|
|
692
|
-
export function
|
|
711
|
+
* @param {string} nostr_hex_sk
|
|
712
|
+
* @returns {Promise<any>}
|
|
713
|
+
*/
|
|
714
|
+
export function bids(nostr_hex_sk) {
|
|
693
715
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
694
716
|
const len0 = WASM_VECTOR_LEN;
|
|
695
|
-
const ret = wasm.
|
|
696
|
-
return
|
|
717
|
+
const ret = wasm.bids(ptr0, len0);
|
|
718
|
+
return ret;
|
|
697
719
|
}
|
|
698
720
|
|
|
699
721
|
/**
|
|
700
|
-
* @param {string} nostr_hex_sk
|
|
701
|
-
* @
|
|
702
|
-
|
|
703
|
-
|
|
722
|
+
* @param {string} nostr_hex_sk
|
|
723
|
+
* @param {string} offer_id
|
|
724
|
+
* @returns {Promise<any>}
|
|
725
|
+
*/
|
|
726
|
+
export function offer_swap_suppl(nostr_hex_sk, offer_id) {
|
|
704
727
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
705
728
|
const len0 = WASM_VECTOR_LEN;
|
|
706
|
-
const
|
|
707
|
-
|
|
729
|
+
const ptr1 = passStringToWasm0(offer_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
730
|
+
const len1 = WASM_VECTOR_LEN;
|
|
731
|
+
const ret = wasm.offer_swap_suppl(ptr0, len0, ptr1, len1);
|
|
732
|
+
return ret;
|
|
708
733
|
}
|
|
709
734
|
|
|
710
735
|
/**
|
|
711
|
-
* @param {string} nostr_hex_sk
|
|
712
|
-
* @param {string}
|
|
713
|
-
* @returns {Promise<any>}
|
|
714
|
-
*/
|
|
715
|
-
export function
|
|
736
|
+
* @param {string} nostr_hex_sk
|
|
737
|
+
* @param {string} bid_id
|
|
738
|
+
* @returns {Promise<any>}
|
|
739
|
+
*/
|
|
740
|
+
export function bid_swap_suppl(nostr_hex_sk, bid_id) {
|
|
716
741
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
717
742
|
const len0 = WASM_VECTOR_LEN;
|
|
718
|
-
const ptr1 = passStringToWasm0(
|
|
743
|
+
const ptr1 = passStringToWasm0(bid_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
719
744
|
const len1 = WASM_VECTOR_LEN;
|
|
720
|
-
const ret = wasm.
|
|
721
|
-
return
|
|
745
|
+
const ret = wasm.bid_swap_suppl(ptr0, len0, ptr1, len1);
|
|
746
|
+
return ret;
|
|
722
747
|
}
|
|
723
748
|
|
|
724
749
|
/**
|
|
725
|
-
* @param {string} nostr_hex_sk
|
|
726
|
-
* @param {
|
|
727
|
-
* @
|
|
728
|
-
|
|
729
|
-
|
|
750
|
+
* @param {string} nostr_hex_sk
|
|
751
|
+
* @param {any} request
|
|
752
|
+
* @param {any} secrets
|
|
753
|
+
* @returns {Promise<any>}
|
|
754
|
+
*/
|
|
755
|
+
export function can_create_offer(nostr_hex_sk, request, secrets) {
|
|
730
756
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
731
757
|
const len0 = WASM_VECTOR_LEN;
|
|
732
|
-
const
|
|
733
|
-
|
|
734
|
-
const ret = wasm.watcher_next_utxo(ptr0, len0, ptr1, len1);
|
|
735
|
-
return takeObject(ret);
|
|
758
|
+
const ret = wasm.can_create_offer(ptr0, len0, request, secrets);
|
|
759
|
+
return ret;
|
|
736
760
|
}
|
|
737
761
|
|
|
738
762
|
/**
|
|
739
|
-
* @param {string} nostr_hex_sk
|
|
740
|
-
* @param {
|
|
741
|
-
* @
|
|
742
|
-
|
|
743
|
-
|
|
763
|
+
* @param {string} nostr_hex_sk
|
|
764
|
+
* @param {any} request
|
|
765
|
+
* @param {any} secrets
|
|
766
|
+
* @returns {Promise<any>}
|
|
767
|
+
*/
|
|
768
|
+
export function create_offer(nostr_hex_sk, request, secrets) {
|
|
744
769
|
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
745
770
|
const len0 = WASM_VECTOR_LEN;
|
|
746
|
-
const
|
|
747
|
-
|
|
748
|
-
const ret = wasm.watcher_unspent_utxos(ptr0, len0, ptr1, len1);
|
|
749
|
-
return takeObject(ret);
|
|
771
|
+
const ret = wasm.create_offer(ptr0, len0, request, secrets);
|
|
772
|
+
return ret;
|
|
750
773
|
}
|
|
751
774
|
|
|
752
775
|
/**
|
|
753
|
-
* @param {string}
|
|
754
|
-
* @param {any} request
|
|
755
|
-
* @returns {Promise<any>}
|
|
756
|
-
*/
|
|
757
|
-
export function
|
|
758
|
-
const ptr0 = passStringToWasm0(
|
|
776
|
+
* @param {string} nostr_hex_sk
|
|
777
|
+
* @param {any} request
|
|
778
|
+
* @returns {Promise<any>}
|
|
779
|
+
*/
|
|
780
|
+
export function cancel_offer(nostr_hex_sk, request) {
|
|
781
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
759
782
|
const len0 = WASM_VECTOR_LEN;
|
|
760
|
-
const ret = wasm.
|
|
761
|
-
return
|
|
783
|
+
const ret = wasm.cancel_offer(ptr0, len0, request);
|
|
784
|
+
return ret;
|
|
762
785
|
}
|
|
763
786
|
|
|
764
787
|
/**
|
|
765
|
-
* @param {string}
|
|
766
|
-
* @
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
788
|
+
* @param {string} nostr_hex_sk
|
|
789
|
+
* @param {any} request
|
|
790
|
+
* @param {any} secrets
|
|
791
|
+
* @returns {Promise<any>}
|
|
792
|
+
*/
|
|
793
|
+
export function can_create_bid(nostr_hex_sk, request, secrets) {
|
|
794
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
770
795
|
const len0 = WASM_VECTOR_LEN;
|
|
771
|
-
const ret = wasm.
|
|
772
|
-
return
|
|
773
|
-
}
|
|
774
|
-
|
|
775
|
-
/**
|
|
776
|
-
* @returns {string}
|
|
777
|
-
*/
|
|
778
|
-
export function get_rgb_version() {
|
|
779
|
-
let deferred1_0;
|
|
780
|
-
let deferred1_1;
|
|
781
|
-
try {
|
|
782
|
-
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
783
|
-
wasm.get_rgb_version(retptr);
|
|
784
|
-
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
|
785
|
-
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
|
786
|
-
deferred1_0 = r0;
|
|
787
|
-
deferred1_1 = r1;
|
|
788
|
-
return getStringFromWasm0(r0, r1);
|
|
789
|
-
} finally {
|
|
790
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
791
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
792
|
-
}
|
|
796
|
+
const ret = wasm.can_create_bid(ptr0, len0, request, secrets);
|
|
797
|
+
return ret;
|
|
793
798
|
}
|
|
794
799
|
|
|
795
800
|
/**
|
|
796
|
-
* @param {string}
|
|
797
|
-
* @
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
wasm.hash_password(retptr, ptr0, len0);
|
|
807
|
-
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
|
808
|
-
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
|
809
|
-
deferred2_0 = r0;
|
|
810
|
-
deferred2_1 = r1;
|
|
811
|
-
return getStringFromWasm0(r0, r1);
|
|
812
|
-
} finally {
|
|
813
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
814
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
815
|
-
}
|
|
801
|
+
* @param {string} nostr_hex_sk
|
|
802
|
+
* @param {any} request
|
|
803
|
+
* @param {any} secrets
|
|
804
|
+
* @returns {Promise<any>}
|
|
805
|
+
*/
|
|
806
|
+
export function create_bid(nostr_hex_sk, request, secrets) {
|
|
807
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
808
|
+
const len0 = WASM_VECTOR_LEN;
|
|
809
|
+
const ret = wasm.create_bid(ptr0, len0, request, secrets);
|
|
810
|
+
return ret;
|
|
816
811
|
}
|
|
817
812
|
|
|
818
813
|
/**
|
|
819
|
-
* @param {string}
|
|
820
|
-
* @
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
814
|
+
* @param {string} nostr_hex_sk
|
|
815
|
+
* @param {any} request
|
|
816
|
+
* @returns {Promise<any>}
|
|
817
|
+
*/
|
|
818
|
+
export function cancel_bid(nostr_hex_sk, request) {
|
|
819
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
824
820
|
const len0 = WASM_VECTOR_LEN;
|
|
825
|
-
const ret = wasm.
|
|
826
|
-
return
|
|
821
|
+
const ret = wasm.cancel_bid(ptr0, len0, request);
|
|
822
|
+
return ret;
|
|
827
823
|
}
|
|
828
824
|
|
|
829
825
|
/**
|
|
830
|
-
* @param {string}
|
|
831
|
-
* @param {
|
|
832
|
-
* @
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
826
|
+
* @param {string} nostr_hex_sk
|
|
827
|
+
* @param {any} request
|
|
828
|
+
* @param {any} secrets
|
|
829
|
+
* @param {bigint} fee
|
|
830
|
+
* @param {string} max_claim
|
|
831
|
+
* @returns {Promise<any>}
|
|
832
|
+
*/
|
|
833
|
+
export function create_airdrop(nostr_hex_sk, request, secrets, fee, max_claim) {
|
|
834
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
836
835
|
const len0 = WASM_VECTOR_LEN;
|
|
837
|
-
const ptr1 = passStringToWasm0(
|
|
836
|
+
const ptr1 = passStringToWasm0(max_claim, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
838
837
|
const len1 = WASM_VECTOR_LEN;
|
|
839
|
-
const ret = wasm.
|
|
840
|
-
return
|
|
838
|
+
const ret = wasm.create_airdrop(ptr0, len0, request, secrets, fee, ptr1, len1);
|
|
839
|
+
return ret;
|
|
841
840
|
}
|
|
842
841
|
|
|
843
842
|
/**
|
|
844
|
-
* @param {string}
|
|
845
|
-
* @param {
|
|
846
|
-
* @
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
const ptr0 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
843
|
+
* @param {string} nostr_hex_sk
|
|
844
|
+
* @param {any} request
|
|
845
|
+
* @returns {Promise<any>}
|
|
846
|
+
*/
|
|
847
|
+
export function create_airdrop_claim(nostr_hex_sk, request) {
|
|
848
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
851
849
|
const len0 = WASM_VECTOR_LEN;
|
|
852
|
-
const
|
|
853
|
-
|
|
854
|
-
const ptr2 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
855
|
-
const len2 = WASM_VECTOR_LEN;
|
|
856
|
-
const ret = wasm.decrypt_wallet(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
857
|
-
return takeObject(ret);
|
|
850
|
+
const ret = wasm.create_airdrop_claim(ptr0, len0, request);
|
|
851
|
+
return ret;
|
|
858
852
|
}
|
|
859
853
|
|
|
860
854
|
/**
|
|
861
|
-
* @param {string}
|
|
862
|
-
* @param {
|
|
863
|
-
* @
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
const ptr0 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
855
|
+
* @param {string} nostr_hex_sk
|
|
856
|
+
* @param {any} request
|
|
857
|
+
* @returns {Promise<any>}
|
|
858
|
+
*/
|
|
859
|
+
export function close_airdrop(nostr_hex_sk, request) {
|
|
860
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
868
861
|
const len0 = WASM_VECTOR_LEN;
|
|
869
|
-
const
|
|
870
|
-
|
|
871
|
-
const ptr2 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
872
|
-
const len2 = WASM_VECTOR_LEN;
|
|
873
|
-
const ret = wasm.upgrade_wallet(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
874
|
-
return takeObject(ret);
|
|
862
|
+
const ret = wasm.close_airdrop(ptr0, len0, request);
|
|
863
|
+
return ret;
|
|
875
864
|
}
|
|
876
865
|
|
|
877
866
|
/**
|
|
878
|
-
* @param {string}
|
|
879
|
-
* @
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
const ptr0 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
867
|
+
* @param {string} nostr_hex_sk
|
|
868
|
+
* @returns {Promise<any>}
|
|
869
|
+
*/
|
|
870
|
+
export function backup_rgb_data(nostr_hex_sk) {
|
|
871
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
884
872
|
const len0 = WASM_VECTOR_LEN;
|
|
885
|
-
const
|
|
886
|
-
|
|
887
|
-
const ret = wasm.new_wallet(ptr0, len0, ptr1, len1);
|
|
888
|
-
return takeObject(ret);
|
|
873
|
+
const ret = wasm.backup_rgb_data(ptr0, len0);
|
|
874
|
+
return ret;
|
|
889
875
|
}
|
|
890
876
|
|
|
891
877
|
/**
|
|
892
|
-
* @param {string}
|
|
893
|
-
* @
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
export function encrypt_wallet(mnemonic, hash, seed_password) {
|
|
898
|
-
const ptr0 = passStringToWasm0(mnemonic, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
878
|
+
* @param {string} nostr_hex_sk
|
|
879
|
+
* @returns {Promise<any>}
|
|
880
|
+
*/
|
|
881
|
+
export function restore_rgb_data(nostr_hex_sk) {
|
|
882
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
899
883
|
const len0 = WASM_VECTOR_LEN;
|
|
900
|
-
const
|
|
901
|
-
|
|
902
|
-
const ptr2 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
903
|
-
const len2 = WASM_VECTOR_LEN;
|
|
904
|
-
const ret = wasm.encrypt_wallet(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
905
|
-
return takeObject(ret);
|
|
884
|
+
const ret = wasm.restore_rgb_data(ptr0, len0);
|
|
885
|
+
return ret;
|
|
906
886
|
}
|
|
907
887
|
|
|
908
888
|
/**
|
|
909
|
-
* @
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
915
|
-
const len0 = WASM_VECTOR_LEN;
|
|
916
|
-
var ptr1 = isLikeNone(change_descriptor) ? 0 : passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
917
|
-
var len1 = WASM_VECTOR_LEN;
|
|
918
|
-
const ret = wasm.get_wallet_data(ptr0, len0, ptr1, len1);
|
|
919
|
-
return takeObject(ret);
|
|
889
|
+
* @returns {Promise<any>}
|
|
890
|
+
*/
|
|
891
|
+
export function get_network() {
|
|
892
|
+
const ret = wasm.get_network();
|
|
893
|
+
return ret;
|
|
920
894
|
}
|
|
921
895
|
|
|
922
896
|
/**
|
|
923
|
-
* @
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
897
|
+
* @param {string} network_str
|
|
898
|
+
* @returns {Promise<any>}
|
|
899
|
+
*/
|
|
900
|
+
export function switch_network(network_str) {
|
|
901
|
+
const ptr0 = passStringToWasm0(network_str, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
902
|
+
const len0 = WASM_VECTOR_LEN;
|
|
903
|
+
const ret = wasm.switch_network(ptr0, len0);
|
|
904
|
+
return ret;
|
|
928
905
|
}
|
|
929
906
|
|
|
930
907
|
/**
|
|
931
|
-
* @param {string}
|
|
932
|
-
* @
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
908
|
+
* @param {string} key
|
|
909
|
+
* @returns {Promise<any>}
|
|
910
|
+
*/
|
|
911
|
+
export function get_env(key) {
|
|
912
|
+
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
937
913
|
const len0 = WASM_VECTOR_LEN;
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
const ret = wasm.get_new_address(ptr0, len0, ptr1, len1);
|
|
941
|
-
return takeObject(ret);
|
|
914
|
+
const ret = wasm.get_env(ptr0, len0);
|
|
915
|
+
return ret;
|
|
942
916
|
}
|
|
943
917
|
|
|
944
918
|
/**
|
|
945
|
-
* @param {string}
|
|
946
|
-
* @param {string}
|
|
947
|
-
* @
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
* @returns {Promise<any>}
|
|
952
|
-
*/
|
|
953
|
-
export function send_sats(descriptor, change_descriptor, destination, amount, broadcast, fee_rate) {
|
|
954
|
-
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
919
|
+
* @param {string} key
|
|
920
|
+
* @param {string} value
|
|
921
|
+
* @returns {Promise<any>}
|
|
922
|
+
*/
|
|
923
|
+
export function set_env(key, value) {
|
|
924
|
+
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
955
925
|
const len0 = WASM_VECTOR_LEN;
|
|
956
|
-
const ptr1 = passStringToWasm0(
|
|
926
|
+
const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
957
927
|
const len1 = WASM_VECTOR_LEN;
|
|
958
|
-
const
|
|
959
|
-
|
|
960
|
-
const ret = wasm.send_sats(ptr0, len0, ptr1, len1, ptr2, len2, amount, broadcast, !isLikeNone(fee_rate), isLikeNone(fee_rate) ? 0 : fee_rate);
|
|
961
|
-
return takeObject(ret);
|
|
928
|
+
const ret = wasm.set_env(ptr0, len0, ptr1, len1);
|
|
929
|
+
return ret;
|
|
962
930
|
}
|
|
963
931
|
|
|
964
932
|
/**
|
|
965
|
-
* @param {
|
|
966
|
-
* @
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
*/
|
|
972
|
-
export function fund_vault(descriptor, change_descriptor, rgb_address, broadcast, fee_rate) {
|
|
973
|
-
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
974
|
-
const len0 = WASM_VECTOR_LEN;
|
|
975
|
-
const ptr1 = passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
976
|
-
const len1 = WASM_VECTOR_LEN;
|
|
977
|
-
const ptr2 = passStringToWasm0(rgb_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
978
|
-
const len2 = WASM_VECTOR_LEN;
|
|
979
|
-
const ret = wasm.fund_vault(ptr0, len0, ptr1, len1, ptr2, len2, broadcast, !isLikeNone(fee_rate), isLikeNone(fee_rate) ? 0 : fee_rate);
|
|
980
|
-
return takeObject(ret);
|
|
933
|
+
* @param {number} ms
|
|
934
|
+
* @returns {Promise<any>}
|
|
935
|
+
*/
|
|
936
|
+
export function sleep(ms) {
|
|
937
|
+
const ret = wasm.sleep(ms);
|
|
938
|
+
return ret;
|
|
981
939
|
}
|
|
982
940
|
|
|
983
941
|
/**
|
|
984
|
-
* @param {string}
|
|
985
|
-
* @
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
942
|
+
* @param {string} decimal
|
|
943
|
+
* @param {number} precision
|
|
944
|
+
* @returns {string}
|
|
945
|
+
*/
|
|
946
|
+
export function convert_contract_amount_raw(decimal, precision) {
|
|
947
|
+
let deferred2_0;
|
|
948
|
+
let deferred2_1;
|
|
949
|
+
try {
|
|
950
|
+
const ptr0 = passStringToWasm0(decimal, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
951
|
+
const len0 = WASM_VECTOR_LEN;
|
|
952
|
+
const ret = wasm.convert_contract_amount_raw(ptr0, len0, precision);
|
|
953
|
+
deferred2_0 = ret[0];
|
|
954
|
+
deferred2_1 = ret[1];
|
|
955
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
956
|
+
} finally {
|
|
957
|
+
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
958
|
+
}
|
|
992
959
|
}
|
|
993
960
|
|
|
994
961
|
/**
|
|
995
|
-
* @param {
|
|
996
|
-
* @param {
|
|
997
|
-
* @
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
962
|
+
* @param {bigint} amount
|
|
963
|
+
* @param {number} precision
|
|
964
|
+
* @returns {string}
|
|
965
|
+
*/
|
|
966
|
+
export function convert_contract_amount_string(amount, precision) {
|
|
967
|
+
let deferred1_0;
|
|
968
|
+
let deferred1_1;
|
|
969
|
+
try {
|
|
970
|
+
const ret = wasm.convert_contract_amount_string(amount, precision);
|
|
971
|
+
deferred1_0 = ret[0];
|
|
972
|
+
deferred1_1 = ret[1];
|
|
973
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
974
|
+
} finally {
|
|
975
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
976
|
+
}
|
|
1010
977
|
}
|
|
1011
978
|
|
|
1012
979
|
/**
|
|
1013
|
-
* @param {string}
|
|
1014
|
-
* @
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
* @returns {Promise<any>}
|
|
1019
|
-
*/
|
|
1020
|
-
export function bump_fee(txid, fee_rate, descriptor, change_descriptor, broadcast) {
|
|
1021
|
-
const ptr0 = passStringToWasm0(txid, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
980
|
+
* @param {string} amount
|
|
981
|
+
* @returns {any}
|
|
982
|
+
*/
|
|
983
|
+
export function parse_contract_amount(amount) {
|
|
984
|
+
const ptr0 = passStringToWasm0(amount, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1022
985
|
const len0 = WASM_VECTOR_LEN;
|
|
1023
|
-
const
|
|
1024
|
-
|
|
1025
|
-
var ptr2 = isLikeNone(change_descriptor) ? 0 : passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1026
|
-
var len2 = WASM_VECTOR_LEN;
|
|
1027
|
-
const ret = wasm.bump_fee(ptr0, len0, fee_rate, ptr1, len1, ptr2, len2, broadcast);
|
|
1028
|
-
return takeObject(ret);
|
|
986
|
+
const ret = wasm.parse_contract_amount(ptr0, len0);
|
|
987
|
+
return ret;
|
|
1029
988
|
}
|
|
1030
989
|
|
|
1031
990
|
/**
|
|
1032
|
-
* @param {
|
|
1033
|
-
* @
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
991
|
+
* @param {string} amount
|
|
992
|
+
* @param {number} precision
|
|
993
|
+
* @returns {string}
|
|
994
|
+
*/
|
|
995
|
+
export function parse_contract_amount_precision(amount, precision) {
|
|
996
|
+
let deferred2_0;
|
|
997
|
+
let deferred2_1;
|
|
998
|
+
try {
|
|
999
|
+
const ptr0 = passStringToWasm0(amount, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1000
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1001
|
+
const ret = wasm.parse_contract_amount_precision(ptr0, len0, precision);
|
|
1002
|
+
deferred2_0 = ret[0];
|
|
1003
|
+
deferred2_1 = ret[1];
|
|
1004
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
1005
|
+
} finally {
|
|
1006
|
+
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1007
|
+
}
|
|
1038
1008
|
}
|
|
1039
1009
|
|
|
1040
1010
|
/**
|
|
1041
|
-
* @
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
return takeObject(ret);
|
|
1011
|
+
* @returns {any}
|
|
1012
|
+
*/
|
|
1013
|
+
export function version() {
|
|
1014
|
+
const ret = wasm.version();
|
|
1015
|
+
return ret;
|
|
1047
1016
|
}
|
|
1048
1017
|
|
|
1049
1018
|
/**
|
|
1050
|
-
* @param {string} username
|
|
1051
|
-
* @param {string} password
|
|
1052
|
-
* @returns {Promise<any>}
|
|
1053
|
-
*/
|
|
1019
|
+
* @param {string} username
|
|
1020
|
+
* @param {string} password
|
|
1021
|
+
* @returns {Promise<any>}
|
|
1022
|
+
*/
|
|
1054
1023
|
export function create_wallet(username, password) {
|
|
1055
1024
|
const ptr0 = passStringToWasm0(username, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1056
1025
|
const len0 = WASM_VECTOR_LEN;
|
|
1057
1026
|
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1058
1027
|
const len1 = WASM_VECTOR_LEN;
|
|
1059
1028
|
const ret = wasm.create_wallet(ptr0, len0, ptr1, len1);
|
|
1060
|
-
return
|
|
1029
|
+
return ret;
|
|
1061
1030
|
}
|
|
1062
1031
|
|
|
1063
1032
|
/**
|
|
1064
|
-
* @param {string} username
|
|
1065
|
-
* @param {string} password
|
|
1066
|
-
* @returns {Promise<any>}
|
|
1067
|
-
*/
|
|
1033
|
+
* @param {string} username
|
|
1034
|
+
* @param {string} password
|
|
1035
|
+
* @returns {Promise<any>}
|
|
1036
|
+
*/
|
|
1068
1037
|
export function auth(username, password) {
|
|
1069
1038
|
const ptr0 = passStringToWasm0(username, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1070
1039
|
const len0 = WASM_VECTOR_LEN;
|
|
1071
1040
|
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1072
1041
|
const len1 = WASM_VECTOR_LEN;
|
|
1073
1042
|
const ret = wasm.auth(ptr0, len0, ptr1, len1);
|
|
1074
|
-
return
|
|
1043
|
+
return ret;
|
|
1075
1044
|
}
|
|
1076
1045
|
|
|
1077
1046
|
/**
|
|
1078
|
-
* @param {string} description
|
|
1079
|
-
* @param {number} amount
|
|
1080
|
-
* @param {string} token
|
|
1081
|
-
* @returns {Promise<any>}
|
|
1082
|
-
*/
|
|
1047
|
+
* @param {string} description
|
|
1048
|
+
* @param {number} amount
|
|
1049
|
+
* @param {string} token
|
|
1050
|
+
* @returns {Promise<any>}
|
|
1051
|
+
*/
|
|
1083
1052
|
export function ln_create_invoice(description, amount, token) {
|
|
1084
1053
|
const ptr0 = passStringToWasm0(description, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1085
1054
|
const len0 = WASM_VECTOR_LEN;
|
|
1086
1055
|
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1087
1056
|
const len1 = WASM_VECTOR_LEN;
|
|
1088
1057
|
const ret = wasm.ln_create_invoice(ptr0, len0, amount, ptr1, len1);
|
|
1089
|
-
return
|
|
1058
|
+
return ret;
|
|
1090
1059
|
}
|
|
1091
1060
|
|
|
1092
1061
|
/**
|
|
1093
|
-
* @param {string} token
|
|
1094
|
-
* @returns {Promise<any>}
|
|
1095
|
-
*/
|
|
1062
|
+
* @param {string} token
|
|
1063
|
+
* @returns {Promise<any>}
|
|
1064
|
+
*/
|
|
1096
1065
|
export function get_balance(token) {
|
|
1097
1066
|
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1098
1067
|
const len0 = WASM_VECTOR_LEN;
|
|
1099
1068
|
const ret = wasm.get_balance(ptr0, len0);
|
|
1100
|
-
return
|
|
1069
|
+
return ret;
|
|
1101
1070
|
}
|
|
1102
1071
|
|
|
1103
1072
|
/**
|
|
1104
|
-
* @param {string} token
|
|
1105
|
-
* @returns {Promise<any>}
|
|
1106
|
-
*/
|
|
1073
|
+
* @param {string} token
|
|
1074
|
+
* @returns {Promise<any>}
|
|
1075
|
+
*/
|
|
1107
1076
|
export function get_txs(token) {
|
|
1108
1077
|
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1109
1078
|
const len0 = WASM_VECTOR_LEN;
|
|
1110
1079
|
const ret = wasm.get_txs(ptr0, len0);
|
|
1111
|
-
return
|
|
1080
|
+
return ret;
|
|
1112
1081
|
}
|
|
1113
1082
|
|
|
1114
1083
|
/**
|
|
1115
|
-
* @param {string} payment_request
|
|
1116
|
-
* @param {string} token
|
|
1117
|
-
* @returns {Promise<any>}
|
|
1118
|
-
*/
|
|
1084
|
+
* @param {string} payment_request
|
|
1085
|
+
* @param {string} token
|
|
1086
|
+
* @returns {Promise<any>}
|
|
1087
|
+
*/
|
|
1119
1088
|
export function pay_invoice(payment_request, token) {
|
|
1120
1089
|
const ptr0 = passStringToWasm0(payment_request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1121
1090
|
const len0 = WASM_VECTOR_LEN;
|
|
1122
1091
|
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1123
1092
|
const len1 = WASM_VECTOR_LEN;
|
|
1124
1093
|
const ret = wasm.pay_invoice(ptr0, len0, ptr1, len1);
|
|
1125
|
-
return
|
|
1094
|
+
return ret;
|
|
1126
1095
|
}
|
|
1127
1096
|
|
|
1128
1097
|
/**
|
|
1129
|
-
* @param {string} payment_hash
|
|
1130
|
-
* @returns {Promise<any>}
|
|
1131
|
-
*/
|
|
1098
|
+
* @param {string} payment_hash
|
|
1099
|
+
* @returns {Promise<any>}
|
|
1100
|
+
*/
|
|
1132
1101
|
export function check_payment(payment_hash) {
|
|
1133
1102
|
const ptr0 = passStringToWasm0(payment_hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1134
1103
|
const len0 = WASM_VECTOR_LEN;
|
|
1135
1104
|
const ret = wasm.check_payment(ptr0, len0);
|
|
1136
|
-
return
|
|
1105
|
+
return ret;
|
|
1137
1106
|
}
|
|
1138
1107
|
|
|
1139
1108
|
/**
|
|
1140
|
-
* @param {string} token
|
|
1141
|
-
* @param {string |
|
|
1142
|
-
* @returns {Promise<any>}
|
|
1143
|
-
*/
|
|
1109
|
+
* @param {string} token
|
|
1110
|
+
* @param {string | null} [ln_address]
|
|
1111
|
+
* @returns {Promise<any>}
|
|
1112
|
+
*/
|
|
1144
1113
|
export function swap_btc_ln(token, ln_address) {
|
|
1145
1114
|
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1146
1115
|
const len0 = WASM_VECTOR_LEN;
|
|
1147
1116
|
var ptr1 = isLikeNone(ln_address) ? 0 : passStringToWasm0(ln_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1148
1117
|
var len1 = WASM_VECTOR_LEN;
|
|
1149
1118
|
const ret = wasm.swap_btc_ln(ptr0, len0, ptr1, len1);
|
|
1150
|
-
return
|
|
1119
|
+
return ret;
|
|
1151
1120
|
}
|
|
1152
1121
|
|
|
1153
1122
|
/**
|
|
1154
|
-
* @param {string} address
|
|
1155
|
-
* @param {bigint} amount
|
|
1156
|
-
* @param {string} token
|
|
1157
|
-
* @returns {Promise<any>}
|
|
1158
|
-
*/
|
|
1123
|
+
* @param {string} address
|
|
1124
|
+
* @param {bigint} amount
|
|
1125
|
+
* @param {string} token
|
|
1126
|
+
* @returns {Promise<any>}
|
|
1127
|
+
*/
|
|
1159
1128
|
export function swap_ln_btc(address, amount, token) {
|
|
1160
1129
|
const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1161
1130
|
const len0 = WASM_VECTOR_LEN;
|
|
1162
1131
|
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1163
1132
|
const len1 = WASM_VECTOR_LEN;
|
|
1164
1133
|
const ret = wasm.swap_ln_btc(ptr0, len0, amount, ptr1, len1);
|
|
1165
|
-
return
|
|
1134
|
+
return ret;
|
|
1166
1135
|
}
|
|
1167
1136
|
|
|
1168
|
-
function passArray8ToWasm0(arg, malloc) {
|
|
1169
|
-
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
1170
|
-
getUint8Memory0().set(arg, ptr / 1);
|
|
1171
|
-
WASM_VECTOR_LEN = arg.length;
|
|
1172
|
-
return ptr;
|
|
1173
|
-
}
|
|
1174
1137
|
/**
|
|
1175
|
-
* @param {string}
|
|
1176
|
-
* @param {
|
|
1177
|
-
* @param {
|
|
1178
|
-
* @param {boolean}
|
|
1179
|
-
* @param {
|
|
1180
|
-
* @
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1138
|
+
* @param {string} sk
|
|
1139
|
+
* @param {number} fee_rate
|
|
1140
|
+
* @param {any} secrets
|
|
1141
|
+
* @param {boolean} broadcast
|
|
1142
|
+
* @param {bigint | null | undefined} fund_value
|
|
1143
|
+
* @param {boolean} coordinator_fee
|
|
1144
|
+
* @returns {Promise<any>}
|
|
1145
|
+
*/
|
|
1146
|
+
export function fund_rgb_vault(sk, fee_rate, secrets, broadcast, fund_value, coordinator_fee) {
|
|
1147
|
+
const ptr0 = passStringToWasm0(sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1184
1148
|
const len0 = WASM_VECTOR_LEN;
|
|
1185
|
-
const
|
|
1186
|
-
|
|
1187
|
-
const ptr2 = passArray8ToWasm0(data, wasm.__wbindgen_malloc);
|
|
1188
|
-
const len2 = WASM_VECTOR_LEN;
|
|
1189
|
-
var ptr3 = isLikeNone(metadata) ? 0 : passArray8ToWasm0(metadata, wasm.__wbindgen_malloc);
|
|
1190
|
-
var len3 = WASM_VECTOR_LEN;
|
|
1191
|
-
const ret = wasm.store(ptr0, len0, ptr1, len1, ptr2, len2, force, ptr3, len3);
|
|
1192
|
-
return takeObject(ret);
|
|
1149
|
+
const ret = wasm.fund_rgb_vault(ptr0, len0, fee_rate, secrets, broadcast, !isLikeNone(fund_value), isLikeNone(fund_value) ? BigInt(0) : fund_value, coordinator_fee);
|
|
1150
|
+
return ret;
|
|
1193
1151
|
}
|
|
1194
1152
|
|
|
1195
1153
|
/**
|
|
1196
|
-
* @param {string}
|
|
1197
|
-
* @param {string}
|
|
1198
|
-
* @
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1154
|
+
* @param {string} sk
|
|
1155
|
+
* @param {string} address
|
|
1156
|
+
* @param {bigint} sats
|
|
1157
|
+
* @param {number} fee_rate
|
|
1158
|
+
* @param {any} secrets
|
|
1159
|
+
* @returns {Promise<any>}
|
|
1160
|
+
*/
|
|
1161
|
+
export function transfer_sats(sk, address, sats, fee_rate, secrets) {
|
|
1162
|
+
const ptr0 = passStringToWasm0(sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1202
1163
|
const len0 = WASM_VECTOR_LEN;
|
|
1203
|
-
const ptr1 = passStringToWasm0(
|
|
1164
|
+
const ptr1 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1204
1165
|
const len1 = WASM_VECTOR_LEN;
|
|
1205
|
-
const ret = wasm.
|
|
1206
|
-
return
|
|
1166
|
+
const ret = wasm.transfer_sats(ptr0, len0, ptr1, len1, sats, fee_rate, secrets);
|
|
1167
|
+
return ret;
|
|
1207
1168
|
}
|
|
1208
1169
|
|
|
1209
1170
|
/**
|
|
1210
|
-
* @param {string}
|
|
1211
|
-
* @
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
const ptr0 = passStringToWasm0(secret_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1171
|
+
* @param {string} sk
|
|
1172
|
+
* @returns {Promise<any>}
|
|
1173
|
+
*/
|
|
1174
|
+
export function get_btc_wallet(sk) {
|
|
1175
|
+
const ptr0 = passStringToWasm0(sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1216
1176
|
const len0 = WASM_VECTOR_LEN;
|
|
1217
|
-
const
|
|
1218
|
-
|
|
1219
|
-
const ret = wasm.retrieve_metadata(ptr0, len0, ptr1, len1);
|
|
1220
|
-
return takeObject(ret);
|
|
1177
|
+
const ret = wasm.get_btc_wallet(ptr0, len0);
|
|
1178
|
+
return ret;
|
|
1221
1179
|
}
|
|
1222
1180
|
|
|
1223
1181
|
/**
|
|
1224
|
-
* @param {
|
|
1225
|
-
* @returns {
|
|
1226
|
-
*/
|
|
1227
|
-
export function
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);
|
|
1233
|
-
const len0 = WASM_VECTOR_LEN;
|
|
1234
|
-
wasm.encode_hex(retptr, ptr0, len0);
|
|
1235
|
-
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
|
1236
|
-
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
|
1237
|
-
deferred2_0 = r0;
|
|
1238
|
-
deferred2_1 = r1;
|
|
1239
|
-
return getStringFromWasm0(r0, r1);
|
|
1240
|
-
} finally {
|
|
1241
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1242
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1243
|
-
}
|
|
1182
|
+
* @param {string} nostr_hex_sk
|
|
1183
|
+
* @returns {Promise<any>}
|
|
1184
|
+
*/
|
|
1185
|
+
export function backup_btc_data(nostr_hex_sk) {
|
|
1186
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1187
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1188
|
+
const ret = wasm.backup_btc_data(ptr0, len0);
|
|
1189
|
+
return ret;
|
|
1244
1190
|
}
|
|
1245
1191
|
|
|
1246
1192
|
/**
|
|
1247
|
-
* @param {
|
|
1248
|
-
* @
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
deferred2_1 = r1;
|
|
1262
|
-
return getStringFromWasm0(r0, r1);
|
|
1263
|
-
} finally {
|
|
1264
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1265
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1266
|
-
}
|
|
1193
|
+
* @param {string} seed
|
|
1194
|
+
* @param {string} pass_phrase
|
|
1195
|
+
* @param {string} recover_address
|
|
1196
|
+
* @returns {Promise<any>}
|
|
1197
|
+
*/
|
|
1198
|
+
export function recover_funds_from_bad_wallets(seed, pass_phrase, recover_address) {
|
|
1199
|
+
const ptr0 = passStringToWasm0(seed, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1200
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1201
|
+
const ptr1 = passStringToWasm0(pass_phrase, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1202
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1203
|
+
const ptr2 = passStringToWasm0(recover_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1204
|
+
const len2 = WASM_VECTOR_LEN;
|
|
1205
|
+
const ret = wasm.recover_funds_from_bad_wallets(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
1206
|
+
return ret;
|
|
1267
1207
|
}
|
|
1268
1208
|
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1209
|
+
/**
|
|
1210
|
+
* @param {string} nostr_hex_sk
|
|
1211
|
+
* @returns {Promise<any>}
|
|
1212
|
+
*/
|
|
1213
|
+
export function restore_btc_data(nostr_hex_sk) {
|
|
1214
|
+
const ptr0 = passStringToWasm0(nostr_hex_sk, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1215
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1216
|
+
const ret = wasm.restore_btc_data(ptr0, len0);
|
|
1217
|
+
return ret;
|
|
1272
1218
|
}
|
|
1219
|
+
|
|
1273
1220
|
/**
|
|
1274
|
-
* @param {string}
|
|
1275
|
-
* @
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
var r2 = getInt32Memory0()[retptr / 4 + 2];
|
|
1286
|
-
var r3 = getInt32Memory0()[retptr / 4 + 3];
|
|
1287
|
-
if (r3) {
|
|
1288
|
-
throw takeObject(r2);
|
|
1289
|
-
}
|
|
1290
|
-
var v2 = getArrayU8FromWasm0(r0, r1).slice();
|
|
1291
|
-
wasm.__wbindgen_free(r0, r1 * 1, 1);
|
|
1292
|
-
return v2;
|
|
1293
|
-
} finally {
|
|
1294
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1295
|
-
}
|
|
1221
|
+
* @param {string} pubkey
|
|
1222
|
+
* @param {string} token
|
|
1223
|
+
* @returns {Promise<any>}
|
|
1224
|
+
*/
|
|
1225
|
+
export function new_nostr_pubkey(pubkey, token) {
|
|
1226
|
+
const ptr0 = passStringToWasm0(pubkey, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1227
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1228
|
+
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1229
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1230
|
+
const ret = wasm.new_nostr_pubkey(ptr0, len0, ptr1, len1);
|
|
1231
|
+
return ret;
|
|
1296
1232
|
}
|
|
1297
1233
|
|
|
1298
1234
|
/**
|
|
1299
|
-
* @param {string}
|
|
1300
|
-
* @
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
var r2 = getInt32Memory0()[retptr / 4 + 2];
|
|
1311
|
-
var r3 = getInt32Memory0()[retptr / 4 + 3];
|
|
1312
|
-
if (r3) {
|
|
1313
|
-
throw takeObject(r2);
|
|
1314
|
-
}
|
|
1315
|
-
var v2 = getArrayU8FromWasm0(r0, r1).slice();
|
|
1316
|
-
wasm.__wbindgen_free(r0, r1 * 1, 1);
|
|
1317
|
-
return v2;
|
|
1318
|
-
} finally {
|
|
1319
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1320
|
-
}
|
|
1235
|
+
* @param {string} pubkey
|
|
1236
|
+
* @param {string} token
|
|
1237
|
+
* @returns {Promise<any>}
|
|
1238
|
+
*/
|
|
1239
|
+
export function update_nostr_pubkey(pubkey, token) {
|
|
1240
|
+
const ptr0 = passStringToWasm0(pubkey, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1241
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1242
|
+
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1243
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1244
|
+
const ret = wasm.update_nostr_pubkey(ptr0, len0, ptr1, len1);
|
|
1245
|
+
return ret;
|
|
1321
1246
|
}
|
|
1322
1247
|
|
|
1323
1248
|
/**
|
|
1324
|
-
* @param {string}
|
|
1325
|
-
* @
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
export function convert_contract_amount_raw(decimal, precision) {
|
|
1249
|
+
* @param {string} password
|
|
1250
|
+
* @returns {string}
|
|
1251
|
+
*/
|
|
1252
|
+
export function hash_password(password) {
|
|
1329
1253
|
let deferred2_0;
|
|
1330
1254
|
let deferred2_1;
|
|
1331
1255
|
try {
|
|
1332
|
-
const
|
|
1333
|
-
const ptr0 = passStringToWasm0(decimal, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1256
|
+
const ptr0 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1334
1257
|
const len0 = WASM_VECTOR_LEN;
|
|
1335
|
-
wasm.
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
deferred2_1 = r1;
|
|
1340
|
-
return getStringFromWasm0(r0, r1);
|
|
1258
|
+
const ret = wasm.hash_password(ptr0, len0);
|
|
1259
|
+
deferred2_0 = ret[0];
|
|
1260
|
+
deferred2_1 = ret[1];
|
|
1261
|
+
return getStringFromWasm0(ret[0], ret[1]);
|
|
1341
1262
|
} finally {
|
|
1342
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1343
1263
|
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1344
1264
|
}
|
|
1345
1265
|
}
|
|
1346
1266
|
|
|
1347
1267
|
/**
|
|
1348
|
-
* @param {
|
|
1349
|
-
* @
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);
|
|
1357
|
-
wasm.convert_contract_amount_string(retptr, amount, precision);
|
|
1358
|
-
var r0 = getInt32Memory0()[retptr / 4 + 0];
|
|
1359
|
-
var r1 = getInt32Memory0()[retptr / 4 + 1];
|
|
1360
|
-
deferred1_0 = r0;
|
|
1361
|
-
deferred1_1 = r1;
|
|
1362
|
-
return getStringFromWasm0(r0, r1);
|
|
1363
|
-
} finally {
|
|
1364
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1365
|
-
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
1366
|
-
}
|
|
1268
|
+
* @param {string} password
|
|
1269
|
+
* @returns {Promise<any>}
|
|
1270
|
+
*/
|
|
1271
|
+
export function new_mnemonic(password) {
|
|
1272
|
+
const ptr0 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1273
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1274
|
+
const ret = wasm.new_mnemonic(ptr0, len0);
|
|
1275
|
+
return ret;
|
|
1367
1276
|
}
|
|
1368
1277
|
|
|
1369
1278
|
/**
|
|
1370
|
-
* @param {string}
|
|
1371
|
-
* @
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1279
|
+
* @param {string} seed
|
|
1280
|
+
* @param {string} password
|
|
1281
|
+
* @returns {Promise<any>}
|
|
1282
|
+
*/
|
|
1283
|
+
export function save_mnemonic(seed, password) {
|
|
1284
|
+
const ptr0 = passStringToWasm0(seed, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1375
1285
|
const len0 = WASM_VECTOR_LEN;
|
|
1376
|
-
const
|
|
1377
|
-
|
|
1286
|
+
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1287
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1288
|
+
const ret = wasm.save_mnemonic(ptr0, len0, ptr1, len1);
|
|
1289
|
+
return ret;
|
|
1378
1290
|
}
|
|
1379
1291
|
|
|
1380
1292
|
/**
|
|
1381
|
-
* @param {string}
|
|
1382
|
-
* @param {
|
|
1383
|
-
* @
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
deferred2_0 = r0;
|
|
1396
|
-
deferred2_1 = r1;
|
|
1397
|
-
return getStringFromWasm0(r0, r1);
|
|
1398
|
-
} finally {
|
|
1399
|
-
wasm.__wbindgen_add_to_stack_pointer(16);
|
|
1400
|
-
wasm.__wbindgen_free(deferred2_0, deferred2_1, 1);
|
|
1401
|
-
}
|
|
1293
|
+
* @param {string} hash
|
|
1294
|
+
* @param {string} encrypted_descriptors
|
|
1295
|
+
* @param {string} seed_password
|
|
1296
|
+
* @returns {Promise<any>}
|
|
1297
|
+
*/
|
|
1298
|
+
export function decrypt_wallet(hash, encrypted_descriptors, seed_password) {
|
|
1299
|
+
const ptr0 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1300
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1301
|
+
const ptr1 = passStringToWasm0(encrypted_descriptors, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1302
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1303
|
+
const ptr2 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1304
|
+
const len2 = WASM_VECTOR_LEN;
|
|
1305
|
+
const ret = wasm.decrypt_wallet(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
1306
|
+
return ret;
|
|
1402
1307
|
}
|
|
1403
1308
|
|
|
1404
1309
|
/**
|
|
1405
|
-
* @
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1310
|
+
* @param {string} hash
|
|
1311
|
+
* @param {string} encrypted_descriptors
|
|
1312
|
+
* @param {string} seed_password
|
|
1313
|
+
* @returns {Promise<any>}
|
|
1314
|
+
*/
|
|
1315
|
+
export function upgrade_wallet(hash, encrypted_descriptors, seed_password) {
|
|
1316
|
+
const ptr0 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1317
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1318
|
+
const ptr1 = passStringToWasm0(encrypted_descriptors, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1319
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1320
|
+
const ptr2 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1321
|
+
const len2 = WASM_VECTOR_LEN;
|
|
1322
|
+
const ret = wasm.upgrade_wallet(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
1323
|
+
return ret;
|
|
1410
1324
|
}
|
|
1411
1325
|
|
|
1412
1326
|
/**
|
|
1413
|
-
* @
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1327
|
+
* @param {string} hash
|
|
1328
|
+
* @param {string} seed_password
|
|
1329
|
+
* @returns {Promise<any>}
|
|
1330
|
+
*/
|
|
1331
|
+
export function new_wallet(hash, seed_password) {
|
|
1332
|
+
const ptr0 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1333
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1334
|
+
const ptr1 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1335
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1336
|
+
const ret = wasm.new_wallet(ptr0, len0, ptr1, len1);
|
|
1337
|
+
return ret;
|
|
1418
1338
|
}
|
|
1419
1339
|
|
|
1420
1340
|
/**
|
|
1421
|
-
* @param {string}
|
|
1422
|
-
* @
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1341
|
+
* @param {string} mnemonic
|
|
1342
|
+
* @param {string} hash
|
|
1343
|
+
* @param {string} seed_password
|
|
1344
|
+
* @returns {Promise<any>}
|
|
1345
|
+
*/
|
|
1346
|
+
export function encrypt_wallet(mnemonic, hash, seed_password) {
|
|
1347
|
+
const ptr0 = passStringToWasm0(mnemonic, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1426
1348
|
const len0 = WASM_VECTOR_LEN;
|
|
1427
|
-
const
|
|
1428
|
-
|
|
1349
|
+
const ptr1 = passStringToWasm0(hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1350
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1351
|
+
const ptr2 = passStringToWasm0(seed_password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1352
|
+
const len2 = WASM_VECTOR_LEN;
|
|
1353
|
+
const ret = wasm.encrypt_wallet(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
1354
|
+
return ret;
|
|
1429
1355
|
}
|
|
1430
1356
|
|
|
1431
1357
|
/**
|
|
1432
|
-
* @param {string}
|
|
1433
|
-
* @
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1358
|
+
* @param {string} descriptor
|
|
1359
|
+
* @param {string | null} [change_descriptor]
|
|
1360
|
+
* @returns {Promise<any>}
|
|
1361
|
+
*/
|
|
1362
|
+
export function get_wallet_data(descriptor, change_descriptor) {
|
|
1363
|
+
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1437
1364
|
const len0 = WASM_VECTOR_LEN;
|
|
1438
|
-
|
|
1439
|
-
|
|
1365
|
+
var ptr1 = isLikeNone(change_descriptor) ? 0 : passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1366
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1367
|
+
const ret = wasm.get_wallet_data(ptr0, len0, ptr1, len1);
|
|
1368
|
+
return ret;
|
|
1440
1369
|
}
|
|
1441
1370
|
|
|
1442
1371
|
/**
|
|
1443
|
-
* @
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1372
|
+
* @returns {Promise<any>}
|
|
1373
|
+
*/
|
|
1374
|
+
export function sync_wallets() {
|
|
1375
|
+
const ret = wasm.sync_wallets();
|
|
1376
|
+
return ret;
|
|
1377
|
+
}
|
|
1378
|
+
|
|
1379
|
+
/**
|
|
1380
|
+
* @param {string} descriptor
|
|
1381
|
+
* @param {string | null} [change_descriptor]
|
|
1382
|
+
* @returns {Promise<any>}
|
|
1383
|
+
*/
|
|
1384
|
+
export function get_new_address(descriptor, change_descriptor) {
|
|
1385
|
+
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1449
1386
|
const len0 = WASM_VECTOR_LEN;
|
|
1450
|
-
|
|
1387
|
+
var ptr1 = isLikeNone(change_descriptor) ? 0 : passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1388
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1389
|
+
const ret = wasm.get_new_address(ptr0, len0, ptr1, len1);
|
|
1390
|
+
return ret;
|
|
1391
|
+
}
|
|
1392
|
+
|
|
1393
|
+
/**
|
|
1394
|
+
* @param {string} descriptor
|
|
1395
|
+
* @param {string} change_descriptor
|
|
1396
|
+
* @param {string} destination
|
|
1397
|
+
* @param {bigint} amount
|
|
1398
|
+
* @param {boolean} broadcast
|
|
1399
|
+
* @param {number | null} [fee_rate]
|
|
1400
|
+
* @returns {Promise<any>}
|
|
1401
|
+
*/
|
|
1402
|
+
export function send_sats(descriptor, change_descriptor, destination, amount, broadcast, fee_rate) {
|
|
1403
|
+
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1404
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1405
|
+
const ptr1 = passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1451
1406
|
const len1 = WASM_VECTOR_LEN;
|
|
1452
|
-
const
|
|
1453
|
-
|
|
1407
|
+
const ptr2 = passStringToWasm0(destination, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1408
|
+
const len2 = WASM_VECTOR_LEN;
|
|
1409
|
+
const ret = wasm.send_sats(ptr0, len0, ptr1, len1, ptr2, len2, amount, broadcast, isLikeNone(fee_rate) ? 0x100000001 : Math.fround(fee_rate));
|
|
1410
|
+
return ret;
|
|
1454
1411
|
}
|
|
1455
1412
|
|
|
1456
1413
|
/**
|
|
1457
|
-
* @param {
|
|
1458
|
-
* @
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1414
|
+
* @param {string} descriptor
|
|
1415
|
+
* @param {string} change_descriptor
|
|
1416
|
+
* @param {string} rgb_address
|
|
1417
|
+
* @param {boolean} broadcast
|
|
1418
|
+
* @param {number | null} [fee_rate]
|
|
1419
|
+
* @returns {Promise<any>}
|
|
1420
|
+
*/
|
|
1421
|
+
export function fund_vault(descriptor, change_descriptor, rgb_address, broadcast, fee_rate) {
|
|
1422
|
+
const ptr0 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1423
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1424
|
+
const ptr1 = passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1425
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1426
|
+
const ptr2 = passStringToWasm0(rgb_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1427
|
+
const len2 = WASM_VECTOR_LEN;
|
|
1428
|
+
const ret = wasm.fund_vault(ptr0, len0, ptr1, len1, ptr2, len2, broadcast, isLikeNone(fee_rate) ? 0x100000001 : Math.fround(fee_rate));
|
|
1429
|
+
return ret;
|
|
1463
1430
|
}
|
|
1464
1431
|
|
|
1465
|
-
|
|
1432
|
+
/**
|
|
1433
|
+
* @param {string} rgb_descriptor_xpub
|
|
1434
|
+
* @returns {Promise<any>}
|
|
1435
|
+
*/
|
|
1436
|
+
export function get_assets_vault(rgb_descriptor_xpub) {
|
|
1437
|
+
const ptr0 = passStringToWasm0(rgb_descriptor_xpub, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1438
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1439
|
+
const ret = wasm.get_assets_vault(ptr0, len0);
|
|
1440
|
+
return ret;
|
|
1441
|
+
}
|
|
1466
1442
|
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1443
|
+
/**
|
|
1444
|
+
* @param {string} destination
|
|
1445
|
+
* @param {string} descriptor
|
|
1446
|
+
* @param {string | null} [change_descriptor]
|
|
1447
|
+
* @param {number | null} [fee_rate]
|
|
1448
|
+
* @returns {Promise<any>}
|
|
1449
|
+
*/
|
|
1450
|
+
export function drain_wallet(destination, descriptor, change_descriptor, fee_rate) {
|
|
1451
|
+
const ptr0 = passStringToWasm0(destination, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1452
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1453
|
+
const ptr1 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1454
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1455
|
+
var ptr2 = isLikeNone(change_descriptor) ? 0 : passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1456
|
+
var len2 = WASM_VECTOR_LEN;
|
|
1457
|
+
const ret = wasm.drain_wallet(ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(fee_rate) ? 0x100000001 : Math.fround(fee_rate));
|
|
1458
|
+
return ret;
|
|
1472
1459
|
}
|
|
1473
1460
|
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1461
|
+
/**
|
|
1462
|
+
* @param {string} txid
|
|
1463
|
+
* @param {number} fee_rate
|
|
1464
|
+
* @param {string} descriptor
|
|
1465
|
+
* @param {string | null | undefined} change_descriptor
|
|
1466
|
+
* @param {boolean} broadcast
|
|
1467
|
+
* @returns {Promise<any>}
|
|
1468
|
+
*/
|
|
1469
|
+
export function bump_fee(txid, fee_rate, descriptor, change_descriptor, broadcast) {
|
|
1470
|
+
const ptr0 = passStringToWasm0(txid, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1471
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1472
|
+
const ptr1 = passStringToWasm0(descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1473
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1474
|
+
var ptr2 = isLikeNone(change_descriptor) ? 0 : passStringToWasm0(change_descriptor, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1475
|
+
var len2 = WASM_VECTOR_LEN;
|
|
1476
|
+
const ret = wasm.bump_fee(ptr0, len0, fee_rate, ptr1, len1, ptr2, len2, broadcast);
|
|
1477
|
+
return ret;
|
|
1483
1478
|
}
|
|
1484
1479
|
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1480
|
+
/**
|
|
1481
|
+
* @param {any} request
|
|
1482
|
+
* @returns {Promise<any>}
|
|
1483
|
+
*/
|
|
1484
|
+
export function psbt_sign_and_publish_file(request) {
|
|
1485
|
+
const ret = wasm.psbt_sign_and_publish_file(request);
|
|
1486
|
+
return ret;
|
|
1491
1487
|
}
|
|
1492
|
-
|
|
1493
|
-
|
|
1488
|
+
|
|
1489
|
+
/**
|
|
1490
|
+
* @param {any} request
|
|
1491
|
+
* @returns {Promise<any>}
|
|
1492
|
+
*/
|
|
1493
|
+
export function psbt_publish_file(request) {
|
|
1494
|
+
const ret = wasm.psbt_publish_file(request);
|
|
1495
|
+
return ret;
|
|
1494
1496
|
}
|
|
1495
1497
|
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
};
|
|
1498
|
+
function __wbg_adapter_54(arg0, arg1, arg2) {
|
|
1499
|
+
wasm.closure1855_externref_shim(arg0, arg1, arg2);
|
|
1500
|
+
}
|
|
1500
1501
|
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1505
|
-
var len1 = WASM_VECTOR_LEN;
|
|
1506
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1507
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
1508
|
-
};
|
|
1502
|
+
function __wbg_adapter_57(arg0, arg1, arg2) {
|
|
1503
|
+
wasm.closure1997_externref_shim(arg0, arg1, arg2);
|
|
1504
|
+
}
|
|
1509
1505
|
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
}
|
|
1506
|
+
function __wbg_adapter_60(arg0, arg1, arg2) {
|
|
1507
|
+
wasm.closure2668_externref_shim(arg0, arg1, arg2);
|
|
1508
|
+
}
|
|
1513
1509
|
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
getFloat64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0 : ret;
|
|
1518
|
-
getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
|
|
1519
|
-
};
|
|
1510
|
+
function __wbg_adapter_63(arg0, arg1, arg2) {
|
|
1511
|
+
wasm.closure3834_externref_shim(arg0, arg1, arg2);
|
|
1512
|
+
}
|
|
1520
1513
|
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1514
|
+
function __wbg_adapter_416(arg0, arg1, arg2, arg3) {
|
|
1515
|
+
wasm.closure4126_externref_shim(arg0, arg1, arg2, arg3);
|
|
1516
|
+
}
|
|
1517
|
+
|
|
1518
|
+
const __wbindgen_enum_IdbTransactionMode = ["readonly", "readwrite", "versionchange", "readwriteflush", "cleanup"];
|
|
1519
|
+
|
|
1520
|
+
const __wbindgen_enum_RequestCredentials = ["omit", "same-origin", "include"];
|
|
1525
1521
|
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1522
|
+
const __wbindgen_enum_RequestMode = ["same-origin", "no-cors", "cors", "navigate"];
|
|
1523
|
+
|
|
1524
|
+
export function __wbg_String_8f0eb39a4a4c2f66(arg0, arg1) {
|
|
1525
|
+
const ret = String(arg1);
|
|
1526
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1527
|
+
const len1 = WASM_VECTOR_LEN;
|
|
1528
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1529
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1529
1530
|
};
|
|
1530
1531
|
|
|
1531
|
-
export function
|
|
1532
|
-
|
|
1533
|
-
return ret;
|
|
1532
|
+
export function __wbg_abort_775ef1d17fc65868(arg0) {
|
|
1533
|
+
arg0.abort();
|
|
1534
1534
|
};
|
|
1535
1535
|
|
|
1536
|
-
export function
|
|
1537
|
-
const ret =
|
|
1536
|
+
export function __wbg_allSettled_d6c2eb0382f2fff9(arg0) {
|
|
1537
|
+
const ret = Promise.allSettled(arg0);
|
|
1538
1538
|
return ret;
|
|
1539
1539
|
};
|
|
1540
1540
|
|
|
1541
|
-
export function
|
|
1542
|
-
const ret =
|
|
1541
|
+
export function __wbg_any_8f7b1d9e103c57f1(arg0) {
|
|
1542
|
+
const ret = Promise.any(arg0);
|
|
1543
1543
|
return ret;
|
|
1544
1544
|
};
|
|
1545
1545
|
|
|
1546
|
-
export function
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
};
|
|
1546
|
+
export function __wbg_append_299d5d48292c0495() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
1547
|
+
arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
|
|
1548
|
+
}, arguments) };
|
|
1550
1549
|
|
|
1551
|
-
export function
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
};
|
|
1550
|
+
export function __wbg_append_8c7dd8d641a5f01b() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
1551
|
+
arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
|
|
1552
|
+
}, arguments) };
|
|
1555
1553
|
|
|
1556
|
-
export function
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
};
|
|
1554
|
+
export function __wbg_append_b2d1fc16de2a0e81() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
1555
|
+
arg0.append(getStringFromWasm0(arg1, arg2), arg3, getStringFromWasm0(arg4, arg5));
|
|
1556
|
+
}, arguments) };
|
|
1560
1557
|
|
|
1561
|
-
export function
|
|
1562
|
-
|
|
1563
|
-
|
|
1558
|
+
export function __wbg_append_b44785ebeb668479() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
1559
|
+
arg0.append(getStringFromWasm0(arg1, arg2), arg3);
|
|
1560
|
+
}, arguments) };
|
|
1561
|
+
|
|
1562
|
+
export function __wbg_arrayBuffer_d1b44c4390db422f() { return handleError(function (arg0) {
|
|
1563
|
+
const ret = arg0.arrayBuffer();
|
|
1564
1564
|
return ret;
|
|
1565
|
-
};
|
|
1565
|
+
}, arguments) };
|
|
1566
1566
|
|
|
1567
|
-
export function
|
|
1568
|
-
const ret =
|
|
1567
|
+
export function __wbg_buffer_609cc3eee51ed158(arg0) {
|
|
1568
|
+
const ret = arg0.buffer;
|
|
1569
1569
|
return ret;
|
|
1570
1570
|
};
|
|
1571
1571
|
|
|
1572
|
-
export function
|
|
1573
|
-
const
|
|
1574
|
-
const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
|
|
1572
|
+
export function __wbg_call_672a4d21634d4a24() { return handleError(function (arg0, arg1) {
|
|
1573
|
+
const ret = arg0.call(arg1);
|
|
1575
1574
|
return ret;
|
|
1575
|
+
}, arguments) };
|
|
1576
|
+
|
|
1577
|
+
export function __wbg_call_7cccdd69e0791ae2() { return handleError(function (arg0, arg1, arg2) {
|
|
1578
|
+
const ret = arg0.call(arg1, arg2);
|
|
1579
|
+
return ret;
|
|
1580
|
+
}, arguments) };
|
|
1581
|
+
|
|
1582
|
+
export function __wbg_close_26fc2e6856d8567a(arg0) {
|
|
1583
|
+
arg0.close();
|
|
1576
1584
|
};
|
|
1577
1585
|
|
|
1578
|
-
export function
|
|
1579
|
-
|
|
1580
|
-
|
|
1586
|
+
export function __wbg_commit_ee33ba79d75a9134() { return handleError(function (arg0) {
|
|
1587
|
+
arg0.commit();
|
|
1588
|
+
}, arguments) };
|
|
1589
|
+
|
|
1590
|
+
export function __wbg_createIndex_873ac48adc772309() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
1591
|
+
const ret = arg0.createIndex(getStringFromWasm0(arg1, arg2), arg3, arg4);
|
|
1592
|
+
return ret;
|
|
1593
|
+
}, arguments) };
|
|
1594
|
+
|
|
1595
|
+
export function __wbg_createObjectStore_d2f9e1016f4d81b9() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
1596
|
+
const ret = arg0.createObjectStore(getStringFromWasm0(arg1, arg2), arg3);
|
|
1597
|
+
return ret;
|
|
1598
|
+
}, arguments) };
|
|
1599
|
+
|
|
1600
|
+
export function __wbg_crypto_8b2f439d7d40e47c(arg0) {
|
|
1601
|
+
const ret = arg0.crypto;
|
|
1602
|
+
return ret;
|
|
1581
1603
|
};
|
|
1582
1604
|
|
|
1583
|
-
export function
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1605
|
+
export function __wbg_debug_07010e9cfe65fce9(arg0, arg1) {
|
|
1606
|
+
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
1607
|
+
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
1608
|
+
console.debug(...v0);
|
|
1609
|
+
};
|
|
1610
|
+
|
|
1611
|
+
export function __wbg_deleteDatabase_b8f234aeb7ad3452() { return handleError(function (arg0, arg1, arg2) {
|
|
1612
|
+
const ret = arg0.deleteDatabase(getStringFromWasm0(arg1, arg2));
|
|
1613
|
+
return ret;
|
|
1614
|
+
}, arguments) };
|
|
1615
|
+
|
|
1616
|
+
export function __wbg_deleteIndex_e6717aa0e9691894() { return handleError(function (arg0, arg1, arg2) {
|
|
1617
|
+
arg0.deleteIndex(getStringFromWasm0(arg1, arg2));
|
|
1618
|
+
}, arguments) };
|
|
1619
|
+
|
|
1620
|
+
export function __wbg_deleteObjectStore_3f08ae00cd288224() { return handleError(function (arg0, arg1, arg2) {
|
|
1621
|
+
arg0.deleteObjectStore(getStringFromWasm0(arg1, arg2));
|
|
1622
|
+
}, arguments) };
|
|
1623
|
+
|
|
1624
|
+
export function __wbg_done_769e5ede4b31c67b(arg0) {
|
|
1625
|
+
const ret = arg0.done;
|
|
1590
1626
|
return ret;
|
|
1591
1627
|
};
|
|
1592
1628
|
|
|
1593
|
-
export function
|
|
1594
|
-
const ret =
|
|
1595
|
-
return
|
|
1629
|
+
export function __wbg_entries_3265d4158b33e5dc(arg0) {
|
|
1630
|
+
const ret = Object.entries(arg0);
|
|
1631
|
+
return ret;
|
|
1596
1632
|
};
|
|
1597
1633
|
|
|
1598
|
-
export function
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1603
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
1634
|
+
export function __wbg_error_3c7d958458bf649b(arg0, arg1) {
|
|
1635
|
+
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
1636
|
+
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
1637
|
+
console.error(...v0);
|
|
1604
1638
|
};
|
|
1605
1639
|
|
|
1606
|
-
export function
|
|
1640
|
+
export function __wbg_error_7534b8e9a36f1ab4(arg0, arg1) {
|
|
1607
1641
|
let deferred0_0;
|
|
1608
1642
|
let deferred0_1;
|
|
1609
1643
|
try {
|
|
@@ -1615,574 +1649,863 @@ export function __wbg_error_f851667af71bcfc6(arg0, arg1) {
|
|
|
1615
1649
|
}
|
|
1616
1650
|
};
|
|
1617
1651
|
|
|
1618
|
-
export function
|
|
1619
|
-
const ret =
|
|
1652
|
+
export function __wbg_error_e9332df4e7a14612(arg0) {
|
|
1653
|
+
const ret = arg0.error;
|
|
1654
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1655
|
+
};
|
|
1656
|
+
|
|
1657
|
+
export function __wbg_error_ff4ddaabdfc5dbb3() { return handleError(function (arg0) {
|
|
1658
|
+
const ret = arg0.error;
|
|
1659
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1660
|
+
}, arguments) };
|
|
1661
|
+
|
|
1662
|
+
export function __wbg_fetch_509096533071c657(arg0, arg1) {
|
|
1663
|
+
const ret = arg0.fetch(arg1);
|
|
1620
1664
|
return ret;
|
|
1621
1665
|
};
|
|
1622
1666
|
|
|
1623
|
-
export function
|
|
1624
|
-
const ret =
|
|
1667
|
+
export function __wbg_fetch_6397c767b06a0785(arg0) {
|
|
1668
|
+
const ret = fetch(arg0);
|
|
1625
1669
|
return ret;
|
|
1626
1670
|
};
|
|
1627
1671
|
|
|
1628
|
-
export function
|
|
1629
|
-
const ret =
|
|
1630
|
-
|
|
1631
|
-
const len1 = WASM_VECTOR_LEN;
|
|
1632
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1633
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
1672
|
+
export function __wbg_fetch_b335d17f45a8b5a1(arg0) {
|
|
1673
|
+
const ret = fetch(arg0);
|
|
1674
|
+
return ret;
|
|
1634
1675
|
};
|
|
1635
1676
|
|
|
1636
|
-
export function
|
|
1637
|
-
const ret =
|
|
1638
|
-
return
|
|
1677
|
+
export function __wbg_fetch_b7bf320f681242d2(arg0, arg1) {
|
|
1678
|
+
const ret = arg0.fetch(arg1);
|
|
1679
|
+
return ret;
|
|
1639
1680
|
};
|
|
1640
1681
|
|
|
1641
|
-
export function
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1682
|
+
export function __wbg_getRandomValues_1c61fac11405ffdc() { return handleError(function (arg0, arg1) {
|
|
1683
|
+
globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
|
|
1684
|
+
}, arguments) };
|
|
1685
|
+
|
|
1686
|
+
export function __wbg_getRandomValues_7b17ba35056bcdd1() { return handleError(function (arg0, arg1) {
|
|
1687
|
+
arg0.getRandomValues(arg1);
|
|
1688
|
+
}, arguments) };
|
|
1689
|
+
|
|
1690
|
+
export function __wbg_getTime_46267b1c24877e30(arg0) {
|
|
1691
|
+
const ret = arg0.getTime();
|
|
1692
|
+
return ret;
|
|
1645
1693
|
};
|
|
1646
1694
|
|
|
1647
|
-
export function
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1695
|
+
export function __wbg_get_4f73335ab78445db(arg0, arg1, arg2) {
|
|
1696
|
+
const ret = arg1[arg2 >>> 0];
|
|
1697
|
+
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1698
|
+
var len1 = WASM_VECTOR_LEN;
|
|
1699
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
1700
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1651
1701
|
};
|
|
1652
1702
|
|
|
1653
|
-
export function
|
|
1703
|
+
export function __wbg_get_67b2ba62fc30de12() { return handleError(function (arg0, arg1) {
|
|
1704
|
+
const ret = Reflect.get(arg0, arg1);
|
|
1705
|
+
return ret;
|
|
1706
|
+
}, arguments) };
|
|
1707
|
+
|
|
1708
|
+
export function __wbg_get_8da03f81f6a1111e() { return handleError(function (arg0, arg1) {
|
|
1709
|
+
const ret = arg0.get(arg1);
|
|
1710
|
+
return ret;
|
|
1711
|
+
}, arguments) };
|
|
1712
|
+
|
|
1713
|
+
export function __wbg_get_b9b93047fe3cf45b(arg0, arg1) {
|
|
1714
|
+
const ret = arg0[arg1 >>> 0];
|
|
1715
|
+
return ret;
|
|
1716
|
+
};
|
|
1717
|
+
|
|
1718
|
+
export function __wbg_getwithrefkey_1dc361bd10053bfe(arg0, arg1) {
|
|
1719
|
+
const ret = arg0[arg1];
|
|
1720
|
+
return ret;
|
|
1721
|
+
};
|
|
1722
|
+
|
|
1723
|
+
export function __wbg_has_a5ea9117f258a0ec() { return handleError(function (arg0, arg1) {
|
|
1724
|
+
const ret = Reflect.has(arg0, arg1);
|
|
1725
|
+
return ret;
|
|
1726
|
+
}, arguments) };
|
|
1727
|
+
|
|
1728
|
+
export function __wbg_headers_9cb51cfd2ac780a4(arg0) {
|
|
1729
|
+
const ret = arg0.headers;
|
|
1730
|
+
return ret;
|
|
1731
|
+
};
|
|
1732
|
+
|
|
1733
|
+
export function __wbg_indexNames_0ed82a19d7d88aa3(arg0) {
|
|
1734
|
+
const ret = arg0.indexNames;
|
|
1735
|
+
return ret;
|
|
1736
|
+
};
|
|
1737
|
+
|
|
1738
|
+
export function __wbg_index_e00ca5fff206ee3e() { return handleError(function (arg0, arg1, arg2) {
|
|
1739
|
+
const ret = arg0.index(getStringFromWasm0(arg1, arg2));
|
|
1740
|
+
return ret;
|
|
1741
|
+
}, arguments) };
|
|
1742
|
+
|
|
1743
|
+
export function __wbg_info_638bd7b680bce79d(arg0, arg1) {
|
|
1654
1744
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
1655
1745
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
1656
1746
|
console.info(...v0);
|
|
1657
1747
|
};
|
|
1658
1748
|
|
|
1659
|
-
export function
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1749
|
+
export function __wbg_instanceof_ArrayBuffer_e14585432e3737fc(arg0) {
|
|
1750
|
+
let result;
|
|
1751
|
+
try {
|
|
1752
|
+
result = arg0 instanceof ArrayBuffer;
|
|
1753
|
+
} catch (_) {
|
|
1754
|
+
result = false;
|
|
1755
|
+
}
|
|
1756
|
+
const ret = result;
|
|
1757
|
+
return ret;
|
|
1758
|
+
};
|
|
1759
|
+
|
|
1760
|
+
export function __wbg_instanceof_Error_4d54113b22d20306(arg0) {
|
|
1761
|
+
let result;
|
|
1762
|
+
try {
|
|
1763
|
+
result = arg0 instanceof Error;
|
|
1764
|
+
} catch (_) {
|
|
1765
|
+
result = false;
|
|
1766
|
+
}
|
|
1767
|
+
const ret = result;
|
|
1768
|
+
return ret;
|
|
1769
|
+
};
|
|
1770
|
+
|
|
1771
|
+
export function __wbg_instanceof_IdbDatabase_a3ef009ca00059f9(arg0) {
|
|
1772
|
+
let result;
|
|
1773
|
+
try {
|
|
1774
|
+
result = arg0 instanceof IDBDatabase;
|
|
1775
|
+
} catch (_) {
|
|
1776
|
+
result = false;
|
|
1777
|
+
}
|
|
1778
|
+
const ret = result;
|
|
1779
|
+
return ret;
|
|
1780
|
+
};
|
|
1781
|
+
|
|
1782
|
+
export function __wbg_instanceof_IdbFactory_12eaba3366f4302f(arg0) {
|
|
1783
|
+
let result;
|
|
1784
|
+
try {
|
|
1785
|
+
result = arg0 instanceof IDBFactory;
|
|
1786
|
+
} catch (_) {
|
|
1787
|
+
result = false;
|
|
1788
|
+
}
|
|
1789
|
+
const ret = result;
|
|
1790
|
+
return ret;
|
|
1791
|
+
};
|
|
1792
|
+
|
|
1793
|
+
export function __wbg_instanceof_IdbOpenDbRequest_a3416e156c9db893(arg0) {
|
|
1794
|
+
let result;
|
|
1795
|
+
try {
|
|
1796
|
+
result = arg0 instanceof IDBOpenDBRequest;
|
|
1797
|
+
} catch (_) {
|
|
1798
|
+
result = false;
|
|
1799
|
+
}
|
|
1800
|
+
const ret = result;
|
|
1801
|
+
return ret;
|
|
1802
|
+
};
|
|
1803
|
+
|
|
1804
|
+
export function __wbg_instanceof_IdbRequest_4813c3f207666aa4(arg0) {
|
|
1805
|
+
let result;
|
|
1806
|
+
try {
|
|
1807
|
+
result = arg0 instanceof IDBRequest;
|
|
1808
|
+
} catch (_) {
|
|
1809
|
+
result = false;
|
|
1810
|
+
}
|
|
1811
|
+
const ret = result;
|
|
1812
|
+
return ret;
|
|
1813
|
+
};
|
|
1814
|
+
|
|
1815
|
+
export function __wbg_instanceof_IdbTransaction_746ea660d347650d(arg0) {
|
|
1816
|
+
let result;
|
|
1817
|
+
try {
|
|
1818
|
+
result = arg0 instanceof IDBTransaction;
|
|
1819
|
+
} catch (_) {
|
|
1820
|
+
result = false;
|
|
1821
|
+
}
|
|
1822
|
+
const ret = result;
|
|
1823
|
+
return ret;
|
|
1824
|
+
};
|
|
1825
|
+
|
|
1826
|
+
export function __wbg_instanceof_Response_f2cc20d9f7dfd644(arg0) {
|
|
1827
|
+
let result;
|
|
1828
|
+
try {
|
|
1829
|
+
result = arg0 instanceof Response;
|
|
1830
|
+
} catch (_) {
|
|
1831
|
+
result = false;
|
|
1832
|
+
}
|
|
1833
|
+
const ret = result;
|
|
1834
|
+
return ret;
|
|
1835
|
+
};
|
|
1836
|
+
|
|
1837
|
+
export function __wbg_instanceof_Uint8Array_17156bcf118086a9(arg0) {
|
|
1838
|
+
let result;
|
|
1839
|
+
try {
|
|
1840
|
+
result = arg0 instanceof Uint8Array;
|
|
1841
|
+
} catch (_) {
|
|
1842
|
+
result = false;
|
|
1843
|
+
}
|
|
1844
|
+
const ret = result;
|
|
1845
|
+
return ret;
|
|
1846
|
+
};
|
|
1847
|
+
|
|
1848
|
+
export function __wbg_instanceof_Window_def73ea0955fc569(arg0) {
|
|
1849
|
+
let result;
|
|
1850
|
+
try {
|
|
1851
|
+
result = arg0 instanceof Window;
|
|
1852
|
+
} catch (_) {
|
|
1853
|
+
result = false;
|
|
1854
|
+
}
|
|
1855
|
+
const ret = result;
|
|
1856
|
+
return ret;
|
|
1857
|
+
};
|
|
1858
|
+
|
|
1859
|
+
export function __wbg_instanceof_WorkerGlobalScope_dbdbdea7e3b56493(arg0) {
|
|
1860
|
+
let result;
|
|
1861
|
+
try {
|
|
1862
|
+
result = arg0 instanceof WorkerGlobalScope;
|
|
1863
|
+
} catch (_) {
|
|
1864
|
+
result = false;
|
|
1865
|
+
}
|
|
1866
|
+
const ret = result;
|
|
1867
|
+
return ret;
|
|
1868
|
+
};
|
|
1869
|
+
|
|
1870
|
+
export function __wbg_isArray_a1eab7e0d067391b(arg0) {
|
|
1871
|
+
const ret = Array.isArray(arg0);
|
|
1872
|
+
return ret;
|
|
1873
|
+
};
|
|
1874
|
+
|
|
1875
|
+
export function __wbg_isSafeInteger_343e2beeeece1bb0(arg0) {
|
|
1876
|
+
const ret = Number.isSafeInteger(arg0);
|
|
1877
|
+
return ret;
|
|
1878
|
+
};
|
|
1879
|
+
|
|
1880
|
+
export function __wbg_iterator_9a24c88df860dc65() {
|
|
1881
|
+
const ret = Symbol.iterator;
|
|
1882
|
+
return ret;
|
|
1883
|
+
};
|
|
1884
|
+
|
|
1885
|
+
export function __wbg_keyPath_443ecf3f74202169() { return handleError(function (arg0) {
|
|
1886
|
+
const ret = arg0.keyPath;
|
|
1887
|
+
return ret;
|
|
1888
|
+
}, arguments) };
|
|
1889
|
+
|
|
1890
|
+
export function __wbg_length_52b6c4580c5ec934(arg0) {
|
|
1891
|
+
const ret = arg0.length;
|
|
1892
|
+
return ret;
|
|
1893
|
+
};
|
|
1894
|
+
|
|
1895
|
+
export function __wbg_length_a446193dc22c12f8(arg0) {
|
|
1896
|
+
const ret = arg0.length;
|
|
1897
|
+
return ret;
|
|
1898
|
+
};
|
|
1899
|
+
|
|
1900
|
+
export function __wbg_length_e2d2a49132c1b256(arg0) {
|
|
1901
|
+
const ret = arg0.length;
|
|
1902
|
+
return ret;
|
|
1903
|
+
};
|
|
1904
|
+
|
|
1905
|
+
export function __wbg_log_c222819a41e063d3(arg0) {
|
|
1906
|
+
console.log(arg0);
|
|
1907
|
+
};
|
|
1908
|
+
|
|
1909
|
+
export function __wbg_message_97a2af9b89d693a3(arg0) {
|
|
1910
|
+
const ret = arg0.message;
|
|
1911
|
+
return ret;
|
|
1912
|
+
};
|
|
1913
|
+
|
|
1914
|
+
export function __wbg_msCrypto_592a45e469d83ced(arg0) {
|
|
1915
|
+
const ret = arg0.msCrypto;
|
|
1916
|
+
return ret;
|
|
1917
|
+
};
|
|
1918
|
+
|
|
1919
|
+
export function __wbg_multiEntry_c146ebd38a5de9ea(arg0) {
|
|
1920
|
+
const ret = arg0.multiEntry;
|
|
1921
|
+
return ret;
|
|
1922
|
+
};
|
|
1923
|
+
|
|
1924
|
+
export function __wbg_name_0b327d569f00ebee(arg0) {
|
|
1925
|
+
const ret = arg0.name;
|
|
1926
|
+
return ret;
|
|
1927
|
+
};
|
|
1928
|
+
|
|
1929
|
+
export function __wbg_new0_f788a2397c7ca929() {
|
|
1930
|
+
const ret = new Date();
|
|
1931
|
+
return ret;
|
|
1932
|
+
};
|
|
1933
|
+
|
|
1934
|
+
export function __wbg_new_018dcc2d6c8c2f6a() { return handleError(function () {
|
|
1935
|
+
const ret = new Headers();
|
|
1936
|
+
return ret;
|
|
1937
|
+
}, arguments) };
|
|
1938
|
+
|
|
1939
|
+
export function __wbg_new_23a2665fac83c611(arg0, arg1) {
|
|
1940
|
+
try {
|
|
1941
|
+
var state0 = {a: arg0, b: arg1};
|
|
1942
|
+
var cb0 = (arg0, arg1) => {
|
|
1943
|
+
const a = state0.a;
|
|
1944
|
+
state0.a = 0;
|
|
1945
|
+
try {
|
|
1946
|
+
return __wbg_adapter_416(a, state0.b, arg0, arg1);
|
|
1947
|
+
} finally {
|
|
1948
|
+
state0.a = a;
|
|
1949
|
+
}
|
|
1950
|
+
};
|
|
1951
|
+
const ret = new Promise(cb0);
|
|
1952
|
+
return ret;
|
|
1953
|
+
} finally {
|
|
1954
|
+
state0.a = state0.b = 0;
|
|
1955
|
+
}
|
|
1956
|
+
};
|
|
1957
|
+
|
|
1958
|
+
export function __wbg_new_405e22f390576ce2() {
|
|
1959
|
+
const ret = new Object();
|
|
1960
|
+
return ret;
|
|
1961
|
+
};
|
|
1962
|
+
|
|
1963
|
+
export function __wbg_new_78feb108b6472713() {
|
|
1964
|
+
const ret = new Array();
|
|
1965
|
+
return ret;
|
|
1966
|
+
};
|
|
1967
|
+
|
|
1968
|
+
export function __wbg_new_80bf4ee74f41ff92() { return handleError(function () {
|
|
1969
|
+
const ret = new URLSearchParams();
|
|
1970
|
+
return ret;
|
|
1971
|
+
}, arguments) };
|
|
1972
|
+
|
|
1973
|
+
export function __wbg_new_8a6f238a6ece86ea() {
|
|
1974
|
+
const ret = new Error();
|
|
1975
|
+
return ret;
|
|
1976
|
+
};
|
|
1977
|
+
|
|
1978
|
+
export function __wbg_new_9fd39a253424609a() { return handleError(function () {
|
|
1979
|
+
const ret = new FormData();
|
|
1980
|
+
return ret;
|
|
1981
|
+
}, arguments) };
|
|
1982
|
+
|
|
1983
|
+
export function __wbg_new_9ffbe0a71eff35e3() { return handleError(function (arg0, arg1) {
|
|
1984
|
+
const ret = new URL(getStringFromWasm0(arg0, arg1));
|
|
1985
|
+
return ret;
|
|
1986
|
+
}, arguments) };
|
|
1987
|
+
|
|
1988
|
+
export function __wbg_new_a12002a7f91c75be(arg0) {
|
|
1989
|
+
const ret = new Uint8Array(arg0);
|
|
1990
|
+
return ret;
|
|
1663
1991
|
};
|
|
1664
1992
|
|
|
1665
|
-
export function
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
};
|
|
1993
|
+
export function __wbg_new_e25e5aab09ff45db() { return handleError(function () {
|
|
1994
|
+
const ret = new AbortController();
|
|
1995
|
+
return ret;
|
|
1996
|
+
}, arguments) };
|
|
1670
1997
|
|
|
1671
|
-
export function
|
|
1672
|
-
const ret =
|
|
1673
|
-
return
|
|
1998
|
+
export function __wbg_newnoargs_105ed471475aaf50(arg0, arg1) {
|
|
1999
|
+
const ret = new Function(getStringFromWasm0(arg0, arg1));
|
|
2000
|
+
return ret;
|
|
1674
2001
|
};
|
|
1675
2002
|
|
|
1676
|
-
export function
|
|
1677
|
-
const ret =
|
|
1678
|
-
return
|
|
2003
|
+
export function __wbg_newwithbyteoffsetandlength_d97e637ebe145a9a(arg0, arg1, arg2) {
|
|
2004
|
+
const ret = new Uint8Array(arg0, arg1 >>> 0, arg2 >>> 0);
|
|
2005
|
+
return ret;
|
|
1679
2006
|
};
|
|
1680
2007
|
|
|
1681
|
-
export function
|
|
1682
|
-
const ret =
|
|
1683
|
-
return
|
|
2008
|
+
export function __wbg_newwithlength_a381634e90c276d4(arg0) {
|
|
2009
|
+
const ret = new Uint8Array(arg0 >>> 0);
|
|
2010
|
+
return ret;
|
|
1684
2011
|
};
|
|
1685
2012
|
|
|
1686
|
-
export function
|
|
1687
|
-
const ret =
|
|
2013
|
+
export function __wbg_newwithstr_78e86e03c4ae814e() { return handleError(function (arg0, arg1) {
|
|
2014
|
+
const ret = new Request(getStringFromWasm0(arg0, arg1));
|
|
1688
2015
|
return ret;
|
|
1689
|
-
};
|
|
2016
|
+
}, arguments) };
|
|
1690
2017
|
|
|
1691
|
-
export function
|
|
1692
|
-
|
|
1693
|
-
|
|
2018
|
+
export function __wbg_newwithstrandinit_06c535e0a867c635() { return handleError(function (arg0, arg1, arg2) {
|
|
2019
|
+
const ret = new Request(getStringFromWasm0(arg0, arg1), arg2);
|
|
2020
|
+
return ret;
|
|
2021
|
+
}, arguments) };
|
|
1694
2022
|
|
|
1695
|
-
export function
|
|
1696
|
-
|
|
1697
|
-
try {
|
|
1698
|
-
result = getObject(arg0) instanceof Window;
|
|
1699
|
-
} catch (_) {
|
|
1700
|
-
result = false;
|
|
1701
|
-
}
|
|
1702
|
-
const ret = result;
|
|
2023
|
+
export function __wbg_newwithu8arraysequence_1e24f242a67f6fdd() { return handleError(function (arg0) {
|
|
2024
|
+
const ret = new Blob(arg0);
|
|
1703
2025
|
return ret;
|
|
1704
|
-
};
|
|
2026
|
+
}, arguments) };
|
|
1705
2027
|
|
|
1706
|
-
export function
|
|
1707
|
-
const ret =
|
|
1708
|
-
return
|
|
2028
|
+
export function __wbg_newwithu8arraysequenceandoptions_068570c487f69127() { return handleError(function (arg0, arg1) {
|
|
2029
|
+
const ret = new Blob(arg0, arg1);
|
|
2030
|
+
return ret;
|
|
2031
|
+
}, arguments) };
|
|
2032
|
+
|
|
2033
|
+
export function __wbg_next_25feadfc0913fea9(arg0) {
|
|
2034
|
+
const ret = arg0.next;
|
|
2035
|
+
return ret;
|
|
1709
2036
|
};
|
|
1710
2037
|
|
|
1711
|
-
export function
|
|
1712
|
-
const ret =
|
|
2038
|
+
export function __wbg_next_6574e1a8a62d1055() { return handleError(function (arg0) {
|
|
2039
|
+
const ret = arg0.next();
|
|
1713
2040
|
return ret;
|
|
1714
2041
|
}, arguments) };
|
|
1715
2042
|
|
|
1716
|
-
export function
|
|
1717
|
-
|
|
1718
|
-
try {
|
|
1719
|
-
result = getObject(arg0) instanceof WorkerGlobalScope;
|
|
1720
|
-
} catch (_) {
|
|
1721
|
-
result = false;
|
|
1722
|
-
}
|
|
1723
|
-
const ret = result;
|
|
2043
|
+
export function __wbg_node_6d722617e26f29f2(arg0) {
|
|
2044
|
+
const ret = arg0.node;
|
|
1724
2045
|
return ret;
|
|
1725
2046
|
};
|
|
1726
2047
|
|
|
1727
|
-
export function
|
|
1728
|
-
const ret =
|
|
1729
|
-
return
|
|
2048
|
+
export function __wbg_now_807e54c39636c349() {
|
|
2049
|
+
const ret = Date.now();
|
|
2050
|
+
return ret;
|
|
1730
2051
|
};
|
|
1731
2052
|
|
|
1732
|
-
export function
|
|
1733
|
-
const ret =
|
|
1734
|
-
return
|
|
2053
|
+
export function __wbg_objectStoreNames_9bb1ab04a7012aaf(arg0) {
|
|
2054
|
+
const ret = arg0.objectStoreNames;
|
|
2055
|
+
return ret;
|
|
1735
2056
|
};
|
|
1736
2057
|
|
|
1737
|
-
export function
|
|
1738
|
-
const ret =
|
|
1739
|
-
return
|
|
2058
|
+
export function __wbg_objectStore_21878d46d25b64b6() { return handleError(function (arg0, arg1, arg2) {
|
|
2059
|
+
const ret = arg0.objectStore(getStringFromWasm0(arg1, arg2));
|
|
2060
|
+
return ret;
|
|
1740
2061
|
}, arguments) };
|
|
1741
2062
|
|
|
1742
|
-
export function
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
export function __wbg_new_a979e9eedc5e81a3() { return handleError(function () {
|
|
1747
|
-
const ret = new Headers();
|
|
1748
|
-
return addHeapObject(ret);
|
|
2063
|
+
export function __wbg_open_88b1390d99a7c691() { return handleError(function (arg0, arg1, arg2) {
|
|
2064
|
+
const ret = arg0.open(getStringFromWasm0(arg1, arg2));
|
|
2065
|
+
return ret;
|
|
1749
2066
|
}, arguments) };
|
|
1750
2067
|
|
|
1751
|
-
export function
|
|
1752
|
-
|
|
2068
|
+
export function __wbg_open_e0c0b2993eb596e1() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
2069
|
+
const ret = arg0.open(getStringFromWasm0(arg1, arg2), arg3 >>> 0);
|
|
2070
|
+
return ret;
|
|
1753
2071
|
}, arguments) };
|
|
1754
2072
|
|
|
1755
|
-
export function
|
|
1756
|
-
|
|
1757
|
-
|
|
2073
|
+
export function __wbg_process_d9ea7ce819197991(arg0) {
|
|
2074
|
+
const ret = arg0.process;
|
|
2075
|
+
return ret;
|
|
2076
|
+
};
|
|
1758
2077
|
|
|
1759
|
-
export function
|
|
1760
|
-
const ret =
|
|
1761
|
-
return
|
|
1762
|
-
}
|
|
2078
|
+
export function __wbg_push_737cfc8c1432c2c6(arg0, arg1) {
|
|
2079
|
+
const ret = arg0.push(arg1);
|
|
2080
|
+
return ret;
|
|
2081
|
+
};
|
|
1763
2082
|
|
|
1764
|
-
export function
|
|
1765
|
-
|
|
2083
|
+
export function __wbg_put_066faa31a6a88f5b() { return handleError(function (arg0, arg1, arg2) {
|
|
2084
|
+
const ret = arg0.put(arg1, arg2);
|
|
2085
|
+
return ret;
|
|
1766
2086
|
}, arguments) };
|
|
1767
2087
|
|
|
1768
|
-
export function
|
|
1769
|
-
|
|
2088
|
+
export function __wbg_put_9ef5363941008835() { return handleError(function (arg0, arg1) {
|
|
2089
|
+
const ret = arg0.put(arg1);
|
|
2090
|
+
return ret;
|
|
1770
2091
|
}, arguments) };
|
|
1771
2092
|
|
|
1772
|
-
export function
|
|
1773
|
-
|
|
1774
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1775
|
-
const len1 = WASM_VECTOR_LEN;
|
|
1776
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1777
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
2093
|
+
export function __wbg_queueMicrotask_97d92b4fcc8a61c5(arg0) {
|
|
2094
|
+
queueMicrotask(arg0);
|
|
1778
2095
|
};
|
|
1779
2096
|
|
|
1780
|
-
export function
|
|
1781
|
-
|
|
2097
|
+
export function __wbg_queueMicrotask_d3219def82552485(arg0) {
|
|
2098
|
+
const ret = arg0.queueMicrotask;
|
|
2099
|
+
return ret;
|
|
1782
2100
|
};
|
|
1783
2101
|
|
|
1784
|
-
export function
|
|
1785
|
-
|
|
1786
|
-
return addHeapObject(ret);
|
|
1787
|
-
}, arguments) };
|
|
1788
|
-
|
|
1789
|
-
export function __wbg_new_26bb7e688dfc365c() { return handleError(function () {
|
|
1790
|
-
const ret = new URLSearchParams();
|
|
1791
|
-
return addHeapObject(ret);
|
|
2102
|
+
export function __wbg_randomFillSync_e2ae5c896c5ec592() { return handleError(function (arg0, arg1) {
|
|
2103
|
+
arg0.randomFillSync(arg1);
|
|
1792
2104
|
}, arguments) };
|
|
1793
2105
|
|
|
1794
|
-
export function
|
|
1795
|
-
const ret =
|
|
1796
|
-
return
|
|
2106
|
+
export function __wbg_require_d3a2417979c32e11() { return handleError(function () {
|
|
2107
|
+
const ret = module.require;
|
|
2108
|
+
return ret;
|
|
1797
2109
|
}, arguments) };
|
|
1798
2110
|
|
|
1799
|
-
export function
|
|
1800
|
-
|
|
1801
|
-
try {
|
|
1802
|
-
result = getObject(arg0) instanceof Response;
|
|
1803
|
-
} catch (_) {
|
|
1804
|
-
result = false;
|
|
1805
|
-
}
|
|
1806
|
-
const ret = result;
|
|
2111
|
+
export function __wbg_resolve_4851785c9c5f573d(arg0) {
|
|
2112
|
+
const ret = Promise.resolve(arg0);
|
|
1807
2113
|
return ret;
|
|
1808
2114
|
};
|
|
1809
2115
|
|
|
1810
|
-
export function
|
|
1811
|
-
const ret =
|
|
2116
|
+
export function __wbg_result_f29afabdf2c05826() { return handleError(function (arg0) {
|
|
2117
|
+
const ret = arg0.result;
|
|
2118
|
+
return ret;
|
|
2119
|
+
}, arguments) };
|
|
2120
|
+
|
|
2121
|
+
export function __wbg_search_e0e79cfe010c5c23(arg0, arg1) {
|
|
2122
|
+
const ret = arg1.search;
|
|
1812
2123
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1813
2124
|
const len1 = WASM_VECTOR_LEN;
|
|
1814
|
-
|
|
1815
|
-
|
|
2125
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
2126
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1816
2127
|
};
|
|
1817
2128
|
|
|
1818
|
-
export function
|
|
1819
|
-
const ret =
|
|
2129
|
+
export function __wbg_setTimeout_f2fe5af8e3debeb3() { return handleError(function (arg0, arg1, arg2) {
|
|
2130
|
+
const ret = arg0.setTimeout(arg1, arg2);
|
|
1820
2131
|
return ret;
|
|
1821
|
-
};
|
|
2132
|
+
}, arguments) };
|
|
2133
|
+
|
|
2134
|
+
export function __wbg_set_11cd83f45504cedf() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
2135
|
+
arg0.set(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
|
|
2136
|
+
}, arguments) };
|
|
1822
2137
|
|
|
1823
|
-
export function
|
|
1824
|
-
|
|
1825
|
-
return addHeapObject(ret);
|
|
2138
|
+
export function __wbg_set_65595bdd868b3009(arg0, arg1, arg2) {
|
|
2139
|
+
arg0.set(arg1, arg2 >>> 0);
|
|
1826
2140
|
};
|
|
1827
2141
|
|
|
1828
|
-
export function
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
}, arguments) };
|
|
2142
|
+
export function __wbg_setautoincrement_8b4327709e9ee7d9(arg0, arg1) {
|
|
2143
|
+
arg0.autoIncrement = arg1 !== 0;
|
|
2144
|
+
};
|
|
1832
2145
|
|
|
1833
|
-
export function
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
}, arguments) };
|
|
2146
|
+
export function __wbg_setbody_5923b78a95eedf29(arg0, arg1) {
|
|
2147
|
+
arg0.body = arg1;
|
|
2148
|
+
};
|
|
1837
2149
|
|
|
1838
|
-
export function
|
|
1839
|
-
|
|
1840
|
-
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1841
|
-
const len1 = WASM_VECTOR_LEN;
|
|
1842
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1843
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
2150
|
+
export function __wbg_setcredentials_c3a22f1cd105a2c6(arg0, arg1) {
|
|
2151
|
+
arg0.credentials = __wbindgen_enum_RequestCredentials[arg1];
|
|
1844
2152
|
};
|
|
1845
2153
|
|
|
1846
|
-
export function
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
}, arguments) };
|
|
2154
|
+
export function __wbg_setheaders_834c0bdb6a8949ad(arg0, arg1) {
|
|
2155
|
+
arg0.headers = arg1;
|
|
2156
|
+
};
|
|
1850
2157
|
|
|
1851
|
-
export function
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
}, arguments) };
|
|
2158
|
+
export function __wbg_setkeypath_691179e313c26ae1(arg0, arg1) {
|
|
2159
|
+
arg0.keyPath = arg1;
|
|
2160
|
+
};
|
|
1855
2161
|
|
|
1856
|
-
export function
|
|
1857
|
-
|
|
1858
|
-
return addHeapObject(ret);
|
|
2162
|
+
export function __wbg_setmethod_3c5280fe5d890842(arg0, arg1, arg2) {
|
|
2163
|
+
arg0.method = getStringFromWasm0(arg1, arg2);
|
|
1859
2164
|
};
|
|
1860
2165
|
|
|
1861
|
-
export function
|
|
1862
|
-
|
|
1863
|
-
return addHeapObject(ret);
|
|
2166
|
+
export function __wbg_setmode_5dc300b865044b65(arg0, arg1) {
|
|
2167
|
+
arg0.mode = __wbindgen_enum_RequestMode[arg1];
|
|
1864
2168
|
};
|
|
1865
2169
|
|
|
1866
|
-
export function
|
|
1867
|
-
|
|
1868
|
-
return addHeapObject(ret);
|
|
2170
|
+
export function __wbg_setmultientry_4c4eee871f29837a(arg0, arg1) {
|
|
2171
|
+
arg0.multiEntry = arg1 !== 0;
|
|
1869
2172
|
};
|
|
1870
2173
|
|
|
1871
|
-
export function
|
|
1872
|
-
|
|
1873
|
-
return addHeapObject(ret);
|
|
2174
|
+
export function __wbg_setonabort_3bf4db6614fa98e9(arg0, arg1) {
|
|
2175
|
+
arg0.onabort = arg1;
|
|
1874
2176
|
};
|
|
1875
2177
|
|
|
1876
|
-
export function
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
}, arguments) };
|
|
2178
|
+
export function __wbg_setoncomplete_4d19df0dadb7c4d4(arg0, arg1) {
|
|
2179
|
+
arg0.oncomplete = arg1;
|
|
2180
|
+
};
|
|
1880
2181
|
|
|
1881
|
-
export function
|
|
1882
|
-
|
|
1883
|
-
return addHeapObject(ret);
|
|
2182
|
+
export function __wbg_setonerror_b0d9d723b8fddbbb(arg0, arg1) {
|
|
2183
|
+
arg0.onerror = arg1;
|
|
1884
2184
|
};
|
|
1885
2185
|
|
|
1886
|
-
export function
|
|
1887
|
-
|
|
1888
|
-
}
|
|
2186
|
+
export function __wbg_setonerror_d7e3056cc6e56085(arg0, arg1) {
|
|
2187
|
+
arg0.onerror = arg1;
|
|
2188
|
+
};
|
|
1889
2189
|
|
|
1890
|
-
export function
|
|
1891
|
-
|
|
1892
|
-
}
|
|
2190
|
+
export function __wbg_setonsuccess_afa464ee777a396d(arg0, arg1) {
|
|
2191
|
+
arg0.onsuccess = arg1;
|
|
2192
|
+
};
|
|
1893
2193
|
|
|
1894
|
-
export function
|
|
1895
|
-
|
|
1896
|
-
return addHeapObject(ret);
|
|
2194
|
+
export function __wbg_setonupgradeneeded_fcf7ce4f2eb0cb5f(arg0, arg1) {
|
|
2195
|
+
arg0.onupgradeneeded = arg1;
|
|
1897
2196
|
};
|
|
1898
2197
|
|
|
1899
|
-
export function
|
|
1900
|
-
|
|
1901
|
-
return ret;
|
|
2198
|
+
export function __wbg_setonversionchange_6ee07fa49ee1e3a5(arg0, arg1) {
|
|
2199
|
+
arg0.onversionchange = arg1;
|
|
1902
2200
|
};
|
|
1903
2201
|
|
|
1904
|
-
export function
|
|
1905
|
-
|
|
1906
|
-
return addHeapObject(ret);
|
|
2202
|
+
export function __wbg_setsearch_609451e9e712f3c6(arg0, arg1, arg2) {
|
|
2203
|
+
arg0.search = getStringFromWasm0(arg1, arg2);
|
|
1907
2204
|
};
|
|
1908
2205
|
|
|
1909
|
-
export function
|
|
1910
|
-
|
|
1911
|
-
return addHeapObject(ret);
|
|
2206
|
+
export function __wbg_setsignal_75b21ef3a81de905(arg0, arg1) {
|
|
2207
|
+
arg0.signal = arg1;
|
|
1912
2208
|
};
|
|
1913
2209
|
|
|
1914
|
-
export function
|
|
1915
|
-
|
|
1916
|
-
return addHeapObject(ret);
|
|
2210
|
+
export function __wbg_settype_39ed370d3edd403c(arg0, arg1, arg2) {
|
|
2211
|
+
arg0.type = getStringFromWasm0(arg1, arg2);
|
|
1917
2212
|
};
|
|
1918
2213
|
|
|
1919
|
-
export function
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
}, arguments) };
|
|
2214
|
+
export function __wbg_setunique_dd24c422aa05df89(arg0, arg1) {
|
|
2215
|
+
arg0.unique = arg1 !== 0;
|
|
2216
|
+
};
|
|
1923
2217
|
|
|
1924
|
-
export function
|
|
1925
|
-
const ret =
|
|
2218
|
+
export function __wbg_signal_aaf9ad74119f20a4(arg0) {
|
|
2219
|
+
const ret = arg0.signal;
|
|
1926
2220
|
return ret;
|
|
1927
2221
|
};
|
|
1928
2222
|
|
|
1929
|
-
export function
|
|
1930
|
-
const ret =
|
|
1931
|
-
|
|
2223
|
+
export function __wbg_stack_0ed75d68575b0f3c(arg0, arg1) {
|
|
2224
|
+
const ret = arg1.stack;
|
|
2225
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2226
|
+
const len1 = WASM_VECTOR_LEN;
|
|
2227
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
2228
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
1932
2229
|
};
|
|
1933
2230
|
|
|
1934
|
-
export function
|
|
1935
|
-
const ret =
|
|
1936
|
-
return
|
|
2231
|
+
export function __wbg_static_accessor_GLOBAL_88a902d13a557d07() {
|
|
2232
|
+
const ret = typeof global === 'undefined' ? null : global;
|
|
2233
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1937
2234
|
};
|
|
1938
2235
|
|
|
1939
|
-
export function
|
|
1940
|
-
const ret =
|
|
1941
|
-
return
|
|
1942
|
-
}
|
|
2236
|
+
export function __wbg_static_accessor_GLOBAL_THIS_56578be7e9f832b0() {
|
|
2237
|
+
const ret = typeof globalThis === 'undefined' ? null : globalThis;
|
|
2238
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
2239
|
+
};
|
|
1943
2240
|
|
|
1944
|
-
export function
|
|
1945
|
-
const ret =
|
|
1946
|
-
return
|
|
1947
|
-
}
|
|
2241
|
+
export function __wbg_static_accessor_SELF_37c5d418e4bf5819() {
|
|
2242
|
+
const ret = typeof self === 'undefined' ? null : self;
|
|
2243
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
2244
|
+
};
|
|
1948
2245
|
|
|
1949
|
-
export function
|
|
1950
|
-
const ret =
|
|
1951
|
-
return
|
|
2246
|
+
export function __wbg_static_accessor_WINDOW_5de37043a91a9c40() {
|
|
2247
|
+
const ret = typeof window === 'undefined' ? null : window;
|
|
2248
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
1952
2249
|
};
|
|
1953
2250
|
|
|
1954
|
-
export function
|
|
1955
|
-
const ret =
|
|
1956
|
-
return
|
|
1957
|
-
}
|
|
2251
|
+
export function __wbg_status_f6360336ca686bf0(arg0) {
|
|
2252
|
+
const ret = arg0.status;
|
|
2253
|
+
return ret;
|
|
2254
|
+
};
|
|
1958
2255
|
|
|
1959
|
-
export function
|
|
1960
|
-
const ret =
|
|
1961
|
-
return
|
|
2256
|
+
export function __wbg_stringify_f7ed6987935b4a24() { return handleError(function (arg0) {
|
|
2257
|
+
const ret = JSON.stringify(arg0);
|
|
2258
|
+
return ret;
|
|
1962
2259
|
}, arguments) };
|
|
1963
2260
|
|
|
1964
|
-
export function
|
|
1965
|
-
const ret =
|
|
1966
|
-
return
|
|
1967
|
-
}
|
|
2261
|
+
export function __wbg_subarray_aa9065fa9dc5df96(arg0, arg1, arg2) {
|
|
2262
|
+
const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
|
|
2263
|
+
return ret;
|
|
2264
|
+
};
|
|
2265
|
+
|
|
2266
|
+
export function __wbg_target_0a62d9d79a2a1ede(arg0) {
|
|
2267
|
+
const ret = arg0.target;
|
|
2268
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
2269
|
+
};
|
|
1968
2270
|
|
|
1969
|
-
export function
|
|
1970
|
-
const ret =
|
|
1971
|
-
return
|
|
2271
|
+
export function __wbg_text_7805bea50de2af49() { return handleError(function (arg0) {
|
|
2272
|
+
const ret = arg0.text();
|
|
2273
|
+
return ret;
|
|
1972
2274
|
}, arguments) };
|
|
1973
2275
|
|
|
1974
|
-
export function
|
|
1975
|
-
const ret =
|
|
2276
|
+
export function __wbg_then_44b73946d2fb3e7d(arg0, arg1) {
|
|
2277
|
+
const ret = arg0.then(arg1);
|
|
1976
2278
|
return ret;
|
|
1977
2279
|
};
|
|
1978
2280
|
|
|
1979
|
-
export function
|
|
1980
|
-
const ret =
|
|
2281
|
+
export function __wbg_then_48b406749878a531(arg0, arg1, arg2) {
|
|
2282
|
+
const ret = arg0.then(arg1, arg2);
|
|
1981
2283
|
return ret;
|
|
1982
2284
|
};
|
|
1983
2285
|
|
|
1984
|
-
export function
|
|
1985
|
-
|
|
1986
|
-
try {
|
|
1987
|
-
result = getObject(arg0) instanceof ArrayBuffer;
|
|
1988
|
-
} catch (_) {
|
|
1989
|
-
result = false;
|
|
1990
|
-
}
|
|
1991
|
-
const ret = result;
|
|
2286
|
+
export function __wbg_toString_5285597960676b7b(arg0) {
|
|
2287
|
+
const ret = arg0.toString();
|
|
1992
2288
|
return ret;
|
|
1993
2289
|
};
|
|
1994
2290
|
|
|
1995
|
-
export function
|
|
1996
|
-
|
|
1997
|
-
try {
|
|
1998
|
-
result = getObject(arg0) instanceof Error;
|
|
1999
|
-
} catch (_) {
|
|
2000
|
-
result = false;
|
|
2001
|
-
}
|
|
2002
|
-
const ret = result;
|
|
2291
|
+
export function __wbg_toString_c813bbd34d063839(arg0) {
|
|
2292
|
+
const ret = arg0.toString();
|
|
2003
2293
|
return ret;
|
|
2004
2294
|
};
|
|
2005
2295
|
|
|
2006
|
-
export function
|
|
2007
|
-
|
|
2008
|
-
|
|
2296
|
+
export function __wbg_trace_4f64f498ecbfeea8(arg0, arg1) {
|
|
2297
|
+
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
2298
|
+
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
2299
|
+
console.trace(...v0);
|
|
2009
2300
|
};
|
|
2010
2301
|
|
|
2011
|
-
export function
|
|
2012
|
-
const ret =
|
|
2013
|
-
return
|
|
2302
|
+
export function __wbg_transaction_d6d07c3c9963c49e() { return handleError(function (arg0, arg1, arg2) {
|
|
2303
|
+
const ret = arg0.transaction(arg1, __wbindgen_enum_IdbTransactionMode[arg2]);
|
|
2304
|
+
return ret;
|
|
2305
|
+
}, arguments) };
|
|
2306
|
+
|
|
2307
|
+
export function __wbg_transaction_e713aa7b07ccaedd(arg0) {
|
|
2308
|
+
const ret = arg0.transaction;
|
|
2309
|
+
return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
|
|
2014
2310
|
};
|
|
2015
2311
|
|
|
2016
|
-
export function
|
|
2017
|
-
const ret =
|
|
2018
|
-
return
|
|
2312
|
+
export function __wbg_unique_23ddfed89bddb31d(arg0) {
|
|
2313
|
+
const ret = arg0.unique;
|
|
2314
|
+
return ret;
|
|
2019
2315
|
};
|
|
2020
2316
|
|
|
2021
|
-
export function
|
|
2022
|
-
const ret =
|
|
2023
|
-
|
|
2024
|
-
|
|
2317
|
+
export function __wbg_url_8f9653b899456042(arg0, arg1) {
|
|
2318
|
+
const ret = arg1.url;
|
|
2319
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2320
|
+
const len1 = WASM_VECTOR_LEN;
|
|
2321
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
2322
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2323
|
+
};
|
|
2324
|
+
|
|
2325
|
+
export function __wbg_url_ae10c34ca209681d(arg0, arg1) {
|
|
2326
|
+
const ret = arg1.url;
|
|
2327
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2328
|
+
const len1 = WASM_VECTOR_LEN;
|
|
2329
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
2330
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2331
|
+
};
|
|
2025
2332
|
|
|
2026
|
-
export function
|
|
2027
|
-
const ret =
|
|
2333
|
+
export function __wbg_value_cd1ffa7b1ab794f1(arg0) {
|
|
2334
|
+
const ret = arg0.value;
|
|
2028
2335
|
return ret;
|
|
2029
2336
|
};
|
|
2030
2337
|
|
|
2031
|
-
export function
|
|
2032
|
-
const ret =
|
|
2338
|
+
export function __wbg_versions_c8e8bcb59a0bf647(arg0) {
|
|
2339
|
+
const ret = arg0.versions;
|
|
2033
2340
|
return ret;
|
|
2034
2341
|
};
|
|
2035
2342
|
|
|
2036
|
-
export function
|
|
2037
|
-
|
|
2038
|
-
|
|
2343
|
+
export function __wbg_warn_1529a2c662795cd8(arg0, arg1) {
|
|
2344
|
+
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
2345
|
+
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
2346
|
+
console.warn(...v0);
|
|
2039
2347
|
};
|
|
2040
2348
|
|
|
2041
|
-
export function
|
|
2042
|
-
const ret =
|
|
2349
|
+
export function __wbindgen_as_number(arg0) {
|
|
2350
|
+
const ret = +arg0;
|
|
2351
|
+
return ret;
|
|
2352
|
+
};
|
|
2353
|
+
|
|
2354
|
+
export function __wbindgen_bigint_from_i64(arg0) {
|
|
2355
|
+
const ret = arg0;
|
|
2043
2356
|
return ret;
|
|
2044
2357
|
};
|
|
2045
2358
|
|
|
2046
|
-
export function
|
|
2047
|
-
const ret =
|
|
2048
|
-
return
|
|
2359
|
+
export function __wbindgen_bigint_from_u64(arg0) {
|
|
2360
|
+
const ret = BigInt.asUintN(64, arg0);
|
|
2361
|
+
return ret;
|
|
2049
2362
|
};
|
|
2050
2363
|
|
|
2051
|
-
export function
|
|
2052
|
-
const
|
|
2053
|
-
|
|
2364
|
+
export function __wbindgen_bigint_get_as_i64(arg0, arg1) {
|
|
2365
|
+
const v = arg1;
|
|
2366
|
+
const ret = typeof(v) === 'bigint' ? v : undefined;
|
|
2367
|
+
getDataViewMemory0().setBigInt64(arg0 + 8 * 1, isLikeNone(ret) ? BigInt(0) : ret, true);
|
|
2368
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
2054
2369
|
};
|
|
2055
2370
|
|
|
2056
|
-
export function
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
};
|
|
2068
|
-
const ret = new Promise(cb0);
|
|
2069
|
-
return addHeapObject(ret);
|
|
2070
|
-
} finally {
|
|
2071
|
-
state0.a = state0.b = 0;
|
|
2371
|
+
export function __wbindgen_boolean_get(arg0) {
|
|
2372
|
+
const v = arg0;
|
|
2373
|
+
const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
|
|
2374
|
+
return ret;
|
|
2375
|
+
};
|
|
2376
|
+
|
|
2377
|
+
export function __wbindgen_cb_drop(arg0) {
|
|
2378
|
+
const obj = arg0.original;
|
|
2379
|
+
if (obj.cnt-- == 1) {
|
|
2380
|
+
obj.a = 0;
|
|
2381
|
+
return true;
|
|
2072
2382
|
}
|
|
2383
|
+
const ret = false;
|
|
2384
|
+
return ret;
|
|
2385
|
+
};
|
|
2386
|
+
|
|
2387
|
+
export function __wbindgen_closure_wrapper11505(arg0, arg1, arg2) {
|
|
2388
|
+
const ret = makeMutClosure(arg0, arg1, 2669, __wbg_adapter_60);
|
|
2389
|
+
return ret;
|
|
2073
2390
|
};
|
|
2074
2391
|
|
|
2075
|
-
export function
|
|
2076
|
-
const ret =
|
|
2077
|
-
return
|
|
2392
|
+
export function __wbindgen_closure_wrapper16024(arg0, arg1, arg2) {
|
|
2393
|
+
const ret = makeMutClosure(arg0, arg1, 3835, __wbg_adapter_63);
|
|
2394
|
+
return ret;
|
|
2078
2395
|
};
|
|
2079
2396
|
|
|
2080
|
-
export function
|
|
2081
|
-
const ret =
|
|
2082
|
-
return
|
|
2397
|
+
export function __wbindgen_closure_wrapper7626(arg0, arg1, arg2) {
|
|
2398
|
+
const ret = makeMutClosure(arg0, arg1, 1856, __wbg_adapter_54);
|
|
2399
|
+
return ret;
|
|
2083
2400
|
};
|
|
2084
2401
|
|
|
2085
|
-
export function
|
|
2086
|
-
const ret =
|
|
2087
|
-
return
|
|
2402
|
+
export function __wbindgen_closure_wrapper8074(arg0, arg1, arg2) {
|
|
2403
|
+
const ret = makeMutClosure(arg0, arg1, 1998, __wbg_adapter_57);
|
|
2404
|
+
return ret;
|
|
2088
2405
|
};
|
|
2089
2406
|
|
|
2090
|
-
export function
|
|
2091
|
-
const ret =
|
|
2092
|
-
|
|
2407
|
+
export function __wbindgen_debug_string(arg0, arg1) {
|
|
2408
|
+
const ret = debugString(arg1);
|
|
2409
|
+
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2410
|
+
const len1 = WASM_VECTOR_LEN;
|
|
2411
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
2412
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2093
2413
|
};
|
|
2094
2414
|
|
|
2095
|
-
export function
|
|
2096
|
-
const ret =
|
|
2097
|
-
return
|
|
2415
|
+
export function __wbindgen_error_new(arg0, arg1) {
|
|
2416
|
+
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
2417
|
+
return ret;
|
|
2098
2418
|
};
|
|
2099
2419
|
|
|
2100
|
-
export function
|
|
2101
|
-
const ret =
|
|
2102
|
-
return
|
|
2420
|
+
export function __wbindgen_in(arg0, arg1) {
|
|
2421
|
+
const ret = arg0 in arg1;
|
|
2422
|
+
return ret;
|
|
2103
2423
|
};
|
|
2104
2424
|
|
|
2105
|
-
export function
|
|
2106
|
-
const
|
|
2107
|
-
|
|
2425
|
+
export function __wbindgen_init_externref_table() {
|
|
2426
|
+
const table = wasm.__wbindgen_export_4;
|
|
2427
|
+
const offset = table.grow(4);
|
|
2428
|
+
table.set(0, undefined);
|
|
2429
|
+
table.set(offset + 0, undefined);
|
|
2430
|
+
table.set(offset + 1, null);
|
|
2431
|
+
table.set(offset + 2, true);
|
|
2432
|
+
table.set(offset + 3, false);
|
|
2433
|
+
;
|
|
2108
2434
|
};
|
|
2109
2435
|
|
|
2110
|
-
export function
|
|
2111
|
-
const ret =
|
|
2112
|
-
return
|
|
2436
|
+
export function __wbindgen_is_bigint(arg0) {
|
|
2437
|
+
const ret = typeof(arg0) === 'bigint';
|
|
2438
|
+
return ret;
|
|
2113
2439
|
};
|
|
2114
2440
|
|
|
2115
|
-
export function
|
|
2116
|
-
|
|
2441
|
+
export function __wbindgen_is_function(arg0) {
|
|
2442
|
+
const ret = typeof(arg0) === 'function';
|
|
2443
|
+
return ret;
|
|
2117
2444
|
};
|
|
2118
2445
|
|
|
2119
|
-
export function
|
|
2120
|
-
const ret =
|
|
2446
|
+
export function __wbindgen_is_null(arg0) {
|
|
2447
|
+
const ret = arg0 === null;
|
|
2121
2448
|
return ret;
|
|
2122
2449
|
};
|
|
2123
2450
|
|
|
2124
|
-
export function
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
result = getObject(arg0) instanceof Uint8Array;
|
|
2128
|
-
} catch (_) {
|
|
2129
|
-
result = false;
|
|
2130
|
-
}
|
|
2131
|
-
const ret = result;
|
|
2451
|
+
export function __wbindgen_is_object(arg0) {
|
|
2452
|
+
const val = arg0;
|
|
2453
|
+
const ret = typeof(val) === 'object' && val !== null;
|
|
2132
2454
|
return ret;
|
|
2133
2455
|
};
|
|
2134
2456
|
|
|
2135
|
-
export function
|
|
2136
|
-
const ret =
|
|
2137
|
-
return
|
|
2457
|
+
export function __wbindgen_is_string(arg0) {
|
|
2458
|
+
const ret = typeof(arg0) === 'string';
|
|
2459
|
+
return ret;
|
|
2138
2460
|
};
|
|
2139
2461
|
|
|
2140
|
-
export function
|
|
2141
|
-
const ret =
|
|
2142
|
-
return
|
|
2462
|
+
export function __wbindgen_is_undefined(arg0) {
|
|
2463
|
+
const ret = arg0 === undefined;
|
|
2464
|
+
return ret;
|
|
2143
2465
|
};
|
|
2144
2466
|
|
|
2145
|
-
export function
|
|
2146
|
-
const ret =
|
|
2467
|
+
export function __wbindgen_jsval_eq(arg0, arg1) {
|
|
2468
|
+
const ret = arg0 === arg1;
|
|
2147
2469
|
return ret;
|
|
2148
|
-
}
|
|
2470
|
+
};
|
|
2149
2471
|
|
|
2150
|
-
export function
|
|
2151
|
-
const ret =
|
|
2472
|
+
export function __wbindgen_jsval_loose_eq(arg0, arg1) {
|
|
2473
|
+
const ret = arg0 == arg1;
|
|
2152
2474
|
return ret;
|
|
2153
|
-
}
|
|
2475
|
+
};
|
|
2154
2476
|
|
|
2155
|
-
export function
|
|
2156
|
-
const ret =
|
|
2157
|
-
return
|
|
2158
|
-
}
|
|
2477
|
+
export function __wbindgen_memory() {
|
|
2478
|
+
const ret = wasm.memory;
|
|
2479
|
+
return ret;
|
|
2480
|
+
};
|
|
2159
2481
|
|
|
2160
|
-
export function
|
|
2161
|
-
const
|
|
2162
|
-
const ret = typeof(
|
|
2163
|
-
|
|
2164
|
-
|
|
2482
|
+
export function __wbindgen_number_get(arg0, arg1) {
|
|
2483
|
+
const obj = arg1;
|
|
2484
|
+
const ret = typeof(obj) === 'number' ? obj : undefined;
|
|
2485
|
+
getDataViewMemory0().setFloat64(arg0 + 8 * 1, isLikeNone(ret) ? 0 : ret, true);
|
|
2486
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, !isLikeNone(ret), true);
|
|
2165
2487
|
};
|
|
2166
2488
|
|
|
2167
|
-
export function
|
|
2168
|
-
const ret =
|
|
2169
|
-
|
|
2170
|
-
const len1 = WASM_VECTOR_LEN;
|
|
2171
|
-
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
2172
|
-
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
2489
|
+
export function __wbindgen_number_new(arg0) {
|
|
2490
|
+
const ret = arg0;
|
|
2491
|
+
return ret;
|
|
2173
2492
|
};
|
|
2174
2493
|
|
|
2175
|
-
export function
|
|
2176
|
-
|
|
2494
|
+
export function __wbindgen_string_get(arg0, arg1) {
|
|
2495
|
+
const obj = arg1;
|
|
2496
|
+
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
2497
|
+
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
2498
|
+
var len1 = WASM_VECTOR_LEN;
|
|
2499
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
2500
|
+
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
2177
2501
|
};
|
|
2178
2502
|
|
|
2179
|
-
export function
|
|
2180
|
-
const ret =
|
|
2181
|
-
return
|
|
2503
|
+
export function __wbindgen_string_new(arg0, arg1) {
|
|
2504
|
+
const ret = getStringFromWasm0(arg0, arg1);
|
|
2505
|
+
return ret;
|
|
2182
2506
|
};
|
|
2183
2507
|
|
|
2184
|
-
export function
|
|
2185
|
-
|
|
2186
|
-
return addHeapObject(ret);
|
|
2508
|
+
export function __wbindgen_throw(arg0, arg1) {
|
|
2509
|
+
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
2187
2510
|
};
|
|
2188
2511
|
|