@dynamic-labs/ethereum 0.19.0-alpha.13 → 0.19.0-alpha.15
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 +28 -0
- package/package.json +7 -7
- package/src/EthWalletConnector.cjs +6 -2
- package/src/EthWalletConnector.js +7 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,32 @@
|
|
|
1
1
|
|
|
2
|
+
## [0.19.0-alpha.15](https://github.com/dynamic-labs/DynamicAuth/compare/v0.19.0-alpha.14...v0.19.0-alpha.15) (2023-10-11)
|
|
3
|
+
|
|
4
|
+
## [0.19.0-alpha.14](https://github.com/dynamic-labs/DynamicAuth/compare/v0.19.0-alpha.13...v0.19.0-alpha.14) (2023-10-10)
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
### ⚠ BREAKING CHANGES
|
|
8
|
+
|
|
9
|
+
* remove numberOfWallets (#3521)
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* add embedded widget components ([#3533](https://github.com/dynamic-labs/DynamicAuth/issues/3533)) ([513cba8](https://github.com/dynamic-labs/DynamicAuth/commit/513cba8e7694544122ff9cce3aa1aea0a0c23986))
|
|
14
|
+
* add ethers extension support to wallet-connectors ([#3544](https://github.com/dynamic-labs/DynamicAuth/issues/3544)) ([3c09ba5](https://github.com/dynamic-labs/DynamicAuth/commit/3c09ba58b0f2c745df60a87b1820abbbfc1b95b7))
|
|
15
|
+
* add switch network for turnkey wallets ([#3539](https://github.com/dynamic-labs/DynamicAuth/issues/3539)) ([1bcbbb2](https://github.com/dynamic-labs/DynamicAuth/commit/1bcbbb2bd4e333d47ce4c93d4bd4b1f29a80c1f4))
|
|
16
|
+
* editable copy for switch network view ([#3561](https://github.com/dynamic-labs/DynamicAuth/issues/3561)) ([4dea2f1](https://github.com/dynamic-labs/DynamicAuth/commit/4dea2f159ee0675d5b9ba1cb412d75e5e211b3d1))
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
### Bug Fixes
|
|
20
|
+
|
|
21
|
+
* always call connectSucess callback after successfully connecting wallet ([#3562](https://github.com/dynamic-labs/DynamicAuth/issues/3562)) ([2587ff8](https://github.com/dynamic-labs/DynamicAuth/commit/2587ff8a915f61793b15bfa1289689514344fc75))
|
|
22
|
+
* don't let user update email if they have an embedded wallet ([#3552](https://github.com/dynamic-labs/DynamicAuth/issues/3552)) ([c710cce](https://github.com/dynamic-labs/DynamicAuth/commit/c710cce22c7a54004f56c8fc68f8c4075f5f9e51))
|
|
23
|
+
* embedded widget rerender bug ([#3545](https://github.com/dynamic-labs/DynamicAuth/issues/3545)) ([27ed979](https://github.com/dynamic-labs/DynamicAuth/commit/27ed979618ac7d9e912381faebbf61ec9e9e839c))
|
|
24
|
+
* sync passkey should not throw error ([#3535](https://github.com/dynamic-labs/DynamicAuth/issues/3535)) ([0336ba6](https://github.com/dynamic-labs/DynamicAuth/commit/0336ba65bf1cc4394e4f005f273baea26326784a))
|
|
25
|
+
* wrap eth wallet connector rpc calls in retry function ([#3497](https://github.com/dynamic-labs/DynamicAuth/issues/3497)) ([7800b45](https://github.com/dynamic-labs/DynamicAuth/commit/7800b45dc93f20731ee643e89e84d57765387778))
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
* remove numberOfWallets ([#3521](https://github.com/dynamic-labs/DynamicAuth/issues/3521)) ([0174297](https://github.com/dynamic-labs/DynamicAuth/commit/017429745d08b7b1edc23bc4da43bc01b4ef1cd4))
|
|
29
|
+
|
|
2
30
|
## [0.19.0-alpha.13](https://github.com/dynamic-labs/DynamicAuth/compare/v0.19.0-alpha.12...v0.19.0-alpha.13) (2023-10-04)
|
|
3
31
|
|
|
4
32
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/ethereum",
|
|
3
|
-
"version": "0.19.0-alpha.
|
|
3
|
+
"version": "0.19.0-alpha.15",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "https://github.com/dynamic-labs/DynamicAuth.git",
|
|
@@ -28,14 +28,14 @@
|
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@walletconnect/client": "1.8.0",
|
|
30
30
|
"@walletconnect/ethereum-provider": "1.8.0",
|
|
31
|
-
"@walletconnect/universal-provider": "2.
|
|
31
|
+
"@walletconnect/universal-provider": "2.10.1",
|
|
32
32
|
"eventemitter3": "5.0.1",
|
|
33
33
|
"buffer": "6.0.3",
|
|
34
|
-
"@dynamic-labs/rpc-providers": "0.19.0-alpha.
|
|
35
|
-
"@dynamic-labs/types": "0.19.0-alpha.
|
|
36
|
-
"@dynamic-labs/utils": "0.19.0-alpha.
|
|
37
|
-
"@dynamic-labs/wallet-book": "0.19.0-alpha.
|
|
38
|
-
"@dynamic-labs/wallet-connector-core": "0.19.0-alpha.
|
|
34
|
+
"@dynamic-labs/rpc-providers": "0.19.0-alpha.15",
|
|
35
|
+
"@dynamic-labs/types": "0.19.0-alpha.15",
|
|
36
|
+
"@dynamic-labs/utils": "0.19.0-alpha.15",
|
|
37
|
+
"@dynamic-labs/wallet-book": "0.19.0-alpha.15",
|
|
38
|
+
"@dynamic-labs/wallet-connector-core": "0.19.0-alpha.15",
|
|
39
39
|
"stream": "0.0.2"
|
|
40
40
|
},
|
|
41
41
|
"peerDependencies": {
|
|
@@ -64,7 +64,9 @@ class EthWalletConnector extends walletConnectorCore.WalletConnectorBase {
|
|
|
64
64
|
if (!this.supportsNetworkSwitching || !provider) {
|
|
65
65
|
return Promise.resolve(undefined);
|
|
66
66
|
}
|
|
67
|
-
return
|
|
67
|
+
return utils.retryableFn(provider.getChainId, {
|
|
68
|
+
fallbackValue: utils.FALLBACK_UNDEFINED,
|
|
69
|
+
});
|
|
68
70
|
});
|
|
69
71
|
}
|
|
70
72
|
getNameService() {
|
|
@@ -140,7 +142,9 @@ class EthWalletConnector extends walletConnectorCore.WalletConnectorBase {
|
|
|
140
142
|
const provider = this.getWeb3Provider();
|
|
141
143
|
if (!provider)
|
|
142
144
|
return [];
|
|
143
|
-
return provider.getAddresses
|
|
145
|
+
return utils.retryableFn(provider.getAddresses, {
|
|
146
|
+
fallbackValue: [],
|
|
147
|
+
});
|
|
144
148
|
});
|
|
145
149
|
}
|
|
146
150
|
providerSwitchNetwork({ network, provider, }) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { __awaiter } from '../_virtual/_tslib.js';
|
|
2
2
|
import { createPublicClient, http, formatEther } from 'viem';
|
|
3
3
|
import { WalletConnectorBase } from '@dynamic-labs/wallet-connector-core';
|
|
4
|
-
import { parseEvmNetworks, getOrMapViemChain, DynamicError } from '@dynamic-labs/utils';
|
|
4
|
+
import { parseEvmNetworks, getOrMapViemChain, retryableFn, FALLBACK_UNDEFINED, DynamicError } from '@dynamic-labs/utils';
|
|
5
5
|
import { ProviderChain } from '@dynamic-labs/rpc-providers';
|
|
6
6
|
import { findEvmNetwork } from './utils/findEvmNetwork.js';
|
|
7
7
|
|
|
@@ -60,7 +60,9 @@ class EthWalletConnector extends WalletConnectorBase {
|
|
|
60
60
|
if (!this.supportsNetworkSwitching || !provider) {
|
|
61
61
|
return Promise.resolve(undefined);
|
|
62
62
|
}
|
|
63
|
-
return
|
|
63
|
+
return retryableFn(provider.getChainId, {
|
|
64
|
+
fallbackValue: FALLBACK_UNDEFINED,
|
|
65
|
+
});
|
|
64
66
|
});
|
|
65
67
|
}
|
|
66
68
|
getNameService() {
|
|
@@ -136,7 +138,9 @@ class EthWalletConnector extends WalletConnectorBase {
|
|
|
136
138
|
const provider = this.getWeb3Provider();
|
|
137
139
|
if (!provider)
|
|
138
140
|
return [];
|
|
139
|
-
return provider.getAddresses
|
|
141
|
+
return retryableFn(provider.getAddresses, {
|
|
142
|
+
fallbackValue: [],
|
|
143
|
+
});
|
|
140
144
|
});
|
|
141
145
|
}
|
|
142
146
|
providerSwitchNetwork({ network, provider, }) {
|