feat: adds zk sync era (#211)

This commit is contained in:
Ramon "9Tails" Canales 2023-06-30 15:31:28 +01:00 committed by GitHub
parent 40b772f142
commit d7c56a3bea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 90 additions and 4 deletions

View File

@ -0,0 +1,5 @@
<svg width="512" height="512" viewBox="0 0 512 512" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M0 64C0 28.6538 28.6538 0 64 0H448C483.346 0 512 28.6538 512 64V448C512 483.346 483.346 512 448 512H64C28.6538 512 0 483.346 0 448V64Z" fill="#F2F2F2"/>
<path d="M160 128L32 256L160 384V288L288 192H160V128Z" fill="black"/>
<path d="M480 256L352 128V224L224 320H352V384L480 256Z" fill="black"/>
</svg>

After

Width:  |  Height:  |  Size: 410 B

View File

@ -16,6 +16,7 @@ export const EIP155Colors = {
goerli: "189, 174, 155",
xdai: "73, 169, 166",
polygon: "130, 71, 229",
zksync: "90, 90, 90",
celo: "60, 203, 132",
arbitrum: "44, 55, 75",
};
@ -63,6 +64,20 @@ export const EIP155ChainData: ChainsMap = {
slip44: 60,
testnet: false,
},
"280": {
name: "zkSync Era Testnet",
id: "eip155:280",
rpc: ["https://testnet.era.zksync.dev"],
slip44: 60,
testnet: true,
},
"324": {
name: "zkSync Era",
id: "eip155:324",
rpc: ["https://mainnet.era.zksync.io"],
slip44: 60,
testnet: false,
},
"137": {
name: "Polygon Mainnet",
id: "eip155:137",
@ -141,6 +156,16 @@ export const EIP155Metadata: NamespaceMetadata = {
logo: BLOCKCHAIN_LOGO_BASE_URL + "eip155:100.png",
rgb: EIP155Colors.xdai,
},
"280": {
name: "zkSync Era Testnet",
logo: "/assets/eip155-324.svg",
rgb: EIP155Colors.zksync,
},
"324": {
name: "zkSync Era",
logo: "/assets/eip155-324.svg",
rgb: EIP155Colors.zksync,
},
"137": {
name: "Polygon",
logo: BLOCKCHAIN_LOGO_BASE_URL + "eip155:137.png",

View File

@ -7,6 +7,7 @@ export const DEFAULT_MAIN_CHAINS = [
"eip155:10",
"eip155:100",
"eip155:137",
"eip155:324",
"eip155:42161",
"eip155:42220",
"cosmos:cosmoshub-4",
@ -20,6 +21,7 @@ export const DEFAULT_MAIN_CHAINS = [
export const DEFAULT_TEST_CHAINS = [
// testnets
"eip155:5",
"eip155:280",
"eip155:420",
"eip155:80001",
"eip155:421611",

View File

@ -26,6 +26,22 @@ export const rpcProvidersByChainId: Record<number, any> = {
symbol: "MATIC",
},
},
280: {
name: "zkSync Era Testnet",
baseURL: "https://testnet.era.zksync.dev",
token: {
name: "Ether",
symbol: "ETH",
},
},
324: {
name: "zkSync Era",
baseURL: "https://mainnet.era.zksync.io",
token: {
name: "Ether",
symbol: "ETH",
},
},
80001: {
name: "Polygon Mumbai",
baseURL: "https://rpc-mumbai.maticvigil.com",

View File

@ -0,0 +1,5 @@
<svg width="512" height="512" viewBox="0 0 512 512" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M0 64C0 28.6538 28.6538 0 64 0H448C483.346 0 512 28.6538 512 64V448C512 483.346 483.346 512 448 512H64C28.6538 512 0 483.346 0 448V64Z" fill="#F2F2F2"/>
<path d="M160 128L32 256L160 384V288L288 192H160V128Z" fill="black"/>
<path d="M480 256L352 128V224L224 320H352V384L480 256Z" fill="black"/>
</svg>

After

Width:  |  Height:  |  Size: 410 B

View File

@ -39,7 +39,14 @@ export const EIP155_MAINNET_CHAINS = {
logo: '/chain-logos/eip155-10.png',
rgb: '235, 0, 25',
rpc: 'https://mainnet.optimism.io'
}
},
'eip155:324': {
chainId: 324,
name: 'zkSync Era',
logo: '/chain-logos/eip155-324.svg',
rgb: '242, 242, 242',
rpc: 'https://mainnet.era.zsync.io/'
},
}
export const EIP155_TEST_CHAINS = {
@ -70,7 +77,14 @@ export const EIP155_TEST_CHAINS = {
logo: '/chain-logos/eip155-10.png',
rgb: '235, 0, 25',
rpc: 'https://goerli.optimism.io'
}
},
'eip155:280': {
chainId: 280,
name: 'zkSync Era Testnet',
logo: '/chain-logos/eip155-324.svg',
rgb: '242, 242, 242',
rpc: 'https://testnet.era.zsync.dev/'
},
}
export const EIP155_CHAINS = { ...EIP155_MAINNET_CHAINS, ...EIP155_TEST_CHAINS }

View File

@ -0,0 +1,5 @@
<svg width="512" height="512" viewBox="0 0 512 512" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M0 64C0 28.6538 28.6538 0 64 0H448C483.346 0 512 28.6538 512 64V448C512 483.346 483.346 512 448 512H64C28.6538 512 0 483.346 0 448V64Z" fill="#F2F2F2"/>
<path d="M160 128L32 256L160 384V288L288 192H160V128Z" fill="black"/>
<path d="M480 256L352 128V224L224 320H352V384L480 256Z" fill="black"/>
</svg>

After

Width:  |  Height:  |  Size: 410 B

View File

@ -39,7 +39,14 @@ export const EIP155_MAINNET_CHAINS = {
logo: '/chain-logos/eip155-10.png',
rgb: '235, 0, 25',
rpc: 'https://mainnet.optimism.io'
}
},
'eip155:324': {
chainId: 324,
name: 'zkSync Era',
logo: '/chain-logos/eip155-324.svg',
rgb: '242, 242, 242',
rpc: 'https://mainnet.era.zsync.io/'
},
}
export const EIP155_TEST_CHAINS = {
@ -70,7 +77,14 @@ export const EIP155_TEST_CHAINS = {
logo: '/chain-logos/eip155-10.png',
rgb: '235, 0, 25',
rpc: 'https://goerli.optimism.io'
}
},
'eip155:280': {
chainId: 280,
name: 'zkSync Era Testnet',
logo: '/chain-logos/eip155-324.svg',
rgb: '242, 242, 242',
rpc: 'https://testnet.era.zsync.dev/'
},
}
export const EIP155_CHAINS = { ...EIP155_MAINNET_CHAINS, ...EIP155_TEST_CHAINS }