@depay/web3-wallets-evm 14.9.0 → 14.9.2
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/dist/esm/index.evm.js +7 -9
- package/dist/esm/index.js +7 -9
- package/dist/umd/index.evm.js +7 -9
- package/dist/umd/index.js +7 -9
- package/package.json +1 -1
package/dist/esm/index.evm.js
CHANGED
|
@@ -60155,8 +60155,8 @@ class WalletConnectV1 {
|
|
|
60155
60155
|
};}
|
|
60156
60156
|
|
|
60157
60157
|
constructor() {
|
|
60158
|
-
this.name = this.constructor.info.name;
|
|
60159
|
-
this.logo = this.constructor.info.logo;
|
|
60158
|
+
this.name = localStorage[KEY$1+'_name'] ? localStorage[KEY$1+'_name'] : this.constructor.info.name;
|
|
60159
|
+
this.logo = localStorage[KEY$1+'_logo'] ? localStorage[KEY$1+'_logo'] : this.constructor.info.logo;
|
|
60160
60160
|
this.blockchains = this.constructor.info.blockchains;
|
|
60161
60161
|
this.sendTransaction = (transaction)=>{
|
|
60162
60162
|
return sendTransaction$3({
|
|
@@ -60185,6 +60185,8 @@ class WalletConnectV1 {
|
|
|
60185
60185
|
|
|
60186
60186
|
instance.on("disconnect", (error, payload) => {
|
|
60187
60187
|
setConnectedInstance$2(undefined);
|
|
60188
|
+
localStorage[KEY$1+'_name'] = undefined;
|
|
60189
|
+
localStorage[KEY$1+'_logo'] = undefined;
|
|
60188
60190
|
if (error) { throw error }
|
|
60189
60191
|
});
|
|
60190
60192
|
|
|
@@ -60204,9 +60206,6 @@ class WalletConnectV1 {
|
|
|
60204
60206
|
|
|
60205
60207
|
async connect(options) {
|
|
60206
60208
|
let connect = (options && options.connect) ? options.connect : ({uri})=>{};
|
|
60207
|
-
localStorage[KEY$1] = {};
|
|
60208
|
-
if(_optionalChain$4([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1].name = this.name = options.name; }
|
|
60209
|
-
if(_optionalChain$4([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1].logo = this.logo = options.logo; }
|
|
60210
60209
|
try {
|
|
60211
60210
|
|
|
60212
60211
|
this.connector = WalletConnectV1.instance;
|
|
@@ -60216,10 +60215,6 @@ class WalletConnectV1 {
|
|
|
60216
60215
|
}
|
|
60217
60216
|
|
|
60218
60217
|
if(this.connector.connected) {
|
|
60219
|
-
if(localStorage[KEY$1]) {
|
|
60220
|
-
if(localStorage[KEY$1].name) { this.name = localStorage[KEY$1].name; }
|
|
60221
|
-
if(localStorage[KEY$1].logo) { this.logo = localStorage[KEY$1].logo; }
|
|
60222
|
-
}
|
|
60223
60218
|
|
|
60224
60219
|
let account = await this.account();
|
|
60225
60220
|
this.connectedChainId = await this.connector.sendCustomRequest({ method: 'eth_chainId' });
|
|
@@ -60229,6 +60224,9 @@ class WalletConnectV1 {
|
|
|
60229
60224
|
|
|
60230
60225
|
let { accounts, chainId } = await this.connector.connect();
|
|
60231
60226
|
|
|
60227
|
+
if(_optionalChain$4([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1+'_name'] = this.name = options.name; }
|
|
60228
|
+
if(_optionalChain$4([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1+'_logo'] = this.logo = options.logo; }
|
|
60229
|
+
|
|
60232
60230
|
if(accounts instanceof Array && accounts.length) {
|
|
60233
60231
|
setConnectedInstance$2(this);
|
|
60234
60232
|
accounts = accounts.map((account)=>ethers.utils.getAddress(account));
|
package/dist/esm/index.js
CHANGED
|
@@ -1249,8 +1249,8 @@ class WalletConnectV1 {
|
|
|
1249
1249
|
};}
|
|
1250
1250
|
|
|
1251
1251
|
constructor() {
|
|
1252
|
-
this.name = this.constructor.info.name;
|
|
1253
|
-
this.logo = this.constructor.info.logo;
|
|
1252
|
+
this.name = localStorage[KEY$1+'_name'] ? localStorage[KEY$1+'_name'] : this.constructor.info.name;
|
|
1253
|
+
this.logo = localStorage[KEY$1+'_logo'] ? localStorage[KEY$1+'_logo'] : this.constructor.info.logo;
|
|
1254
1254
|
this.blockchains = this.constructor.info.blockchains;
|
|
1255
1255
|
this.sendTransaction = (transaction)=>{
|
|
1256
1256
|
return sendTransaction$2({
|
|
@@ -1279,6 +1279,8 @@ class WalletConnectV1 {
|
|
|
1279
1279
|
|
|
1280
1280
|
instance.on("disconnect", (error, payload) => {
|
|
1281
1281
|
setConnectedInstance$2(undefined);
|
|
1282
|
+
localStorage[KEY$1+'_name'] = undefined;
|
|
1283
|
+
localStorage[KEY$1+'_logo'] = undefined;
|
|
1282
1284
|
if (error) { throw error }
|
|
1283
1285
|
});
|
|
1284
1286
|
|
|
@@ -1298,9 +1300,6 @@ class WalletConnectV1 {
|
|
|
1298
1300
|
|
|
1299
1301
|
async connect(options) {
|
|
1300
1302
|
let connect = (options && options.connect) ? options.connect : ({uri})=>{};
|
|
1301
|
-
localStorage[KEY$1] = {};
|
|
1302
|
-
if(_optionalChain$2([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1].name = this.name = options.name; }
|
|
1303
|
-
if(_optionalChain$2([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1].logo = this.logo = options.logo; }
|
|
1304
1303
|
try {
|
|
1305
1304
|
|
|
1306
1305
|
this.connector = WalletConnectV1.instance;
|
|
@@ -1310,10 +1309,6 @@ class WalletConnectV1 {
|
|
|
1310
1309
|
}
|
|
1311
1310
|
|
|
1312
1311
|
if(this.connector.connected) {
|
|
1313
|
-
if(localStorage[KEY$1]) {
|
|
1314
|
-
if(localStorage[KEY$1].name) { this.name = localStorage[KEY$1].name; }
|
|
1315
|
-
if(localStorage[KEY$1].logo) { this.logo = localStorage[KEY$1].logo; }
|
|
1316
|
-
}
|
|
1317
1312
|
|
|
1318
1313
|
let account = await this.account();
|
|
1319
1314
|
this.connectedChainId = await this.connector.sendCustomRequest({ method: 'eth_chainId' });
|
|
@@ -1323,6 +1318,9 @@ class WalletConnectV1 {
|
|
|
1323
1318
|
|
|
1324
1319
|
let { accounts, chainId } = await this.connector.connect();
|
|
1325
1320
|
|
|
1321
|
+
if(_optionalChain$2([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1+'_name'] = this.name = options.name; }
|
|
1322
|
+
if(_optionalChain$2([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1+'_logo'] = this.logo = options.logo; }
|
|
1323
|
+
|
|
1326
1324
|
if(accounts instanceof Array && accounts.length) {
|
|
1327
1325
|
setConnectedInstance$2(this);
|
|
1328
1326
|
accounts = accounts.map((account)=>ethers.utils.getAddress(account));
|
package/dist/umd/index.evm.js
CHANGED
|
@@ -60153,8 +60153,8 @@
|
|
|
60153
60153
|
};}
|
|
60154
60154
|
|
|
60155
60155
|
constructor() {
|
|
60156
|
-
this.name = this.constructor.info.name;
|
|
60157
|
-
this.logo = this.constructor.info.logo;
|
|
60156
|
+
this.name = localStorage[KEY$1+'_name'] ? localStorage[KEY$1+'_name'] : this.constructor.info.name;
|
|
60157
|
+
this.logo = localStorage[KEY$1+'_logo'] ? localStorage[KEY$1+'_logo'] : this.constructor.info.logo;
|
|
60158
60158
|
this.blockchains = this.constructor.info.blockchains;
|
|
60159
60159
|
this.sendTransaction = (transaction)=>{
|
|
60160
60160
|
return sendTransaction$3({
|
|
@@ -60183,6 +60183,8 @@
|
|
|
60183
60183
|
|
|
60184
60184
|
instance.on("disconnect", (error, payload) => {
|
|
60185
60185
|
setConnectedInstance$2(undefined);
|
|
60186
|
+
localStorage[KEY$1+'_name'] = undefined;
|
|
60187
|
+
localStorage[KEY$1+'_logo'] = undefined;
|
|
60186
60188
|
if (error) { throw error }
|
|
60187
60189
|
});
|
|
60188
60190
|
|
|
@@ -60202,9 +60204,6 @@
|
|
|
60202
60204
|
|
|
60203
60205
|
async connect(options) {
|
|
60204
60206
|
let connect = (options && options.connect) ? options.connect : ({uri})=>{};
|
|
60205
|
-
localStorage[KEY$1] = {};
|
|
60206
|
-
if(_optionalChain$4([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1].name = this.name = options.name; }
|
|
60207
|
-
if(_optionalChain$4([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1].logo = this.logo = options.logo; }
|
|
60208
60207
|
try {
|
|
60209
60208
|
|
|
60210
60209
|
this.connector = WalletConnectV1.instance;
|
|
@@ -60214,10 +60213,6 @@
|
|
|
60214
60213
|
}
|
|
60215
60214
|
|
|
60216
60215
|
if(this.connector.connected) {
|
|
60217
|
-
if(localStorage[KEY$1]) {
|
|
60218
|
-
if(localStorage[KEY$1].name) { this.name = localStorage[KEY$1].name; }
|
|
60219
|
-
if(localStorage[KEY$1].logo) { this.logo = localStorage[KEY$1].logo; }
|
|
60220
|
-
}
|
|
60221
60216
|
|
|
60222
60217
|
let account = await this.account();
|
|
60223
60218
|
this.connectedChainId = await this.connector.sendCustomRequest({ method: 'eth_chainId' });
|
|
@@ -60227,6 +60222,9 @@
|
|
|
60227
60222
|
|
|
60228
60223
|
let { accounts, chainId } = await this.connector.connect();
|
|
60229
60224
|
|
|
60225
|
+
if(_optionalChain$4([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1+'_name'] = this.name = options.name; }
|
|
60226
|
+
if(_optionalChain$4([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1+'_logo'] = this.logo = options.logo; }
|
|
60227
|
+
|
|
60230
60228
|
if(accounts instanceof Array && accounts.length) {
|
|
60231
60229
|
setConnectedInstance$2(this);
|
|
60232
60230
|
accounts = accounts.map((account)=>ethers.ethers.utils.getAddress(account));
|
package/dist/umd/index.js
CHANGED
|
@@ -1246,8 +1246,8 @@
|
|
|
1246
1246
|
};}
|
|
1247
1247
|
|
|
1248
1248
|
constructor() {
|
|
1249
|
-
this.name = this.constructor.info.name;
|
|
1250
|
-
this.logo = this.constructor.info.logo;
|
|
1249
|
+
this.name = localStorage[KEY$1+'_name'] ? localStorage[KEY$1+'_name'] : this.constructor.info.name;
|
|
1250
|
+
this.logo = localStorage[KEY$1+'_logo'] ? localStorage[KEY$1+'_logo'] : this.constructor.info.logo;
|
|
1251
1251
|
this.blockchains = this.constructor.info.blockchains;
|
|
1252
1252
|
this.sendTransaction = (transaction)=>{
|
|
1253
1253
|
return sendTransaction$2({
|
|
@@ -1276,6 +1276,8 @@
|
|
|
1276
1276
|
|
|
1277
1277
|
instance.on("disconnect", (error, payload) => {
|
|
1278
1278
|
setConnectedInstance$2(undefined);
|
|
1279
|
+
localStorage[KEY$1+'_name'] = undefined;
|
|
1280
|
+
localStorage[KEY$1+'_logo'] = undefined;
|
|
1279
1281
|
if (error) { throw error }
|
|
1280
1282
|
});
|
|
1281
1283
|
|
|
@@ -1295,9 +1297,6 @@
|
|
|
1295
1297
|
|
|
1296
1298
|
async connect(options) {
|
|
1297
1299
|
let connect = (options && options.connect) ? options.connect : ({uri})=>{};
|
|
1298
|
-
localStorage[KEY$1] = {};
|
|
1299
|
-
if(_optionalChain$2([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1].name = this.name = options.name; }
|
|
1300
|
-
if(_optionalChain$2([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1].logo = this.logo = options.logo; }
|
|
1301
1300
|
try {
|
|
1302
1301
|
|
|
1303
1302
|
this.connector = WalletConnectV1.instance;
|
|
@@ -1307,10 +1306,6 @@
|
|
|
1307
1306
|
}
|
|
1308
1307
|
|
|
1309
1308
|
if(this.connector.connected) {
|
|
1310
|
-
if(localStorage[KEY$1]) {
|
|
1311
|
-
if(localStorage[KEY$1].name) { this.name = localStorage[KEY$1].name; }
|
|
1312
|
-
if(localStorage[KEY$1].logo) { this.logo = localStorage[KEY$1].logo; }
|
|
1313
|
-
}
|
|
1314
1309
|
|
|
1315
1310
|
let account = await this.account();
|
|
1316
1311
|
this.connectedChainId = await this.connector.sendCustomRequest({ method: 'eth_chainId' });
|
|
@@ -1320,6 +1315,9 @@
|
|
|
1320
1315
|
|
|
1321
1316
|
let { accounts, chainId } = await this.connector.connect();
|
|
1322
1317
|
|
|
1318
|
+
if(_optionalChain$2([options, 'optionalAccess', _ => _.name])) { localStorage[KEY$1+'_name'] = this.name = options.name; }
|
|
1319
|
+
if(_optionalChain$2([options, 'optionalAccess', _2 => _2.logo])) { localStorage[KEY$1+'_logo'] = this.logo = options.logo; }
|
|
1320
|
+
|
|
1323
1321
|
if(accounts instanceof Array && accounts.length) {
|
|
1324
1322
|
setConnectedInstance$2(this);
|
|
1325
1323
|
accounts = accounts.map((account)=>ethers.ethers.utils.getAddress(account));
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@depay/web3-wallets-evm",
|
|
3
3
|
"moduleName": "Web3Wallets",
|
|
4
|
-
"version": "14.9.
|
|
4
|
+
"version": "14.9.2",
|
|
5
5
|
"description": "One-Stop-Shop JavaScript library to integrate various web3 crypto wallets and multiple blockchains at once with a single interface.",
|
|
6
6
|
"main": "dist/umd/index.evm.js",
|
|
7
7
|
"module": "dist/esm/index.evm.js",
|