@dynamic-labs/solana 4.45.2 → 4.46.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 +24 -0
- package/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +12 -12
- package/src/index.cjs +2 -0
- package/src/index.d.ts +1 -0
- package/src/index.js +1 -0
- package/src/injected/InjectedWalletBase/InjectedWalletBase.cjs +1 -1
- package/src/injected/InjectedWalletBase/InjectedWalletBase.js +1 -1
- package/src/walletConnect/SolanaWalletConnectConnectors.cjs +21 -0
- package/src/walletConnect/SolanaWalletConnectConnectors.d.ts +8 -0
- package/src/walletConnect/SolanaWalletConnectConnectors.js +17 -0
- package/src/walletConnect/utils/addSolanaWalletConnectConnectors/addSolanaWalletConnectConnectors.cjs +8 -4
- package/src/walletConnect/utils/addSolanaWalletConnectConnectors/addSolanaWalletConnectConnectors.js +8 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,28 @@
|
|
|
1
1
|
|
|
2
|
+
## [4.46.0](https://github.com/dynamic-labs/dynamic-auth/compare/v4.45.3...v4.46.0) (2025-11-19)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* **react-native:** add client.solana.simulateTransaction method ([#9910](https://github.com/dynamic-labs/dynamic-auth/issues/9910)) ([61bbe45](https://github.com/dynamic-labs/dynamic-auth/commit/61bbe453eeb2790dffc533aa57f6bc050c3c0461))
|
|
8
|
+
* **react-native:** add simulateEVMTransactionAA and simulateEVMTransaction methods ([#9907](https://github.com/dynamic-labs/dynamic-auth/issues/9907)) ([e54d63e](https://github.com/dynamic-labs/dynamic-auth/commit/e54d63eaa80c2bc865ef6199405b0ed7943d4b83))
|
|
9
|
+
|
|
10
|
+
### [4.45.3](https://github.com/dynamic-labs/dynamic-auth/compare/v4.45.2...v4.45.3) (2025-11-18)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Features
|
|
14
|
+
|
|
15
|
+
* add trc20 token transfer to dynamic widget ([#9877](https://github.com/dynamic-labs/dynamic-auth/issues/9877)) ([4365102](https://github.com/dynamic-labs/dynamic-auth/commit/436510253436239d64d4f47b7d0532e65401c19d))
|
|
16
|
+
* add trc20 tokens to sendBalance ([#9873](https://github.com/dynamic-labs/dynamic-auth/issues/9873)) ([fec5e67](https://github.com/dynamic-labs/dynamic-auth/commit/fec5e6715f87fd6a3f7b2ca21c94e4f32ec86031))
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
### Bug Fixes
|
|
20
|
+
|
|
21
|
+
* don't allow mobileExperience override to redirect for wallets that don't support it ([#9865](https://github.com/dynamic-labs/dynamic-auth/issues/9865)) ([b34ada5](https://github.com/dynamic-labs/dynamic-auth/commit/b34ada5ac0450667bf33b3cf2ce13e5c16235cfc))
|
|
22
|
+
* **global-wallet:** validate the redirect url ([#9894](https://github.com/dynamic-labs/dynamic-auth/issues/9894)) ([4cf27b5](https://github.com/dynamic-labs/dynamic-auth/commit/4cf27b538da5a9d1da04160faad009880f15f175))
|
|
23
|
+
* temporarily skip Phantom account creation steps due to extension… ([#9893](https://github.com/dynamic-labs/dynamic-auth/issues/9893)) ([87f8a2e](https://github.com/dynamic-labs/dynamic-auth/commit/87f8a2e1185be09c255e7865980f02b13e916db4))
|
|
24
|
+
* wallet book is required console errors ([#9887](https://github.com/dynamic-labs/dynamic-auth/issues/9887)) ([417605d](https://github.com/dynamic-labs/dynamic-auth/commit/417605d605f70ee558dd550b1fb50c996f219b31))
|
|
25
|
+
|
|
2
26
|
### [4.45.2](https://github.com/dynamic-labs/dynamic-auth/compare/v4.45.1...v4.45.2) (2025-11-17)
|
|
3
27
|
|
|
4
28
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/solana",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.46.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,7 +18,7 @@
|
|
|
18
18
|
},
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@dynamic-labs/wallet-connect": "4.
|
|
21
|
+
"@dynamic-labs/wallet-connect": "4.46.0",
|
|
22
22
|
"@solana/web3.js": "1.98.1",
|
|
23
23
|
"@wallet-standard/app": "1.0.1",
|
|
24
24
|
"@wallet-standard/base": "1.0.1",
|
|
@@ -29,17 +29,17 @@
|
|
|
29
29
|
"@walletconnect/sign-client": "2.21.5",
|
|
30
30
|
"@walletconnect/utils": "2.21.5",
|
|
31
31
|
"@walletconnect/types": "2.21.5",
|
|
32
|
-
"@dynamic-labs/assert-package-version": "4.
|
|
33
|
-
"@dynamic-labs/embedded-wallet-solana": "4.
|
|
34
|
-
"@dynamic-labs/logger": "4.
|
|
35
|
-
"@dynamic-labs/rpc-providers": "4.
|
|
32
|
+
"@dynamic-labs/assert-package-version": "4.46.0",
|
|
33
|
+
"@dynamic-labs/embedded-wallet-solana": "4.46.0",
|
|
34
|
+
"@dynamic-labs/logger": "4.46.0",
|
|
35
|
+
"@dynamic-labs/rpc-providers": "4.46.0",
|
|
36
36
|
"@dynamic-labs/sdk-api-core": "0.0.821",
|
|
37
|
-
"@dynamic-labs/solana-core": "4.
|
|
38
|
-
"@dynamic-labs/types": "4.
|
|
39
|
-
"@dynamic-labs/utils": "4.
|
|
40
|
-
"@dynamic-labs/waas-svm": "4.
|
|
41
|
-
"@dynamic-labs/wallet-book": "4.
|
|
42
|
-
"@dynamic-labs/wallet-connector-core": "4.
|
|
37
|
+
"@dynamic-labs/solana-core": "4.46.0",
|
|
38
|
+
"@dynamic-labs/types": "4.46.0",
|
|
39
|
+
"@dynamic-labs/utils": "4.46.0",
|
|
40
|
+
"@dynamic-labs/waas-svm": "4.46.0",
|
|
41
|
+
"@dynamic-labs/wallet-book": "4.46.0",
|
|
42
|
+
"@dynamic-labs/wallet-connector-core": "4.46.0",
|
|
43
43
|
"eventemitter3": "5.0.1"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {}
|
package/src/index.cjs
CHANGED
|
@@ -9,6 +9,7 @@ var solanaCore = require('@dynamic-labs/solana-core');
|
|
|
9
9
|
var BackpackSol = require('./injected/BackpackSol/BackpackSol.cjs');
|
|
10
10
|
var InjectedWalletBase = require('./injected/InjectedWalletBase/InjectedWalletBase.cjs');
|
|
11
11
|
var SolanaWalletConnectors = require('./SolanaWalletConnectors.cjs');
|
|
12
|
+
var SolanaWalletConnectConnectors = require('./walletConnect/SolanaWalletConnectConnectors.cjs');
|
|
12
13
|
var SolanaWalletConnectorsWithConfig = require('./SolanaWalletConnectorsWithConfig/SolanaWalletConnectorsWithConfig.cjs');
|
|
13
14
|
var isBackpackSolanaSigner = require('./utils/isBackpackSolanaSigner.cjs');
|
|
14
15
|
var isSignedMessage = require('./utils/isSignedMessage.cjs');
|
|
@@ -36,6 +37,7 @@ Object.defineProperty(exports, 'isSolanaWallet', {
|
|
|
36
37
|
exports.BackpackConnector = BackpackSol.BackpackSol;
|
|
37
38
|
exports.SolanaInjectedConnector = InjectedWalletBase.InjectedWalletBase;
|
|
38
39
|
exports.SolanaWalletConnectors = SolanaWalletConnectors.SolanaWalletConnectors;
|
|
40
|
+
exports.SolanaWalletConnectConnectors = SolanaWalletConnectConnectors.SolanaWalletConnectConnectors;
|
|
39
41
|
exports.SolanaWalletConnectorsWithConfig = SolanaWalletConnectorsWithConfig.SolanaWalletConnectorsWithConfig;
|
|
40
42
|
exports.isBackpackSolanaSigner = isBackpackSolanaSigner.isBackpackSolanaSigner;
|
|
41
43
|
exports.isSignedMessage = isSignedMessage.isSignedMessage;
|
package/src/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ export { isSolanaWallet, SolanaWalletConnector, } from '@dynamic-labs/solana-cor
|
|
|
3
3
|
export { BackpackSol as BackpackConnector } from './injected/BackpackSol';
|
|
4
4
|
export { InjectedWalletBase as SolanaInjectedConnector } from './injected/InjectedWalletBase';
|
|
5
5
|
export { SolanaWalletConnectors } from './SolanaWalletConnectors';
|
|
6
|
+
export { SolanaWalletConnectConnectors } from './walletConnect/SolanaWalletConnectConnectors';
|
|
6
7
|
export { SolanaWalletConnectorsWithConfig } from './SolanaWalletConnectorsWithConfig';
|
|
7
8
|
export { isBackpackSolanaSigner } from './utils/isBackpackSolanaSigner';
|
|
8
9
|
export { isSignedMessage } from './utils/isSignedMessage';
|
package/src/index.js
CHANGED
|
@@ -5,6 +5,7 @@ export { SolanaWalletConnector, isSolanaWallet } from '@dynamic-labs/solana-core
|
|
|
5
5
|
export { BackpackSol as BackpackConnector } from './injected/BackpackSol/BackpackSol.js';
|
|
6
6
|
export { InjectedWalletBase as SolanaInjectedConnector } from './injected/InjectedWalletBase/InjectedWalletBase.js';
|
|
7
7
|
export { SolanaWalletConnectors } from './SolanaWalletConnectors.js';
|
|
8
|
+
export { SolanaWalletConnectConnectors } from './walletConnect/SolanaWalletConnectConnectors.js';
|
|
8
9
|
export { SolanaWalletConnectorsWithConfig } from './SolanaWalletConnectorsWithConfig/SolanaWalletConnectorsWithConfig.js';
|
|
9
10
|
export { isBackpackSolanaSigner } from './utils/isBackpackSolanaSigner.js';
|
|
10
11
|
export { isSignedMessage } from './utils/isSignedMessage.js';
|
|
@@ -36,7 +36,7 @@ class InjectedWalletBase extends solanaCore.SolanaWalletConnector {
|
|
|
36
36
|
return this;
|
|
37
37
|
}
|
|
38
38
|
// if the wallet is not installed on the browser and WC is available, return the WC connector
|
|
39
|
-
const wcConnector = new SolanaWalletConnectConnector.SolanaWalletConnectConnector(Object.assign(Object.assign({}, this.constructorProps), { metadata: walletConnectorCore.getWalletMetadataFromWalletBook(Object.assign(Object.assign({}, this.metadata), { walletBookWallet: this.walletConnectWalletBookEntry, walletKey: this.key })), overrideKey: this.key, walletName: this.name }));
|
|
39
|
+
const wcConnector = new SolanaWalletConnectConnector.SolanaWalletConnectConnector(Object.assign(Object.assign({}, this.constructorProps), { metadata: walletConnectorCore.getWalletMetadataFromWalletBook(Object.assign(Object.assign({}, this.metadata), { walletBook: this.walletBook, walletBookWallet: this.walletConnectWalletBookEntry, walletKey: this.key })), overrideKey: this.key, walletName: this.name }));
|
|
40
40
|
wcConnector.init();
|
|
41
41
|
return wcConnector;
|
|
42
42
|
}
|
|
@@ -32,7 +32,7 @@ class InjectedWalletBase extends SolanaWalletConnector {
|
|
|
32
32
|
return this;
|
|
33
33
|
}
|
|
34
34
|
// if the wallet is not installed on the browser and WC is available, return the WC connector
|
|
35
|
-
const wcConnector = new SolanaWalletConnectConnector(Object.assign(Object.assign({}, this.constructorProps), { metadata: getWalletMetadataFromWalletBook(Object.assign(Object.assign({}, this.metadata), { walletBookWallet: this.walletConnectWalletBookEntry, walletKey: this.key })), overrideKey: this.key, walletName: this.name }));
|
|
35
|
+
const wcConnector = new SolanaWalletConnectConnector(Object.assign(Object.assign({}, this.constructorProps), { metadata: getWalletMetadataFromWalletBook(Object.assign(Object.assign({}, this.metadata), { walletBook: this.walletBook, walletBookWallet: this.walletConnectWalletBookEntry, walletKey: this.key })), overrideKey: this.key, walletName: this.name }));
|
|
36
36
|
wcConnector.init();
|
|
37
37
|
return wcConnector;
|
|
38
38
|
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
'use client'
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
+
|
|
6
|
+
var addSolanaWalletConnectConnectors = require('./utils/addSolanaWalletConnectConnectors/addSolanaWalletConnectConnectors.cjs');
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Returns ALL Solana WalletConnect connectors from the wallet book.
|
|
10
|
+
*
|
|
11
|
+
* WARNING: This should only be used if you have no other Solana connectors.
|
|
12
|
+
* If you have other Solana connectors, you should use addSolanaWalletConnectConnectors instead.
|
|
13
|
+
*/
|
|
14
|
+
const SolanaWalletConnectConnectors = (
|
|
15
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
16
|
+
props) => addSolanaWalletConnectConnectors.addSolanaWalletConnectConnectors({
|
|
17
|
+
connectors: [],
|
|
18
|
+
walletBook: props.walletBook,
|
|
19
|
+
});
|
|
20
|
+
|
|
21
|
+
exports.SolanaWalletConnectConnectors = SolanaWalletConnectConnectors;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { WalletConnectorConstructor } from '@dynamic-labs/wallet-connector-core';
|
|
2
|
+
/**
|
|
3
|
+
* Returns ALL Solana WalletConnect connectors from the wallet book.
|
|
4
|
+
*
|
|
5
|
+
* WARNING: This should only be used if you have no other Solana connectors.
|
|
6
|
+
* If you have other Solana connectors, you should use addSolanaWalletConnectConnectors instead.
|
|
7
|
+
*/
|
|
8
|
+
export declare const SolanaWalletConnectConnectors: (props: any) => WalletConnectorConstructor[];
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
'use client'
|
|
2
|
+
import { addSolanaWalletConnectConnectors } from './utils/addSolanaWalletConnectConnectors/addSolanaWalletConnectConnectors.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Returns ALL Solana WalletConnect connectors from the wallet book.
|
|
6
|
+
*
|
|
7
|
+
* WARNING: This should only be used if you have no other Solana connectors.
|
|
8
|
+
* If you have other Solana connectors, you should use addSolanaWalletConnectConnectors instead.
|
|
9
|
+
*/
|
|
10
|
+
const SolanaWalletConnectConnectors = (
|
|
11
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
12
|
+
props) => addSolanaWalletConnectConnectors({
|
|
13
|
+
connectors: [],
|
|
14
|
+
walletBook: props.walletBook,
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
export { SolanaWalletConnectConnectors };
|
|
@@ -27,6 +27,7 @@ const addSolanaWalletConnectConnectors = ({ walletBook, connectors: currentConne
|
|
|
27
27
|
const SolanaWalletConnectConnectorConstructor = class extends SolanaWalletConnectConnector.SolanaWalletConnectConnector {
|
|
28
28
|
constructor(props) {
|
|
29
29
|
super(Object.assign(Object.assign({}, props), { metadata: walletConnectorCore.getWalletMetadataFromWalletBook({
|
|
30
|
+
walletBook,
|
|
30
31
|
walletBookWallet: wallet,
|
|
31
32
|
walletKey: key,
|
|
32
33
|
}), overrideKey: key, walletName: name }));
|
|
@@ -53,11 +54,14 @@ const addSolanaWalletConnectConnectors = ({ walletBook, connectors: currentConne
|
|
|
53
54
|
});
|
|
54
55
|
return SolanaWalletConnectConnectorConstructor;
|
|
55
56
|
});
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
let filteredWcConstructors = allWcConstructors;
|
|
58
|
+
if (currentConnectors.length > 0) {
|
|
59
|
+
filteredWcConstructors = allWcConstructors.filter((constructor) => currentConnectors.every((existingConnector) =>
|
|
59
60
|
// @ts-expect-error - the key type is not defined for the constructor
|
|
60
|
-
|
|
61
|
+
existingConnector['key'] !== constructor['key'] &&
|
|
62
|
+
// @ts-expect-error - the key type is not defined for the constructor
|
|
63
|
+
!constructor['groupedKeys'].includes(existingConnector['key'])));
|
|
64
|
+
}
|
|
61
65
|
return [...currentConnectors, ...filteredWcConstructors];
|
|
62
66
|
};
|
|
63
67
|
|
package/src/walletConnect/utils/addSolanaWalletConnectConnectors/addSolanaWalletConnectConnectors.js
CHANGED
|
@@ -23,6 +23,7 @@ const addSolanaWalletConnectConnectors = ({ walletBook, connectors: currentConne
|
|
|
23
23
|
const SolanaWalletConnectConnectorConstructor = class extends SolanaWalletConnectConnector {
|
|
24
24
|
constructor(props) {
|
|
25
25
|
super(Object.assign(Object.assign({}, props), { metadata: getWalletMetadataFromWalletBook({
|
|
26
|
+
walletBook,
|
|
26
27
|
walletBookWallet: wallet,
|
|
27
28
|
walletKey: key,
|
|
28
29
|
}), overrideKey: key, walletName: name }));
|
|
@@ -49,11 +50,14 @@ const addSolanaWalletConnectConnectors = ({ walletBook, connectors: currentConne
|
|
|
49
50
|
});
|
|
50
51
|
return SolanaWalletConnectConnectorConstructor;
|
|
51
52
|
});
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
53
|
+
let filteredWcConstructors = allWcConstructors;
|
|
54
|
+
if (currentConnectors.length > 0) {
|
|
55
|
+
filteredWcConstructors = allWcConstructors.filter((constructor) => currentConnectors.every((existingConnector) =>
|
|
55
56
|
// @ts-expect-error - the key type is not defined for the constructor
|
|
56
|
-
|
|
57
|
+
existingConnector['key'] !== constructor['key'] &&
|
|
58
|
+
// @ts-expect-error - the key type is not defined for the constructor
|
|
59
|
+
!constructor['groupedKeys'].includes(existingConnector['key'])));
|
|
60
|
+
}
|
|
57
61
|
return [...currentConnectors, ...filteredWcConstructors];
|
|
58
62
|
};
|
|
59
63
|
|