From 11c93b6f3ee7c383c36cab1f0142ddb0198d2a25 Mon Sep 17 00:00:00 2001 From: Nam Nguyen Date: Fri, 8 Sep 2023 10:42:23 +0700 Subject: [PATCH] shutdown Velas & Oasis (#2225) --- package.json | 4 +- src/components/ApproveMessage/index.tsx | 2 - src/components/Icons/Oasis.tsx | 15 ----- src/components/Icons/OasisLogoFull.tsx | 27 --------- src/components/Icons/Velas.tsx | 15 ----- src/components/Icons/VelasLogoFull.tsx | 20 ------- src/components/Icons/index.ts | 4 -- src/constants/bases.ts | 6 -- src/constants/index.ts | 2 +- src/constants/networks.ts | 22 +------- src/constants/networks/index.ts | 2 - src/constants/networks/oasis.ts | 72 ------------------------ src/constants/networks/velas.ts | 72 ------------------------ src/constants/permit.ts | 23 -------- src/constants/tokens.ts | 43 -------------- src/hooks/useElasticLegacy.ts | 14 ----- src/pages/About/AboutKyberSwap/index.tsx | 4 -- src/pages/About/styleds.tsx | 2 +- src/pages/BuyCrypto/index.tsx | 2 - yarn.lock | 8 +-- 20 files changed, 9 insertions(+), 350 deletions(-) delete mode 100644 src/components/Icons/Oasis.tsx delete mode 100644 src/components/Icons/OasisLogoFull.tsx delete mode 100644 src/components/Icons/Velas.tsx delete mode 100644 src/components/Icons/VelasLogoFull.tsx delete mode 100644 src/constants/networks/oasis.ts delete mode 100644 src/constants/networks/velas.ts diff --git a/package.json b/package.json index 6384580c7e..bc32c52c60 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "@esbuild-plugins/node-globals-polyfill": "^0.2.3", "@kybernetwork/oauth2": "1.0.0", "@kyberswap/ks-sdk-classic": "^1.0.3", - "@kyberswap/ks-sdk-core": "1.0.10", + "@kyberswap/ks-sdk-core": "1.0.11", "@kyberswap/ks-sdk-elastic": "^1.1.2", "@kyberswap/ks-sdk-solana": "^1.0.2", "@lingui/loader": "~3.14.0", @@ -198,7 +198,7 @@ "vite-tsconfig-paths": "^4.0.8" }, "resolutions": { - "@kyberswap/ks-sdk-core": "1.0.10", + "@kyberswap/ks-sdk-core": "1.0.11", "react-error-overlay": "6.0.9", "@lingui/babel-plugin-extract-messages": "3.14.0", "@lingui/cli": "3.14.0", diff --git a/src/components/ApproveMessage/index.tsx b/src/components/ApproveMessage/index.tsx index 7ab65dc039..cbba7119b9 100644 --- a/src/components/ApproveMessage/index.tsx +++ b/src/components/ApproveMessage/index.tsx @@ -30,7 +30,6 @@ export default function ApproveMessage({ ![ ChainId.BSCMAINNET, ChainId.BTTC, - ChainId.VELAS, ChainId.CRONOS, ChainId.ARBITRUM, ChainId.MATIC, @@ -39,7 +38,6 @@ export default function ApproveMessage({ ChainId.AURORA, ChainId.MAINNET, ChainId.AVAXMAINNET, - ChainId.OASIS, ].includes(chainId) ) { return null diff --git a/src/components/Icons/Oasis.tsx b/src/components/Icons/Oasis.tsx deleted file mode 100644 index db0f7bf55d..0000000000 --- a/src/components/Icons/Oasis.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import useTheme from 'hooks/useTheme' - -function Oasis({ size }: { size?: number }) { - const theme = useTheme() - return ( - - - - ) -} - -export default Oasis diff --git a/src/components/Icons/OasisLogoFull.tsx b/src/components/Icons/OasisLogoFull.tsx deleted file mode 100644 index d63b3c5ce2..0000000000 --- a/src/components/Icons/OasisLogoFull.tsx +++ /dev/null @@ -1,27 +0,0 @@ -import useTheme from 'hooks/useTheme' - -function OasisLogoFull() { - const theme = useTheme() - - return ( - - - - - {/* */} - - - - ) -} - -export default OasisLogoFull diff --git a/src/components/Icons/Velas.tsx b/src/components/Icons/Velas.tsx deleted file mode 100644 index 8741e7d627..0000000000 --- a/src/components/Icons/Velas.tsx +++ /dev/null @@ -1,15 +0,0 @@ -import useTheme from 'hooks/useTheme' - -function Velas({ size }: { size?: number }) { - const theme = useTheme() - return ( - - - - ) -} - -export default Velas diff --git a/src/components/Icons/VelasLogoFull.tsx b/src/components/Icons/VelasLogoFull.tsx deleted file mode 100644 index 5952b8ba08..0000000000 --- a/src/components/Icons/VelasLogoFull.tsx +++ /dev/null @@ -1,20 +0,0 @@ -import useTheme from 'hooks/useTheme' - -function VelasLogoFull({ color }: { size?: number; color?: string }) { - const theme = useTheme() - - return ( - - {' '} - - - ) -} - -export default VelasLogoFull diff --git a/src/components/Icons/index.ts b/src/components/Icons/index.ts index d276b16984..11d68a723a 100644 --- a/src/components/Icons/index.ts +++ b/src/components/Icons/index.ts @@ -21,8 +21,6 @@ export { default as LowestSlippage } from './LowestSlippage' export { default as MoneyBagOutline } from './MoneyBagOutline' export { default as MoneyBag } from './MoneyBag' export { default as MoneyFill } from './MoneyFill' -export { default as Oasis } from './Oasis' -export { default as OasisLogoFull } from './OasisLogoFull' export { default as OptimismLogo } from './OptimismLogo' export { default as OptimismLogoFull } from './OptimismLogoFull' export { default as Polygon } from './Polygon' @@ -36,8 +34,6 @@ export { default as LineaFull } from './LineaFull' export { default as Swap } from './Swap' export { default as Swap2 } from './Swap_2' export { default as Telegram } from './Telegram' -export { default as Velas } from './Velas' -export { default as VelasLogoFull } from './VelasLogoFull' export { default as FarmingIcon } from './FarmingIcon' export { default as CheckCircle } from './CheckCircle' export { default as XCircle } from './XCircle' diff --git a/src/constants/bases.ts b/src/constants/bases.ts index d9a6516f45..8a4bd0bae2 100644 --- a/src/constants/bases.ts +++ b/src/constants/bases.ts @@ -22,8 +22,6 @@ const WETH_ONLY: ChainTokenList = { [ChainId.AURORA]: [WETH[ChainId.AURORA]], [ChainId.BTTC]: [WETH[ChainId.BTTC]], [ChainId.ARBITRUM]: [WETH[ChainId.ARBITRUM]], - [ChainId.VELAS]: [WETH[ChainId.VELAS]], - [ChainId.OASIS]: [WETH[ChainId.OASIS]], [ChainId.OPTIMISM]: [WETH[ChainId.OPTIMISM]], [ChainId.ZKSYNC]: [WETH[ChainId.ZKSYNC]], [ChainId.SOLANA]: [WETH[ChainId.SOLANA]], @@ -81,8 +79,6 @@ export const BASES_TO_CHECK_TRADES_AGAINST: ChainTokenList = { [ChainId.FANTOM]: [...WETH_ONLY[ChainId.FANTOM], DAI[ChainId.FANTOM], USDC[ChainId.FANTOM], USDT[ChainId.FANTOM]], [ChainId.CRONOS]: [...WETH_ONLY[ChainId.CRONOS], DAI[ChainId.CRONOS], USDC[ChainId.CRONOS], USDT[ChainId.CRONOS]], [ChainId.AURORA]: [...WETH_ONLY[ChainId.AURORA], DAI[ChainId.AURORA], USDC[ChainId.AURORA], USDT[ChainId.AURORA]], - [ChainId.VELAS]: [...WETH_ONLY[ChainId.VELAS], USDC[ChainId.VELAS], USDT[ChainId.VELAS]], - [ChainId.OASIS]: [...WETH_ONLY[ChainId.OASIS], USDC[ChainId.OASIS], USDT[ChainId.OASIS]], [ChainId.BTTC]: [ ...WETH_ONLY[ChainId.BTTC], DAI[ChainId.BTTC], @@ -159,8 +155,6 @@ export const SUGGESTED_BASES: ChainTokenList = { new Token(ChainId.ARBITRUM, '0x5979D7b546E38E414F7E9822514be443A4800529', 18, 'wstETH', 'Lido Wrapped Staked ETH'), ], [ChainId.BTTC]: [...WETH_ONLY[ChainId.BTTC], DAI[ChainId.BTTC], USDC[ChainId.BTTC], USDT[ChainId.BTTC]], - [ChainId.VELAS]: [...WETH_ONLY[ChainId.VELAS], USDC[ChainId.VELAS], USDT[ChainId.VELAS]], - [ChainId.OASIS]: [...WETH_ONLY[ChainId.OASIS], USDC[ChainId.OASIS], USDT[ChainId.OASIS]], [ChainId.OPTIMISM]: [ ...WETH_ONLY[ChainId.OPTIMISM], USDC[ChainId.OPTIMISM], diff --git a/src/constants/index.ts b/src/constants/index.ts index 25f90d0e0a..d0a2696b93 100644 --- a/src/constants/index.ts +++ b/src/constants/index.ts @@ -305,7 +305,7 @@ export const TRANSACTION_STATE_DEFAULT: TransactionFlowState = { pendingText: '', } -export const CHAINS_SUPPORT_FEE_CONFIGS = [ChainId.OASIS, ChainId.VELAS, ChainId.AURORA, ChainId.CRONOS] +export const CHAINS_SUPPORT_FEE_CONFIGS = [ChainId.AURORA, ChainId.CRONOS] export const CHAINS_SUPPORT_CROSS_CHAIN = ENV.ENV_KEY === ENV.EnvKeys.PROD || ENV.ENV_KEY === ENV.EnvKeys.STG ? [ diff --git a/src/constants/networks.ts b/src/constants/networks.ts index ed4678ac7d..1d2f7068c3 100644 --- a/src/constants/networks.ts +++ b/src/constants/networks.ts @@ -19,11 +19,9 @@ import { linea, matic, mumbai, - oasis, optimism, solana, solanaDevnet, - velas, zkEvm, zksync, } from './networks/index' @@ -47,9 +45,7 @@ const NETWORKS_INFO_CONFIG: NETWORKS_INFO_CONFIG_TYPE = { [ChainId.CRONOS]: cronos, [ChainId.ARBITRUM]: arbitrum, [ChainId.BTTC]: bttc, - [ChainId.VELAS]: velas, [ChainId.AURORA]: aurora, - [ChainId.OASIS]: oasis, [ChainId.OPTIMISM]: optimism, [ChainId.ZKSYNC]: zksync, [ChainId.LINEA]: linea, @@ -87,8 +83,6 @@ export const MAINNET_NETWORKS = [ ChainId.FANTOM, ChainId.BTTC, ChainId.CRONOS, - ChainId.VELAS, - ChainId.OASIS, ChainId.AURORA, ] as const @@ -149,8 +143,6 @@ export const CHAINS_SUPPORT_NEW_POOL_FARM_API: readonly ChainId[] = [ ChainId.BTTC, ChainId.ARBITRUM, ChainId.AURORA, - // ChainId.VELAS, - // ChainId.OASIS, ChainId.OPTIMISM, ] @@ -158,8 +150,6 @@ export const CHAINS_SUPPORT_NEW_POOL_FARM_API: readonly ChainId[] = [ export const STATIC_FEE_OPTIONS: { [chainId: number]: number[] | undefined } = { [ChainId.ARBITRUM]: [8, 10, 50, 300, 500, 1000], [ChainId.AURORA]: [8, 10, 50, 300, 500, 1000], - [ChainId.VELAS]: [8, 10, 50, 300, 500, 1000], - [ChainId.OASIS]: [8, 10, 50, 300, 500, 1000], [ChainId.MAINNET]: [8, 10, 50, 300, 500, 1000], [ChainId.MATIC]: [8, 10, 50, 300, 500, 1000], [ChainId.AVAXMAINNET]: [8, 10, 50, 300, 500, 1000], @@ -178,8 +168,6 @@ export const STATIC_FEE_OPTIONS: { [chainId: number]: number[] | undefined } = { export const ONLY_STATIC_FEE_CHAINS = [ ChainId.ARBITRUM, ChainId.AURORA, - ChainId.VELAS, - ChainId.OASIS, ChainId.OPTIMISM, ChainId.GÖRLI, ChainId.ZKSYNC, @@ -214,18 +202,11 @@ export const SUPPORTED_NETWORKS_FOR_MY_EARNINGS = [ ChainId.FANTOM, ChainId.CRONOS, ChainId.BTTC, - ChainId.VELAS, ChainId.AURORA, - ChainId.OASIS, ] export const COMING_SOON_NETWORKS_FOR_MY_EARNINGS: ChainId[] = [] export const COMING_SOON_NETWORKS_FOR_MY_EARNINGS_LEGACY: ChainId[] = [] -export const COMING_SOON_NETWORKS_FOR_MY_EARNINGS_CLASSIC: ChainId[] = [ - ChainId.CRONOS, - ChainId.VELAS, - ChainId.AURORA, - ChainId.OASIS, -] +export const COMING_SOON_NETWORKS_FOR_MY_EARNINGS_CLASSIC: ChainId[] = [ChainId.CRONOS, ChainId.AURORA] export const BLOCTO_SUPPORTED_NETWORKS: ChainId[] = [ ChainId.MAINNET, ChainId.ARBITRUM, @@ -238,7 +219,6 @@ export const BLOCTO_SUPPORTED_NETWORKS: ChainId[] = [ export const ELASTIC_NOT_SUPPORTED: { [key: string]: string } = { [ChainId.AURORA]: t`Elastic is not supported on Aurora. Please switch to other chains`, [ChainId.ZKSYNC]: t`Elastic will be available soon`, - // [ChainId.VELAS]: t`Elastic will be available soon`, } export const CLASSIC_NOT_SUPPORTED: { [key: string]: string } = { diff --git a/src/constants/networks/index.ts b/src/constants/networks/index.ts index d5d9729def..d5d210bd1b 100644 --- a/src/constants/networks/index.ts +++ b/src/constants/networks/index.ts @@ -11,10 +11,8 @@ export { default as fantom } from './fantom' export { default as görli } from './görli' export { default as matic } from './matic' export { default as mumbai } from './mumbai' -export { default as oasis } from './oasis' export { default as optimism } from './optimism' export { default as solana } from './solana' -export { default as velas } from './velas' export { default as zksync } from './zksync' export { default as linea } from './linea' export { default as zkEvm } from './zkevm' diff --git a/src/constants/networks/oasis.ts b/src/constants/networks/oasis.ts deleted file mode 100644 index d6d3ee62cf..0000000000 --- a/src/constants/networks/oasis.ts +++ /dev/null @@ -1,72 +0,0 @@ -import { ChainId } from '@kyberswap/ks-sdk-core' - -import OASIS from 'assets/networks/oasis-network.svg' -import { EVMNetworkInfo } from 'constants/networks/type' - -const EMPTY = '' -const EMPTY_ARRAY: any[] = [] -const NOT_SUPPORT = null - -const oasisInfo: EVMNetworkInfo = { - chainId: ChainId.OASIS, - route: 'oasis', - ksSettingRoute: 'oasis', - priceRoute: 'oasis', - poolFarmRoute: 'oasis', - aggregatorRoute: 'oasis', - name: 'Oasis', - icon: OASIS, - iconDark: NOT_SUPPORT, - iconSelected: NOT_SUPPORT, - iconDarkSelected: NOT_SUPPORT, - defaultBlockSubgraph: 'https://oasis-graph.kyberengineering.io/subgraphs/name/kybernetwork/oasis-blocks', - etherscanUrl: 'https://explorer.emerald.oasis.dev', - etherscanName: 'Oasis Emerald Explorer', - bridgeURL: EMPTY, - nativeToken: { - symbol: 'ROSE', - name: 'ROSE', - logo: OASIS, - decimal: 18, - minForGas: 10 ** 16, - }, - defaultRpcUrl: 'https://oasis.kyberengineering.io', - multicall: '0xBF69a56D35B8d6f5A8e0e96B245a72F735751e54', - classic: { - defaultSubgraph: 'https://oasis-graph.kyberengineering.io/subgraphs/name/kybernetwork/kyberswap-exchange-oasis', - static: { - zap: '0x2abE8750e4a65584d7452316356128C936273e0D', - router: '0x5649B4DD00780e99Bab7Abb4A3d581Ea1aEB23D0', - factory: '0x1c758aF0688502e49140230F6b0EBd376d429be5', - }, - oldStatic: { - zap: '0x83D4908c1B4F9Ca423BEE264163BC1d50F251c31', - router: '0xEaE47c5D99f7B31165a7f0c5f7E0D6afA25CFd55', - factory: '0xD9bfE9979e9CA4b2fe84bA5d4Cf963bBcB376974', - }, - dynamic: NOT_SUPPORT, - claimReward: NOT_SUPPORT, - fairlaunch: EMPTY_ARRAY, - fairlaunchV2: EMPTY_ARRAY, - }, - elastic: { - defaultSubgraph: 'https://oasis-graph.kyberengineering.io/subgraphs/name/kybernetwork/kyberswap-elastic-oasis', - startBlock: 5735155, - coreFactory: '0xC7a590291e07B9fe9E64b86c58fD8fC764308C4A', - nonfungiblePositionManager: '0xe222fBE074A436145b255442D919E4E3A6c6a480', - tickReader: '0x8Fd8Cb948965d9305999D767A02bf79833EADbB3', - initCodeHash: '0x00e263aaa3a2c06a89b53217a9e7aad7e15613490a72e0f95f303c4de2dc7045', - quoter: '0x4d47fd5a29904Dae0Ef51b1c450C9750F15D7856', - routers: '0xF9c2b5746c946EF883ab2660BbbB1f10A5bdeAb4', - farms: [], - }, - limitOrder: NOT_SUPPORT, - averageBlockTimeInSeconds: 10, - coingeckoNetworkId: 'oasis', - coingeckoNativeTokenId: 'oasis-network', - deBankSlug: EMPTY, - dexToCompare: 'valleyswap-v2', - geckoTermialId: 'oasis', -} - -export default oasisInfo diff --git a/src/constants/networks/velas.ts b/src/constants/networks/velas.ts deleted file mode 100644 index f829e0e899..0000000000 --- a/src/constants/networks/velas.ts +++ /dev/null @@ -1,72 +0,0 @@ -import { ChainId } from '@kyberswap/ks-sdk-core' - -import VELAS from 'assets/networks/velas-network.png' -import { EVMNetworkInfo } from 'constants/networks/type' - -const EMPTY = '' -const EMPTY_ARRAY: any[] = [] -const NOT_SUPPORT = null - -const velasInfo: EVMNetworkInfo = { - chainId: ChainId.VELAS, - route: 'velas', - ksSettingRoute: 'velas', - priceRoute: 'velas', - poolFarmRoute: 'velas', - aggregatorRoute: 'velas', - name: 'Velas', - icon: VELAS, - iconDark: NOT_SUPPORT, - iconSelected: NOT_SUPPORT, - iconDarkSelected: NOT_SUPPORT, - defaultBlockSubgraph: 'https://velas-graph.kyberengineering.io/subgraphs/name/kybernetwork/velas-blocks', - etherscanUrl: 'https://evmexplorer.velas.com', - etherscanName: 'Velas EVM Explorer', - bridgeURL: EMPTY, - nativeToken: { - symbol: 'VLX', - name: 'VLX', - logo: VELAS, - decimal: 18, - minForGas: 10 ** 16, - }, - defaultRpcUrl: 'https://evmexplorer.velas.com/rpc', - multicall: '0x1877Ec0770901cc6886FDA7E7525a78c2Ed4e975', - classic: { - defaultSubgraph: 'https://velas-graph.kyberengineering.io/subgraphs/name/kybernetwork/kyberswap-exchange-velas', - static: { - zap: '0x2abE8750e4a65584d7452316356128C936273e0D', - router: '0x5649B4DD00780e99Bab7Abb4A3d581Ea1aEB23D0', - factory: '0x1c758aF0688502e49140230F6b0EBd376d429be5', - }, - oldStatic: { - zap: '0x83D4908c1B4F9Ca423BEE264163BC1d50F251c31', - router: '0xEaE47c5D99f7B31165a7f0c5f7E0D6afA25CFd55', - factory: '0xD9bfE9979e9CA4b2fe84bA5d4Cf963bBcB376974', - }, - dynamic: NOT_SUPPORT, - claimReward: NOT_SUPPORT, - fairlaunch: EMPTY_ARRAY, - fairlaunchV2: EMPTY_ARRAY, - }, - elastic: { - defaultSubgraph: 'https://velas-graph.kyberengineering.io/subgraphs/name/kybernetwork/kyberswap-elastic-velas', - startBlock: 63322472, - coreFactory: '0xC7a590291e07B9fe9E64b86c58fD8fC764308C4A', - nonfungiblePositionManager: '0xe222fBE074A436145b255442D919E4E3A6c6a480', - tickReader: '0x8Fd8Cb948965d9305999D767A02bf79833EADbB3', - initCodeHash: '0x00e263aaa3a2c06a89b53217a9e7aad7e15613490a72e0f95f303c4de2dc7045', - quoter: '0x4d47fd5a29904Dae0Ef51b1c450C9750F15D7856', - routers: '0xF9c2b5746c946EF883ab2660BbbB1f10A5bdeAb4', - farms: [], - }, - limitOrder: NOT_SUPPORT, - averageBlockTimeInSeconds: 0.4, - coingeckoNetworkId: 'velas', - coingeckoNativeTokenId: 'velas', - deBankSlug: EMPTY, - dexToCompare: 'wagyuswap', - geckoTermialId: 'velas', -} - -export default velasInfo diff --git a/src/constants/permit.ts b/src/constants/permit.ts index 15ecb4e302..752a27f274 100644 --- a/src/constants/permit.ts +++ b/src/constants/permit.ts @@ -38,26 +38,6 @@ export const PERMITTABLE_TOKENS: { '0xeEeEEb57642040bE42185f49C52F7E9B38f8eeeE': { type: PermitType.AMOUNT, version: '1' }, // ELK '0x8497842420cFdbc97896C2353D75d89Fc8D5Be5D': { type: PermitType.AMOUNT, version: '1' }, // VERSA }, - [ChainId.OASIS]: { - // '0x32847e63E99D3a044908763056e25694490082F8': { type: PermitType.SALT, version: '1' }, - // '0xd79Ef9A91b56c690C7b80570a3c060678667f469': { type: PermitType.SALT, version: '1' }, - // '0x4cA2A3De42eabC8fd8b0AC46127E64DB08b9150e': { type: PermitType.SALT, version: '1' }, - // '0x366EF31C8dc715cbeff5fA54Ad106dC9c25C6153': { type: PermitType.SALT, version: '1' }, - // '0x3223f17957Ba502cbe71401D55A0DB26E5F7c68F': { type: PermitType.SALT, version: '1' }, - // '0xE8A638b3B7565Ee7c5eb9755E58552aFc87b94DD': { type: PermitType.SALT, version: '1' }, - // '0xdC19A122e268128B5eE20366299fc7b5b199C8e3': { type: PermitType.SALT, version: '1' }, - // '0xd43ce0aa2a29DCb75bDb83085703dc589DE6C7eb': { type: PermitType.SALT, version: '1' }, - // '0x3E62a9c3aF8b810dE79645C4579acC8f0d06a241': { type: PermitType.SALT, version: '1' }, - // '0xFffD69E757d8220CEA60dc80B9Fe1a30b58c94F3': { type: PermitType.SALT, version: '1' }, - // '0x1d1149a53deB36F2836Ae7877c9176413aDfA4A8': { type: PermitType.SALT, version: '1' }, - // '0x24285C5232ce3858F00bacb950Cae1f59d1b2704': { type: PermitType.SALT, version: '1' }, - // '0xa1E73c01E0cF7930F5e91CB291031739FE5Ad6C2': { type: PermitType.SALT, version: '1' }, - // '0x4F43717B20ae319Aa50BC5B2349B93af5f7Ac823': { type: PermitType.SALT, version: '1' }, - '0xB44a9B6905aF7c801311e8F4E76932ee959c663C': { type: PermitType.AMOUNT, version: '1' }, //ETH - '0x80A16016cC4A2E6a2CACA8a4a498b1699fF0f844': { type: PermitType.AMOUNT, version: '1' }, //USDC - '0xE3F5a90F9cb311505cd691a46596599aA1A0AD7D': { type: PermitType.AMOUNT, version: '1' }, //BNB - '0x639A647fbe20b6c8ac19E48E2de44ea792c62c5C': { type: PermitType.AMOUNT, version: '1' }, //BUSD - }, [ChainId.CRONOS]: { '0xe6801928061CDbE32AC5AD0634427E140EFd05F9': { type: PermitType.AMOUNT, version: '1' }, //BIFI }, @@ -80,9 +60,6 @@ export const PERMITTABLE_TOKENS: { [ChainId.BSCMAINNET]: { // '0xD6Cce248263ea1e2b8cB765178C944Fc16Ed0727': { type: PermitType.SALT, version: '1' }, }, - [ChainId.VELAS]: { - // '0xcD7509b76281223f5B7d3aD5d47F8D7Aa5C2B9bf': { type: PermitType.SALT, version: '1' }, - }, [ChainId.OPTIMISM]: { // '0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1': { type: PermitType.SALT, version: '1' }, // '0xbfD291DA8A403DAAF7e5E9DC1ec0aCEaCd4848B9': { type: PermitType.SALT, version: '1' }, diff --git a/src/constants/tokens.ts b/src/constants/tokens.ts index 1f218561e9..8087ffb1e5 100644 --- a/src/constants/tokens.ts +++ b/src/constants/tokens.ts @@ -28,16 +28,6 @@ export const NativeCurrencies = new Proxy(NativeCurrenciesLocal, { // This list is intentionally different from the list above // Was requested from product team, to implement Swap fee config export const STABLE_COIN_ADDRESSES_TO_TAKE_FEE: Record = { - [ChainId.OASIS]: [ - '0x80A16016cC4A2E6a2CACA8a4a498b1699fF0f844', // usdc - '0x6Cb9750a92643382e020eA9a170AbB83Df05F30B', // usdt - '0x639A647fbe20b6c8ac19E48E2de44ea792c62c5C', // busd - ], - [ChainId.VELAS]: [ - '0xe2C120f188eBd5389F71Cf4d9C16d05b62A58993', // usdc - '0x01445C31581c354b7338AC35693AB2001B50b9aE', // usdt - '0xc111c29A988AE0C0087D97b33C6E6766808A3BD3', // busd - ], [ChainId.AURORA]: [ '0xB12BFcA5A55806AaF64E99521918A4bf0fC40802', // usdc '0x4988a896b1227218e4A686fdE5EabdcAbd91571f', // usdt @@ -131,24 +121,11 @@ export const SUPER_STABLE_COINS_ADDRESS: { [chainId in ChainId]: string[] } = { '0xE887512ab8BC60BcC9224e1c3b5Be68E26048B8B', // usdt_e '0xAE17940943BA9440540940DB0F1877f101D39e8b', // usdc_e ], - [ChainId.VELAS]: [ - '0xe2C120f188eBd5389F71Cf4d9C16d05b62A58993', // usdc - '0x01445C31581c354b7338AC35693AB2001B50b9aE', // usdt - ], [ChainId.AURORA]: [ '0xe3520349F477A5F6EB06107066048508498A291b', // Dai '0xB12BFcA5A55806AaF64E99521918A4bf0fC40802', // usdc '0x4988a896b1227218e4A686fdE5EabdcAbd91571f', // usdt ], - [ChainId.OASIS]: [ - '0x80A16016cC4A2E6a2CACA8a4a498b1699fF0f844', // usdc - '0xdC19A122e268128B5eE20366299fc7b5b199C8e3', // usdtet - '0x639A647fbe20b6c8ac19E48E2de44ea792c62c5C', // busd - '0x6Cb9750a92643382e020eA9a170AbB83Df05F30B', // usdt - '0x5a4Ba16C2AeB295822A95280A7c7149E87769E6A', // ceDAI - '0x81ECac0D6Be0550A00FF064a4f9dd2400585FE9c', // ceUSDC - '0x4Bf769b05E832FCdc9053fFFBC78Ca889aCb5E1E', // ceUSDT - ], [ChainId.OPTIMISM]: [ '0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1', // Dai '0x94b008aA00579c1307B0EF2c499aD98a8ce58e58', // usdt @@ -213,9 +190,7 @@ export const CORRELATED_COINS_ADDRESS: { [chainId in ChainId]: string[][] } = { [ChainId.CRONOS]: [], [ChainId.ARBITRUM]: [], [ChainId.BTTC]: [], - [ChainId.VELAS]: [], [ChainId.AURORA]: [], - [ChainId.OASIS]: [], [ChainId.OPTIMISM]: [], [ChainId.SOLANA]: [], [ChainId.GÖRLI]: [], @@ -252,10 +227,6 @@ export const DAI: { [chainId in ChainId]: Token } = { [ChainId.LINEA]: new Token(ChainId.LINEA, '0x4AF15ec2A0BD43Db75dd04E62FAA3B8EF36b00d5', 18, 'DAI', 'Dai'), [ChainId.BASE]: new Token(ChainId.BASE, '0x50c5725949a6f0c72e6c4a641f24049a917db0cb', 18, 'DAI', 'Dai'), - //not existing on Velas - [ChainId.VELAS]: new Token(ChainId.VELAS, '0xe7dC549AE8DB61BDE71F22097BEcc8dB542cA100', 18, 'DAI', 'DAI'), - //not existing on Oasis - [ChainId.OASIS]: new Token(ChainId.OASIS, '0xe7dC549AE8DB61BDE71F22097BEcc8dB542cA100', 18, 'DAI', 'DAI'), [ChainId.OPTIMISM]: new Token(ChainId.OPTIMISM, '0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1', 18, 'DAI', 'DAI'), [ChainId.ZKSYNC]: new Token(ChainId.ZKSYNC, '0x4BEf76b6b7f2823C6c1f4FcfEACD85C24548ad7e', 18, 'DAI', 'Dai'), [ChainId.SOLANA]: new Token( @@ -300,14 +271,6 @@ export const USDC: { [chainId in ChainId]: Token } = { [ChainId.ARBITRUM]: new Token(ChainId.ARBITRUM, '0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8', 6, 'USDC', 'USD Coin'), [ChainId.BTTC]: new Token(ChainId.BTTC, '0xCa424b845497f7204D9301bd13Ff87C0E2e86FCF', 18, 'USDC_b', 'USD Coin_BSC'), [ChainId.AURORA]: new Token(ChainId.AURORA, '0xB12BFcA5A55806AaF64E99521918A4bf0fC40802', 6, 'USDC', 'USD Coin'), - [ChainId.VELAS]: new Token(ChainId.VELAS, '0xe2C120f188eBd5389F71Cf4d9C16d05b62A58993', 6, 'USDC', 'Multichain USDC'), - [ChainId.OASIS]: new Token( - ChainId.OASIS, - '0x80a16016cc4a2e6a2caca8a4a498b1699ff0f844', - 6, - 'USDC', - 'USD Coin (Multichain)', - ), [ChainId.OPTIMISM]: new Token(ChainId.OPTIMISM, '0x7F5c764cBc14f9669B88837ca1490cCa17c31607', 6, 'USDC', 'USD Coin'), [ChainId.ZKSYNC]: new Token(ChainId.ZKSYNC, '0x3355df6D4c9C3035724Fd0e3914dE96A5a83aaf4', 6, 'USDC', 'USD Coin'), [ChainId.SOLANA]: new Token(ChainId.SOLANA, 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v', 6, 'USDC', 'USD Coin'), @@ -367,8 +330,6 @@ export const USDT: { [chainId in ChainId]: Token } = { ), [ChainId.BTTC]: new Token(ChainId.BTTC, '0x9B5F27f6ea9bBD753ce3793a07CbA3C74644330d', 18, 'USDT_b', 'Tether USD_BSC'), [ChainId.AURORA]: new Token(ChainId.AURORA, '0x4988a896b1227218e4A686fdE5EabdcAbd91571f', 6, 'USDT', 'Tether USD'), - [ChainId.VELAS]: new Token(ChainId.VELAS, '0x01445C31581c354b7338AC35693AB2001B50b9aE', 6, 'USDT', 'Multichain USDT'), - [ChainId.OASIS]: new Token(ChainId.OASIS, '0x6Cb9750a92643382e020eA9a170AbB83Df05F30B', 6, 'USDT', 'Tether USD'), [ChainId.OPTIMISM]: new Token( ChainId.OPTIMISM, '0x94b008aA00579c1307B0EF2c499aD98a8ce58e58', @@ -427,8 +388,6 @@ export const KNC: { [chainId in ChainId]: Token } = { [ChainId.FANTOM]: new Token(ChainId.FANTOM, KNC_ADDRESS, 18, 'KNC', 'KNC'), [ChainId.BASE]: new Token(ChainId.BASE, KNC_ADDRESS, 18, 'KNC', 'KNC'), [ChainId.ZKSYNC]: new Token(ChainId.ZKSYNC, KNC_ADDRESS, 18, 'KNC', 'KNC'), - [ChainId.VELAS]: new Token(ChainId.VELAS, KNC_ADDRESS, 18, 'KNC', 'KNC'), - [ChainId.OASIS]: new Token(ChainId.OASIS, KNC_ADDRESS, 18, 'KNC', 'KNC'), [ChainId.AVAXTESTNET]: new Token(ChainId.AVAXTESTNET, KNC_ADDRESS, 18, 'KNC', 'KNC'), [ChainId.MUMBAI]: new Token(ChainId.MUMBAI, '0xFD1f9381Cb641Dc76Fe8087dbcf8ea84a2c77cbE', 18, 'KNC', 'KNC'), @@ -463,9 +422,7 @@ export const DEFAULT_OUTPUT_TOKEN_BY_CHAIN: Partial> = { [ChainId.CRONOS]: USDC[ChainId.CRONOS], [ChainId.ARBITRUM]: new Token(ChainId.ARBITRUM, '0x912CE59144191C1204E64559FE8253a0e49E6548', 18, 'ARB', 'Arbitrum'), [ChainId.OPTIMISM]: USDC[ChainId.OPTIMISM], - [ChainId.VELAS]: USDC[ChainId.VELAS], [ChainId.AURORA]: USDC[ChainId.AURORA], - [ChainId.OASIS]: USDC[ChainId.OASIS], [ChainId.BTTC]: USDT[ChainId.BTTC], // USDT_b [ChainId.SOLANA]: USDC[ChainId.SOLANA], [ChainId.GÖRLI]: USDT[ChainId.GÖRLI], diff --git a/src/hooks/useElasticLegacy.ts b/src/hooks/useElasticLegacy.ts index 6699174773..204b1e02e4 100644 --- a/src/hooks/useElasticLegacy.ts +++ b/src/hooks/useElasticLegacy.ts @@ -92,20 +92,6 @@ export const config: { positionManagerContract: '0x2B1c7b41f6A8F2b2bc45C3233a5d5FB3cD6dC9A8', tickReaderContract: '0x165c68077ac06c83800d19200e6E2B08D02dE75D', }, - - [ChainId.VELAS]: { - subgraphUrl: 'https://velas-graph.kyberengineering.io/subgraphs/name/kybernetwork/kyberswap-elastic-velas-legacy', - farmContract: '', - positionManagerContract: '0x2B1c7b41f6A8F2b2bc45C3233a5d5FB3cD6dC9A8', - tickReaderContract: '0x165c68077ac06c83800d19200e6E2B08D02dE75D', - }, - - [ChainId.OASIS]: { - subgraphUrl: 'https://oasis-graph.kyberengineering.io/subgraphs/name/kybernetwork/kyberswap-elastic-oasis-legacy', - farmContract: '', - positionManagerContract: '0x2B1c7b41f6A8F2b2bc45C3233a5d5FB3cD6dC9A8', - tickReaderContract: '0x165c68077ac06c83800d19200e6E2B08D02dE75D', - }, } const query = (user: string) => ` diff --git a/src/pages/About/AboutKyberSwap/index.tsx b/src/pages/About/AboutKyberSwap/index.tsx index 9843a19356..520339d1a4 100644 --- a/src/pages/About/AboutKyberSwap/index.tsx +++ b/src/pages/About/AboutKyberSwap/index.tsx @@ -42,10 +42,8 @@ import { LineaFull, LowestSlippage, MoneyBagOutline, - OasisLogoFull, OptimismLogoFull, PolygonLogoFull, - VelasLogoFull, } from 'components/Icons' import AntiSnippingAttack from 'components/Icons/AntiSnippingAttack' import ZkSyncFull from 'components/Icons/ZkSyncFull' @@ -1023,9 +1021,7 @@ function AboutKyberSwap() { - - btt {/* */} diff --git a/src/pages/About/styleds.tsx b/src/pages/About/styleds.tsx index 8a3551a1b9..5dc86eb046 100644 --- a/src/pages/About/styleds.tsx +++ b/src/pages/About/styleds.tsx @@ -227,7 +227,7 @@ export const Powered = styled.div` justify-content: center; gap: 52px; & > * { - width: calc(100% / 6 - 52px); + width: calc(100% / 5 - 52px); } svg { max-width: 100%; diff --git a/src/pages/BuyCrypto/index.tsx b/src/pages/BuyCrypto/index.tsx index 9fca37c261..31034126cd 100644 --- a/src/pages/BuyCrypto/index.tsx +++ b/src/pages/BuyCrypto/index.tsx @@ -187,7 +187,6 @@ function BuyCrypto() { [ChainId.BSCMAINNET]: 'bsc', [ChainId.AVAXMAINNET]: 'avaxcchain', [ChainId.FANTOM]: 'fantom', - [ChainId.VELAS]: 'velasevm', [ChainId.SOLANA]: 'solana', [ChainId.ZKSYNC]: null, @@ -198,7 +197,6 @@ function BuyCrypto() { [ChainId.AVAXTESTNET]: null, [ChainId.BTTC]: null, [ChainId.AURORA]: null, - [ChainId.OASIS]: null, } const supportedCurrencies = [ 'AVAX', diff --git a/yarn.lock b/yarn.lock index c5c59fa22d..99dcc5b2df 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2233,10 +2233,10 @@ tiny-warning "^1.0.3" toformat "^2.0.0" -"@kyberswap/ks-sdk-core@1.0.10", "@kyberswap/ks-sdk-core@^1.0.5": - version "1.0.10" - resolved "https://registry.yarnpkg.com/@kyberswap/ks-sdk-core/-/ks-sdk-core-1.0.10.tgz#11de6c644d67ecdf3ced22e2560ff28580225846" - integrity sha512-g3+EDfCjH0waYacmN/yiSvEWITwDME2lWLutCPx1G43ySfmQoFTXIuzcBWdit8t2eXtTLBhzu1IBTM1WjUbaOA== +"@kyberswap/ks-sdk-core@1.0.11", "@kyberswap/ks-sdk-core@^1.0.5": + version "1.0.11" + resolved "https://registry.yarnpkg.com/@kyberswap/ks-sdk-core/-/ks-sdk-core-1.0.11.tgz#59362240147001ccabcb49ed77991b2f78b0e440" + integrity sha512-A7pPRqr0lFeSYOsuitsld+WglV4G8Tl5FsKZpx9mBjOrSFKGLOtCE0oMwAeD4+Jjo8VyLJppkBINQYY7wAq8Xg== dependencies: "@ethersproject/address" "^5.0.2" "@solana/web3.js" "^1.66.2"