@crossmint/wallets-sdk 0.18.11 → 0.18.12
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/dist/api/client.cjs +4 -4
- package/dist/api/client.js +3 -3
- package/dist/api/index.cjs +4 -4
- package/dist/api/index.js +3 -3
- package/dist/{chunk-FQRYO6LZ.js → chunk-23HJV5QR.js} +2 -3
- package/dist/{chunk-UH62INDA.cjs → chunk-2YEF7ARX.cjs} +9 -9
- package/dist/{chunk-WRIOKE3W.cjs → chunk-3K3ZODTJ.cjs} +5 -6
- package/dist/{chunk-AJIUH7J4.js → chunk-EDVMJRYK.js} +2 -2
- package/dist/{chunk-QKDQHKDJ.cjs → chunk-EP3UIAFB.cjs} +38 -38
- package/dist/{chunk-EDBSUNF2.js → chunk-FYJW7Q2N.js} +1 -1
- package/dist/{chunk-XCBU56Z2.js → chunk-G2NUNSFB.js} +3 -3
- package/dist/{chunk-WACETVEE.cjs → chunk-IG557MDN.cjs} +7 -7
- package/dist/{chunk-WDYAGKXG.cjs → chunk-K45GD5NV.cjs} +12 -12
- package/dist/{chunk-HZKNKBU5.cjs → chunk-K4KXB2EM.cjs} +1 -1
- package/dist/{chunk-JFIN435P.js → chunk-LXWT2YKV.js} +2 -2
- package/dist/{chunk-UCHEZUU2.js → chunk-OZ5QGDNP.js} +2 -2
- package/dist/{chunk-PSKZR36J.cjs → chunk-QOBVGFJV.cjs} +9 -9
- package/dist/{chunk-66OKXCYL.js → chunk-SF4JGPRB.js} +2 -2
- package/dist/{chunk-THJFGWWT.cjs → chunk-SZCB7LEX.cjs} +17 -17
- package/dist/{chunk-GAGVFMN7.js → chunk-VBKKSVLN.js} +2 -2
- package/dist/{chunk-6DRR3LG4.js → chunk-VYVA567V.js} +2 -2
- package/dist/{chunk-KWII4S3U.cjs → chunk-WW2RXFIY.cjs} +21 -21
- package/dist/index.cjs +10 -10
- package/dist/index.js +9 -9
- package/dist/logger/index.cjs +3 -3
- package/dist/logger/index.js +2 -2
- package/dist/logger/init.cjs +3 -3
- package/dist/logger/init.js +2 -2
- package/dist/sdk.cjs +7 -7
- package/dist/sdk.js +6 -6
- package/dist/utils/constants.cjs +2 -2
- package/dist/utils/constants.js +1 -1
- package/dist/wallets/evm.cjs +5 -5
- package/dist/wallets/evm.js +4 -4
- package/dist/wallets/solana.cjs +5 -5
- package/dist/wallets/solana.js +4 -4
- package/dist/wallets/stellar.cjs +5 -5
- package/dist/wallets/stellar.js +4 -4
- package/dist/wallets/wallet-factory.cjs +5 -5
- package/dist/wallets/wallet-factory.js +4 -4
- package/dist/wallets/wallet.cjs +4 -4
- package/dist/wallets/wallet.js +3 -3
- package/package.json +3 -4
|
@@ -18,10 +18,10 @@ import {
|
|
|
18
18
|
} from "./chunk-SGINWAB6.js";
|
|
19
19
|
import {
|
|
20
20
|
walletsLogger
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-23HJV5QR.js";
|
|
22
22
|
import {
|
|
23
23
|
STATUS_POLLING_INTERVAL_MS
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-FYJW7Q2N.js";
|
|
25
25
|
import {
|
|
26
26
|
__async,
|
|
27
27
|
__decorateClass,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Wallet
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-LXWT2YKV.js";
|
|
4
4
|
import {
|
|
5
5
|
TransactionNotCreatedError
|
|
6
6
|
} from "./chunk-SGINWAB6.js";
|
|
7
7
|
import {
|
|
8
8
|
walletsLogger
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-23HJV5QR.js";
|
|
10
10
|
import {
|
|
11
11
|
__async,
|
|
12
12
|
__decorateClass
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkEP3UIAFBcjs = require('./chunk-EP3UIAFB.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
var _chunkXC2V34TScjs = require('./chunk-XC2V34TS.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunk3K3ZODTJcjs = require('./chunk-3K3ZODTJ.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
@@ -14,7 +14,7 @@ var _chunkUO2J2ZB2cjs = require('./chunk-UO2J2ZB2.cjs');
|
|
|
14
14
|
|
|
15
15
|
// src/wallets/stellar.ts
|
|
16
16
|
var _commonsdkbase = require('@crossmint/common-sdk-base');
|
|
17
|
-
var _StellarWallet = class _StellarWallet extends
|
|
17
|
+
var _StellarWallet = class _StellarWallet extends _chunkEP3UIAFBcjs.Wallet {
|
|
18
18
|
constructor(wallet) {
|
|
19
19
|
super(
|
|
20
20
|
{
|
|
@@ -22,10 +22,10 @@ var _StellarWallet = class _StellarWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
22
22
|
address: wallet.address,
|
|
23
23
|
owner: wallet.owner,
|
|
24
24
|
signer: wallet.signer,
|
|
25
|
-
options:
|
|
25
|
+
options: _chunkEP3UIAFBcjs.Wallet.getOptions(wallet),
|
|
26
26
|
alias: wallet.alias
|
|
27
27
|
},
|
|
28
|
-
|
|
28
|
+
_chunkEP3UIAFBcjs.Wallet.getApiClient(wallet)
|
|
29
29
|
);
|
|
30
30
|
}
|
|
31
31
|
static from(wallet) {
|
|
@@ -37,11 +37,11 @@ var _StellarWallet = class _StellarWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
37
37
|
sendTransaction(params) {
|
|
38
38
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
39
39
|
var _a;
|
|
40
|
-
|
|
40
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("stellarWallet.sendTransaction.start");
|
|
41
41
|
yield this.preAuthIfNeeded();
|
|
42
42
|
const createdTransaction = yield this.createTransaction(params);
|
|
43
43
|
if ((_a = params.options) == null ? void 0 : _a.experimental_prepareOnly) {
|
|
44
|
-
|
|
44
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("stellarWallet.sendTransaction.prepared", {
|
|
45
45
|
transactionId: createdTransaction.id
|
|
46
46
|
});
|
|
47
47
|
return {
|
|
@@ -52,7 +52,7 @@ var _StellarWallet = class _StellarWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
52
52
|
}
|
|
53
53
|
const options = {};
|
|
54
54
|
const result = yield this.approveTransactionAndWait(createdTransaction.id, options);
|
|
55
|
-
|
|
55
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("stellarWallet.sendTransaction.success", {
|
|
56
56
|
transactionId: createdTransaction.id,
|
|
57
57
|
hash: result.hash
|
|
58
58
|
});
|
|
@@ -96,7 +96,7 @@ var _StellarWallet = class _StellarWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
96
96
|
};
|
|
97
97
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
98
98
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
99
|
-
logger:
|
|
99
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
100
100
|
methodName: "stellarWallet.sendTransaction",
|
|
101
101
|
buildContext(thisArg) {
|
|
102
102
|
return { chain: thisArg.chain, address: thisArg.address };
|
|
@@ -3,11 +3,11 @@ import {
|
|
|
3
3
|
} from "./chunk-SGINWAB6.js";
|
|
4
4
|
import {
|
|
5
5
|
walletsLogger
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-23HJV5QR.js";
|
|
7
7
|
import {
|
|
8
8
|
SDK_NAME,
|
|
9
9
|
SDK_VERSION
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-FYJW7Q2N.js";
|
|
11
11
|
import {
|
|
12
12
|
__async
|
|
13
13
|
} from "./chunk-ASE2FXWP.js";
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
var _chunkRBHGZDDXcjs = require('./chunk-RBHGZDDX.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunkEP3UIAFBcjs = require('./chunk-EP3UIAFB.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
var _chunk6Z5QSTIScjs = require('./chunk-6Z5QSTIS.cjs');
|
|
@@ -14,7 +14,7 @@ var _chunk6Z5QSTIScjs = require('./chunk-6Z5QSTIS.cjs');
|
|
|
14
14
|
var _chunkXC2V34TScjs = require('./chunk-XC2V34TS.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var
|
|
17
|
+
var _chunk3K3ZODTJcjs = require('./chunk-3K3ZODTJ.cjs');
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
@@ -32,7 +32,7 @@ var WalletFactory = class {
|
|
|
32
32
|
getOrCreateWallet(args) {
|
|
33
33
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
34
34
|
if (this.apiClient.isServerSide) {
|
|
35
|
-
|
|
35
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("walletFactory.getOrCreateWallet.error", {
|
|
36
36
|
error: "getOrCreateWallet can only be called from client-side code"
|
|
37
37
|
});
|
|
38
38
|
throw new (0, _chunkXC2V34TScjs.WalletCreationError)(
|
|
@@ -40,35 +40,35 @@ var WalletFactory = class {
|
|
|
40
40
|
);
|
|
41
41
|
}
|
|
42
42
|
const locator = this.getWalletLocator(args);
|
|
43
|
-
|
|
43
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.getOrCreateWallet.start");
|
|
44
44
|
const existingWallet = yield this.apiClient.getWallet(locator);
|
|
45
45
|
if (existingWallet != null && !("error" in existingWallet)) {
|
|
46
|
-
|
|
46
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.getOrCreateWallet.existing", {
|
|
47
47
|
address: existingWallet.address
|
|
48
48
|
});
|
|
49
49
|
return this.createWalletInstance(existingWallet, args);
|
|
50
50
|
}
|
|
51
|
-
|
|
51
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.getOrCreateWallet.creating");
|
|
52
52
|
return this.createWallet(args);
|
|
53
53
|
});
|
|
54
54
|
}
|
|
55
55
|
getWallet(walletLocator, args) {
|
|
56
56
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
57
57
|
if (!this.apiClient.isServerSide) {
|
|
58
|
-
|
|
58
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("walletFactory.getWallet.error", {
|
|
59
59
|
error: "getWallet is not supported on client side"
|
|
60
60
|
});
|
|
61
61
|
throw new (0, _chunkXC2V34TScjs.WalletCreationError)("getWallet is not supported on client side, use getOrCreateWallet instead");
|
|
62
62
|
}
|
|
63
|
-
|
|
63
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.getWallet.start");
|
|
64
64
|
const existingWallet = yield this.apiClient.getWallet(walletLocator);
|
|
65
65
|
if ("error" in existingWallet) {
|
|
66
|
-
|
|
66
|
+
_chunk3K3ZODTJcjs.walletsLogger.warn("walletFactory.getWallet.notFound", {
|
|
67
67
|
error: existingWallet.error
|
|
68
68
|
});
|
|
69
69
|
throw new (0, _chunkXC2V34TScjs.WalletNotAvailableError)(JSON.stringify(existingWallet));
|
|
70
70
|
}
|
|
71
|
-
|
|
71
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.getWallet.success", {
|
|
72
72
|
address: existingWallet.address
|
|
73
73
|
});
|
|
74
74
|
return this.createWalletInstance(existingWallet, args);
|
|
@@ -78,7 +78,7 @@ var WalletFactory = class {
|
|
|
78
78
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
79
79
|
var _a, _b, _c, _d, _e;
|
|
80
80
|
yield (_c = (_b = (_a = args.options) == null ? void 0 : _a.experimental_callbacks) == null ? void 0 : _b.onWalletCreationStart) == null ? void 0 : _c.call(_b);
|
|
81
|
-
|
|
81
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.createWallet.start");
|
|
82
82
|
this.mutateSignerFromCustomAuth(args, true);
|
|
83
83
|
const adminSigner = args.signer.type === "passkey" ? yield this.createPasskeyAdminSigner(args.signer) : args.signer;
|
|
84
84
|
const walletResponse = yield this.apiClient.createWallet({
|
|
@@ -91,12 +91,12 @@ var WalletFactory = class {
|
|
|
91
91
|
alias: (_e = args.alias) != null ? _e : void 0
|
|
92
92
|
});
|
|
93
93
|
if ("error" in walletResponse) {
|
|
94
|
-
|
|
94
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("walletFactory.createWallet.error", {
|
|
95
95
|
error: walletResponse.error
|
|
96
96
|
});
|
|
97
97
|
throw new (0, _chunkXC2V34TScjs.WalletCreationError)(JSON.stringify(walletResponse));
|
|
98
98
|
}
|
|
99
|
-
|
|
99
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("walletFactory.createWallet.success", {
|
|
100
100
|
address: walletResponse.address
|
|
101
101
|
});
|
|
102
102
|
return this.createWalletInstance(walletResponse, args);
|
|
@@ -105,7 +105,7 @@ var WalletFactory = class {
|
|
|
105
105
|
createWalletInstance(walletResponse, args) {
|
|
106
106
|
this.validateExistingWalletConfig(walletResponse, args);
|
|
107
107
|
const signerConfig = this.toInternalSignerConfig(walletResponse, args.signer, args.options);
|
|
108
|
-
return new (0,
|
|
108
|
+
return new (0, _chunkEP3UIAFBcjs.Wallet)(
|
|
109
109
|
{
|
|
110
110
|
chain: args.chain,
|
|
111
111
|
address: walletResponse.address,
|
|
@@ -289,7 +289,7 @@ var WalletFactory = class {
|
|
|
289
289
|
};
|
|
290
290
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
291
291
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
292
|
-
logger:
|
|
292
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
293
293
|
methodName: "walletFactory.getOrCreateWallet",
|
|
294
294
|
buildContext(_thisArg, args) {
|
|
295
295
|
const walletArgs = args[0];
|
|
@@ -299,7 +299,7 @@ _chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
|
299
299
|
], WalletFactory.prototype, "getOrCreateWallet", 1);
|
|
300
300
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
301
301
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
302
|
-
logger:
|
|
302
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
303
303
|
methodName: "walletFactory.getWallet",
|
|
304
304
|
buildContext(_thisArg, args) {
|
|
305
305
|
const walletLocator = args[0];
|
|
@@ -310,7 +310,7 @@ _chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
|
310
310
|
], WalletFactory.prototype, "getWallet", 1);
|
|
311
311
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
312
312
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
313
|
-
logger:
|
|
313
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
314
314
|
methodName: "walletFactory.createWallet",
|
|
315
315
|
buildContext(_thisArg, args) {
|
|
316
316
|
const walletArgs = args[0];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Wallet
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-LXWT2YKV.js";
|
|
4
4
|
import {
|
|
5
5
|
InvalidTypedDataError,
|
|
6
6
|
SignatureNotCreatedError,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
} from "./chunk-NJTKHWXR.js";
|
|
12
12
|
import {
|
|
13
13
|
walletsLogger
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-23HJV5QR.js";
|
|
15
15
|
import {
|
|
16
16
|
__async,
|
|
17
17
|
__decorateClass
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./chunk-ZP4ZZCIE.js";
|
|
5
5
|
import {
|
|
6
6
|
Wallet
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-LXWT2YKV.js";
|
|
8
8
|
import {
|
|
9
9
|
assembleSigner
|
|
10
10
|
} from "./chunk-UZN67GMO.js";
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
} from "./chunk-SGINWAB6.js";
|
|
15
15
|
import {
|
|
16
16
|
walletsLogger
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-23HJV5QR.js";
|
|
18
18
|
import {
|
|
19
19
|
__async,
|
|
20
20
|
__decorateClass,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkEP3UIAFBcjs = require('./chunk-EP3UIAFB.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -11,7 +11,7 @@ var _chunkXC2V34TScjs = require('./chunk-XC2V34TS.cjs');
|
|
|
11
11
|
var _chunkGROJZ247cjs = require('./chunk-GROJZ247.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _chunk3K3ZODTJcjs = require('./chunk-3K3ZODTJ.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
|
|
@@ -20,7 +20,7 @@ var _chunkUO2J2ZB2cjs = require('./chunk-UO2J2ZB2.cjs');
|
|
|
20
20
|
// src/wallets/evm.ts
|
|
21
21
|
var _viem = require('viem');
|
|
22
22
|
var _commonsdkbase = require('@crossmint/common-sdk-base');
|
|
23
|
-
var _EVMWallet = class _EVMWallet extends
|
|
23
|
+
var _EVMWallet = class _EVMWallet extends _chunkEP3UIAFBcjs.Wallet {
|
|
24
24
|
constructor(wallet) {
|
|
25
25
|
super(
|
|
26
26
|
{
|
|
@@ -28,10 +28,10 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
28
28
|
address: wallet.address,
|
|
29
29
|
owner: wallet.owner,
|
|
30
30
|
signer: wallet.signer,
|
|
31
|
-
options:
|
|
31
|
+
options: _chunkEP3UIAFBcjs.Wallet.getOptions(wallet),
|
|
32
32
|
alias: wallet.alias
|
|
33
33
|
},
|
|
34
|
-
|
|
34
|
+
_chunkEP3UIAFBcjs.Wallet.getApiClient(wallet)
|
|
35
35
|
);
|
|
36
36
|
}
|
|
37
37
|
static from(wallet) {
|
|
@@ -43,12 +43,12 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
43
43
|
sendTransaction(params) {
|
|
44
44
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
45
45
|
var _a;
|
|
46
|
-
|
|
46
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.sendTransaction.start");
|
|
47
47
|
yield this.preAuthIfNeeded();
|
|
48
48
|
const builtTransaction = this.buildTransaction(params);
|
|
49
49
|
const createdTransaction = yield this.createTransaction(builtTransaction, params.options);
|
|
50
50
|
if ((_a = params.options) == null ? void 0 : _a.experimental_prepareOnly) {
|
|
51
|
-
|
|
51
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.sendTransaction.prepared", {
|
|
52
52
|
transactionId: createdTransaction.id
|
|
53
53
|
});
|
|
54
54
|
return {
|
|
@@ -58,7 +58,7 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
58
58
|
};
|
|
59
59
|
}
|
|
60
60
|
const result = yield this.approveTransactionAndWait(createdTransaction.id);
|
|
61
|
-
|
|
61
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.sendTransaction.success", {
|
|
62
62
|
transactionId: createdTransaction.id,
|
|
63
63
|
hash: result.hash
|
|
64
64
|
});
|
|
@@ -68,7 +68,7 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
68
68
|
signMessage(params) {
|
|
69
69
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
70
70
|
var _a;
|
|
71
|
-
|
|
71
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.signMessage.start");
|
|
72
72
|
yield this.preAuthIfNeeded();
|
|
73
73
|
const signatureCreationResponse = yield this.apiClient.createSignature(this.walletLocator, {
|
|
74
74
|
type: "message",
|
|
@@ -79,11 +79,11 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
79
79
|
}
|
|
80
80
|
});
|
|
81
81
|
if ("error" in signatureCreationResponse) {
|
|
82
|
-
|
|
82
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("evmWallet.signMessage.error", { error: signatureCreationResponse });
|
|
83
83
|
throw new (0, _chunkXC2V34TScjs.SignatureNotCreatedError)(JSON.stringify(signatureCreationResponse));
|
|
84
84
|
}
|
|
85
85
|
if ((_a = params.options) == null ? void 0 : _a.experimental_prepareOnly) {
|
|
86
|
-
|
|
86
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.signMessage.prepared", {
|
|
87
87
|
signatureId: signatureCreationResponse.id
|
|
88
88
|
});
|
|
89
89
|
return {
|
|
@@ -92,23 +92,23 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
92
92
|
};
|
|
93
93
|
}
|
|
94
94
|
const result = yield this.approveSignatureAndWait(signatureCreationResponse.id);
|
|
95
|
-
|
|
95
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.signMessage.success", { signatureId: signatureCreationResponse.id });
|
|
96
96
|
return result;
|
|
97
97
|
});
|
|
98
98
|
}
|
|
99
99
|
signTypedData(params) {
|
|
100
100
|
return _chunkUO2J2ZB2cjs.__async.call(void 0, this, null, function* () {
|
|
101
101
|
var _a;
|
|
102
|
-
|
|
102
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.signTypedData.start");
|
|
103
103
|
yield this.preAuthIfNeeded();
|
|
104
104
|
const { domain, message, primaryType, types, chain } = params;
|
|
105
105
|
if (!domain || !message || !types || !chain) {
|
|
106
|
-
|
|
106
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("evmWallet.signTypedData.error", { error: "Invalid typed data" });
|
|
107
107
|
throw new (0, _chunkXC2V34TScjs.InvalidTypedDataError)("Invalid typed data");
|
|
108
108
|
}
|
|
109
109
|
const { name, version, chainId, verifyingContract, salt } = domain;
|
|
110
110
|
if (!name || !version || !chainId || !verifyingContract) {
|
|
111
|
-
|
|
111
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("evmWallet.signTypedData.error", { error: "Invalid typed data domain" });
|
|
112
112
|
throw new (0, _chunkXC2V34TScjs.InvalidTypedDataError)("Invalid typed data domain");
|
|
113
113
|
}
|
|
114
114
|
const signatureCreationResponse = yield this.apiClient.createSignature(this.walletLocator, {
|
|
@@ -131,11 +131,11 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
131
131
|
}
|
|
132
132
|
});
|
|
133
133
|
if ("error" in signatureCreationResponse) {
|
|
134
|
-
|
|
134
|
+
_chunk3K3ZODTJcjs.walletsLogger.error("evmWallet.signTypedData.error", { error: signatureCreationResponse });
|
|
135
135
|
throw new (0, _chunkXC2V34TScjs.SignatureNotCreatedError)(JSON.stringify(signatureCreationResponse));
|
|
136
136
|
}
|
|
137
137
|
if ((_a = params.options) == null ? void 0 : _a.experimental_prepareOnly) {
|
|
138
|
-
|
|
138
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.signTypedData.prepared", {
|
|
139
139
|
signatureId: signatureCreationResponse.id
|
|
140
140
|
});
|
|
141
141
|
return {
|
|
@@ -144,7 +144,7 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
144
144
|
};
|
|
145
145
|
}
|
|
146
146
|
const result = yield this.approveSignatureAndWait(signatureCreationResponse.id);
|
|
147
|
-
|
|
147
|
+
_chunk3K3ZODTJcjs.walletsLogger.info("evmWallet.signTypedData.success", { signatureId: signatureCreationResponse.id });
|
|
148
148
|
return result;
|
|
149
149
|
});
|
|
150
150
|
}
|
|
@@ -200,7 +200,7 @@ var _EVMWallet = class _EVMWallet extends _chunkQKDQHKDJcjs.Wallet {
|
|
|
200
200
|
};
|
|
201
201
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
202
202
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
203
|
-
logger:
|
|
203
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
204
204
|
methodName: "evmWallet.sendTransaction",
|
|
205
205
|
buildContext(thisArg) {
|
|
206
206
|
return { chain: thisArg.chain, address: thisArg.address };
|
|
@@ -209,7 +209,7 @@ _chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
|
209
209
|
], _EVMWallet.prototype, "sendTransaction", 1);
|
|
210
210
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
211
211
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
212
|
-
logger:
|
|
212
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
213
213
|
methodName: "evmWallet.signMessage",
|
|
214
214
|
buildContext(thisArg) {
|
|
215
215
|
return { chain: thisArg.chain, address: thisArg.address };
|
|
@@ -218,7 +218,7 @@ _chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
|
218
218
|
], _EVMWallet.prototype, "signMessage", 1);
|
|
219
219
|
_chunkUO2J2ZB2cjs.__decorateClass.call(void 0, [
|
|
220
220
|
_commonsdkbase.WithLoggerContext.call(void 0, {
|
|
221
|
-
logger:
|
|
221
|
+
logger: _chunk3K3ZODTJcjs.walletsLogger,
|
|
222
222
|
methodName: "evmWallet.signTypedData",
|
|
223
223
|
buildContext(thisArg) {
|
|
224
224
|
return { chain: thisArg.chain, address: thisArg.address };
|
package/dist/index.cjs
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunkWW2RXFIYcjs = require('./chunk-WW2RXFIY.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunk2YEF7ARXcjs = require('./chunk-2YEF7ARX.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkQOBVGFJVcjs = require('./chunk-QOBVGFJV.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
|
|
13
|
-
var
|
|
14
|
-
require('./chunk-
|
|
13
|
+
var _chunkIG557MDNcjs = require('./chunk-IG557MDN.cjs');
|
|
14
|
+
require('./chunk-SZCB7LEX.cjs');
|
|
15
15
|
require('./chunk-RBHGZDDX.cjs');
|
|
16
16
|
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _chunkEP3UIAFBcjs = require('./chunk-EP3UIAFB.cjs');
|
|
19
19
|
require('./chunk-6Z5QSTIS.cjs');
|
|
20
20
|
require('./chunk-PO6S7UR3.cjs');
|
|
21
21
|
require('./chunk-WFGKVGZ2.cjs');
|
|
@@ -35,7 +35,7 @@ var _chunkRHR6P2KPcjs = require('./chunk-RHR6P2KP.cjs');
|
|
|
35
35
|
require('./chunk-6HXIZLEQ.cjs');
|
|
36
36
|
|
|
37
37
|
|
|
38
|
-
var
|
|
38
|
+
var _chunkK45GD5NVcjs = require('./chunk-K45GD5NV.cjs');
|
|
39
39
|
require('./chunk-XC2V34TS.cjs');
|
|
40
40
|
require('./chunk-ECAM5KTH.cjs');
|
|
41
41
|
require('./chunk-GROJZ247.cjs');
|
|
@@ -44,8 +44,8 @@ require('./chunk-HTSQPZHW.cjs');
|
|
|
44
44
|
require('./chunk-NIBKCMQ2.cjs');
|
|
45
45
|
require('./chunk-55V4VMTX.cjs');
|
|
46
46
|
require('./chunk-CCIGWTAO.cjs');
|
|
47
|
-
require('./chunk-
|
|
48
|
-
require('./chunk-
|
|
47
|
+
require('./chunk-3K3ZODTJ.cjs');
|
|
48
|
+
require('./chunk-K4KXB2EM.cjs');
|
|
49
49
|
require('./chunk-UO2J2ZB2.cjs');
|
|
50
50
|
|
|
51
51
|
|
|
@@ -56,4 +56,4 @@ require('./chunk-UO2J2ZB2.cjs');
|
|
|
56
56
|
|
|
57
57
|
|
|
58
58
|
|
|
59
|
-
exports.CrossmintWallets =
|
|
59
|
+
exports.CrossmintWallets = _chunkIG557MDNcjs.CrossmintWallets; exports.EVMWallet = _chunkWW2RXFIYcjs.EVMWallet; exports.SolanaWallet = _chunk2YEF7ARXcjs.SolanaWallet; exports.StellarWallet = _chunkQOBVGFJVcjs.StellarWallet; exports.Wallet = _chunkEP3UIAFBcjs.Wallet; exports.WalletsApiClient = _chunkK45GD5NVcjs.ApiClient; exports.createCrossmint = _chunkIG557MDNcjs.createCrossmint; exports.isExportableSigner = _chunkRHR6P2KPcjs.isExportableSigner;
|
package/dist/index.js
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import {
|
|
2
2
|
EVMWallet
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-VBKKSVLN.js";
|
|
4
4
|
import {
|
|
5
5
|
SolanaWallet
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-EDVMJRYK.js";
|
|
7
7
|
import {
|
|
8
8
|
StellarWallet
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-OZ5QGDNP.js";
|
|
10
10
|
import {
|
|
11
11
|
CrossmintWallets,
|
|
12
12
|
createCrossmint
|
|
13
|
-
} from "./chunk-
|
|
14
|
-
import "./chunk-
|
|
13
|
+
} from "./chunk-G2NUNSFB.js";
|
|
14
|
+
import "./chunk-VYVA567V.js";
|
|
15
15
|
import "./chunk-ZP4ZZCIE.js";
|
|
16
16
|
import {
|
|
17
17
|
Wallet
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-LXWT2YKV.js";
|
|
19
19
|
import "./chunk-UZN67GMO.js";
|
|
20
20
|
import "./chunk-YDZRBHS3.js";
|
|
21
21
|
import "./chunk-UPS2UQJO.js";
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
import "./chunk-5IFDVB4Y.js";
|
|
36
36
|
import {
|
|
37
37
|
ApiClient
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-SF4JGPRB.js";
|
|
39
39
|
import "./chunk-SGINWAB6.js";
|
|
40
40
|
import "./chunk-KBJA7JDT.js";
|
|
41
41
|
import "./chunk-NJTKHWXR.js";
|
|
@@ -44,8 +44,8 @@ import "./chunk-ZBLW42YE.js";
|
|
|
44
44
|
import "./chunk-2T5HHKUI.js";
|
|
45
45
|
import "./chunk-3U6UAYOV.js";
|
|
46
46
|
import "./chunk-455NK5LB.js";
|
|
47
|
-
import "./chunk-
|
|
48
|
-
import "./chunk-
|
|
47
|
+
import "./chunk-23HJV5QR.js";
|
|
48
|
+
import "./chunk-FYJW7Q2N.js";
|
|
49
49
|
import "./chunk-ASE2FXWP.js";
|
|
50
50
|
export {
|
|
51
51
|
CrossmintWallets,
|
package/dist/logger/index.cjs
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
6
|
-
require('../chunk-
|
|
5
|
+
var _chunk3K3ZODTJcjs = require('../chunk-3K3ZODTJ.cjs');
|
|
6
|
+
require('../chunk-K4KXB2EM.cjs');
|
|
7
7
|
require('../chunk-UO2J2ZB2.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
exports.initWalletsLogger =
|
|
11
|
+
exports.initWalletsLogger = _chunk3K3ZODTJcjs.initWalletsLogger; exports.walletsLogger = _chunk3K3ZODTJcjs.walletsLogger;
|
package/dist/logger/index.js
CHANGED
|
@@ -2,8 +2,8 @@ import "../chunk-455NK5LB.js";
|
|
|
2
2
|
import {
|
|
3
3
|
initWalletsLogger,
|
|
4
4
|
walletsLogger
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-23HJV5QR.js";
|
|
6
|
+
import "../chunk-FYJW7Q2N.js";
|
|
7
7
|
import "../chunk-ASE2FXWP.js";
|
|
8
8
|
export {
|
|
9
9
|
initWalletsLogger,
|
package/dist/logger/init.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('../chunk-
|
|
4
|
+
var _chunk3K3ZODTJcjs = require('../chunk-3K3ZODTJ.cjs');
|
|
5
|
+
require('../chunk-K4KXB2EM.cjs');
|
|
6
6
|
require('../chunk-UO2J2ZB2.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
exports.initWalletsLogger =
|
|
10
|
+
exports.initWalletsLogger = _chunk3K3ZODTJcjs.initWalletsLogger; exports.walletsLogger = _chunk3K3ZODTJcjs.walletsLogger;
|
package/dist/logger/init.js
CHANGED
package/dist/sdk.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('./chunk-
|
|
4
|
+
var _chunkIG557MDNcjs = require('./chunk-IG557MDN.cjs');
|
|
5
|
+
require('./chunk-SZCB7LEX.cjs');
|
|
6
6
|
require('./chunk-RBHGZDDX.cjs');
|
|
7
|
-
require('./chunk-
|
|
7
|
+
require('./chunk-EP3UIAFB.cjs');
|
|
8
8
|
require('./chunk-6Z5QSTIS.cjs');
|
|
9
9
|
require('./chunk-PO6S7UR3.cjs');
|
|
10
10
|
require('./chunk-WFGKVGZ2.cjs');
|
|
@@ -20,14 +20,14 @@ require('./chunk-Q5KNPVYI.cjs');
|
|
|
20
20
|
require('./chunk-IOMKHF6R.cjs');
|
|
21
21
|
require('./chunk-RHR6P2KP.cjs');
|
|
22
22
|
require('./chunk-6HXIZLEQ.cjs');
|
|
23
|
-
require('./chunk-
|
|
23
|
+
require('./chunk-K45GD5NV.cjs');
|
|
24
24
|
require('./chunk-XC2V34TS.cjs');
|
|
25
25
|
require('./chunk-ECAM5KTH.cjs');
|
|
26
26
|
require('./chunk-CCIGWTAO.cjs');
|
|
27
|
-
require('./chunk-
|
|
28
|
-
require('./chunk-
|
|
27
|
+
require('./chunk-3K3ZODTJ.cjs');
|
|
28
|
+
require('./chunk-K4KXB2EM.cjs');
|
|
29
29
|
require('./chunk-UO2J2ZB2.cjs');
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
|
|
33
|
-
exports.CrossmintWallets =
|
|
33
|
+
exports.CrossmintWallets = _chunkIG557MDNcjs.CrossmintWallets; exports.createCrossmint = _chunkIG557MDNcjs.createCrossmint;
|
package/dist/sdk.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
CrossmintWallets,
|
|
3
3
|
createCrossmint
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-G2NUNSFB.js";
|
|
5
|
+
import "./chunk-VYVA567V.js";
|
|
6
6
|
import "./chunk-ZP4ZZCIE.js";
|
|
7
|
-
import "./chunk-
|
|
7
|
+
import "./chunk-LXWT2YKV.js";
|
|
8
8
|
import "./chunk-UZN67GMO.js";
|
|
9
9
|
import "./chunk-YDZRBHS3.js";
|
|
10
10
|
import "./chunk-UPS2UQJO.js";
|
|
@@ -20,12 +20,12 @@ import "./chunk-PIFD6KNH.js";
|
|
|
20
20
|
import "./chunk-PK7J3Y3L.js";
|
|
21
21
|
import "./chunk-WJUPOCKJ.js";
|
|
22
22
|
import "./chunk-5IFDVB4Y.js";
|
|
23
|
-
import "./chunk-
|
|
23
|
+
import "./chunk-SF4JGPRB.js";
|
|
24
24
|
import "./chunk-SGINWAB6.js";
|
|
25
25
|
import "./chunk-KBJA7JDT.js";
|
|
26
26
|
import "./chunk-455NK5LB.js";
|
|
27
|
-
import "./chunk-
|
|
28
|
-
import "./chunk-
|
|
27
|
+
import "./chunk-23HJV5QR.js";
|
|
28
|
+
import "./chunk-FYJW7Q2N.js";
|
|
29
29
|
import "./chunk-ASE2FXWP.js";
|
|
30
30
|
export {
|
|
31
31
|
CrossmintWallets,
|