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

Local node #14

Open
wants to merge 4 commits into
base: development-3.3.6
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
2 changes: 1 addition & 1 deletion .yarnrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ignore-scripts true
ignore-scripts false
9 changes: 7 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@
"compile-v3-contract-types": "typechain --target ethers-v5 --out-dir src/types/v3 './node_modules/@uniswap/?(v3-core|v3-periphery)/artifacts/contracts/**/*.json'",
"build": "yarn compile-contract-types && react-scripts build",
"integration-test": "start-server-and-test 'serve build -l 3000' http://localhost:3000 'cypress run'",
"postinstall": "yarn compile-contract-types",
"postinstall": "yarn compile-contract-types && yarn patch-package",
"start": "yarn compile-contract-types && react-scripts start",
"storybook": "start-storybook -p 6006",
"test": "react-scripts test --env=jsdom"
Expand All @@ -149,5 +149,10 @@
]
},
"license": "GPL-3.0-or-later",
"dependencies": {}
"dependencies": {
"patch-package": "^6.5.1",
"postinstall-postinstall": "^2.1.0",
"tiny-invariant": "^1.3.1"
},
"packageManager": "yarn@3.0.0"
}
91 changes: 91 additions & 0 deletions patches/@uniswap+sdk-core+3.0.0-alpha.1.patch

Large diffs are not rendered by default.

106 changes: 106 additions & 0 deletions patches/@uniswap+v2-sdk+3.0.0-alpha.0.patch

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion src/components/CurrencyLogo/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ChainId, Currency } from '@uniswap/sdk-core'
import { Currency } from '@uniswap/sdk-core'
import { ChainId } from '../../constants/goerliConstants'
import React, { useMemo } from 'react'
import styled from 'styled-components/macro'
import EthereumLogo from '../../assets/images/ethereum-logo.png'
Expand Down
3 changes: 2 additions & 1 deletion src/components/Header/UniBalanceContent.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ChainId, CurrencyAmount, Token } from '@uniswap/sdk-core'
import { CurrencyAmount, Token } from '@uniswap/sdk-core'
import { ChainId } from '../../constants/goerliConstants'
import React, { useMemo } from 'react'
import { X } from 'react-feather'
import styled from 'styled-components/macro'
Expand Down
3 changes: 2 additions & 1 deletion src/components/Header/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../../constants/goerliConstants'
import useScrollPosition from '@react-hook/window-scroll'
import React, { useState } from 'react'
import { Text } from 'rebass'
Expand Down Expand Up @@ -306,6 +306,7 @@ const NETWORK_LABELS: { [chainId in ChainId]?: string } = {
[ChainId.ROPSTEN]: 'Ropsten',
[ChainId.GÖRLI]: 'Görli',
[ChainId.KOVAN]: 'Kovan',
[ChainId.LOCALNODE]: 'Localnode',
}

export default function Header() {
Expand Down
3 changes: 2 additions & 1 deletion src/components/PositionListItem/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ import { Link } from 'react-router-dom'
import styled from 'styled-components/macro'
import { HideSmall, MEDIA_WIDTHS, SmallOnly } from 'theme'
import { PositionDetails } from 'types/position'
import { WETH9, Price, Token, Percent } from '@uniswap/sdk-core'
import { Price, Token, Percent } from '@uniswap/sdk-core'
import { WETH9 } from '../../constants/goerliConstants'
import { formatPrice } from 'utils/formatTokenAmount'
import Loader from 'components/Loader'
import { unwrappedToken } from 'utils/wrappedCurrency'
Expand Down
3 changes: 2 additions & 1 deletion src/components/SearchModal/CommonBases.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react'
import { Text } from 'rebass'
import { ChainId, Currency, currencyEquals, Token, ETHER } from '@uniswap/sdk-core'
import { Currency, currencyEquals, Token, ETHER } from '@uniswap/sdk-core'
import { ChainId } from '../../constants/goerliConstants'
import styled from 'styled-components/macro'

import { SUGGESTED_BASES } from '../../constants/routing'
Expand Down
3 changes: 2 additions & 1 deletion src/components/TransactionConfirmationModal/index.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ChainId, Currency } from '@uniswap/sdk-core'
import { Currency } from '@uniswap/sdk-core'
import { ChainId } from '../../constants/goerliConstants'
import React, { useContext } from 'react'
import styled, { ThemeContext } from 'styled-components'
import { getExplorerLink, ExplorerDataType } from '../../utils/getExplorerLink'
Expand Down
2 changes: 1 addition & 1 deletion src/connectors/Fortmatic.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { FortmaticConnector as FortmaticConnectorCore } from '@web3-react/fortmatic-connector'

