From 21e2a710a795e380700efed61e3fbfd205e215e9 Mon Sep 17 00:00:00 2001 From: Kevin Peters Date: Tue, 15 Mar 2022 00:22:24 +0000 Subject: [PATCH] bridge_ui: enable polygon transfers --- bridge_ui/src/components/NFT/Source.tsx | 10 ++----- bridge_ui/src/components/NFT/Target.tsx | 5 +--- .../components/PolygonNetworkDownWarning.tsx | 30 ------------------- bridge_ui/src/components/Transfer/Source.tsx | 8 +---- 4 files changed, 4 insertions(+), 49 deletions(-) delete mode 100644 bridge_ui/src/components/PolygonNetworkDownWarning.tsx diff --git a/bridge_ui/src/components/NFT/Source.tsx b/bridge_ui/src/components/NFT/Source.tsx index cff35235b..da8d6ad9c 100644 --- a/bridge_ui/src/components/NFT/Source.tsx +++ b/bridge_ui/src/components/NFT/Source.tsx @@ -1,8 +1,4 @@ -import { - CHAIN_ID_POLYGON, - CHAIN_ID_SOLANA, - isEVMChain, -} from "@certusone/wormhole-sdk"; +import { CHAIN_ID_SOLANA, isEVMChain } from "@certusone/wormhole-sdk"; import { Button, makeStyles } from "@material-ui/core"; import { VerifiedUser } from "@material-ui/icons"; import { Alert } from "@material-ui/lab"; @@ -23,7 +19,6 @@ import ButtonWithLoader from "../ButtonWithLoader"; import ChainSelect from "../ChainSelect"; import KeyAndBalance from "../KeyAndBalance"; import LowBalanceWarning from "../LowBalanceWarning"; -import PolygonNetworkDownWarning from "../PolygonNetworkDownWarning"; import SolanaTPSWarning from "../SolanaTPSWarning"; import StepDescription from "../StepDescription"; import { TokenSelector } from "../TokenSelectors/SourceTokenSelector"; @@ -97,10 +92,9 @@ function Source() { ) : null} - {sourceChain === CHAIN_ID_POLYGON && } {sourceChain === CHAIN_ID_SOLANA && } {targetChain === CHAIN_ID_SOLANA && } - {targetChain === CHAIN_ID_POLYGON && } ({ - alert: { - marginTop: theme.spacing(1), - marginBottom: theme.spacing(1), - }, -})); - -export default function PolygonNetworkDownWarning() { - const classes = useStyles(); - - return ( - - Polygon is currently experiencing partial downtime. - As a precautionary measure, Wormhole Network and Portal have paused Polygon - support until the network has been fully restored. - - - Follow @0xPolygonDevs for updates - - - - ); -} diff --git a/bridge_ui/src/components/Transfer/Source.tsx b/bridge_ui/src/components/Transfer/Source.tsx index 08e1dc668..065e516ed 100644 --- a/bridge_ui/src/components/Transfer/Source.tsx +++ b/bridge_ui/src/components/Transfer/Source.tsx @@ -1,7 +1,6 @@ import { CHAIN_ID_BSC, CHAIN_ID_ETH, - CHAIN_ID_POLYGON, CHAIN_ID_SOLANA, } from "@certusone/wormhole-sdk"; import { getAddress } from "@ethersproject/address"; @@ -40,7 +39,6 @@ import ChainSelectArrow from "../ChainSelectArrow"; import KeyAndBalance from "../KeyAndBalance"; import LowBalanceWarning from "../LowBalanceWarning"; import NumberTextField from "../NumberTextField"; -import PolygonNetworkDownWarning from "../PolygonNetworkDownWarning"; import SolanaTPSWarning from "../SolanaTPSWarning"; import StepDescription from "../StepDescription"; import { TokenSelector } from "../TokenSelectors/SourceTokenSelector"; @@ -142,9 +140,6 @@ function Source() { dispatch(incrementStep()); }, [dispatch]); - const isPolygonTransfer = - sourceChain === CHAIN_ID_POLYGON || targetChain === CHAIN_ID_POLYGON; - return ( <> @@ -220,7 +215,6 @@ function Source() { <> {sourceChain === CHAIN_ID_SOLANA && } - {isPolygonTransfer && } ) : null}