@dynamic-labs/wagmi-connector 0.15.14 → 0.15.16
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 +17 -0
- package/index.cjs +5 -6
- package/index.js +5 -6
- package/package.json +2 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,21 @@
|
|
|
1
1
|
|
|
2
|
+
### [0.15.16](https://github.com/dynamic-labs/DynamicAuth/compare/v0.15.15...v0.15.16) (2023-03-24)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Bug Fixes
|
|
6
|
+
|
|
7
|
+
* **magic_wallet:** prevent failure when email is edited ([3caa374](https://github.com/dynamic-labs/DynamicAuth/commit/3caa3744a7dbcd1f5d7515e271fe0df53364a81d))
|
|
8
|
+
* remove dep on multi-wallet in wagmi connector ([9475f3d](https://github.com/dynamic-labs/DynamicAuth/commit/9475f3dd42e1ae3d6b56f61afe342dcaeed8699a))
|
|
9
|
+
|
|
10
|
+
### [0.15.15](https://github.com/dynamic-labs/DynamicAuth/compare/v0.15.14...v0.15.15) (2023-03-23)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
* **CustomerCallbacks:** make sure that we always call customer callbacks ([cad24fc](https://github.com/dynamic-labs/DynamicAuth/commit/cad24fc7a5556f2ac9ea3c2d327255fcdef1a275))
|
|
16
|
+
* **magic_wallet:** disconnect user when magic is logged out ([8a1885e](https://github.com/dynamic-labs/DynamicAuth/commit/8a1885ea52e078dbc5d2d4b52dcced3e97ae16a7))
|
|
17
|
+
* **NetworkPicker:** make sure that we use correct network picker on 'network not supported' step ([2777b35](https://github.com/dynamic-labs/DynamicAuth/commit/2777b35e0adb76857cbe155d0ce9895b534535bf))
|
|
18
|
+
|
|
2
19
|
### [0.15.14](https://github.com/dynamic-labs/DynamicAuth/compare/v0.15.13...v0.15.14) (2023-03-23)
|
|
3
20
|
|
|
4
21
|
|
package/index.cjs
CHANGED
|
@@ -7,7 +7,6 @@ var wagmi = require('wagmi');
|
|
|
7
7
|
var _public = require('wagmi/providers/public');
|
|
8
8
|
var sdkReact = require('@dynamic-labs/sdk-react');
|
|
9
9
|
var utils = require('ethers/lib/utils.js');
|
|
10
|
-
var multiWallet = require('@dynamic-labs/multi-wallet');
|
|
11
10
|
var allChains = require('wagmi/chains');
|
|
12
11
|
var ethers = require('ethers');
|
|
13
12
|
|
|
@@ -1188,7 +1187,7 @@ class Connector extends wagmi.Connector {
|
|
|
1188
1187
|
connect(config) {
|
|
1189
1188
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1190
1189
|
if (!this.walletConnector) {
|
|
1191
|
-
throw new
|
|
1190
|
+
throw new Error('WalletConnector is not defined');
|
|
1192
1191
|
}
|
|
1193
1192
|
const account = yield this.getAccount();
|
|
1194
1193
|
this.setupEventListeners();
|
|
@@ -1228,7 +1227,7 @@ class Connector extends wagmi.Connector {
|
|
|
1228
1227
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1229
1228
|
const address = yield (_a = this.walletConnector) === null || _a === void 0 ? void 0 : _a.fetchPublicAddress();
|
|
1230
1229
|
if (!address) {
|
|
1231
|
-
throw new
|
|
1230
|
+
throw new Error('Not connected');
|
|
1232
1231
|
}
|
|
1233
1232
|
return utils.getAddress(address);
|
|
1234
1233
|
});
|
|
@@ -1236,11 +1235,11 @@ class Connector extends wagmi.Connector {
|
|
|
1236
1235
|
getChainId() {
|
|
1237
1236
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1238
1237
|
if (!this.walletConnector) {
|
|
1239
|
-
throw new
|
|
1238
|
+
throw new Error('WalletConnector is not defined');
|
|
1240
1239
|
}
|
|
1241
1240
|
const network = yield this.walletConnector.getNetwork();
|
|
1242
1241
|
if (!network) {
|
|
1243
|
-
throw new
|
|
1242
|
+
throw new Error('Network is not defined');
|
|
1244
1243
|
}
|
|
1245
1244
|
return network;
|
|
1246
1245
|
});
|
|
@@ -1289,7 +1288,7 @@ class Connector extends wagmi.Connector {
|
|
|
1289
1288
|
});
|
|
1290
1289
|
}
|
|
1291
1290
|
watchAsset(asset) {
|
|
1292
|
-
throw new
|
|
1291
|
+
throw new Error('Method not implemented.');
|
|
1293
1292
|
}
|
|
1294
1293
|
}
|
|
1295
1294
|
|
package/index.js
CHANGED
|
@@ -3,7 +3,6 @@ import { Connector as Connector$1, useClient, useConnect, useDisconnect, mainnet
|
|
|
3
3
|
import { publicProvider } from 'wagmi/providers/public';
|
|
4
4
|
import { useDynamicContext } from '@dynamic-labs/sdk-react';
|
|
5
5
|
import { getAddress, hexValue } from 'ethers/lib/utils.js';
|
|
6
|
-
import { DynamicError } from '@dynamic-labs/multi-wallet';
|
|
7
6
|
import * as allChains from 'wagmi/chains';
|
|
8
7
|
import { providers } from 'ethers';
|
|
9
8
|
|
|
@@ -1161,7 +1160,7 @@ class Connector extends Connector$1 {
|
|
|
1161
1160
|
connect(config) {
|
|
1162
1161
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1163
1162
|
if (!this.walletConnector) {
|
|
1164
|
-
throw new
|
|
1163
|
+
throw new Error('WalletConnector is not defined');
|
|
1165
1164
|
}
|
|
1166
1165
|
const account = yield this.getAccount();
|
|
1167
1166
|
this.setupEventListeners();
|
|
@@ -1201,7 +1200,7 @@ class Connector extends Connector$1 {
|
|
|
1201
1200
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1202
1201
|
const address = yield (_a = this.walletConnector) === null || _a === void 0 ? void 0 : _a.fetchPublicAddress();
|
|
1203
1202
|
if (!address) {
|
|
1204
|
-
throw new
|
|
1203
|
+
throw new Error('Not connected');
|
|
1205
1204
|
}
|
|
1206
1205
|
return getAddress(address);
|
|
1207
1206
|
});
|
|
@@ -1209,11 +1208,11 @@ class Connector extends Connector$1 {
|
|
|
1209
1208
|
getChainId() {
|
|
1210
1209
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1211
1210
|
if (!this.walletConnector) {
|
|
1212
|
-
throw new
|
|
1211
|
+
throw new Error('WalletConnector is not defined');
|
|
1213
1212
|
}
|
|
1214
1213
|
const network = yield this.walletConnector.getNetwork();
|
|
1215
1214
|
if (!network) {
|
|
1216
|
-
throw new
|
|
1215
|
+
throw new Error('Network is not defined');
|
|
1217
1216
|
}
|
|
1218
1217
|
return network;
|
|
1219
1218
|
});
|
|
@@ -1262,7 +1261,7 @@ class Connector extends Connector$1 {
|
|
|
1262
1261
|
});
|
|
1263
1262
|
}
|
|
1264
1263
|
watchAsset(asset) {
|
|
1265
|
-
throw new
|
|
1264
|
+
throw new Error('Method not implemented.');
|
|
1266
1265
|
}
|
|
1267
1266
|
}
|
|
1268
1267
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/wagmi-connector",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.16",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -12,8 +12,7 @@
|
|
|
12
12
|
"react": "^17.0.2 || ^18.0.0",
|
|
13
13
|
"ethers": "^5.7.2",
|
|
14
14
|
"wagmi": "~0.10.3",
|
|
15
|
-
"@dynamic-labs/
|
|
16
|
-
"@dynamic-labs/sdk-react": "0.15.14"
|
|
15
|
+
"@dynamic-labs/sdk-react": "0.15.16"
|
|
17
16
|
},
|
|
18
17
|
"license": "MIT",
|
|
19
18
|
"module": "./index.js",
|