@cartridge/controller-wasm 0.2.1 → 0.2.3
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/package.json +1 -1
- package/pkg-controller/account_wasm.d.ts +2 -1
- package/pkg-controller/account_wasm_bg.js +30 -8
- package/pkg-controller/account_wasm_bg.wasm +0 -0
- package/pkg-session/session_wasm.d.ts +1 -0
- package/pkg-session/session_wasm_bg.js +4 -4
- package/pkg-session/session_wasm_bg.wasm +0 -0
package/package.json
CHANGED
|
@@ -139,6 +139,7 @@ export interface Eip191Signer {
|
|
|
139
139
|
}
|
|
140
140
|
|
|
141
141
|
export interface Signer {
|
|
142
|
+
webauthns?: WebauthnSigner[];
|
|
142
143
|
webauthn?: WebauthnSigner;
|
|
143
144
|
starknet?: StarknetSigner;
|
|
144
145
|
eip191?: Eip191Signer;
|
|
@@ -198,7 +199,7 @@ export class CartridgeAccount {
|
|
|
198
199
|
registerSession(policies: Policy[], expires_at: bigint, public_key: JsFelt, max_fee?: JsFeeEstimate | null): Promise<any>;
|
|
199
200
|
registerSessionCalldata(policies: Policy[], expires_at: bigint, public_key: JsFelt): Promise<any>;
|
|
200
201
|
upgrade(new_class_hash: JsFelt): Promise<JsCall>;
|
|
201
|
-
login(expires_at: bigint, is_controller_registered?: boolean | null): Promise<AuthorizedSession>;
|
|
202
|
+
login(expires_at: bigint, is_controller_registered?: boolean | null, signers?: Signer | null): Promise<AuthorizedSession>;
|
|
202
203
|
register(register: JsRegister): Promise<JsRegisterResponse>;
|
|
203
204
|
createSession(policies: Policy[], expires_at: bigint): Promise<AuthorizedSession | undefined>;
|
|
204
205
|
skipSession(policies: Policy[]): Promise<void>;
|
|
@@ -289,7 +289,7 @@ function __wbg_adapter_47(arg0, arg1, arg2) {
|
|
|
289
289
|
wasm.__wbindgen_export_6(arg0, arg1, addHeapObject(arg2));
|
|
290
290
|
}
|
|
291
291
|
|
|
292
|
-
function
|
|
292
|
+
function __wbg_adapter_259(arg0, arg1, arg2, arg3) {
|
|
293
293
|
wasm.__wbindgen_export_7(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
|
|
294
294
|
}
|
|
295
295
|
|
|
@@ -500,10 +500,11 @@ export class CartridgeAccount {
|
|
|
500
500
|
/**
|
|
501
501
|
* @param {bigint} expires_at
|
|
502
502
|
* @param {boolean | null} [is_controller_registered]
|
|
503
|
+
* @param {Signer | null} [signers]
|
|
503
504
|
* @returns {Promise<AuthorizedSession>}
|
|
504
505
|
*/
|
|
505
|
-
login(expires_at, is_controller_registered) {
|
|
506
|
-
const ret = wasm.cartridgeaccount_login(this.__wbg_ptr, expires_at, isLikeNone(is_controller_registered) ? 0xFFFFFF : is_controller_registered ? 1 : 0);
|
|
506
|
+
login(expires_at, is_controller_registered, signers) {
|
|
507
|
+
const ret = wasm.cartridgeaccount_login(this.__wbg_ptr, expires_at, isLikeNone(is_controller_registered) ? 0xFFFFFF : is_controller_registered ? 1 : 0, isLikeNone(signers) ? 0 : addHeapObject(signers));
|
|
507
508
|
return takeObject(ret);
|
|
508
509
|
}
|
|
509
510
|
/**
|
|
@@ -1180,6 +1181,17 @@ export function __wbg_instanceof_Window_def73ea0955fc569(arg0) {
|
|
|
1180
1181
|
return ret;
|
|
1181
1182
|
};
|
|
1182
1183
|
|
|
1184
|
+
export function __wbg_instanceof_WorkerGlobalScope_dbdbdea7e3b56493(arg0) {
|
|
1185
|
+
let result;
|
|
1186
|
+
try {
|
|
1187
|
+
result = getObject(arg0) instanceof WorkerGlobalScope;
|
|
1188
|
+
} catch (_) {
|
|
1189
|
+
result = false;
|
|
1190
|
+
}
|
|
1191
|
+
const ret = result;
|
|
1192
|
+
return ret;
|
|
1193
|
+
};
|
|
1194
|
+
|
|
1183
1195
|
export function __wbg_iterator_9a24c88df860dc65() {
|
|
1184
1196
|
const ret = Symbol.iterator;
|
|
1185
1197
|
return addHeapObject(ret);
|
|
@@ -1236,7 +1248,7 @@ export function __wbg_new_23a2665fac83c611(arg0, arg1) {
|
|
|
1236
1248
|
const a = state0.a;
|
|
1237
1249
|
state0.a = 0;
|
|
1238
1250
|
try {
|
|
1239
|
-
return
|
|
1251
|
+
return __wbg_adapter_259(a, state0.b, arg0, arg1);
|
|
1240
1252
|
} finally {
|
|
1241
1253
|
state0.a = a;
|
|
1242
1254
|
}
|
|
@@ -1313,6 +1325,11 @@ export function __wbg_node_905d3e251edff8a2(arg0) {
|
|
|
1313
1325
|
return addHeapObject(ret);
|
|
1314
1326
|
};
|
|
1315
1327
|
|
|
1328
|
+
export function __wbg_now_807e54c39636c349() {
|
|
1329
|
+
const ret = Date.now();
|
|
1330
|
+
return ret;
|
|
1331
|
+
};
|
|
1332
|
+
|
|
1316
1333
|
export function __wbg_obtain_a9626b3b96e6dc2c(arg0) {
|
|
1317
1334
|
const ret = getObject(arg0).obtain();
|
|
1318
1335
|
return addHeapObject(ret);
|
|
@@ -1372,6 +1389,11 @@ export function __wbg_setTimeout_73ce8df12de4f2f2(arg0, arg1) {
|
|
|
1372
1389
|
return addHeapObject(ret);
|
|
1373
1390
|
};
|
|
1374
1391
|
|
|
1392
|
+
export function __wbg_setTimeout_b4ee584b3f982e97() { return handleError(function (arg0, arg1, arg2) {
|
|
1393
|
+
const ret = getObject(arg0).setTimeout(getObject(arg1), arg2);
|
|
1394
|
+
return ret;
|
|
1395
|
+
}, arguments) };
|
|
1396
|
+
|
|
1375
1397
|
export function __wbg_setTimeout_f2fe5af8e3debeb3() { return handleError(function (arg0, arg1, arg2) {
|
|
1376
1398
|
const ret = getObject(arg0).setTimeout(getObject(arg1), arg2);
|
|
1377
1399
|
return ret;
|
|
@@ -1539,13 +1561,13 @@ export function __wbindgen_cb_drop(arg0) {
|
|
|
1539
1561
|
return ret;
|
|
1540
1562
|
};
|
|
1541
1563
|
|
|
1542
|
-
export function
|
|
1543
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1564
|
+
export function __wbindgen_closure_wrapper5664(arg0, arg1, arg2) {
|
|
1565
|
+
const ret = makeMutClosure(arg0, arg1, 663, __wbg_adapter_44);
|
|
1544
1566
|
return addHeapObject(ret);
|
|
1545
1567
|
};
|
|
1546
1568
|
|
|
1547
|
-
export function
|
|
1548
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1569
|
+
export function __wbindgen_closure_wrapper5810(arg0, arg1, arg2) {
|
|
1570
|
+
const ret = makeMutClosure(arg0, arg1, 696, __wbg_adapter_47);
|
|
1549
1571
|
return addHeapObject(ret);
|
|
1550
1572
|
};
|
|
1551
1573
|
|
|
Binary file
|
|
@@ -1024,13 +1024,13 @@ export function __wbindgen_cb_drop(arg0) {
|
|
|
1024
1024
|
return ret;
|
|
1025
1025
|
};
|
|
1026
1026
|
|
|
1027
|
-
export function
|
|
1028
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1027
|
+
export function __wbindgen_closure_wrapper2845(arg0, arg1, arg2) {
|
|
1028
|
+
const ret = makeMutClosure(arg0, arg1, 363, __wbg_adapter_42);
|
|
1029
1029
|
return addHeapObject(ret);
|
|
1030
1030
|
};
|
|
1031
1031
|
|
|
1032
|
-
export function
|
|
1033
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1032
|
+
export function __wbindgen_closure_wrapper2978(arg0, arg1, arg2) {
|
|
1033
|
+
const ret = makeMutClosure(arg0, arg1, 396, __wbg_adapter_45);
|
|
1034
1034
|
return addHeapObject(ret);
|
|
1035
1035
|
};
|
|
1036
1036
|
|
|
Binary file
|