Skip to content

Commit

Permalink
Merge pull request #906 from latticexyz/redstone-usdc
Browse files Browse the repository at this point in the history
add Redstone BridgedUSDC
  • Loading branch information
nitaliano authored Aug 6, 2024
2 parents 29a9605 + d6edded commit 2ddf548
Show file tree
Hide file tree
Showing 5 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ We currently accept tokens on the following chains:
- `pgn`
- `lisk`
- `lisk-sepolia`
- `redstone`

#### Non-bridgable tokens

Expand Down
8 changes: 8 additions & 0 deletions data/BridgedUSDC/data.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@
"name": "Bridged USDC",
"symbol": "USDC.e"
}
},
"redstone": {
"address": "0xD5d59fC063e7548b6015A36fEb10B875924A19be",
"overrides": {
"name": "Bridged USDC (Lattice)",
"symbol": "USDC.e",
"bridge": "0x4200000000000000000000000000000000000010"
}
}
}
}
16 changes: 16 additions & 0 deletions src/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,14 @@ export const NETWORK_DATA: Record<Chain, Network> = {
),
layer: 2,
},
'redstone': {
id: 690,
name: 'Redstone',
provider: new ethers.providers.StaticJsonRpcProvider(
'https://rpc.redstonechain.com'
),
layer: 2
},
sepolia: {
id: 11155111,
name: 'Sepolia',
Expand Down Expand Up @@ -123,6 +131,9 @@ export const L2_STANDARD_BRIDGE_INFORMATION: Record<
lisk: {
l2StandardBridgeAddress: '0x4200000000000000000000000000000000000010',
},
'redstone': {
l2StandardBridgeAddress: '0x4200000000000000000000000000000000000010'
},
'optimism-sepolia': {
l2StandardBridgeAddress: '0x4200000000000000000000000000000000000010',
},
Expand All @@ -143,6 +154,7 @@ export const L2_TO_L1_PAIR: Partial<Record<L2Chain, L1Chain>> = {
pgn: 'ethereum',
mode: 'ethereum',
lisk: 'ethereum',
redstone: 'ethereum',
'optimism-sepolia': 'sepolia',
'base-sepolia': 'sepolia',
'pgn-sepolia': 'sepolia',
Expand Down Expand Up @@ -174,6 +186,10 @@ export const L1_STANDARD_BRIDGE_INFORMATION: Record<
l2Chain: 'lisk',
l1StandardBridgeAddress: '0x2658723Bf70c7667De6B25F99fcce13A16D25d08',
},
{
l2Chain: 'redstone',
l1StandardBridgeAddress: '0xc473ca7E02af24c129c2eEf51F2aDf0411c1Df69',
},
],
sepolia: [
{
Expand Down
2 changes: 2 additions & 0 deletions src/schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ export const TOKEN_DATA_SCHEMA = {
lisk: TOKEN_SCHEMA,
mode: TOKEN_SCHEMA,
pgn: TOKEN_SCHEMA,
redstone: TOKEN_SCHEMA,
sepolia: TOKEN_SCHEMA,
'base-sepolia': TOKEN_SCHEMA,
'optimism-sepolia': TOKEN_SCHEMA,
Expand All @@ -78,6 +79,7 @@ export const TOKEN_DATA_SCHEMA = {
{ required: ['mode'] },
{ required: ['pgn'] },
{ required: ['lisk'] },
{ required: ['redstone'] },
{ required: ['sepolia'] },
{ required: ['base-sepolia'] },
{ required: ['optimism-sepolia'] },
Expand Down
2 changes: 2 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ export type Chain =
| 'mode'
| 'lisk'
| 'lisk-sepolia'
| 'redstone'

const l2Chains = [
'optimism',
Expand All @@ -42,6 +43,7 @@ const l2Chains = [
'mode',
'lisk',
'lisk-sepolia',
'redstone'
] as const
export type L2Chain = typeof l2Chains[number]

Expand Down

0 comments on commit 2ddf548

Please sign in to comment.