From d8bfd898acc75c6471829ad2c629089db65c6268 Mon Sep 17 00:00:00 2001 From: Sebastian Scatularo Date: Thu, 27 Jul 2023 19:03:48 -0300 Subject: [PATCH] bump wormhole-sdk version, prettier checks, remove unecesary constant --- package-lock.json | 18 +++++++++--------- package.json | 2 +- src/components/ShowTx.tsx | 8 ++++---- src/utils/consts.ts | 12 +++++------- src/utils/metaMaskChainParameters.ts | 2 +- 5 files changed, 20 insertions(+), 22 deletions(-) diff --git a/package-lock.json b/package-lock.json index b95f91c51..4b6d7acc3 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,14 +1,14 @@ { "name": "@xlabs/portal-bridge-ui", - "version": "0.1.51", + "version": "0.1.52", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@xlabs/portal-bridge-ui", - "version": "0.1.51", + "version": "0.1.52", "dependencies": { - "@certusone/wormhole-sdk": "^0.9.20", + "@certusone/wormhole-sdk": "^0.9.22", "@injectivelabs/sdk-ts": "^1.10.72", "@injectivelabs/ts-types": "^1.10.4", "@injectivelabs/wallet-ts": "^1.10.51", @@ -2280,9 +2280,9 @@ } }, "node_modules/@certusone/wormhole-sdk": { - "version": "0.9.20", - "resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.9.20.tgz", - "integrity": "sha512-sHmvqK0FYUa+NCO+kqPQ7CkPrFnl40pGQ8pmp3KW/xn3ECz7ECA3M1/07UvMNzcifbHwM1nmO0QhkEAjREB8wg==", + "version": "0.9.22", + "resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.9.22.tgz", + "integrity": "sha512-4wZFyqqSQBtTq5S42TCrTAircnRjd0t0OZnFRyMe5qtqk96l5iDwIztKBaIccUW+XDXoGfBhSGooW15tH/IpIQ==", "dependencies": { "@certusone/wormhole-sdk-proto-web": "0.0.6", "@certusone/wormhole-sdk-wasm": "^0.0.1", @@ -45449,9 +45449,9 @@ } }, "@certusone/wormhole-sdk": { - "version": "0.9.20", - "resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.9.20.tgz", - "integrity": "sha512-sHmvqK0FYUa+NCO+kqPQ7CkPrFnl40pGQ8pmp3KW/xn3ECz7ECA3M1/07UvMNzcifbHwM1nmO0QhkEAjREB8wg==", + "version": "0.9.22", + "resolved": "https://registry.npmjs.org/@certusone/wormhole-sdk/-/wormhole-sdk-0.9.22.tgz", + "integrity": "sha512-4wZFyqqSQBtTq5S42TCrTAircnRjd0t0OZnFRyMe5qtqk96l5iDwIztKBaIccUW+XDXoGfBhSGooW15tH/IpIQ==", "requires": { "@certusone/wormhole-sdk-proto-web": "0.0.6", "@certusone/wormhole-sdk-wasm": "^0.0.1", diff --git a/package.json b/package.json index 74f83c57f..1a1b5a1dc 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "version": "0.1.52", "private": true, "dependencies": { - "@certusone/wormhole-sdk": "^0.9.20", + "@certusone/wormhole-sdk": "^0.9.22", "@injectivelabs/sdk-ts": "^1.10.72", "@injectivelabs/ts-types": "^1.10.4", "@injectivelabs/wallet-ts": "^1.10.51", diff --git a/src/components/ShowTx.tsx b/src/components/ShowTx.tsx index 2b14090d6..e6424a986 100644 --- a/src/components/ShowTx.tsx +++ b/src/components/ShowTx.tsx @@ -23,7 +23,7 @@ import { CHAIN_ID_INJECTIVE, CHAIN_ID_OPTIMISM, CHAIN_ID_SUI, - CHAIN_ID_BASE + CHAIN_ID_BASE, } from "@certusone/wormhole-sdk"; import { CHAIN_ID_NEAR } from "@certusone/wormhole-sdk/lib/esm"; import { Button, makeStyles, Typography } from "@material-ui/core"; @@ -137,9 +137,9 @@ export default function ShowTx({ CLUSTER === "testnet" ? "moonbase." : "" }moonscan.io/tx/${tx?.id}` : chainId === CHAIN_ID_BASE - ? `https://${CLUSTER === "testnet" ? "goerli." : ""}basescan.org/tx/${ - tx?.id - }` + ? `https://${ + CLUSTER === "testnet" ? "goerli." : "" + }basescan.org/tx/${tx?.id}` : chainId === CHAIN_ID_XPLA ? `https://explorer.xpla.io/${ CLUSTER === "testnet" ? "testnet" : "mainnet" diff --git a/src/utils/consts.ts b/src/utils/consts.ts index c657d14ac..5eefcbbbe 100644 --- a/src/utils/consts.ts +++ b/src/utils/consts.ts @@ -44,7 +44,7 @@ import algorandIcon from "../icons/algorand.svg"; import arbitrumIcon from "../icons/arbitrum.svg"; import auroraIcon from "../icons/aurora.svg"; import avaxIcon from "../icons/avax.svg"; -import baseIcon from '../icons/base.svg'; +import baseIcon from "../icons/base.svg"; import bscIcon from "../icons/bsc.svg"; import celoIcon from "../icons/celo.svg"; import ethIcon from "../icons/eth.svg"; @@ -122,7 +122,7 @@ export const CHAINS: ChainInfo[] = { id: CHAIN_ID_BASE, name: "Base", - logo: baseIcon + logo: baseIcon, }, { id: CHAIN_ID_BSC, @@ -245,7 +245,7 @@ export const CHAINS: ChainInfo[] = { id: CHAIN_ID_BASE, name: "Base", - logo: baseIcon + logo: baseIcon, }, { id: CHAIN_ID_BSC, @@ -629,7 +629,7 @@ export const ARBITRUM_NETWORK_CHAIN_ID = CLUSTER === "mainnet" ? 42161 : CLUSTER === "testnet" ? 421613 : 1381; export const OPTIMISM_NETWORK_CHAIN_ID = CLUSTER === "mainnet" ? 10 : CLUSTER === "testnet" ? 420 : 1381; -export const BASE_NETWORK_CHAIN_ID = +export const BASE_NETWORK_CHAIN_ID = CLUSTER === "mainnet" ? 8453 : CLUSTER === "testnet" ? 84531 : 1381; export const getEvmChainId = (chainId: ChainId) => @@ -1262,7 +1262,7 @@ export const COVALENT_OPTIMISM = CLUSTER === "devnet" ? null : OPTIMISM_NETWORK_CHAIN_ID; // Covalent only supports mainnet export const COVALENT_BASE = - CLUSTER === "devnet" ? null : BASE_NETWORK_CHAIN_ID + CLUSTER === "devnet" ? null : BASE_NETWORK_CHAIN_ID; export const COVALENT_GET_TOKENS_URL = ( chainId: ChainId, @@ -1360,8 +1360,6 @@ export const WETH_ADDRESS = : "0xDDb64fE46a91D46ee29420539FC25FD07c5FEa3E"; export const WETH_DECIMALS = 18; -export const BASE_WETH_DECIMALS = 18; - export const WBNB_ADDRESS = CLUSTER === "mainnet" ? "0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c" diff --git a/src/utils/metaMaskChainParameters.ts b/src/utils/metaMaskChainParameters.ts index 12d55f4ac..ef2df5dbf 100644 --- a/src/utils/metaMaskChainParameters.ts +++ b/src/utils/metaMaskChainParameters.ts @@ -240,7 +240,7 @@ export const METAMASK_CHAIN_PARAMETERS: { nativeCurrency: { name: "Goerli Ether", symbol: "GOR", decimals: 18 }, rpcUrls: ["https://goerli.base.org"], blockExplorerUrls: ["https://goerli.basescan.org"], - } + }, }; export interface EvmRpcMap {