@dynamic-labs/waas-svm 5.11.0 → 5.12.1
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/CHANGELOG.md +18 -0
- package/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +12 -11
- package/src/connector/DynamicWaasSVMConnector.cjs +11 -9
- package/src/connector/DynamicWaasSVMConnector.d.ts +13 -6
- package/src/connector/DynamicWaasSVMConnector.js +11 -9
- package/src/signer/DynamicWaasSVMSigner.cjs +3 -2
- package/src/signer/DynamicWaasSVMSigner.d.ts +2 -2
- package/src/signer/DynamicWaasSVMSigner.js +3 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,22 @@
|
|
|
1
1
|
|
|
2
|
+
### [5.12.1](https://github.com/dynamic-labs/dynamic-auth/compare/v5.12.0...v5.12.1) (2026-10-20)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Bug Fixes
|
|
6
|
+
|
|
7
|
+
* rabby not using native rabby:// scheme when redirecting on android devices [main] ([#12541](https://github.com/dynamic-labs/dynamic-auth/issues/12541)) ([923a372](https://github.com/dynamic-labs/dynamic-auth/commit/923a3724eae5e82ef896de78641320b7320933df))
|
|
8
|
+
* **sui,ton:** sign serialized Sui txs without parsing; native TON balance for jetton sends ([#12503](https://github.com/dynamic-labs/dynamic-auth/issues/12503)) ([6a5bfd6](https://github.com/dynamic-labs/dynamic-auth/commit/6a5bfd6bd0118b8ed7ce079159c10ac47cade337))
|
|
9
|
+
|
|
10
|
+
## [5.12.0](https://github.com/dynamic-labs/dynamic-auth/compare/v5.11.0...v5.12.0) (2026-10-16)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* **embedded-wallet-solana:** add getSolanaSponsorAddress ([#12517](https://github.com/dynamic-labs/dynamic-auth/issues/12517)) ([b95c550](https://github.com/dynamic-labs/dynamic-auth/commit/b95c550e3dab783b7ff0b019051a17b22ea44f97))
|
|
16
|
+
* **embedded-wallet:** show chain and wallet in private key export modal ([#12507](https://github.com/dynamic-labs/dynamic-auth/issues/12507)) ([4bfb6d6](https://github.com/dynamic-labs/dynamic-auth/commit/4bfb6d6168aac3f800792fde933e0597f288058f))
|
|
17
|
+
* **sdk-react-core:** send OTP purpose from step-up flows ([#12511](https://github.com/dynamic-labs/dynamic-auth/issues/12511)) ([0d2d8a3](https://github.com/dynamic-labs/dynamic-auth/commit/0d2d8a31058b3e75c71af7a34f459e2a3ddf383b)), closes [#12898](https://github.com/dynamic-labs/dynamic-auth/issues/12898) [#816](https://github.com/dynamic-labs/dynamic-auth/issues/816) [#203](https://github.com/dynamic-labs/dynamic-auth/issues/203) [#12512](https://github.com/dynamic-labs/dynamic-auth/issues/12512)
|
|
18
|
+
* **wallet-connect:** back WalletConnect storage with native secure storage on mobile ([#12515](https://github.com/dynamic-labs/dynamic-auth/issues/12515)) ([7b57903](https://github.com/dynamic-labs/dynamic-auth/commit/7b5790325fce707d73d591483a0130b960ed055c))
|
|
19
|
+
|
|
2
20
|
## [5.11.0](https://github.com/dynamic-labs/dynamic-auth/compare/v5.10.0...v5.11.0) (2026-10-14)
|
|
3
21
|
|
|
4
22
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/waas-svm",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.12.1",
|
|
4
4
|
"description": "A React SDK for implementing wallet web3 authentication and authorization to your website.",
|
|
5
5
|
"author": "Dynamic Labs, Inc.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -18,19 +18,20 @@
|
|
|
18
18
|
},
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@dynamic-labs/
|
|
22
|
-
"@dynamic-labs/
|
|
21
|
+
"@dynamic-labs-wallet/core": "1.1.43",
|
|
22
|
+
"@dynamic-labs/sdk-api-core": "0.104.0",
|
|
23
|
+
"@dynamic-labs/embedded-wallet-solana": "5.12.1",
|
|
23
24
|
"@solana/web3.js": "1.98.1",
|
|
24
25
|
"eventemitter3": "5.0.1",
|
|
25
26
|
"bs58": "5.0.0",
|
|
26
|
-
"@dynamic-labs/assert-package-version": "5.
|
|
27
|
-
"@dynamic-labs/logger": "5.
|
|
28
|
-
"@dynamic-labs/rpc-providers": "5.
|
|
29
|
-
"@dynamic-labs/solana-core": "5.
|
|
30
|
-
"@dynamic-labs/types": "5.
|
|
31
|
-
"@dynamic-labs/utils": "5.
|
|
32
|
-
"@dynamic-labs/waas": "5.
|
|
33
|
-
"@dynamic-labs/wallet-connector-core": "5.
|
|
27
|
+
"@dynamic-labs/assert-package-version": "5.12.1",
|
|
28
|
+
"@dynamic-labs/logger": "5.12.1",
|
|
29
|
+
"@dynamic-labs/rpc-providers": "5.12.1",
|
|
30
|
+
"@dynamic-labs/solana-core": "5.12.1",
|
|
31
|
+
"@dynamic-labs/types": "5.12.1",
|
|
32
|
+
"@dynamic-labs/utils": "5.12.1",
|
|
33
|
+
"@dynamic-labs/waas": "5.12.1",
|
|
34
|
+
"@dynamic-labs/wallet-connector-core": "5.12.1"
|
|
34
35
|
},
|
|
35
36
|
"peerDependencies": {}
|
|
36
37
|
}
|
|
@@ -180,7 +180,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
180
180
|
});
|
|
181
181
|
}
|
|
182
182
|
internalSignMessage(message_1) {
|
|
183
|
-
return _tslib.__awaiter(this, arguments, void 0, function* (message, { parentTraceId, startTime, } = {}) {
|
|
183
|
+
return _tslib.__awaiter(this, arguments, void 0, function* (message, { approvalQuorum, parentTraceId, startTime, } = {}) {
|
|
184
184
|
var _a, _b, _c, _d;
|
|
185
185
|
const traceId = parentTraceId || this.generateTraceId();
|
|
186
186
|
const effectiveStartTime = startTime || Date.now();
|
|
@@ -213,6 +213,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
213
213
|
fn: () => _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
214
214
|
return walletClient.signMessage({
|
|
215
215
|
accountAddress,
|
|
216
|
+
approvalQuorum,
|
|
216
217
|
authToken,
|
|
217
218
|
elevatedAccessToken,
|
|
218
219
|
message,
|
|
@@ -231,7 +232,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
231
232
|
return signedMessage;
|
|
232
233
|
});
|
|
233
234
|
}
|
|
234
|
-
signMessage(message) {
|
|
235
|
+
signMessage(message, options) {
|
|
235
236
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
236
237
|
if (!this.activeAccountAddress) {
|
|
237
238
|
throw new Error('Active account address is required');
|
|
@@ -247,6 +248,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
247
248
|
const signedMessage = yield this.walletUiUtils.signMessage({
|
|
248
249
|
handler: () => _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
249
250
|
return this.internalSignMessage(message, {
|
|
251
|
+
approvalQuorum: options === null || options === void 0 ? void 0 : options.approvalQuorum,
|
|
250
252
|
parentTraceId: traceId,
|
|
251
253
|
startTime,
|
|
252
254
|
});
|
|
@@ -264,7 +266,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
264
266
|
});
|
|
265
267
|
}
|
|
266
268
|
internalSignTransaction(transaction_1) {
|
|
267
|
-
return _tslib.__awaiter(this, arguments, void 0, function* (transaction, { parentTraceId, startTime, overrideBlockhash, sponsorshipMode, } = {}) {
|
|
269
|
+
return _tslib.__awaiter(this, arguments, void 0, function* (transaction, { parentTraceId, startTime, approvalQuorum, overrideBlockhash, sponsorshipMode, } = {}) {
|
|
268
270
|
var _a, _b, _c;
|
|
269
271
|
const traceId = parentTraceId || this.generateTraceId();
|
|
270
272
|
const effectiveStartTime = startTime || Date.now();
|
|
@@ -319,6 +321,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
319
321
|
fn: () => _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
320
322
|
var _d;
|
|
321
323
|
return walletClient.signTransaction({
|
|
324
|
+
approvalQuorum,
|
|
322
325
|
authToken: (_d = this.getAuthToken) === null || _d === void 0 ? void 0 : _d.call(this),
|
|
323
326
|
chainId,
|
|
324
327
|
elevatedAccessToken,
|
|
@@ -371,7 +374,7 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
371
374
|
from: this.activeAccountAddress,
|
|
372
375
|
multipleTransactions: [transaction],
|
|
373
376
|
onSubmit: () => _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
374
|
-
return this.internalSignTransaction(transaction, Object.assign(Object.assign({ parentTraceId: traceId }, ((options === null || options === void 0 ? void 0 : options.sponsorshipMode) && {
|
|
377
|
+
return this.internalSignTransaction(transaction, Object.assign(Object.assign({ approvalQuorum: options === null || options === void 0 ? void 0 : options.approvalQuorum, parentTraceId: traceId }, ((options === null || options === void 0 ? void 0 : options.sponsorshipMode) && {
|
|
375
378
|
sponsorshipMode: options.sponsorshipMode,
|
|
376
379
|
})), { startTime }));
|
|
377
380
|
}),
|
|
@@ -394,11 +397,10 @@ class DynamicWaasSVMConnector extends waas.withDynamicWaas(solanaCore.SolanaWall
|
|
|
394
397
|
}
|
|
395
398
|
const signedTransactions = [];
|
|
396
399
|
for (const transaction of transactions) {
|
|
397
|
-
const signedTx = (
|
|
398
|
-
?
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
: yield this.internalSignTransaction(transaction);
|
|
400
|
+
const signedTx = yield this.internalSignTransaction(transaction, {
|
|
401
|
+
approvalQuorum: options === null || options === void 0 ? void 0 : options.approvalQuorum,
|
|
402
|
+
sponsorshipMode: options === null || options === void 0 ? void 0 : options.sponsorshipMode,
|
|
403
|
+
});
|
|
402
404
|
signedTransactions.push(signedTx);
|
|
403
405
|
}
|
|
404
406
|
return signedTransactions;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Connection, SendOptions, Transaction, VersionedTransaction } from '@solana/web3.js';
|
|
2
|
+
import type { ApprovalQuorumRequestContext } from '@dynamic-labs-wallet/core';
|
|
2
3
|
import { MFAAction, TokenScope } from '@dynamic-labs/sdk-api-core';
|
|
3
4
|
import { GasSponsorshipMode, ISolanaSigner, SolanaSendOptions, SolanaTransactionOptions, SolanaWalletConnector, SolanaWalletConnectorOpts } from '@dynamic-labs/solana-core';
|
|
4
5
|
import { IUITransaction, WalletUiUtils } from '@dynamic-labs/types';
|
|
@@ -59,7 +60,7 @@ declare const DynamicWaasSVMConnector_base: (abstract new (...args: any[]) => {
|
|
|
59
60
|
delegateKeyShares({ accountAddress, password, initialSignerRules, }: {
|
|
60
61
|
accountAddress: string;
|
|
61
62
|
password?: string | undefined;
|
|
62
|
-
initialSignerRules?: import("@dynamic-labs/
|
|
63
|
+
initialSignerRules?: import("@dynamic-labs-wallet/core").WaasPolicyRule[] | undefined;
|
|
63
64
|
}): Promise<void>;
|
|
64
65
|
createRevocableSignedSessionCallback(): {
|
|
65
66
|
getSignedSessionId: () => Promise<string>;
|
|
@@ -151,9 +152,10 @@ declare const DynamicWaasSVMConnector_base: (abstract new (...args: any[]) => {
|
|
|
151
152
|
accountAddress: string;
|
|
152
153
|
newPassword: string;
|
|
153
154
|
}): Promise<void>;
|
|
154
|
-
signRawMessage({ accountAddress, context, message, password, }: {
|
|
155
|
+
signRawMessage({ accountAddress, approvalQuorum, context, message, password, }: {
|
|
155
156
|
accountAddress: string;
|
|
156
|
-
|
|
157
|
+
approvalQuorum?: ApprovalQuorumRequestContext | undefined;
|
|
158
|
+
context?: import("@dynamic-labs-wallet/core").SignMessageContext | undefined;
|
|
157
159
|
message: string;
|
|
158
160
|
password?: string | undefined;
|
|
159
161
|
}): Promise<string>;
|
|
@@ -250,12 +252,17 @@ export declare class DynamicWaasSVMConnector extends DynamicWaasSVMConnector_bas
|
|
|
250
252
|
private setActiveAccountAddress;
|
|
251
253
|
getActiveAccountAddress(): Promise<string | undefined>;
|
|
252
254
|
validateActiveWallet(expectedAddress: string): Promise<void>;
|
|
253
|
-
internalSignMessage(message: string, { parentTraceId, startTime, }?: {
|
|
255
|
+
internalSignMessage(message: string, { approvalQuorum, parentTraceId, startTime, }?: {
|
|
256
|
+
approvalQuorum?: ApprovalQuorumRequestContext;
|
|
254
257
|
parentTraceId?: string;
|
|
255
258
|
startTime?: number;
|
|
256
259
|
}): Promise<string>;
|
|
257
|
-
signMessage(message: string
|
|
258
|
-
|
|
260
|
+
signMessage(message: string, options?: {
|
|
261
|
+
address?: string;
|
|
262
|
+
approvalQuorum?: ApprovalQuorumRequestContext;
|
|
263
|
+
}): Promise<string>;
|
|
264
|
+
internalSignTransaction<T extends Transaction | VersionedTransaction>(transaction: T, { parentTraceId, startTime, approvalQuorum, overrideBlockhash, sponsorshipMode, }?: {
|
|
265
|
+
approvalQuorum?: ApprovalQuorumRequestContext;
|
|
259
266
|
parentTraceId?: string;
|
|
260
267
|
startTime?: number;
|
|
261
268
|
overrideBlockhash?: {
|
|
@@ -176,7 +176,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
176
176
|
});
|
|
177
177
|
}
|
|
178
178
|
internalSignMessage(message_1) {
|
|
179
|
-
return __awaiter(this, arguments, void 0, function* (message, { parentTraceId, startTime, } = {}) {
|
|
179
|
+
return __awaiter(this, arguments, void 0, function* (message, { approvalQuorum, parentTraceId, startTime, } = {}) {
|
|
180
180
|
var _a, _b, _c, _d;
|
|
181
181
|
const traceId = parentTraceId || this.generateTraceId();
|
|
182
182
|
const effectiveStartTime = startTime || Date.now();
|
|
@@ -209,6 +209,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
209
209
|
fn: () => __awaiter(this, void 0, void 0, function* () {
|
|
210
210
|
return walletClient.signMessage({
|
|
211
211
|
accountAddress,
|
|
212
|
+
approvalQuorum,
|
|
212
213
|
authToken,
|
|
213
214
|
elevatedAccessToken,
|
|
214
215
|
message,
|
|
@@ -227,7 +228,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
227
228
|
return signedMessage;
|
|
228
229
|
});
|
|
229
230
|
}
|
|
230
|
-
signMessage(message) {
|
|
231
|
+
signMessage(message, options) {
|
|
231
232
|
return __awaiter(this, void 0, void 0, function* () {
|
|
232
233
|
if (!this.activeAccountAddress) {
|
|
233
234
|
throw new Error('Active account address is required');
|
|
@@ -243,6 +244,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
243
244
|
const signedMessage = yield this.walletUiUtils.signMessage({
|
|
244
245
|
handler: () => __awaiter(this, void 0, void 0, function* () {
|
|
245
246
|
return this.internalSignMessage(message, {
|
|
247
|
+
approvalQuorum: options === null || options === void 0 ? void 0 : options.approvalQuorum,
|
|
246
248
|
parentTraceId: traceId,
|
|
247
249
|
startTime,
|
|
248
250
|
});
|
|
@@ -260,7 +262,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
260
262
|
});
|
|
261
263
|
}
|
|
262
264
|
internalSignTransaction(transaction_1) {
|
|
263
|
-
return __awaiter(this, arguments, void 0, function* (transaction, { parentTraceId, startTime, overrideBlockhash, sponsorshipMode, } = {}) {
|
|
265
|
+
return __awaiter(this, arguments, void 0, function* (transaction, { parentTraceId, startTime, approvalQuorum, overrideBlockhash, sponsorshipMode, } = {}) {
|
|
264
266
|
var _a, _b, _c;
|
|
265
267
|
const traceId = parentTraceId || this.generateTraceId();
|
|
266
268
|
const effectiveStartTime = startTime || Date.now();
|
|
@@ -315,6 +317,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
315
317
|
fn: () => __awaiter(this, void 0, void 0, function* () {
|
|
316
318
|
var _d;
|
|
317
319
|
return walletClient.signTransaction({
|
|
320
|
+
approvalQuorum,
|
|
318
321
|
authToken: (_d = this.getAuthToken) === null || _d === void 0 ? void 0 : _d.call(this),
|
|
319
322
|
chainId,
|
|
320
323
|
elevatedAccessToken,
|
|
@@ -367,7 +370,7 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
367
370
|
from: this.activeAccountAddress,
|
|
368
371
|
multipleTransactions: [transaction],
|
|
369
372
|
onSubmit: () => __awaiter(this, void 0, void 0, function* () {
|
|
370
|
-
return this.internalSignTransaction(transaction, Object.assign(Object.assign({ parentTraceId: traceId }, ((options === null || options === void 0 ? void 0 : options.sponsorshipMode) && {
|
|
373
|
+
return this.internalSignTransaction(transaction, Object.assign(Object.assign({ approvalQuorum: options === null || options === void 0 ? void 0 : options.approvalQuorum, parentTraceId: traceId }, ((options === null || options === void 0 ? void 0 : options.sponsorshipMode) && {
|
|
371
374
|
sponsorshipMode: options.sponsorshipMode,
|
|
372
375
|
})), { startTime }));
|
|
373
376
|
}),
|
|
@@ -390,11 +393,10 @@ class DynamicWaasSVMConnector extends withDynamicWaas(SolanaWalletConnector) {
|
|
|
390
393
|
}
|
|
391
394
|
const signedTransactions = [];
|
|
392
395
|
for (const transaction of transactions) {
|
|
393
|
-
const signedTx = (
|
|
394
|
-
?
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
: yield this.internalSignTransaction(transaction);
|
|
396
|
+
const signedTx = yield this.internalSignTransaction(transaction, {
|
|
397
|
+
approvalQuorum: options === null || options === void 0 ? void 0 : options.approvalQuorum,
|
|
398
|
+
sponsorshipMode: options === null || options === void 0 ? void 0 : options.sponsorshipMode,
|
|
399
|
+
});
|
|
398
400
|
signedTransactions.push(signedTx);
|
|
399
401
|
}
|
|
400
402
|
return signedTransactions;
|
|
@@ -36,11 +36,12 @@ class DynamicWaasSVMSigner extends EventEmitter__default["default"] {
|
|
|
36
36
|
? new web3_js.PublicKey(this.accountAddress)
|
|
37
37
|
: undefined;
|
|
38
38
|
}
|
|
39
|
-
signMessage(encodedMessage) {
|
|
39
|
+
signMessage(encodedMessage, options) {
|
|
40
40
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
41
41
|
// Convert Uint8Array to string for the DynamicWaasSVMConnector
|
|
42
42
|
const messageString = Buffer.from(encodedMessage).toString();
|
|
43
|
-
const
|
|
43
|
+
const approvalQuorum = typeof options === 'object' ? options.approvalQuorum : undefined;
|
|
44
|
+
const signedMessage = yield this.walletConnector.signMessage(messageString, { approvalQuorum });
|
|
44
45
|
// Convert base64 string to Uint8Array
|
|
45
46
|
const signatureBytes = bs58__default["default"].decode(signedMessage);
|
|
46
47
|
return { signature: signatureBytes };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { PublicKey, Transaction, TransactionSignature, VersionedTransaction } from '@solana/web3.js';
|
|
2
2
|
import EventEmitter from 'eventemitter3';
|
|
3
|
-
import { SignedMessage, ISolanaSigner, ConnectionResult, ISolanaEvents, SolanaSendOptions, SolanaTransactionOptions } from '@dynamic-labs/solana-core';
|
|
3
|
+
import { SignedMessage, ISolanaSigner, ConnectionResult, ISolanaEvents, SolanaSendOptions, SolanaSignMessageOptions, SolanaTransactionOptions } from '@dynamic-labs/solana-core';
|
|
4
4
|
import { DynamicWaasSVMConnector } from '../connector/DynamicWaasSVMConnector';
|
|
5
5
|
/**
|
|
6
6
|
* Signer implementation for DynamicWaasSVMConnector
|
|
@@ -22,7 +22,7 @@ export declare class DynamicWaasSVMSigner extends EventEmitter<ISolanaEvents> im
|
|
|
22
22
|
constructor({ walletConnector, }: {
|
|
23
23
|
walletConnector: DynamicWaasSVMConnector;
|
|
24
24
|
});
|
|
25
|
-
signMessage(encodedMessage: Uint8Array): Promise<SignedMessage>;
|
|
25
|
+
signMessage(encodedMessage: Uint8Array, options?: string | SolanaSignMessageOptions): Promise<SignedMessage>;
|
|
26
26
|
signTransaction<T extends Transaction | VersionedTransaction>(transaction: T, options?: SolanaTransactionOptions): Promise<T>;
|
|
27
27
|
signAllTransactions<T extends Transaction | VersionedTransaction>(transactions: T[], options?: SolanaTransactionOptions): Promise<T[]>;
|
|
28
28
|
signAndSendTransaction<T extends Transaction | VersionedTransaction>(transaction: T, options?: SolanaSendOptions): Promise<{
|
|
@@ -27,11 +27,12 @@ class DynamicWaasSVMSigner extends EventEmitter {
|
|
|
27
27
|
? new PublicKey(this.accountAddress)
|
|
28
28
|
: undefined;
|
|
29
29
|
}
|
|
30
|
-
signMessage(encodedMessage) {
|
|
30
|
+
signMessage(encodedMessage, options) {
|
|
31
31
|
return __awaiter(this, void 0, void 0, function* () {
|
|
32
32
|
// Convert Uint8Array to string for the DynamicWaasSVMConnector
|
|
33
33
|
const messageString = Buffer.from(encodedMessage).toString();
|
|
34
|
-
const
|
|
34
|
+
const approvalQuorum = typeof options === 'object' ? options.approvalQuorum : undefined;
|
|
35
|
+
const signedMessage = yield this.walletConnector.signMessage(messageString, { approvalQuorum });
|
|
35
36
|
// Convert base64 string to Uint8Array
|
|
36
37
|
const signatureBytes = bs58.decode(signedMessage);
|
|
37
38
|
return { signature: signatureBytes };
|