@dynamic-labs/ton 4.59.2 → 4.60.0
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
CHANGED
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
|
|
2
|
+
## [4.60.0](https://github.com/dynamic-labs/dynamic-auth/compare/v4.59.2...v4.60.0) (2026-02-05)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* add prompt to unlock wallet when getting encrypted shares ([#10333](https://github.com/dynamic-labs/dynamic-auth/issues/10333)) ([7009dfa](https://github.com/dynamic-labs/dynamic-auth/commit/7009dfa315538f4f4ad27ff37e7902f10e1cf019))
|
|
8
|
+
* add stellar sendBalance method ([#10310](https://github.com/dynamic-labs/dynamic-auth/issues/10310)) ([c083ea0](https://github.com/dynamic-labs/dynamic-auth/commit/c083ea0a7caa0cb9095d32897acf677c1b661cb4))
|
|
9
|
+
* **webview-controller:** add DelegatedAccessController ([#10348](https://github.com/dynamic-labs/dynamic-auth/issues/10348)) ([57599e4](https://github.com/dynamic-labs/dynamic-auth/commit/57599e4dd1ad6f4b22f98d49d7fae1a724b719ee))
|
|
10
|
+
* **webview-messages:** add DelegatedAccessMessages types ([#10347](https://github.com/dynamic-labs/dynamic-auth/issues/10347)) ([b0a1275](https://github.com/dynamic-labs/dynamic-auth/commit/b0a12759016fa6f8a76753c2394d589acb18ccf1))
|
|
11
|
+
|
|
2
12
|
### [4.59.2](https://github.com/dynamic-labs/dynamic-auth/compare/v4.59.1...v4.59.2) (2026-02-03)
|
|
3
13
|
|
|
4
14
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/ton",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.60.0",
|
|
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,14 +18,14 @@
|
|
|
18
18
|
},
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@dynamic-labs/assert-package-version": "4.
|
|
22
|
-
"@dynamic-labs/logger": "4.
|
|
21
|
+
"@dynamic-labs/assert-package-version": "4.60.0",
|
|
22
|
+
"@dynamic-labs/logger": "4.60.0",
|
|
23
23
|
"@dynamic-labs/sdk-api-core": "0.0.860",
|
|
24
|
-
"@dynamic-labs/types": "4.
|
|
25
|
-
"@dynamic-labs/utils": "4.
|
|
26
|
-
"@dynamic-labs/waas": "4.
|
|
27
|
-
"@dynamic-labs/wallet-book": "4.
|
|
28
|
-
"@dynamic-labs/wallet-connector-core": "4.
|
|
24
|
+
"@dynamic-labs/types": "4.60.0",
|
|
25
|
+
"@dynamic-labs/utils": "4.60.0",
|
|
26
|
+
"@dynamic-labs/waas": "4.60.0",
|
|
27
|
+
"@dynamic-labs/wallet-book": "4.60.0",
|
|
28
|
+
"@dynamic-labs/wallet-connector-core": "4.60.0",
|
|
29
29
|
"@ton/core": "0.62.0",
|
|
30
30
|
"@ton/crypto": "3.3.0",
|
|
31
31
|
"@ton/ton": "16.0.0",
|
|
@@ -9,20 +9,20 @@ var sdkApiCore = require('@dynamic-labs/sdk-api-core');
|
|
|
9
9
|
var utils = require('@dynamic-labs/utils');
|
|
10
10
|
var waas = require('@dynamic-labs/waas');
|
|
11
11
|
var walletConnectorCore = require('@dynamic-labs/wallet-connector-core');
|
|
12
|
-
var TonUiTransaction = require('../../utils/TonUiTransaction/TonUiTransaction.cjs');
|
|
13
12
|
var TonWalletConnector = require('../../TonWalletConnector.cjs');
|
|
13
|
+
var TonUiTransaction = require('../../utils/TonUiTransaction/TonUiTransaction.cjs');
|
|
14
14
|
var convertSendTransactionRequest = require('../../utils/convertSendTransactionRequest/convertSendTransactionRequest.cjs');
|
|
15
|
+
var createWalletStateInit = require('../../utils/createWalletStateInit/createWalletStateInit.cjs');
|
|
15
16
|
var executeTransaction = require('../../utils/executeTransaction/executeTransaction.cjs');
|
|
16
17
|
var extractDisplayInfoFromRequest = require('../../utils/extractDisplayInfoFromRequest/extractDisplayInfoFromRequest.cjs');
|
|
17
18
|
var generateTonConnectProofHash = require('../../utils/generateTonConnectProofHash/generateTonConnectProofHash.cjs');
|
|
18
19
|
var getWalletSeqno = require('../../utils/getWalletSeqno/getWalletSeqno.cjs');
|
|
20
|
+
var isWalletDeployed = require('../../utils/isWalletDeployed/isWalletDeployed.cjs');
|
|
21
|
+
var logger = require('../../utils/logger/logger.cjs');
|
|
19
22
|
var prepareJettonTransfer = require('../../utils/prepareJettonTransfer/prepareJettonTransfer.cjs');
|
|
20
|
-
var prepareTransaction = require('../../utils/prepareTransaction/prepareTransaction.cjs');
|
|
21
23
|
var prepareTonTransfer = require('../../utils/prepareTonTransfer/prepareTonTransfer.cjs');
|
|
22
|
-
var
|
|
24
|
+
var prepareTransaction = require('../../utils/prepareTransaction/prepareTransaction.cjs');
|
|
23
25
|
var WaasTonWallet = require('../../wallet/WaasTonWallet.cjs');
|
|
24
|
-
var isWalletDeployed = require('../../utils/isWalletDeployed/isWalletDeployed.cjs');
|
|
25
|
-
var createWalletStateInit = require('../../utils/createWalletStateInit/createWalletStateInit.cjs');
|
|
26
26
|
var logger$1 = require('@dynamic-labs/logger');
|
|
27
27
|
|
|
28
28
|
class DynamicWaasTonConnector extends waas.withDynamicWaas(TonWalletConnector.TonWalletConnector) {
|
|
@@ -165,11 +165,15 @@ class DynamicWaasTonConnector extends waas.withDynamicWaas(TonWalletConnector.To
|
|
|
165
165
|
const mfaToken = yield ((_a = this.getMfaToken) === null || _a === void 0 ? void 0 : _a.call(this, {
|
|
166
166
|
mfaAction: sdkApiCore.MFAAction.WalletWaasSign,
|
|
167
167
|
}));
|
|
168
|
+
const password = yield this.getPasswordIfNeeded({
|
|
169
|
+
accountAddress: this.activeAccountAddress,
|
|
170
|
+
});
|
|
168
171
|
const signedMessage = yield walletClient.signMessage({
|
|
169
172
|
accountAddress: this.activeAccountAddress,
|
|
170
173
|
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
171
174
|
message,
|
|
172
175
|
mfaToken,
|
|
176
|
+
password,
|
|
173
177
|
signedSessionId,
|
|
174
178
|
});
|
|
175
179
|
return signedMessage;
|
|
@@ -248,9 +252,13 @@ class DynamicWaasTonConnector extends waas.withDynamicWaas(TonWalletConnector.To
|
|
|
248
252
|
const mfaToken = yield ((_a = this.getMfaToken) === null || _a === void 0 ? void 0 : _a.call(this, {
|
|
249
253
|
mfaAction: sdkApiCore.MFAAction.WalletWaasSign,
|
|
250
254
|
}));
|
|
255
|
+
const password = yield this.getPasswordIfNeeded({
|
|
256
|
+
accountAddress: this.activeAccountAddress,
|
|
257
|
+
});
|
|
251
258
|
const signature = yield walletClient.signTransaction({
|
|
252
259
|
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
253
260
|
mfaToken,
|
|
261
|
+
password,
|
|
254
262
|
senderAddress: this.activeAccountAddress,
|
|
255
263
|
signedSessionId,
|
|
256
264
|
transaction: hashToSignHex,
|
|
@@ -3,7 +3,7 @@ import { JwtVerifiedCredential, MFAAction, SignMessageContext } from '@dynamic-l
|
|
|
3
3
|
import { IUITransaction, WalletUiUtils } from '@dynamic-labs/types';
|
|
4
4
|
import { IDynamicWaasConnector, InternalWalletConnector } from '@dynamic-labs/wallet-connector-core';
|
|
5
5
|
import { TonWalletConnector } from '../../TonWalletConnector';
|
|
6
|
-
import { SendTransactionRequest,
|
|
6
|
+
import { SendTransactionRequest, TonConnectConnectorOpts, TonConnectProof } from '../../types';
|
|
7
7
|
import { Logger } from '../../utils/logger/logger';
|
|
8
8
|
import { WaasTonWallet } from '../../wallet/WaasTonWallet';
|
|
9
9
|
export type DynamicWaasTonConnectorProps = TonConnectConnectorOpts & {
|
|
@@ -18,6 +18,7 @@ declare const DynamicWaasTonConnector_base: (abstract new (...args: any[]) => {
|
|
|
18
18
|
getMfaToken?: ((props?: {
|
|
19
19
|
mfaAction?: MFAAction | undefined;
|
|
20
20
|
} | undefined) => Promise<string | undefined>) | undefined;
|
|
21
|
+
getPasswordForSigning?: import("dist/packages/waas/src/DynamicWaasMixin").GetPasswordForSigningFn | undefined;
|
|
21
22
|
getAuthToken?: (() => string) | undefined;
|
|
22
23
|
environmentId?: string | undefined;
|
|
23
24
|
baseApiUrl?: string | undefined;
|
|
@@ -34,13 +35,19 @@ declare const DynamicWaasTonConnector_base: (abstract new (...args: any[]) => {
|
|
|
34
35
|
setGetMfaTokenFunction(getMfaToken: (props?: {
|
|
35
36
|
mfaAction?: MFAAction | undefined;
|
|
36
37
|
} | undefined) => Promise<string | undefined>): void;
|
|
38
|
+
setGetPasswordForSigningFunction(getPasswordForSigning: import("dist/packages/waas/src/DynamicWaasMixin").GetPasswordForSigningFn): void;
|
|
39
|
+
getPasswordIfNeeded({ accountAddress, }: {
|
|
40
|
+
accountAddress: string;
|
|
41
|
+
}): Promise<string | undefined>;
|
|
37
42
|
setEnvironmentId(environmentId: string): void;
|
|
38
43
|
setBaseApiUrl(baseApiUrl: string): void;
|
|
39
44
|
setBaseClientKeysharesRelayApiUrl(baseClientKeysharesRelayApiUrl?: string | undefined): void;
|
|
40
45
|
setRelayUrl(relayUrl: string): void;
|
|
41
46
|
setGetSignedSessionIdFunction(getSignedSessionId: () => Promise<string>): void;
|
|
42
47
|
delegateKeyShares({ accountAddress, password, }: {
|
|
43
|
-
accountAddress: string;
|
|
48
|
+
accountAddress: string; /**
|
|
49
|
+
* Override setEnvironmentId to ensure it's set on the global logger
|
|
50
|
+
*/
|
|
44
51
|
password?: string | undefined;
|
|
45
52
|
}): Promise<void>;
|
|
46
53
|
createDynamicWaasClient(traceContext?: import("dist/packages/waas/utils/instrumentation").TraceContext | undefined): Promise<import("@dynamic-labs-wallet/browser-wallet-client").DynamicWalletClient>;
|
|
@@ -118,8 +125,9 @@ declare const DynamicWaasTonConnector_base: (abstract new (...args: any[]) => {
|
|
|
118
125
|
accountAddress: string;
|
|
119
126
|
password: string;
|
|
120
127
|
}): Promise<import("@dynamic-labs-wallet/core").GetWalletResponse>;
|
|
121
|
-
getWalletRecoveryState({ accountAddress, }: {
|
|
128
|
+
getWalletRecoveryState({ accountAddress, signedSessionId, }: {
|
|
122
129
|
accountAddress: string;
|
|
130
|
+
signedSessionId: string;
|
|
123
131
|
}): Promise<import("@dynamic-labs-wallet/core").WalletRecoveryState>;
|
|
124
132
|
endSession(): Promise<void>;
|
|
125
133
|
getActiveAccountAddress(): Promise<string | undefined>;
|
|
@@ -5,20 +5,20 @@ import { MFAAction } from '@dynamic-labs/sdk-api-core';
|
|
|
5
5
|
import { DynamicError, PlatformService } from '@dynamic-labs/utils';
|
|
6
6
|
import { withDynamicWaas } from '@dynamic-labs/waas';
|
|
7
7
|
import { isSameAddress } from '@dynamic-labs/wallet-connector-core';
|
|
8
|
-
import { TonUiTransaction, NANOTON_PER_TON } from '../../utils/TonUiTransaction/TonUiTransaction.js';
|
|
9
8
|
import { TonWalletConnector } from '../../TonWalletConnector.js';
|
|
9
|
+
import { TonUiTransaction, NANOTON_PER_TON } from '../../utils/TonUiTransaction/TonUiTransaction.js';
|
|
10
10
|
import { convertSendTransactionRequest } from '../../utils/convertSendTransactionRequest/convertSendTransactionRequest.js';
|
|
11
|
+
import { createWalletStateInit } from '../../utils/createWalletStateInit/createWalletStateInit.js';
|
|
11
12
|
import { executeTransaction } from '../../utils/executeTransaction/executeTransaction.js';
|
|
12
13
|
import { extractDisplayInfoFromRequest } from '../../utils/extractDisplayInfoFromRequest/extractDisplayInfoFromRequest.js';
|
|
13
14
|
import { generateTonConnectProofHash } from '../../utils/generateTonConnectProofHash/generateTonConnectProofHash.js';
|
|
14
15
|
import { getWalletSeqno } from '../../utils/getWalletSeqno/getWalletSeqno.js';
|
|
16
|
+
import { isWalletDeployed } from '../../utils/isWalletDeployed/isWalletDeployed.js';
|
|
17
|
+
import { logger } from '../../utils/logger/logger.js';
|
|
15
18
|
import { prepareJettonTransfer } from '../../utils/prepareJettonTransfer/prepareJettonTransfer.js';
|
|
16
|
-
import { prepareTransaction } from '../../utils/prepareTransaction/prepareTransaction.js';
|
|
17
19
|
import { prepareTonTransfer } from '../../utils/prepareTonTransfer/prepareTonTransfer.js';
|
|
18
|
-
import {
|
|
20
|
+
import { prepareTransaction } from '../../utils/prepareTransaction/prepareTransaction.js';
|
|
19
21
|
import { WaasTonWallet } from '../../wallet/WaasTonWallet.js';
|
|
20
|
-
import { isWalletDeployed } from '../../utils/isWalletDeployed/isWalletDeployed.js';
|
|
21
|
-
import { createWalletStateInit } from '../../utils/createWalletStateInit/createWalletStateInit.js';
|
|
22
22
|
import { Logger } from '@dynamic-labs/logger';
|
|
23
23
|
|
|
24
24
|
class DynamicWaasTonConnector extends withDynamicWaas(TonWalletConnector) {
|
|
@@ -161,11 +161,15 @@ class DynamicWaasTonConnector extends withDynamicWaas(TonWalletConnector) {
|
|
|
161
161
|
const mfaToken = yield ((_a = this.getMfaToken) === null || _a === void 0 ? void 0 : _a.call(this, {
|
|
162
162
|
mfaAction: MFAAction.WalletWaasSign,
|
|
163
163
|
}));
|
|
164
|
+
const password = yield this.getPasswordIfNeeded({
|
|
165
|
+
accountAddress: this.activeAccountAddress,
|
|
166
|
+
});
|
|
164
167
|
const signedMessage = yield walletClient.signMessage({
|
|
165
168
|
accountAddress: this.activeAccountAddress,
|
|
166
169
|
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
167
170
|
message,
|
|
168
171
|
mfaToken,
|
|
172
|
+
password,
|
|
169
173
|
signedSessionId,
|
|
170
174
|
});
|
|
171
175
|
return signedMessage;
|
|
@@ -244,9 +248,13 @@ class DynamicWaasTonConnector extends withDynamicWaas(TonWalletConnector) {
|
|
|
244
248
|
const mfaToken = yield ((_a = this.getMfaToken) === null || _a === void 0 ? void 0 : _a.call(this, {
|
|
245
249
|
mfaAction: MFAAction.WalletWaasSign,
|
|
246
250
|
}));
|
|
251
|
+
const password = yield this.getPasswordIfNeeded({
|
|
252
|
+
accountAddress: this.activeAccountAddress,
|
|
253
|
+
});
|
|
247
254
|
const signature = yield walletClient.signTransaction({
|
|
248
255
|
authToken: (_b = this.getAuthToken) === null || _b === void 0 ? void 0 : _b.call(this),
|
|
249
256
|
mfaToken,
|
|
257
|
+
password,
|
|
250
258
|
senderAddress: this.activeAccountAddress,
|
|
251
259
|
signedSessionId,
|
|
252
260
|
transaction: hashToSignHex,
|