export const OVERLAY_READY = 'OVERLAY_READY'
Expand Down
12 changes: 10 additions & 2 deletions src/connectors/index.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { Web3Provider } from '@ethersproject/providers'
import { InjectedConnector } from '@web3-react/injected-connector'
import { WalletConnectConnector } from '@web3-react/walletconnect-connector'
Expand Down Expand Up @@ -27,9 +27,17 @@ const NETWORK_URLS: {
[ChainId.ROPSTEN]: `https://ropsten.infura.io/v3/${INFURA_KEY}`,
[ChainId.GÖRLI]: `https://goerli.infura.io/v3/${INFURA_KEY}`,
[ChainId.KOVAN]: `https://kovan.infura.io/v3/${INFURA_KEY}`,
[ChainId.LOCALNODE]: `http://localhost:8545/`,
}

const SUPPORTED_CHAIN_IDS = [ChainId.MAINNET, ChainId.RINKEBY, ChainId.ROPSTEN, ChainId.KOVAN, ChainId.GÖRLI]
const SUPPORTED_CHAIN_IDS = [
ChainId.MAINNET,
ChainId.RINKEBY,
ChainId.ROPSTEN,
ChainId.KOVAN,
ChainId.GÖRLI,
ChainId.LOCALNODE,
]

export const network = new NetworkConnector({
urls: NETWORK_URLS,
Expand Down
6 changes: 3 additions & 3 deletions src/constants/addresses.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { FACTORY_ADDRESS as V3_FACTORY_ADDRESS } from '@uniswap/v3-sdk'
import { constructSameAddressMap } from '../utils/constructSameAddressMap'

export const UNI_ADDRESS = constructSameAddressMap('0x1f9840a85d5aF5bf1D1762F925BDADdC4201F984')
export const MULTICALL2_ADDRESSES = constructSameAddressMap('0x5BA1e12693Dc8F9c48aAD8770482f4739bEeD696')
export const V2_ROUTER_ADDRESS = constructSameAddressMap('0x7a250d5630B4cF539739dF2C5dAcb4c659F2488D')
export const MULTICALL2_ADDRESSES = constructSameAddressMap('0xF6d8b02D83D01b5879fCB4092B9c285871Ab4Fa1')
export const V2_ROUTER_ADDRESS = constructSameAddressMap('0xb3Ed9Fc48C9A495177a5aB31ea5cdA419cC6EaA1')
export const GOVERNANCE_ADDRESS = constructSameAddressMap('0x5e4be8Bc9637f0EAA1A755019e06A68ce081D58F')
export const TIMELOCK_ADDRESS = constructSameAddressMap('0x1a9C8182C09F50C8318d769245beA52c32BE35BC')
export const MERKLE_DISTRIBUTOR_ADDRESS: { [chainId in ChainId]?: string } = {
Expand Down
20 changes: 20 additions & 0 deletions src/constants/goerliConstants.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import { Token } from '@uniswap/sdk-core'

enum ChainId {
MAINNET = 1,
ROPSTEN = 3,
RINKEBY = 4,
GÖRLI = 5,
KOVAN = 42,
LOCALNODE = 31337,
}

const WETH9: { [chainId: number]: Token } = {
[1]: new Token(1, '0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2', 18, 'WETH', 'Wrapped Ether'),
[3]: new Token(3, '0xc778417E063141139Fce010982780140Aa0cD5Ab', 18, 'WETH', 'Wrapped Ether'),
[4]: new Token(4, '0xc778417E063141139Fce010982780140Aa0cD5Ab', 18, 'WETH', 'Wrapped Ether'),
[5]: new Token(5, '0xB4FBF271143F4FBf7B91A5ded31805e42b2208d6', 18, 'WETH', 'Wrapped Ether'),
[42]: new Token(42, '0xd0A1E359811322d97991E03f863a0C30C2cF029C', 18, 'WETH', 'Wrapped Ether'),
[31337]: new Token(31337, '0x403E6e00E035E81e7FE446ac8dc44d3A34155bB0', 18, 'WETH9', 'Wrapped Ether'),
}
export { WETH9, ChainId }
7 changes: 6 additions & 1 deletion src/constants/governance.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { GOVERNANCE_ADDRESS, TIMELOCK_ADDRESS, UNI_ADDRESS } from './addresses'

export const COMMON_CONTRACT_NAMES: { [chainId in ChainId]?: { [address: string]: string } } = {
Expand Down Expand Up @@ -27,6 +27,11 @@ export const COMMON_CONTRACT_NAMES: { [chainId in ChainId]?: { [address: string]
[GOVERNANCE_ADDRESS[ChainId.GÖRLI]]: 'Goerli Governance',
[TIMELOCK_ADDRESS[ChainId.GÖRLI]]: 'Goerli Timelock',
},
[ChainId.LOCALNODE]: {
['0x31f116f6E800863efc7F32aE4AC4E63c67aDF03b']: 'Local UNI',
[GOVERNANCE_ADDRESS[ChainId.LOCALNODE]]: 'Local Governance',
[TIMELOCK_ADDRESS[ChainId.LOCALNODE]]: 'Local Timelock',
},
}

export const DEFAULT_AVERAGE_BLOCK_TIME_IN_SECS = 13
Expand Down
12 changes: 5 additions & 7 deletions src/constants/lists.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
// used to mark unsupported tokens, these are hosted lists of unsupported tokens

const COMPOUND_LIST = 'https://raw.githubusercontent.com/compound-finance/token-list/master/compound.tokenlist.json'
const UMA_LIST = 'https://umaproject.org/uma.tokenlist.json'
const AAVE_LIST = 'tokenlist.aave.eth'
const SYNTHETIX_LIST = 'synths.snx.eth'
const WRAPPED_LIST = 'wrapped.tokensoft.eth'
const SET_LIST = 'https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/set.tokenlist.json'
const OPYN_LIST = 'https://raw.githubusercontent.com/opynfinance/opyn-tokenlist/master/opyn-v1.tokenlist.json'
const ROLL_LIST = 'https://app.tryroll.com/tokens.json'
const COINGECKO_LIST = 'https://tokens.coingecko.com/uniswap/all.json'
const CMC_ALL_LIST = 'defi.cmc.eth'
Expand All @@ -19,19 +16,20 @@ const NEW_TOKEN_LIST =
const CUSTOM_TOKEN_LIST =
'https://raw.githubusercontent.com/OnGridSystems/goerliswap-dapp/development-3.3.6/src/constants/tokenLists/custom.tokenlist.json'

const LOCALNODE_TOKEN_LIST =
'https://raw.githubusercontent.com/OnGridSystems/goerliswap-dapp/local-node/src/constants/tokenLists/localnode.tokenlist.json'

export const UNSUPPORTED_LIST_URLS: string[] = [BA_LIST]

// lower index == higher priority for token import
export const DEFAULT_LIST_OF_LISTS: string[] = [
NEW_TOKEN_LIST,
CUSTOM_TOKEN_LIST,
LOCALNODE_TOKEN_LIST,
COMPOUND_LIST,
AAVE_LIST,
SYNTHETIX_LIST,
UMA_LIST,
WRAPPED_LIST,
SET_LIST,
OPYN_LIST,
ROLL_LIST,
COINGECKO_LIST,
CMC_ALL_LIST,
Expand All @@ -42,4 +40,4 @@ export const DEFAULT_LIST_OF_LISTS: string[] = [
]

// default lists to be 'active' aka searched across
export const DEFAULT_ACTIVE_LIST_URLS: string[] = [CUSTOM_TOKEN_LIST, NEW_TOKEN_LIST, GEMINI_LIST]
export const DEFAULT_ACTIVE_LIST_URLS: string[] = [CUSTOM_TOKEN_LIST, LOCALNODE_TOKEN_LIST, NEW_TOKEN_LIST, GEMINI_LIST]
4 changes: 3 additions & 1 deletion src/constants/routing.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
// a list of tokens by chain
import { ChainId, Token, WETH9 } from '@uniswap/sdk-core'
import { Token } from '@uniswap/sdk-core'
import { ChainId, WETH9 } from '../constants/goerliConstants'
import { AMPL, DAI, FEI, FRAX, FXS, MIR, renBTC, TRIBE, UMA, UNI, USDC, USDT, UST, WBTC } from './tokens'

type ChainTokenList = {
Expand Down Expand Up @@ -31,6 +32,7 @@ const WETH_ONLY: ChainTokenList = {
[ChainId.RINKEBY]: [WETH9[ChainId.RINKEBY]],
[ChainId.GÖRLI]: [WETH9[ChainId.GÖRLI]],
[ChainId.KOVAN]: [WETH9[ChainId.KOVAN]],
[ChainId.LOCALNODE]: [WETH9[ChainId.LOCALNODE]],
}
// used to construct intermediary pairs for trading
export const BASES_TO_CHECK_TRADES_AGAINST: ChainTokenList = {
Expand Down
70 changes: 70 additions & 0 deletions src/constants/tokenLists/localnode.tokenlist.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
{
"name": "Locanode Tokens",
"timestamp": "2023-01-20T08:10:26.867Z",
"tags": {},
"version": {
"major": 0,
"minor": 1,
"patch": 0
},
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/assets/set-logo.svg",
"keywords": ["uniswap", "custom"],
"tokens": [
{
"chainId": 31337,
"address": "0x403E6e00E035E81e7FE446ac8dc44d3A34155bB0",
"name": "Wrapped Ether",
"symbol": "WETH9",
"decimals": 18,
"logoURI": "https://raw.githubusercontent.com/Uniswap/assets/master/blockchains/ethereum/assets/0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2/logo.png"
},
{
"chainId": 31337,
"address": "0x31f116f6E800863efc7F32aE4AC4E63c67aDF03b",
"name": "Uniswap",
"symbol": "UNI",
"decimals": 18,
"logoURI": "https://cloudflare-ipfs.com/ipfs/QmXttGpZrECX5qCyXbBQiqgQNytVGeZW5Anewvh2jc4psg/"
},
{
"chainId": 31337,
"address": "0x27e0fDc6F46b68Aa7C79481905e039F7287Bd4e4",
"name": "Token1",
"symbol": "TKN",
"decimals": 18,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/assets/tokens/yam_house.png"
},
{
"chainId": 31337,
"address": "0x88a0Bc4c00223781dab3eE654097715500bab5a9",
"name": "Token2",
"symbol": "TKN",
"decimals": 18,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/assets/tokens/mvi.png"
},
{
"chainId": 31337,
"address": "0x5266564b1Fe7Ee3F57932Cc3d9D9678BA4D43d8F",
"name": "Token3",
"symbol": "TKN",
"decimals": 18,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/assets/tokens/green-indexes-GEX.png"
},
{
"chainId": 31337,
"address": "0xA9Ca1A512aAb13fBBf9a6b316Dd7D037b827369D",
"name": "Token4",
"symbol": "TKN",
"decimals": 18,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/assets/tokens/5aBvPVaM_400x400.jpeg"
},
{
"chainId": 31337,
"address": "0xab763d778e0D615901F9e7e926798181cE238225",
"name": "Token5",
"symbol": "TKN",
"decimals": 18,
"logoURI": "https://raw.githubusercontent.com/SetProtocol/uniswap-tokenlist/main/assets/tokens/beverage-linketh.png"
}
]
}
4 changes: 3 additions & 1 deletion src/constants/tokens.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ChainId, Token } from '@uniswap/sdk-core'
import { Token } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { UNI_ADDRESS } from './addresses'

export const AMPL = new Token(ChainId.MAINNET, '0xD46bA6D942050d489DBd938a2C909A5d5039A161', 9, 'AMPL', 'Ampleforth')
Expand Down Expand Up @@ -27,4 +28,5 @@ export const UNI: { [chainId in ChainId]: Token } = {
[ChainId.ROPSTEN]: new Token(ChainId.ROPSTEN, UNI_ADDRESS[ChainId.ROPSTEN], 18, 'UNI', 'Uniswap'),
[ChainId.GÖRLI]: new Token(ChainId.GÖRLI, UNI_ADDRESS[ChainId.GÖRLI], 18, 'UNI', 'Uniswap'),
[ChainId.KOVAN]: new Token(ChainId.KOVAN, UNI_ADDRESS[ChainId.KOVAN], 18, 'UNI', 'Uniswap'),
[ChainId.LOCALNODE]: new Token(ChainId.LOCALNODE, '0x31f116f6E800863efc7F32aE4AC4E63c67aDF03b', 18, 'UNI', 'Uniswap'),
}
3 changes: 2 additions & 1 deletion src/hooks/useAllV3Routes.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ChainId, Currency } from '@uniswap/sdk-core'
import { Currency } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { Pool, Route } from '@uniswap/v3-sdk'
import { useMemo } from 'react'
import { useUserSingleHopOnly } from '../state/user/hooks'
Expand Down
3 changes: 2 additions & 1 deletion src/hooks/useApproveCallback.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { MaxUint256 } from '@ethersproject/constants'
import { TransactionResponse } from '@ethersproject/providers'
import { CurrencyAmount, ChainId, Percent, Currency, TradeType } from '@uniswap/sdk-core'
import { CurrencyAmount, Percent, Currency, TradeType } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { Trade as V2Trade } from '@uniswap/v2-sdk'
import { Trade as V3Trade } from '@uniswap/v3-sdk'
import { useCallback, useMemo } from 'react'
Expand Down
3 changes: 2 additions & 1 deletion src/hooks/useColor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ import { useState, useLayoutEffect } from 'react'
import { shade } from 'polished'
import Vibrant from 'node-vibrant'
import { hex } from 'wcag-contrast'
import { Token, ChainId } from '@uniswap/sdk-core'
import { Token } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import uriToHttp from 'utils/uriToHttp'

async function getColorFromToken(token: Token): Promise<string | null> {
Expand Down
2 changes: 1 addition & 1 deletion src/hooks/useContract.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Contract } from '@ethersproject/contracts'
import { ChainId, WETH9 } from '@uniswap/sdk-core'
import { ChainId, WETH9 } from '../constants/goerliConstants'
import { abi as GOVERNANCE_ABI } from '@uniswap/governance/build/GovernorAlpha.json'
import { abi as UNI_ABI } from '@uniswap/governance/build/Uni.json'
import { abi as STAKING_REWARDS_ABI } from '@uniswap/liquidity-staker/build/StakingRewards.json'
Expand Down
6 changes: 5 additions & 1 deletion src/hooks/useERC20Permit.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import JSBI from 'jsbi'
import { ChainId, Percent, CurrencyAmount, Currency, TradeType, Token } from '@uniswap/sdk-core'
import { Percent, CurrencyAmount, Currency, TradeType, Token } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { Trade as V2Trade } from '@uniswap/v2-sdk'
import { Trade as V3Trade } from '@uniswap/v3-sdk'
import { splitSignature } from 'ethers/lib/utils'
Expand Down Expand Up @@ -52,6 +53,9 @@ const PERMITTABLE_TOKENS: {
[ChainId.KOVAN]: {
[UNI[ChainId.KOVAN].address]: { type: PermitType.AMOUNT, name: 'Uniswap' },
},
[ChainId.LOCALNODE]: {
[UNI[ChainId.LOCALNODE].address]: { type: PermitType.AMOUNT, name: 'Uniswap' },
},
}

export enum UseERC20PermitState {
Expand Down
2 changes: 1 addition & 1 deletion src/hooks/useFetchListCallback.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { nanoid } from '@reduxjs/toolkit'
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { TokenList } from '@uniswap/token-lists'
import { useCallback } from 'react'
import { useDispatch } from 'react-redux'
Expand Down
3 changes: 2 additions & 1 deletion src/hooks/useSwapCallback.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { BigNumber } from '@ethersproject/bignumber'
import { Router, Trade as V2Trade } from '@uniswap/v2-sdk'
import { SwapRouter, Trade as V3Trade } from '@uniswap/v3-sdk'
import { ChainId, Currency, Percent, TradeType } from '@uniswap/sdk-core'
import { Currency, Percent, TradeType } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { useMemo } from 'react'
import { SWAP_ROUTER_ADDRESSES } from '../constants/addresses'
import { calculateGasMargin } from '../utils/calculateGasMargin'
Expand Down
3 changes: 2 additions & 1 deletion src/hooks/useUSDCPrice.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ChainId, Currency, CurrencyAmount, Price, Token } from '@uniswap/sdk-core'
import { Currency, CurrencyAmount, Price, Token } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { useMemo } from 'react'
import { USDC } from '../constants/tokens'
import { useV2TradeExactOut } from './useV2Trade'
Expand Down
3 changes: 2 additions & 1 deletion src/hooks/useWrapCallback.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Currency, currencyEquals, WETH9 } from '@uniswap/sdk-core'
import { Currency, currencyEquals } from '@uniswap/sdk-core'
import { WETH9 } from '../constants/goerliConstants'
import { useMemo } from 'react'
import { tryParseAmount } from '../state/swap/hooks'
import { useTransactionAdder } from '../state/transactions/hooks'
Expand Down
2 changes: 1 addition & 1 deletion src/hooks/web3.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Web3Provider } from '@ethersproject/providers'
import { ChainId } from '@uniswap/sdk-core'
import { ChainId } from '../constants/goerliConstants'
import { useWeb3React as useWeb3ReactCore } from '@web3-react/core'
import { Web3ReactContextInterface } from '@web3-react/core/dist/types'
import { useEffect, useState } from 'react'
Expand Down
Loading