@dynamic-labs/ethereum-core 4.9.5 → 4.9.6
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 +15 -0
- package/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +8 -8
- package/src/connector/EthereumWalletConnector.cjs +3 -2
- package/src/connector/EthereumWalletConnector.d.ts +5 -4
- package/src/connector/EthereumWalletConnector.js +3 -2
- package/src/rpc/RpcProvidersEthereum/RpcProvidersEthereum.cjs +1 -1
- package/src/rpc/RpcProvidersEthereum/RpcProvidersEthereum.d.ts +4 -0
- package/src/rpc/RpcProvidersEthereum/RpcProvidersEthereum.js +1 -1
- package/src/wallet/EthereumWallet.cjs +3 -0
- package/src/wallet/EthereumWallet.d.ts +2 -1
- package/src/wallet/EthereumWallet.js +3 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,19 @@
|
|
|
1
1
|
|
|
2
|
+
### [4.9.6](https://github.com/dynamic-labs/dynamic-auth/compare/v4.9.5...v4.9.6) (2025-03-21)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* add initial sui support ([#8317](https://github.com/dynamic-labs/dynamic-auth/issues/8317)) ([88c0234](https://github.com/dynamic-labs/dynamic-auth/commit/88c023483bad5736f38cb313b035279460f6e256))
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Bug Fixes
|
|
11
|
+
|
|
12
|
+
* allow metmask sdk to retry connection ([#8322](https://github.com/dynamic-labs/dynamic-auth/issues/8322)) ([603ed99](https://github.com/dynamic-labs/dynamic-auth/commit/603ed99de3b5d90ac4f5eabcdcd3b2e90863298f))
|
|
13
|
+
* css for profile page without embedded wallets ([#8339](https://github.com/dynamic-labs/dynamic-auth/issues/8339)) ([7f696e9](https://github.com/dynamic-labs/dynamic-auth/commit/7f696e9986ddd899d140640f9af7cfd2dcd7c37a))
|
|
14
|
+
* ensure metamask connector can get display uri for multiple connections ([#8324](https://github.com/dynamic-labs/dynamic-auth/issues/8324)) ([1d95f08](https://github.com/dynamic-labs/dynamic-auth/commit/1d95f089589779e8ef078b80bd84fa0754179696))
|
|
15
|
+
* pass HttpTransportConfig to WalletClient, not just PublicClient ([#8333](https://github.com/dynamic-labs/dynamic-auth/issues/8333)) ([a0ddd10](https://github.com/dynamic-labs/dynamic-auth/commit/a0ddd10f1df57555cf0a3ed777f5d354eb140582))
|
|
16
|
+
|
|
2
17
|
### [4.9.5](https://github.com/dynamic-labs/dynamic-auth/compare/v4.9.4...v4.9.5) (2025-03-19)
|
|
3
18
|
|
|
4
19
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/ethereum-core",
|
|
3
|
-
"version": "4.9.
|
|
3
|
+
"version": "4.9.6",
|
|
4
4
|
"description": "Core package for utilities and types for viem",
|
|
5
5
|
"author": "Dynamic Labs, Inc.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -19,13 +19,13 @@
|
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@dynamic-labs/sdk-api-core": "0.0.644",
|
|
22
|
-
"@dynamic-labs/assert-package-version": "4.9.
|
|
23
|
-
"@dynamic-labs/logger": "4.9.
|
|
24
|
-
"@dynamic-labs/rpc-providers": "4.9.
|
|
25
|
-
"@dynamic-labs/types": "4.9.
|
|
26
|
-
"@dynamic-labs/utils": "4.9.
|
|
27
|
-
"@dynamic-labs/wallet-book": "4.9.
|
|
28
|
-
"@dynamic-labs/wallet-connector-core": "4.9.
|
|
22
|
+
"@dynamic-labs/assert-package-version": "4.9.6",
|
|
23
|
+
"@dynamic-labs/logger": "4.9.6",
|
|
24
|
+
"@dynamic-labs/rpc-providers": "4.9.6",
|
|
25
|
+
"@dynamic-labs/types": "4.9.6",
|
|
26
|
+
"@dynamic-labs/utils": "4.9.6",
|
|
27
|
+
"@dynamic-labs/wallet-book": "4.9.6",
|
|
28
|
+
"@dynamic-labs/wallet-connector-core": "4.9.6"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {
|
|
31
31
|
"viem": "^2.21.55"
|
|
@@ -19,7 +19,7 @@ var EthereumWallet = require('../wallet/EthereumWallet.cjs');
|
|
|
19
19
|
|
|
20
20
|
class EthereumWalletConnector extends walletConnectorCore.WalletConnectorBase {
|
|
21
21
|
constructor(props) {
|
|
22
|
-
var _a, _b;
|
|
22
|
+
var _a, _b, _c;
|
|
23
23
|
super(props);
|
|
24
24
|
this.supportedChains = ['EVM', 'ETH'];
|
|
25
25
|
this.connectedChain = 'EVM';
|
|
@@ -33,8 +33,9 @@ class EthereumWalletConnector extends walletConnectorCore.WalletConnectorBase {
|
|
|
33
33
|
}, {});
|
|
34
34
|
this.walletUiUtils = props.walletUiUtils;
|
|
35
35
|
this.evmNetworks = utils.parseEvmNetworks(props.evmNetworks);
|
|
36
|
+
this.providersConfig = (_a = props.providersConfig) !== null && _a !== void 0 ? _a : {};
|
|
36
37
|
this.chainRpcProviders = props.chainRpcProviders;
|
|
37
|
-
(
|
|
38
|
+
(_b = this.chainRpcProviders) === null || _b === void 0 ? void 0 : _b.registerEvmProviders((_c = this.providersConfig) !== null && _c !== void 0 ? _c : {});
|
|
38
39
|
}
|
|
39
40
|
getPublicClient() {
|
|
40
41
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
@@ -23,6 +23,7 @@ export declare abstract class EthereumWalletConnector extends WalletConnectorBas
|
|
|
23
23
|
supportedChains: Chain[];
|
|
24
24
|
connectedChain: Chain;
|
|
25
25
|
evmNetworks: EvmNetwork[];
|
|
26
|
+
providersConfig: RegisterEvmProvidersConfig;
|
|
26
27
|
ChainWallet: typeof EthereumWallet;
|
|
27
28
|
private activeAccount;
|
|
28
29
|
private activeChain;
|
|
@@ -7471,7 +7472,7 @@ export declare abstract class EthereumWalletConnector extends WalletConnectorBas
|
|
|
7471
7472
|
[x: `address[${string}]`]: undefined;
|
|
7472
7473
|
[x: `bool[${string}]`]: undefined;
|
|
7473
7474
|
[x: `bytes[${string}]`]: undefined;
|
|
7474
|
-
[x: `
|
|
7475
|
+
[x: `bytes11[${string}]`]: undefined;
|
|
7475
7476
|
[x: `bytes1[${string}]`]: undefined;
|
|
7476
7477
|
[x: `bytes32[${string}]`]: undefined;
|
|
7477
7478
|
[x: `bytes31[${string}]`]: undefined;
|
|
@@ -7495,7 +7496,7 @@ export declare abstract class EthereumWalletConnector extends WalletConnectorBas
|
|
|
7495
7496
|
[x: `bytes14[${string}]`]: undefined;
|
|
7496
7497
|
[x: `bytes13[${string}]`]: undefined;
|
|
7497
7498
|
[x: `bytes12[${string}]`]: undefined;
|
|
7498
|
-
[x: `
|
|
7499
|
+
[x: `bytes10[${string}]`]: undefined;
|
|
7499
7500
|
[x: `bytes9[${string}]`]: undefined;
|
|
7500
7501
|
[x: `bytes8[${string}]`]: undefined;
|
|
7501
7502
|
[x: `bytes7[${string}]`]: undefined;
|
|
@@ -7573,7 +7574,7 @@ export declare abstract class EthereumWalletConnector extends WalletConnectorBas
|
|
|
7573
7574
|
address?: undefined;
|
|
7574
7575
|
bool?: undefined;
|
|
7575
7576
|
bytes?: undefined;
|
|
7576
|
-
|
|
7577
|
+
bytes11?: undefined;
|
|
7577
7578
|
bytes1?: undefined;
|
|
7578
7579
|
bytes32?: undefined;
|
|
7579
7580
|
bytes31?: undefined;
|
|
@@ -7597,7 +7598,7 @@ export declare abstract class EthereumWalletConnector extends WalletConnectorBas
|
|
|
7597
7598
|
bytes14?: undefined;
|
|
7598
7599
|
bytes13?: undefined;
|
|
7599
7600
|
bytes12?: undefined;
|
|
7600
|
-
|
|
7601
|
+
bytes10?: undefined;
|
|
7601
7602
|
bytes9?: undefined;
|
|
7602
7603
|
bytes8?: undefined;
|
|
7603
7604
|
bytes7?: undefined;
|
|
@@ -15,7 +15,7 @@ import { EthereumWallet } from '../wallet/EthereumWallet.js';
|
|
|
15
15
|
|
|
16
16
|
class EthereumWalletConnector extends WalletConnectorBase {
|
|
17
17
|
constructor(props) {
|
|
18
|
-
var _a, _b;
|
|
18
|
+
var _a, _b, _c;
|
|
19
19
|
super(props);
|
|
20
20
|
this.supportedChains = ['EVM', 'ETH'];
|
|
21
21
|
this.connectedChain = 'EVM';
|
|
@@ -29,8 +29,9 @@ class EthereumWalletConnector extends WalletConnectorBase {
|
|
|
29
29
|
}, {});
|
|
30
30
|
this.walletUiUtils = props.walletUiUtils;
|
|
31
31
|
this.evmNetworks = parseEvmNetworks(props.evmNetworks);
|
|
32
|
+
this.providersConfig = (_a = props.providersConfig) !== null && _a !== void 0 ? _a : {};
|
|
32
33
|
this.chainRpcProviders = props.chainRpcProviders;
|
|
33
|
-
(
|
|
34
|
+
(_b = this.chainRpcProviders) === null || _b === void 0 ? void 0 : _b.registerEvmProviders((_c = this.providersConfig) !== null && _c !== void 0 ? _c : {});
|
|
34
35
|
}
|
|
35
36
|
getPublicClient() {
|
|
36
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -23,7 +23,7 @@ rpcProviders.ChainRpcProviders.registerEvmProviders = (providersConfig) => {
|
|
|
23
23
|
const rpcUrl = ((_a = network.privateCustomerRpcUrls) === null || _a === void 0 ? void 0 : _a[0]) || network.rpcUrls[0];
|
|
24
24
|
const provider = viem.createPublicClient({
|
|
25
25
|
chain: getOrMapViemChain.getOrMapViemChain(network),
|
|
26
|
-
transport: viem.http(rpcUrl, providersConfig === null || providersConfig === void 0 ? void 0 : providersConfig.
|
|
26
|
+
transport: viem.http(rpcUrl, providersConfig === null || providersConfig === void 0 ? void 0 : providersConfig.httpTransportConfig),
|
|
27
27
|
});
|
|
28
28
|
return {
|
|
29
29
|
chainId: network.chainId,
|
|
@@ -6,7 +6,11 @@ type IEvmRpcProvider = {
|
|
|
6
6
|
provider: PublicClient<Transport, Chain>;
|
|
7
7
|
};
|
|
8
8
|
export type RegisterEvmProvidersConfig = {
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated Use `httpTransportConfig` instead.
|
|
11
|
+
*/
|
|
9
12
|
publicClientHttpTransportConfig?: HttpTransportConfig;
|
|
13
|
+
httpTransportConfig?: HttpTransportConfig;
|
|
10
14
|
};
|
|
11
15
|
declare module '@dynamic-labs/rpc-providers' {
|
|
12
16
|
type EvmRpcProvider = IEvmRpcProvider;
|
|
@@ -21,7 +21,7 @@ ChainRpcProviders.registerEvmProviders = (providersConfig) => {
|
|
|
21
21
|
const rpcUrl = ((_a = network.privateCustomerRpcUrls) === null || _a === void 0 ? void 0 : _a[0]) || network.rpcUrls[0];
|
|
22
22
|
const provider = createPublicClient({
|
|
23
23
|
chain: getOrMapViemChain(network),
|
|
24
|
-
transport: http(rpcUrl, providersConfig === null || providersConfig === void 0 ? void 0 : providersConfig.
|
|
24
|
+
transport: http(rpcUrl, providersConfig === null || providersConfig === void 0 ? void 0 : providersConfig.httpTransportConfig),
|
|
25
25
|
});
|
|
26
26
|
return {
|
|
27
27
|
chainId: network.chainId,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Account, Chain, PublicClient, Transport, WalletClient } from 'viem';
|
|
1
|
+
import { Account, Chain, HttpTransportConfig, PublicClient, Transport, WalletClient } from 'viem';
|
|
2
2
|
import { Wallet, WalletProps } from '@dynamic-labs/wallet-connector-core';
|
|
3
3
|
import { EthereumWalletConnector } from '../connector';
|
|
4
4
|
export declare class EthereumWallet extends Wallet<EthereumWalletConnector> {
|
|
@@ -33,4 +33,5 @@ export declare class EthereumWallet extends Wallet<EthereumWalletConnector> {
|
|
|
33
33
|
* or throws if the client cannot be retrieved.
|
|
34
34
|
*/
|
|
35
35
|
getWalletClient(chainId?: string): Promise<WalletClient<Transport, Chain, Account>>;
|
|
36
|
+
getTransportConfig(): HttpTransportConfig | undefined;
|
|
36
37
|
}
|