Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(ink): deploy ink #1342

Merged
merged 2 commits into from
Jan 2, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
"private": true,
"license": "AGPL-3.0-only",
"dependencies": {
"@across-protocol/constants": "^3.1.22",
"@across-protocol/contracts": "^3.0.17",
"@across-protocol/constants": "^3.1.24",
"@across-protocol/contracts": "^3.0.19",
"@across-protocol/contracts-v3.0.6": "npm:@across-protocol/[email protected]",
"@across-protocol/sdk": "^3.3.25",
"@across-protocol/sdk": "^3.3.27",
"@amplitude/analytics-browser": "^2.3.5",
"@balancer-labs/sdk": "1.1.6-beta.16",
"@emotion/react": "^11.13.0",
Expand Down
1 change: 1 addition & 0 deletions scripts/chain-configs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ export { default as BASE } from "./base";
export { default as BASE_SEPOLIA } from "./base-sepolia";
export { default as BLAST } from "./blast";
export { default as BLAST_SEPOLIA } from "./blast-sepolia";
export { default as INK } from "./ink";
export { default as LINEA } from "./linea";
export { default as LISK } from "./lisk";
export { default as LISK_SEPOLIA } from "./lisk-sepolia";
Expand Down
5 changes: 5 additions & 0 deletions scripts/chain-configs/ink/assets/grayscale-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions scripts/chain-configs/ink/assets/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions scripts/chain-configs/ink/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import { CHAIN_IDs, PUBLIC_NETWORKS } from "@across-protocol/constants";
import { utils as sdkUtils } from "@across-protocol/sdk";
import { ChainConfig } from "../types";

const { getDeployedAddress, getDeployedBlockNumber } = sdkUtils;

const chainId = CHAIN_IDs.INK;
const chainInfoBase = PUBLIC_NETWORKS[chainId];

export default {
...chainInfoBase,
logoPath: "./assets/logo.svg",
grayscaleLogoPath: "./assets/grayscale-logo.svg",
spokePool: {
address: getDeployedAddress("SpokePool", chainId),
blockNumber: getDeployedBlockNumber("SpokePool", chainId),
},
chainId,
publicRpcUrl: "https://rpc-gel.inkonchain.com",
blockTimeSeconds: 1,
tokens: ["WETH", "ETH"],
enableCCTP: false,
} as ChainConfig;
2 changes: 2 additions & 0 deletions scripts/generate-routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ const enabledMainnetChainConfigs = [
chainConfigs.ZORA,
chainConfigs.WORLD_CHAIN,
chainConfigs.ALEPH_ZERO,
chainConfigs.INK,
];

const enabledSepoliaChainConfigs = [
Expand Down Expand Up @@ -89,6 +90,7 @@ const enabledRoutes = {
CHAIN_IDs.SCROLL,
CHAIN_IDs.ZORA,
CHAIN_IDs.WORLD_CHAIN,
CHAIN_IDs.INK,
],
},
swapAndBridgeAddresses: {
Expand Down
5 changes: 5 additions & 0 deletions src/assets/chain-logos/ink-grayscale.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions src/assets/chain-logos/ink.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions src/constants/chains/configs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ import blastSepoliaGrayscaleLogo from "assets/chain-logos/blast-sepolia-grayscal
import { ReactComponent as blastSepoliaLogoSvg } from "assets/chain-logos/blast-sepolia.svg";
import { ReactComponent as blastSepoliaGrayscaleLogoSvg } from "assets/chain-logos/blast-sepolia-grayscale.svg";

import inkLogo from "assets/chain-logos/ink.svg";
import inkGrayscaleLogo from "assets/chain-logos/ink-grayscale.svg";
import { ReactComponent as inkLogoSvg } from "assets/chain-logos/ink.svg";
import { ReactComponent as inkGrayscaleLogoSvg } from "assets/chain-logos/ink-grayscale.svg";

import lineaLogo from "assets/chain-logos/linea.svg";
import lineaGrayscaleLogo from "assets/chain-logos/linea-grayscale.svg";
import { ReactComponent as lineaLogoSvg } from "assets/chain-logos/linea.svg";
Expand Down Expand Up @@ -233,6 +238,22 @@ export const blastSepolia = {
pollingInterval: 2000,
};

export const ink = {
name: "Ink",
fullName: "Ink",
chainId: 57073,
logoURI: inkLogo,
grayscaleLogoURI: inkGrayscaleLogo,
logoSvg: inkLogoSvg,
grayscaleLogoSvg: inkGrayscaleLogoSvg,
rpcUrl: "https://rpc-gel.inkonchain.com",
explorerUrl: "https://explorer.inkonchain.com",
constructExplorerLink: (txHash: string) => `${ink.explorerUrl}/tx/${txHash}`,
nativeCurrencySymbol: "ETH",
customRpcUrl: process.env.REACT_APP_CHAIN_57073_PROVIDER_URL,
pollingInterval: 1000,
};

export const linea = {
name: "Linea",
fullName: "Linea",
Expand Down Expand Up @@ -510,6 +531,7 @@ export const chainConfigs = [
baseSepolia,
blast,
blastSepolia,
ink,
linea,
lisk,
liskSepolia,
Expand Down
1 change: 1 addition & 0 deletions src/constants/chains/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ const orderedEnabledChainIds = [
CHAIN_IDs.ZORA,
CHAIN_IDs.WORLD_CHAIN,
CHAIN_IDs.ALEPH_ZERO,
CHAIN_IDs.INK,
// testnet
CHAIN_IDs.SEPOLIA,
CHAIN_IDs.BASE_SEPOLIA,
Expand Down
41 changes: 41 additions & 0 deletions src/data/chains_1.json
Original file line number Diff line number Diff line change
Expand Up @@ -1523,5 +1523,46 @@
"logoUrl": "https://raw.githubusercontent.com/across-protocol/frontend/master/src/assets/token-logos/usdt.svg"
}
]
},
{
"chainId": 57073,
"name": "Ink",
"publicRpcUrl": "https://rpc-gel.inkonchain.com",
"explorerUrl": "https://explorer.inkonchain.com",
"logoUrl": "https://raw.githubusercontent.com/across-protocol/frontend/master/scripts/chain-configs/ink/assets/logo.svg",
"spokePool": "0xeF684C38F94F48775959ECf2012D7E864ffb9dd4",
"spokePoolBlock": 1139240,
"inputTokens": [
{
"address": "0x4200000000000000000000000000000000000006",
"symbol": "WETH",
"name": "Wrapped Ether",
"decimals": 18,
"logoUrl": "https://raw.githubusercontent.com/across-protocol/frontend/master/src/assets/token-logos/weth.svg"
},
{
"address": "0x4200000000000000000000000000000000000006",
"symbol": "ETH",
"name": "Ether",
"decimals": 18,
"logoUrl": "https://raw.githubusercontent.com/across-protocol/frontend/master/src/assets/token-logos/eth.svg"
}
],
"outputTokens": [
{
"address": "0x4200000000000000000000000000000000000006",
"symbol": "WETH",
"name": "Wrapped Ether",
"decimals": 18,
"logoUrl": "https://raw.githubusercontent.com/across-protocol/frontend/master/src/assets/token-logos/weth.svg"
},
{
"address": "0x4200000000000000000000000000000000000006",
"symbol": "ETH",
"name": "Ether",
"decimals": 18,
"logoUrl": "https://raw.githubusercontent.com/across-protocol/frontend/master/src/assets/token-logos/eth.svg"
}
]
}
]
Loading
Loading