From 5ac2e4d913be89069ad46de78bd44007c7ecbafd Mon Sep 17 00:00:00 2001 From: Sven Date: Tue, 6 Feb 2024 16:42:59 +0100 Subject: [PATCH 1/2] fix unsupported chain issue ethers --- packages/ethers/src/client.ts | 4 ++++ packages/ethers5/src/client.ts | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/packages/ethers/src/client.ts b/packages/ethers/src/client.ts index 92f5571c64..05be73c2cb 100644 --- a/packages/ethers/src/client.ts +++ b/packages/ethers/src/client.ts @@ -818,6 +818,10 @@ export class Web3Modal extends Web3ModalScaffold { await this.syncBalance(address) } } + } else if (isConnected) { + this.setCaipNetwork({ + id: `${ConstantsUtil.EIP155}:${chainId}` + }) } } } diff --git a/packages/ethers5/src/client.ts b/packages/ethers5/src/client.ts index 959b8e88a5..69b1d1adad 100644 --- a/packages/ethers5/src/client.ts +++ b/packages/ethers5/src/client.ts @@ -751,6 +751,10 @@ export class Web3Modal extends Web3ModalScaffold { await this.syncBalance(address) } } + } else if (isConnected) { + this.setCaipNetwork({ + id: `${ConstantsUtil.EIP155}:${chainId}` + }) } } } From f8e734ffef7f0c5ffefe8955c159d75c2d00b483 Mon Sep 17 00:00:00 2001 From: Sven Date: Tue, 6 Feb 2024 16:44:30 +0100 Subject: [PATCH 2/2] fix wallet transaction --- .../src/composites/wui-list-wallet-transaction/index.ts | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/packages/ui/src/composites/wui-list-wallet-transaction/index.ts b/packages/ui/src/composites/wui-list-wallet-transaction/index.ts index e8ddf9b3ab..95899c71d9 100644 --- a/packages/ui/src/composites/wui-list-wallet-transaction/index.ts +++ b/packages/ui/src/composites/wui-list-wallet-transaction/index.ts @@ -41,7 +41,7 @@ export class WuiListWalletTransaction extends LitElement { @@ -56,12 +56,6 @@ export class WuiListWalletTransaction extends LitElement { return html`` } - - private onExplorer() { - if (this.addressExplorerUrl) { - window.open(this.addressExplorerUrl, '_blank', 'noreferrer noopener') - } - } } declare global {