Skip to content

Commit

Permalink
common: explorer links for new chains
Browse files Browse the repository at this point in the history
  • Loading branch information
evan-gray committed May 2, 2024
1 parent 61f19d5 commit e0527d4
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions common/src/explorer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,18 @@ export const explorerBlock = (network: Network, chainId: ChainId, block: string)
? `https://basescan.org/block/${block}`
: chainId === chainToChainId('Sei')
? `https://www.seiscan.app/pacific-1/blocks/${block}`
: chainId === chainToChainId('Scroll')
? `https://scrollscan.com/block/${block}`
: chainId === chainToChainId('Mantle')
? `https://explorer.mantle.xyz/block/${block}`
: chainId === chainToChainId('Blast')
? `https://blastscan.io/block/${block}`
: chainId === chainToChainId('Xlayer')
? `https://www.oklink.com/xlayer/block/${block}`
: chainId === chainToChainId('Linea')
? `https://lineascan.build/block/${block}`
: chainId === chainToChainId('Berachain')
? `https://beratrail.io/block/${block}`
: chainId === chainToChainId('Wormchain')
? `https://bigdipper.live/wormhole/blocks/${block}`
: ''
Expand Down Expand Up @@ -104,6 +116,18 @@ export const explorerBlock = (network: Network, chainId: ChainId, block: string)
? `https://goerli.basescan.org/block/${block}`
: chainId === chainToChainId('Sei')
? `https://www.seiscan.app/atlantic-2/blocks/${block}`
: chainId === chainToChainId('Scroll')
? `https://sepolia.scrollscan.com/block/${block}`
: chainId === chainToChainId('Mantle')
? `https://explorer.sepolia.mantle.xyz/block/${block}`
: chainId === chainToChainId('Blast')
? `https://testnet.blastscan.io/block/${block}`
: chainId === chainToChainId('Xlayer')
? `https://www.oklink.com/xlayer-test/block/${block}`
: chainId === chainToChainId('Linea')
? `https://sepolia.lineascan.build/block/${block}`
: chainId === chainToChainId('Berachain')
? `https://artio.beratrail.io/block/${block}`
: // : chainId === chainToChainId('Wormscan') <-- not supported on testnet dashboard
'';

Expand Down Expand Up @@ -157,6 +181,18 @@ export const explorerTx = (network: Network, chainId: ChainId, tx: string) =>
? `https://basescan.org/tx/${tx}`
: chainId === chainToChainId('Sei')
? `https://www.seiscan.app/pacific-1/txs/${tx}`
: chainId === chainToChainId('Scroll')
? `https://scrollscan.com/tx/${tx}`
: chainId === chainToChainId('Mantle')
? `https://explorer.mantle.xyz/tx/${tx}`
: chainId === chainToChainId('Blast')
? `https://blastscan.io/tx/${tx}`
: chainId === chainToChainId('Xlayer')
? `https://www.oklink.com/xlayer/tx/${tx}`
: chainId === chainToChainId('Linea')
? `https://lineascan.build/tx/${tx}`
: chainId === chainToChainId('Berachain')
? `https://artio.beratrail.io/tx/${tx}`
: chainId === chainToChainId('Wormchain')
? `https://bigdipper.live/wormhole/transactions/${tx}`
: ''
Expand Down Expand Up @@ -203,6 +239,18 @@ export const explorerTx = (network: Network, chainId: ChainId, tx: string) =>
? `https://goerli.basescan.org/tx/${tx}`
: chainId === chainToChainId('Sei')
? `https://www.seiscan.app/atlantic-2/txs/${tx}`
: chainId === chainToChainId('Scroll')
? `https://sepolia.scrollscan.com/tx/${tx}`
: chainId === chainToChainId('Mantle')
? `https://explorer.sepolia.mantle.xyz/tx/${tx}`
: chainId === chainToChainId('Blast')
? `https://testnet.blastscan.io/tx/${tx}`
: chainId === chainToChainId('Xlayer')
? `https://www.oklink.com/xlayer-test/tx/${tx}`
: chainId === chainToChainId('Linea')
? `https://sepolia.lineascan.build/tx/${tx}`
: chainId === chainToChainId('Berachain')
? `https://artio.beratrail.io/tx/${tx}`
: // chainId === chainToChainId('Wormscan') <-- not supported on testnet dashboard
'';

Expand Down

0 comments on commit e0527d4

Please sign in to comment.