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

Add Bttc network #1049

Open
wants to merge 5 commits into
base: dev2
Choose a base branch
from
Open
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
Binary file added public/BTT.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/components/styles/Header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,9 @@
position: relative;
display: flex;
margin-right: 8px;
& img {
border-radius: 50%;
}
& .networkActiveDot {
position: absolute;
top: -4px;
Expand Down
102 changes: 102 additions & 0 deletions src/config/bttc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
{
"v3": true,
"v2": false,
"rpc": "https://rpc.bt.io",
"blockExplorer": "https://bttcscan.com",
"networkName": "BitTorrent Chain Mainnet",
"aprAPINetwork": "bttc",
"chainId": 199,
"isMainnet": true,
"visible": true,
"nativeCurrencyImage": "/BTT.png",
"nativeCurrency": {
"name": "BitTorrent Token",
"symbol": "BTT",
"decimals": 18
},
"swap": {
"available": true,
"bestTrade": false,
"proMode": false,
"limitOrder": false,
"liquidityHub": false,
"crossChain": false
},
"pools": {
"available": true
},
"farm": {
"quickswap": false,
"merkl": false,
"available": false
},
"lair": {
"available": false,
"oldLair": false,
"newLair": false,
"syrup": false
},
"convert": {
"available": false
},
"predictions": {
"available": false
},
"analytics": {
"liquidityHub": false,
"available": true
},
"lending": {
"available": false
},
"migrate": {
"available": false
},
"gamingHub": {
"available": false
},
"leaderboard": {
"available": false
},
"safe": {
"available": false
},
"perps": {
"available": false
},
"hydra": {
"available": false
},
"perpsV2": {
"available": false
},
"bos": {
"available": false
},
"gamma": {
"available": false
},
"unipilot": {
"available": false
},
"defiedge": {
"available": false
},
"bonds": {
"available": false
},
"steer": {
"available": false
},
"dappos": {
"available": false
},
"ichi": {
"available": false
},
"lpLock": {
"available": false
},
"maxChunks": 20,
"blocksPerFetch": 25
}
2 changes: 2 additions & 0 deletions src/config/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import manta from './manta.json';
import zkartana from './zkartana.json';
import tIMX from './tIMX.json';
import qlpmanager from './qlpmanager.json';
import bttc from './bttc.json';
import x1 from './x1.json';
import IMX from './imx.json';
import astarZkevm from './astarzkevm.json';
Expand All @@ -22,6 +23,7 @@ const configs: any = {
[ChainId.ZKEVM]: zkmainnet,
[ChainId.MANTA]: manta,
[ChainId.ZKATANA]: zkartana,
[ChainId.BTTC]: bttc,
[ChainId.TIMX]: tIMX,
[ChainId.X1]: x1,
[ChainId.IMX]: IMX,
Expand Down
19 changes: 16 additions & 3 deletions src/constants/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ import {
AAVE,
USDCE,
fxMETOD,
USDCT,
USDTT,
PKR,
SLING,
NINJAZ,
Expand Down Expand Up @@ -366,6 +368,7 @@ export const SUPPORTED_CHAINIDS = [
ChainId.MATIC,
ChainId.ZKEVM,
ChainId.MANTA,
ChainId.BTTC,
ChainId.IMX,
ChainId.ASTARZKEVM,
ChainId.DOGECHAIN,
Expand Down Expand Up @@ -2693,8 +2696,13 @@ export const GlobalData = {
DAI[ChainId.MANTA],
],
[ChainId.ZKATANA]: [USDC[ChainId.ZKATANA]],
[ChainId.BTTC]: [
USDC[ChainId.BTTC],
USDCT[ChainId.BTTC],
USDT[ChainId.BTTC],
USDTT[ChainId.BTTC],
],
[ChainId.TIMX]: [USDC[ChainId.TIMX]],
[ChainId.BTTC]: [],
[ChainId.X1]: [USDC[ChainId.X1]],
[ChainId.IMX]: [USDC[ChainId.IMX], USDT[ChainId.IMX], axlUSDC[ChainId.IMX]],
[ChainId.ASTARZKEVM]: [
Expand Down Expand Up @@ -2748,8 +2756,13 @@ export const GlobalData = {
MATIC[ChainId.MANTA],
],
[ChainId.ZKATANA]: [WETH[ChainId.ZKATANA], USDC[ChainId.ZKATANA]],
[ChainId.BTTC]: [
WETH[ChainId.BTTC],
ETHER[ChainId.BTTC],
USDC[ChainId.BTTC],
USDT[ChainId.BTTC],
],
[ChainId.TIMX]: [WETH[ChainId.TIMX], USDC[ChainId.TIMX]],
[ChainId.BTTC]: [],
[ChainId.X1]: [WETH[ChainId.X1], USDC[ChainId.X1]],
[ChainId.IMX]: [
WETH[ChainId.IMX],
Expand Down Expand Up @@ -2807,8 +2820,8 @@ export const GlobalData = {
[WETH[ChainId.MANTA], WSTETH[ChainId.MANTA]],
],
[ChainId.ZKATANA]: [],
[ChainId.TIMX]: [],
[ChainId.BTTC]: [],
[ChainId.TIMX]: [],
[ChainId.X1]: [],
[ChainId.IMX]: [],
[ChainId.ASTARZKEVM]: [
Expand Down
2 changes: 1 addition & 1 deletion src/constants/providers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export const rpcMap = {
[ChainId.KAVA]: '',
[ChainId.MANTA]: 'https://pacific-rpc.manta.network/http',
[ChainId.ZKATANA]: 'https://rpc.zkatana.gelato.digital',
[ChainId.BTTC]: '',
[ChainId.BTTC]: 'https://rpc.bt.io',
[ChainId.TIMX]: 'https://rpc.testnet.immutable.com',
[ChainId.X1]: 'https://testrpc.x1.tech',
[ChainId.IMX]: 'https://rpc.immutable.com',
Expand Down
60 changes: 60 additions & 0 deletions src/constants/v3/addresses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ export const MULTICALL_NETWORKS: { [chainId in ChainId]?: string } = {
[ChainId.ZKEVM]: '0x6a1d2eca13222E7ffDDfdf1Df701D41D3E4cC0BE',
[ChainId.MANTA]: '0x55BeE1bD3Eb9986f6d2d963278de09eE92a3eF1D',
[ChainId.ZKATANA]: '0xF6Ad3CcF71Abb3E12beCf6b3D2a74C963859ADCd',
[ChainId.BTTC]: '0x55BeE1bD3Eb9986f6d2d963278de09eE92a3eF1D',
[ChainId.TIMX]: '0x55BeE1bD3Eb9986f6d2d963278de09eE92a3eF1D',
[ChainId.X1]: '0x55BeE1bD3Eb9986f6d2d963278de09eE92a3eF1D',
[ChainId.IMX]: '0x55BeE1bD3Eb9986f6d2d963278de09eE92a3eF1D',
Expand Down Expand Up @@ -161,6 +162,7 @@ export const UNIV3_QUOTER_ADDRESSES: AddressMap = {
[ChainId.ZKEVM]: '0xB18FB423Fb241CE0DE345d74904f97D60792FFd8',
[ChainId.MANTA]: '0x3005827fB92A0cb7D0f65738D6D645d98A4Ad96b',
[ChainId.ZKATANA]: '0x6c28AeF8977c9B773996d0e8376d2EE379446F2f',
[ChainId.BTTC]: '0xE9CC37904875B459Fa5D0FE37680d36F1ED55e38',
[ChainId.TIMX]: '0xE9CC37904875B459Fa5D0FE37680d36F1ED55e38',
[ChainId.X1]: '0xE9CC37904875B459Fa5D0FE37680d36F1ED55e38',
[ChainId.IMX]: '0xE9CC37904875B459Fa5D0FE37680d36F1ED55e38',
Expand Down Expand Up @@ -191,6 +193,7 @@ export const UNI_V3_FACTORY_ADDRESS: AddressMap = {
[ChainId.ZKEVM]: '0xD9a2AD9E927Bd7014116CC5c7328f028D4318178',
[ChainId.MANTA]: '0x56c2162254b0E4417288786eE402c2B41d4e181e',
[ChainId.ZKATANA]: '0x56c2162254b0E4417288786eE402c2B41d4e181e',
[ChainId.BTTC]: '0x56c2162254b0E4417288786eE402c2B41d4e181e',
[ChainId.TIMX]: '0x56c2162254b0E4417288786eE402c2B41d4e181e',
[ChainId.X1]: '0x56c2162254b0E4417288786eE402c2B41d4e181e',
[ChainId.IMX]: '0x56c2162254b0E4417288786eE402c2B41d4e181e',
Expand All @@ -201,6 +204,7 @@ export const UNI_NFT_POSITION_MANAGER_ADDRESS: AddressMap = {
[ChainId.ZKEVM]: '0x331F3a300b7115A45ba31E3428AC002267BB6D77',
[ChainId.MANTA]: '0xa5E0829CaCEd8fFDD4De3c43696c57F7D7A678ff',
[ChainId.ZKATANA]: '0x55BeE1bD3Eb9986f6d2d963278de09eE92a3eF1D',
[ChainId.BTTC]: '0xa5E0829CaCEd8fFDD4De3c43696c57F7D7A678ff',
[ChainId.TIMX]: '0xa5E0829CaCEd8fFDD4De3c43696c57F7D7A678ff',
[ChainId.X1]: '0xa5E0829CaCEd8fFDD4De3c43696c57F7D7A678ff',
[ChainId.IMX]: '0xa5E0829CaCEd8fFDD4De3c43696c57F7D7A678ff',
Expand All @@ -212,6 +216,12 @@ export const UNI_SWAP_ROUTER: AddressMap = {
[ChainId.ZKEVM]: '0x1E7E4c855520b2106320952A570a3e5E3E618101',
[ChainId.MANTA]: '0xfdE3eaC61C5Ad5Ed617eB1451cc7C3a0AC197564',
[ChainId.ZKATANA]: '0x0d500B1d8E8eF31E21C99d1Db9A6444d3ADf1270',
[ChainId.BTTC]: '0x6c28AeF8977c9B773996d0e8376d2EE379446F2f',
};

export const GAMMA_UNIPROXY_ADDRESSES: AddressMap = {
[ChainId.MATIC]: '0xe0A61107E250f8B5B24bf272baBFCf638569830C',
[ChainId.ZKEVM]: '0x66CD859053c458688044d816117D5Bdf42A56813',
[ChainId.TIMX]: '0x6c28AeF8977c9B773996d0e8376d2EE379446F2f',
[ChainId.X1]: '0x6c28AeF8977c9B773996d0e8376d2EE379446F2f',
[ChainId.IMX]: '0x6c28AeF8977c9B773996d0e8376d2EE379446F2f',
Expand Down Expand Up @@ -239,6 +249,7 @@ export const MULTICALL_ADDRESS: AddressMap = {
[ChainId.ZKEVM]: '0x61530d6E1c7A47BBB3e48e8b8EdF7569DcFeE121',
[ChainId.MANTA]: '0x1FD671daC06DF1431E79d772037E93bdB2dfeb48',
[ChainId.ZKATANA]: '0x61211321E272584d6686F79bb205082C4cDa5d5F',
[ChainId.BTTC]: '0xdc55A13b6b61A8fDa5ACDf760D14AF9DA9a38367',
[ChainId.TIMX]: '0x4857Dfd11c712e862eC362cEee29F7974B70EfcD',
[ChainId.X1]: '0x4857Dfd11c712e862eC362cEee29F7974B70EfcD',
[ChainId.IMX]: '0xc7efb32470dEE601959B15f1f923e017C6A918cA',
Expand Down Expand Up @@ -451,6 +462,13 @@ export const WMATIC_EXTENDED: { [chainId: number]: TokenV3 } = {
'WETH',
'Wrapped ETHER',
),
[ChainId.BTTC]: new TokenV3(
ChainId.BTTC,
'0x23181F21DEa5936e24163FFABa4Ea3B316B57f3C',
18,
'WBTT',
'Wrapped BTT',
),
[ChainId.TIMX]: new TokenV3(
ChainId.TIMX,
'0x1CcCa691501174B4A623CeDA58cC8f1a76dc3439',
Expand Down Expand Up @@ -514,6 +532,13 @@ export const USDC: { [chainId: number]: Token } = {
'USDC',
'USD Coin',
),
[ChainId.BTTC]: new Token(
ChainId.BTTC,
'0xAE17940943BA9440540940DB0F1877f101D39e8b',
6,
'USDC.e',
'USD Coin_Ethereum',
),
[ChainId.X1]: new Token(
ChainId.X1,
'0x04292af1cf8687235a83766d55b307880fc5e76d',
Expand Down Expand Up @@ -578,6 +603,16 @@ export const DAIE: { [chainId: number]: Token } = {
),
};

export const USDCT: { [chainId: number]: Token } = {
[ChainId.BTTC]: new Token(
ChainId.BTTC,
'0x935faA2FCec6Ab81265B301a30467Bbc804b43d3',
6,
'USDC.t',
'USD Coin_TRON',
),
};

export const USDT: { [chainId: number]: Token } = {
[ChainId.ETHEREUM]: new Token(
ChainId.ETHEREUM,
Expand Down Expand Up @@ -621,6 +656,13 @@ export const USDT: { [chainId: number]: Token } = {
'USDT',
'Tether USD',
),
[ChainId.BTTC]: new Token(
ChainId.BTTC,
'0xE887512ab8BC60BcC9224e1c3b5Be68E26048B8B',
6,
'USDT.e',
'Tether USD_Ethereum',
),
[ChainId.IMX]: new Token(
ChainId.IMX,
'0x68bcc7F1190AF20e7b572BCfb431c3Ac10A936Ab',
Expand All @@ -644,6 +686,16 @@ export const USDT: { [chainId: number]: Token } = {
),
};

export const USDTT: { [chainId: number]: Token } = {
[ChainId.BTTC]: new Token(
ChainId.BTTC,
'0xdB28719F7f938507dBfe4f0eAe55668903D34a15',
6,
'USDT.t',
'Tether USD_TRON',
),
};

export const OLD_QUICK: { [chainId: number]: Token } = {
[ChainId.MATIC]: new Token(
ChainId.MATIC,
Expand Down Expand Up @@ -812,6 +864,13 @@ export const ETHER: { [chainId: number]: Token } = {
'ETH',
'Ether',
),
[ChainId.BTTC]: new Token(
ChainId.BTTC,
'0x1249C65AfB11D179FFB3CE7D4eEDd1D9b98AD006',
18,
'ETH',
'Ether',
),
[ChainId.IMX]: new Token(
ChainId.IMX,
'0x52A6c53869Ce09a731CD772f245b97A4401d3348',
Expand Down Expand Up @@ -1574,6 +1633,7 @@ export const SUGGESTED_BASES: {
STONE[ChainId.MANTA],
],
[ChainId.ZKATANA]: [WETH[ChainId.ZKATANA], USDC[ChainId.ZKATANA]],
[ChainId.BTTC]: [WETH[ChainId.BTTC], USDC[ChainId.BTTC], USDT[ChainId.BTTC]],
[ChainId.X1]: [WETH[ChainId.X1], USDC[ChainId.X1]],
[ChainId.TIMX]: [WETH[ChainId.TIMX], USDC[ChainId.TIMX]],
[ChainId.IMX]: [
Expand Down
9 changes: 9 additions & 0 deletions src/constants/v3/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,15 @@ export const CHAIN_INFO: ChainInfo = {
nativeCurrencyName: 'Ether',
nativeCurrencyDecimals: 18,
},
[ChainId.BTTC]: {
docs: 'https://algebra.finance/',
explorer: 'https://bttcscan.com',
infoLink: 'https://algebra.finance',
label: 'bttc',
nativeCurrencySymbol: 'BTT',
nativeCurrencyName: 'BitTorrent Token',
nativeCurrencyDecimals: 18,
},
[ChainId.TIMX]: {
docs: 'https://algebra.finance/',
explorer: 'https://explorer.testnet.immutable.com',
Expand Down
Loading