chore: prohibit barrels (#7362)
* chore: prohibit barrels * lint * lint * more lint * add motivation to eslint message
This commit is contained in:
parent
4a8fb760d2
commit
fbc7e64032
@ -70,6 +70,13 @@ module.exports = {
|
|||||||
],
|
],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
'no-restricted-syntax': [
|
||||||
|
'error',
|
||||||
|
{
|
||||||
|
selector: ':matches(ExportAllDeclaration)',
|
||||||
|
message: 'Barrel exports bloat the bundle size by preventing tree-shaking.',
|
||||||
|
},
|
||||||
|
],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -2,7 +2,8 @@ import { BrowserEvent, InterfaceElementName, SharedEventName } from '@uniswap/an
|
|||||||
import { TraceEvent } from 'analytics'
|
import { TraceEvent } from 'analytics'
|
||||||
import { useDisableNFTRoutes } from 'hooks/useDisableNFTRoutes'
|
import { useDisableNFTRoutes } from 'hooks/useDisableNFTRoutes'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { BREAKPOINTS, ExternalLink, StyledRouterLink } from 'theme'
|
import { BREAKPOINTS } from 'theme'
|
||||||
|
import { ExternalLink, StyledRouterLink } from 'theme/components'
|
||||||
import { useIsDarkMode } from 'theme/components/ThemeToggle'
|
import { useIsDarkMode } from 'theme/components/ThemeToggle'
|
||||||
|
|
||||||
import { DiscordIcon, GithubIcon, TwitterIcon } from './Icons'
|
import { DiscordIcon, GithubIcon, TwitterIcon } from './Icons'
|
||||||
|
@ -23,7 +23,7 @@ import { useNavigate } from 'react-router-dom'
|
|||||||
import { useAppDispatch } from 'state/hooks'
|
import { useAppDispatch } from 'state/hooks'
|
||||||
import { updateSelectedWallet } from 'state/user/reducer'
|
import { updateSelectedWallet } from 'state/user/reducer'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { CopyHelper, ExternalLink, ThemedText } from 'theme'
|
import { CopyHelper, ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { shortenAddress } from 'utils'
|
import { shortenAddress } from 'utils'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { InterfaceElementName } from '@uniswap/analytics-events'
|
import { InterfaceElementName } from '@uniswap/analytics-events'
|
||||||
import { PropsWithChildren, useCallback } from 'react'
|
import { PropsWithChildren, useCallback } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ClickableStyle } from 'theme'
|
import { ClickableStyle } from 'theme/components'
|
||||||
import { openDownloadApp } from 'utils/openDownloadApp'
|
import { openDownloadApp } from 'utils/openDownloadApp'
|
||||||
|
|
||||||
const StyledButton = styled.button<{ padded?: boolean; branded?: boolean }>`
|
const StyledButton = styled.button<{ padded?: boolean; branded?: boolean }>`
|
||||||
|
@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro'
|
|||||||
import Tooltip from 'components/Tooltip'
|
import Tooltip from 'components/Tooltip'
|
||||||
import useCopyClipboard from 'hooks/useCopyClipboard'
|
import useCopyClipboard from 'hooks/useCopyClipboard'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const Container = styled.div`
|
const Container = styled.div`
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -8,7 +8,7 @@ import { TransactionStatus } from 'graphql/data/__generated__/types-and-hooks'
|
|||||||
import useENSName from 'hooks/useENSName'
|
import useENSName from 'hooks/useENSName'
|
||||||
import { useCallback } from 'react'
|
import { useCallback } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { EllipsisStyle, ThemedText } from 'theme'
|
import { EllipsisStyle, ThemedText } from 'theme/components'
|
||||||
import { shortenAddress } from 'utils'
|
import { shortenAddress } from 'utils'
|
||||||
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
||||||
|
|
||||||
|
@ -17,7 +17,7 @@ import { InterfaceTrade } from 'state/routing/types'
|
|||||||
import { useOrder } from 'state/signatures/hooks'
|
import { useOrder } from 'state/signatures/hooks'
|
||||||
import { UniswapXOrderDetails } from 'state/signatures/types'
|
import { UniswapXOrderDetails } from 'state/signatures/types'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
||||||
|
|
||||||
type SelectedOrderInfo = {
|
type SelectedOrderInfo = {
|
||||||
|
@ -6,7 +6,7 @@ import { atom, useAtom } from 'jotai'
|
|||||||
import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletContent'
|
import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletContent'
|
||||||
import { useEffect, useMemo } from 'react'
|
import { useEffect, useMemo } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { PortfolioSkeleton, PortfolioTabWrapper } from '../PortfolioRow'
|
import { PortfolioSkeleton, PortfolioTabWrapper } from '../PortfolioRow'
|
||||||
import { ActivityRow } from './ActivityRow'
|
import { ActivityRow } from './ActivityRow'
|
||||||
|
@ -4,7 +4,7 @@ import Row from 'components/Row'
|
|||||||
import { PropsWithChildren } from 'react'
|
import { PropsWithChildren } from 'react'
|
||||||
import { ChevronDown } from 'react-feather'
|
import { ChevronDown } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const ExpandIcon = styled(ChevronDown)<{ $expanded: boolean }>`
|
const ExpandIcon = styled(ChevronDown)<{ $expanded: boolean }>`
|
||||||
color: ${({ theme }) => theme.neutral2};
|
color: ${({ theme }) => theme.neutral2};
|
||||||
|
@ -11,7 +11,7 @@ import { WalletAsset } from 'nft/types'
|
|||||||
import { floorFormatter } from 'nft/utils'
|
import { floorFormatter } from 'nft/utils'
|
||||||
import { useNavigate } from 'react-router-dom'
|
import { useNavigate } from 'react-router-dom'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const FloorPrice = styled(Row)`
|
const FloorPrice = styled(Row)`
|
||||||
opacity: 0;
|
opacity: 0;
|
||||||
|
@ -12,7 +12,7 @@ import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletConten
|
|||||||
import { useCallback, useMemo, useReducer } from 'react'
|
import { useCallback, useMemo, useReducer } from 'react'
|
||||||
import { useNavigate } from 'react-router-dom'
|
import { useNavigate } from 'react-router-dom'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import { ExpandoRow } from '../ExpandoRow'
|
import { ExpandoRow } from '../ExpandoRow'
|
||||||
|
@ -10,7 +10,7 @@ import { EmptyWalletModule } from 'nft/components/profile/view/EmptyWalletConten
|
|||||||
import { useCallback, useMemo, useState } from 'react'
|
import { useCallback, useMemo, useState } from 'react'
|
||||||
import { useNavigate } from 'react-router-dom'
|
import { useNavigate } from 'react-router-dom'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { EllipsisStyle, ThemedText } from 'theme'
|
import { EllipsisStyle, ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
import { splitHiddenTokens } from 'utils/splitHiddenTokens'
|
import { splitHiddenTokens } from 'utils/splitHiddenTokens'
|
||||||
|
|
||||||
|
@ -8,7 +8,8 @@ import { useDisableNFTRoutes } from 'hooks/useDisableNFTRoutes'
|
|||||||
import { useIsNftPage } from 'hooks/useIsNftPage'
|
import { useIsNftPage } from 'hooks/useIsNftPage'
|
||||||
import { useEffect, useState } from 'react'
|
import { useEffect, useState } from 'react'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { BREAKPOINTS, ThemedText } from 'theme'
|
import { BREAKPOINTS } from 'theme'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { ActivityTab } from './Activity'
|
import { ActivityTab } from './Activity'
|
||||||
import { usePendingActivity } from './Activity/hooks'
|
import { usePendingActivity } from './Activity/hooks'
|
||||||
|
@ -8,7 +8,7 @@ import { useActiveLocale } from 'hooks/useActiveLocale'
|
|||||||
import { ReactNode } from 'react'
|
import { ReactNode } from 'react'
|
||||||
import { ChevronRight } from 'react-feather'
|
import { ChevronRight } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ClickableStyle, ThemedText } from 'theme'
|
import { ClickableStyle, ThemedText } from 'theme/components'
|
||||||
import ThemeToggle from 'theme/components/ThemeToggle'
|
import ThemeToggle from 'theme/components/ThemeToggle'
|
||||||
|
|
||||||
import { AnalyticsToggle } from './AnalyticsToggle'
|
import { AnalyticsToggle } from './AnalyticsToggle'
|
||||||
|
@ -2,7 +2,7 @@ import Column from 'components/Column'
|
|||||||
import Row from 'components/Row'
|
import Row from 'components/Row'
|
||||||
import Toggle from 'components/Toggle'
|
import Toggle from 'components/Toggle'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const StyledColumn = styled(Column)`
|
const StyledColumn = styled(Column)`
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -2,7 +2,7 @@ import Column from 'components/Column'
|
|||||||
import { ScrollBarStyles } from 'components/Common'
|
import { ScrollBarStyles } from 'components/Common'
|
||||||
import { ArrowLeft } from 'react-feather'
|
import { ArrowLeft } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ClickableStyle, ThemedText } from 'theme'
|
import { ClickableStyle, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const Menu = styled(Column)`
|
const Menu = styled(Column)`
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -12,7 +12,7 @@ import { UniwalletConnect as UniwalletConnectV2 } from 'connection/WalletConnect
|
|||||||
import { QRCodeSVG } from 'qrcode.react'
|
import { QRCodeSVG } from 'qrcode.react'
|
||||||
import { useEffect, useState } from 'react'
|
import { useEffect, useState } from 'react'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { CloseIcon, ThemedText } from 'theme'
|
import { CloseIcon, ThemedText } from 'theme/components'
|
||||||
import { isIOS } from 'utils/userAgent'
|
import { isIOS } from 'utils/userAgent'
|
||||||
|
|
||||||
import uniPng from '../../assets/images/uniwallet_modal_icon.png'
|
import uniPng from '../../assets/images/uniwallet_modal_icon.png'
|
||||||
|
@ -10,7 +10,8 @@ import { useCallback, useEffect, useRef, useState } from 'react'
|
|||||||
import { ChevronsRight } from 'react-feather'
|
import { ChevronsRight } from 'react-feather'
|
||||||
import { useGesture } from 'react-use-gesture'
|
import { useGesture } from 'react-use-gesture'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { BREAKPOINTS, ClickableStyle } from 'theme'
|
import { BREAKPOINTS } from 'theme'
|
||||||
|
import { ClickableStyle } from 'theme/components'
|
||||||
import { Z_INDEX } from 'theme/zIndex'
|
import { Z_INDEX } from 'theme/zIndex'
|
||||||
import { isMobile } from 'utils/userAgent'
|
import { isMobile } from 'utils/userAgent'
|
||||||
|
|
||||||
|
@ -5,7 +5,8 @@ import { Check } from 'react-feather'
|
|||||||
import type { To } from 'react-router-dom'
|
import type { To } from 'react-router-dom'
|
||||||
import { Link } from 'react-router-dom'
|
import { Link } from 'react-router-dom'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { BREAKPOINTS, ClickableStyle, ThemedText } from 'theme'
|
import { BREAKPOINTS } from 'theme'
|
||||||
|
import { ClickableStyle, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const InternalLinkMenuItem = styled(Link)`
|
const InternalLinkMenuItem = styled(Link)`
|
||||||
${ClickableStyle}
|
${ClickableStyle}
|
||||||
|
@ -4,10 +4,10 @@ import { t } from '@lingui/macro'
|
|||||||
import { useWeb3React } from '@web3-react/core'
|
import { useWeb3React } from '@web3-react/core'
|
||||||
import { ChangeEvent, ReactNode, useCallback } from 'react'
|
import { ChangeEvent, ReactNode, useCallback } from 'react'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { flexColumnNoWrap } from 'theme/styles'
|
import { flexColumnNoWrap } from 'theme/styles'
|
||||||
|
|
||||||
import useENS from '../../hooks/useENS'
|
import useENS from '../../hooks/useENS'
|
||||||
import { ExternalLink, ThemedText } from '../../theme'
|
|
||||||
import { ExplorerDataType, getExplorerLink } from '../../utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from '../../utils/getExplorerLink'
|
||||||
import { AutoColumn } from '../Column'
|
import { AutoColumn } from '../Column'
|
||||||
import { RowBetween } from '../Row'
|
import { RowBetween } from '../Row'
|
||||||
|
@ -10,14 +10,14 @@ import Loader from 'components/Icons/LoadingSpinner'
|
|||||||
import { useContract } from 'hooks/useContract'
|
import { useContract } from 'hooks/useContract'
|
||||||
import { ChevronRightIcon } from 'nft/components/icons'
|
import { ChevronRightIcon } from 'nft/components/icons'
|
||||||
import { useIsNftClaimAvailable } from 'nft/hooks/useIsNftClaimAvailable'
|
import { useIsNftClaimAvailable } from 'nft/hooks/useIsNftClaimAvailable'
|
||||||
import { CollectionRewardsFetcher } from 'nft/queries/genie/GetAirdorpMerkle'
|
import { CollectionRewardsFetcher } from 'nft/queries/genie'
|
||||||
import { Airdrop, Rewards } from 'nft/types/airdrop'
|
import { Airdrop, Rewards } from 'nft/types/airdrop'
|
||||||
import { useEffect, useState } from 'react'
|
import { useEffect, useState } from 'react'
|
||||||
import { AlertTriangle } from 'react-feather'
|
import { AlertTriangle } from 'react-feather'
|
||||||
import { useModalIsOpen, useToggleModal } from 'state/application/hooks'
|
import { useModalIsOpen, useToggleModal } from 'state/application/hooks'
|
||||||
import { ApplicationModal } from 'state/application/reducer'
|
import { ApplicationModal } from 'state/application/reducer'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { CloseIcon, ThemedText } from 'theme'
|
import { CloseIcon, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import Modal from '../Modal'
|
import Modal from '../Modal'
|
||||||
|
|
||||||
|
@ -7,7 +7,7 @@ import baseLogoUrl from 'assets/svg/base_background_icon.svg'
|
|||||||
import { useScreenSize } from 'hooks/useScreenSize'
|
import { useScreenSize } from 'hooks/useScreenSize'
|
||||||
import { useLocation } from 'react-router-dom'
|
import { useLocation } from 'react-router-dom'
|
||||||
import { useHideBaseWalletBanner } from 'state/user/hooks'
|
import { useHideBaseWalletBanner } from 'state/user/hooks'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { openDownloadApp, openWalletMicrosite } from 'utils/openDownloadApp'
|
import { openDownloadApp, openWalletMicrosite } from 'utils/openDownloadApp'
|
||||||
import { isIOS, isMobileSafari } from 'utils/userAgent'
|
import { isIOS, isMobileSafari } from 'utils/userAgent'
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SpinnerSVG } from 'theme'
|
import { SpinnerSVG } from 'theme/components'
|
||||||
|
|
||||||
const ButtonLoadingSpinner = (props: React.ComponentPropsWithoutRef<'svg'>) => (
|
const ButtonLoadingSpinner = (props: React.ComponentPropsWithoutRef<'svg'>) => (
|
||||||
<SpinnerSVG width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" {...props}>
|
<SpinnerSVG width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" {...props}>
|
||||||
|
@ -16,7 +16,7 @@ import { useActiveLocale } from 'hooks/useActiveLocale'
|
|||||||
import { ReactNode, useCallback, useEffect, useMemo, useState } from 'react'
|
import { ReactNode, useCallback, useEffect, useMemo, useState } from 'react'
|
||||||
import { Info } from 'react-feather'
|
import { Info } from 'react-feather'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { textFadeIn } from 'theme/styles'
|
import { textFadeIn } from 'theme/styles'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
|
@ -2,9 +2,9 @@ import { Trans } from '@lingui/macro'
|
|||||||
import Column from 'components/Column'
|
import Column from 'components/Column'
|
||||||
import { BlockedIcon } from 'components/TokenSafety/TokenSafetyIcon'
|
import { BlockedIcon } from 'components/TokenSafety/TokenSafetyIcon'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
|
import { CopyHelper } from 'theme/components'
|
||||||
|
|
||||||
import { CopyHelper } from '../../theme'
|
|
||||||
import Modal from '../Modal'
|
import Modal from '../Modal'
|
||||||
|
|
||||||
const ContentWrapper = styled(Column)`
|
const ContentWrapper = styled(Column)`
|
||||||
|
@ -5,7 +5,7 @@ import { LoadingBubble } from 'components/Tokens/loading'
|
|||||||
import { MouseoverTooltip } from 'components/Tooltip'
|
import { MouseoverTooltip } from 'components/Tooltip'
|
||||||
import { useMemo } from 'react'
|
import { useMemo } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
import { warningSeverity } from 'utils/prices'
|
import { warningSeverity } from 'utils/prices'
|
||||||
|
|
||||||
|
@ -15,12 +15,12 @@ import { darken } from 'polished'
|
|||||||
import { forwardRef, ReactNode, useCallback, useEffect, useState } from 'react'
|
import { forwardRef, ReactNode, useCallback, useEffect, useState } from 'react'
|
||||||
import { Lock } from 'react-feather'
|
import { Lock } from 'react-feather'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles'
|
import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import { ReactComponent as DropDown } from '../../assets/images/dropdown.svg'
|
import { ReactComponent as DropDown } from '../../assets/images/dropdown.svg'
|
||||||
import { useCurrencyBalance } from '../../state/connection/hooks'
|
import { useCurrencyBalance } from '../../state/connection/hooks'
|
||||||
import { ThemedText } from '../../theme'
|
|
||||||
import { ButtonGray } from '../Button'
|
import { ButtonGray } from '../Button'
|
||||||
import DoubleCurrencyLogo from '../DoubleLogo'
|
import DoubleCurrencyLogo from '../DoubleLogo'
|
||||||
import { Input as NumericalInput } from '../NumericalInput'
|
import { Input as NumericalInput } from '../NumericalInput'
|
||||||
|
@ -10,12 +10,12 @@ import { isSupportedChain } from 'constants/chains'
|
|||||||
import { darken } from 'polished'
|
import { darken } from 'polished'
|
||||||
import { ReactNode, useCallback, useState } from 'react'
|
import { ReactNode, useCallback, useState } from 'react'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles'
|
import { flexColumnNoWrap, flexRowNoWrap } from 'theme/styles'
|
||||||
import { formatCurrencyAmount } from 'utils/formatCurrencyAmount'
|
import { formatCurrencyAmount } from 'utils/formatCurrencyAmount'
|
||||||
|
|
||||||
import { ReactComponent as DropDown } from '../../assets/images/dropdown.svg'
|
import { ReactComponent as DropDown } from '../../assets/images/dropdown.svg'
|
||||||
import { useCurrencyBalance } from '../../state/connection/hooks'
|
import { useCurrencyBalance } from '../../state/connection/hooks'
|
||||||
import { ThemedText } from '../../theme'
|
|
||||||
import { ButtonGray } from '../Button'
|
import { ButtonGray } from '../Button'
|
||||||
import DoubleCurrencyLogo from '../DoubleLogo'
|
import DoubleCurrencyLogo from '../DoubleLogo'
|
||||||
import CurrencyLogo from '../Logo/CurrencyLogo'
|
import CurrencyLogo from '../Logo/CurrencyLogo'
|
||||||
|
@ -7,9 +7,9 @@ import { useIsMobile } from 'nft/hooks'
|
|||||||
import React, { PropsWithChildren, useState } from 'react'
|
import React, { PropsWithChildren, useState } from 'react'
|
||||||
import { Copy } from 'react-feather'
|
import { Copy } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
|
import { CopyToClipboard, ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { isSentryEnabled } from 'utils/env'
|
import { isSentryEnabled } from 'utils/env'
|
||||||
|
|
||||||
import { CopyToClipboard, ExternalLink, ThemedText } from '../../theme'
|
|
||||||
import { Column } from '../Column'
|
import { Column } from '../Column'
|
||||||
|
|
||||||
const FallbackWrapper = styled.div`
|
const FallbackWrapper = styled.div`
|
||||||
|
@ -6,7 +6,7 @@ import { useFeeTierDistribution } from 'hooks/useFeeTierDistribution'
|
|||||||
import { PoolState } from 'hooks/usePools'
|
import { PoolState } from 'hooks/usePools'
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { FeeTierPercentageBadge } from './FeeTierPercentageBadge'
|
import { FeeTierPercentageBadge } from './FeeTierPercentageBadge'
|
||||||
import { FEE_AMOUNT_DETAIL } from './shared'
|
import { FEE_AMOUNT_DETAIL } from './shared'
|
||||||
|
@ -4,7 +4,7 @@ import Badge from 'components/Badge'
|
|||||||
import { useFeeTierDistribution } from 'hooks/useFeeTierDistribution'
|
import { useFeeTierDistribution } from 'hooks/useFeeTierDistribution'
|
||||||
import { PoolState } from 'hooks/usePools'
|
import { PoolState } from 'hooks/usePools'
|
||||||
import React from 'react'
|
import React from 'react'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
export function FeeTierPercentageBadge({
|
export function FeeTierPercentageBadge({
|
||||||
feeAmount,
|
feeAmount,
|
||||||
|
@ -15,7 +15,7 @@ import { DynamicSection } from 'pages/AddLiquidity/styled'
|
|||||||
import { useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
import { useCallback, useEffect, useMemo, useRef, useState } from 'react'
|
||||||
import { Box } from 'rebass'
|
import { Box } from 'rebass'
|
||||||
import styled, { keyframes } from 'styled-components'
|
import styled, { keyframes } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { FeeOption } from './FeeOption'
|
import { FeeOption } from './FeeOption'
|
||||||
import { FeeTierPercentageBadge } from './FeeTierPercentageBadge'
|
import { FeeTierPercentageBadge } from './FeeTierPercentageBadge'
|
||||||
|
@ -5,7 +5,7 @@ import { useHref } from 'react-router-dom'
|
|||||||
import { useCloseModal, useModalIsOpen } from 'state/application/hooks'
|
import { useCloseModal, useModalIsOpen } from 'state/application/hooks'
|
||||||
import { ApplicationModal } from 'state/application/reducer'
|
import { ApplicationModal } from 'state/application/reducer'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { CustomLightSpinner, ThemedText } from 'theme'
|
import { CustomLightSpinner, ThemedText } from 'theme/components'
|
||||||
import { useIsDarkMode } from 'theme/components/ThemeToggle'
|
import { useIsDarkMode } from 'theme/components/ThemeToggle'
|
||||||
|
|
||||||
import Circle from '../../assets/images/blue-loader.svg'
|
import Circle from '../../assets/images/blue-loader.svg'
|
||||||
|
@ -6,7 +6,7 @@ import { AutoColumn } from 'components/Column'
|
|||||||
import { ReactNode, useCallback, useEffect, useState } from 'react'
|
import { ReactNode, useCallback, useEffect, useState } from 'react'
|
||||||
import { Minus, Plus } from 'react-feather'
|
import { Minus, Plus } from 'react-feather'
|
||||||
import styled, { keyframes } from 'styled-components'
|
import styled, { keyframes } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { Input as NumericalInput } from '../NumericalInput'
|
import { Input as NumericalInput } from '../NumericalInput'
|
||||||
|
|
||||||
|
@ -11,8 +11,8 @@ import { BarChart2, CloudOff, Inbox } from 'react-feather'
|
|||||||
import { batch } from 'react-redux'
|
import { batch } from 'react-redux'
|
||||||
import { Bound } from 'state/mint/v3/actions'
|
import { Bound } from 'state/mint/v3/actions'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { ThemedText } from '../../theme'
|
|
||||||
import { Chart } from './Chart'
|
import { Chart } from './Chart'
|
||||||
import { useDensityChartData } from './hooks'
|
import { useDensityChartData } from './hooks'
|
||||||
import { ZoomLevels } from './types'
|
import { ZoomLevels } from './types'
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import { Trans } from '@lingui/macro'
|
import { Trans } from '@lingui/macro'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import UniswapXRouterLabel, { UnswapXRouterLabelProps } from '../RouterLabel/UniswapXRouterLabel'
|
import UniswapXRouterLabel, { UnswapXRouterLabelProps } from '../RouterLabel/UniswapXRouterLabel'
|
||||||
|
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
import { FunctionComponent, PropsWithChildren, useRef } from 'react'
|
import { FunctionComponent, PropsWithChildren, useRef } from 'react'
|
||||||
import { Link } from 'react-router-dom'
|
import { Link } from 'react-router-dom'
|
||||||
import styled, { css } from 'styled-components'
|
import styled, { css } from 'styled-components'
|
||||||
|
import { ExternalLink } from 'theme/components'
|
||||||
|
|
||||||
import { ReactComponent as MenuIcon } from '../../assets/images/menu.svg'
|
import { ReactComponent as MenuIcon } from '../../assets/images/menu.svg'
|
||||||
import { useOnClickOutside } from '../../hooks/useOnClickOutside'
|
import { useOnClickOutside } from '../../hooks/useOnClickOutside'
|
||||||
import { useModalIsOpen, useToggleModal } from '../../state/application/hooks'
|
import { useModalIsOpen, useToggleModal } from '../../state/application/hooks'
|
||||||
import { ApplicationModal } from '../../state/application/reducer'
|
import { ApplicationModal } from '../../state/application/reducer'
|
||||||
import { ExternalLink } from '../../theme'
|
|
||||||
|
|
||||||
export enum FlyoutAlignment {
|
export enum FlyoutAlignment {
|
||||||
LEFT = 'LEFT',
|
LEFT = 'LEFT',
|
||||||
|
@ -2,9 +2,9 @@ import { Trans } from '@lingui/macro'
|
|||||||
import { useWeb3React } from '@web3-react/core'
|
import { useWeb3React } from '@web3-react/core'
|
||||||
import { ArrowUpCircle } from 'react-feather'
|
import { ArrowUpCircle } from 'react-feather'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { CloseIcon, CustomLightSpinner, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import Circle from '../../assets/images/blue-loader.svg'
|
import Circle from '../../assets/images/blue-loader.svg'
|
||||||
import { CloseIcon, CustomLightSpinner, ThemedText } from '../../theme'
|
|
||||||
import { ExternalLink } from '../../theme/components'
|
import { ExternalLink } from '../../theme/components'
|
||||||
import { ExplorerDataType, getExplorerLink } from '../../utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from '../../utils/getExplorerLink'
|
||||||
import { AutoColumn, ColumnCenter } from '../Column'
|
import { AutoColumn, ColumnCenter } from '../Column'
|
||||||
|
@ -20,7 +20,7 @@ import { GenieCollection, TrendingCollection } from 'nft/types'
|
|||||||
import { useEffect, useMemo, useState } from 'react'
|
import { useEffect, useMemo, useState } from 'react'
|
||||||
import { useLocation } from 'react-router-dom'
|
import { useLocation } from 'react-router-dom'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { ClockIcon, TrendingArrow } from '../../nft/components/icons'
|
import { ClockIcon, TrendingArrow } from '../../nft/components/icons'
|
||||||
import { SuspendConditionally } from '../Suspense/SuspendConditionally'
|
import { SuspendConditionally } from '../Suspense/SuspendConditionally'
|
||||||
|
@ -17,7 +17,7 @@ import { putCommas } from 'nft/utils/putCommas'
|
|||||||
import { useCallback, useEffect, useState } from 'react'
|
import { useCallback, useEffect, useState } from 'react'
|
||||||
import { Link, useNavigate } from 'react-router-dom'
|
import { Link, useNavigate } from 'react-router-dom'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import { DeltaArrow, DeltaText } from '../Tokens/TokenDetails/Delta'
|
import { DeltaArrow, DeltaText } from '../Tokens/TokenDetails/Delta'
|
||||||
|
@ -7,7 +7,7 @@ import { useAppDispatch } from 'state/hooks'
|
|||||||
import { resetMintState } from 'state/mint/actions'
|
import { resetMintState } from 'state/mint/actions'
|
||||||
import { resetMintState as resetMintV3State } from 'state/mint/v3/actions'
|
import { resetMintState as resetMintV3State } from 'state/mint/v3/actions'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { flexRowNoWrap } from 'theme/styles'
|
import { flexRowNoWrap } from 'theme/styles'
|
||||||
|
|
||||||
import { RowBetween } from '../Row'
|
import { RowBetween } from '../Row'
|
||||||
|
@ -4,8 +4,8 @@ import { useWeb3React } from '@web3-react/core'
|
|||||||
import { getChainInfo } from 'constants/chainInfo'
|
import { getChainInfo } from 'constants/chainInfo'
|
||||||
import { ArrowUpRight } from 'react-feather'
|
import { ArrowUpRight } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink, HideSmall } from 'theme'
|
|
||||||
import { colors } from 'theme/colors'
|
import { colors } from 'theme/colors'
|
||||||
|
import { ExternalLink, HideSmall } from 'theme/components'
|
||||||
import { useDarkModeManager } from 'theme/components/ThemeToggle'
|
import { useDarkModeManager } from 'theme/components/ThemeToggle'
|
||||||
|
|
||||||
import Column from '../Column'
|
import Column from '../Column'
|
||||||
|
@ -4,7 +4,8 @@ import { useWeb3React } from '@web3-react/core'
|
|||||||
import { getChainInfoOrDefault, L2ChainInfo } from 'constants/chainInfo'
|
import { getChainInfoOrDefault, L2ChainInfo } from 'constants/chainInfo'
|
||||||
import { AlertTriangle } from 'react-feather'
|
import { AlertTriangle } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink, MEDIA_WIDTHS } from 'theme'
|
import { MEDIA_WIDTHS } from 'theme'
|
||||||
|
import { ExternalLink } from 'theme/components'
|
||||||
|
|
||||||
const BodyRow = styled.div`
|
const BodyRow = styled.div`
|
||||||
color: ${({ theme }) => theme.neutral1};
|
color: ${({ theme }) => theme.neutral1};
|
||||||
|
@ -10,7 +10,7 @@ import useBlockNumber from 'lib/hooks/useBlockNumber'
|
|||||||
import ms from 'ms'
|
import ms from 'ms'
|
||||||
import { useEffect, useMemo, useState } from 'react'
|
import { useEffect, useMemo, useState } from 'react'
|
||||||
import styled, { keyframes } from 'styled-components'
|
import styled, { keyframes } from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
||||||
|
|
||||||
import { MouseoverTooltip } from '../Tooltip'
|
import { MouseoverTooltip } from '../Tooltip'
|
||||||
|
@ -4,6 +4,7 @@ import { useWeb3React } from '@web3-react/core'
|
|||||||
import { useCallback, useEffect } from 'react'
|
import { useCallback, useEffect } from 'react'
|
||||||
import { Heart, X } from 'react-feather'
|
import { Heart, X } from 'react-feather'
|
||||||
import styled, { keyframes } from 'styled-components'
|
import styled, { keyframes } from 'styled-components'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import tokenLogo from '../../assets/images/token-logo.png'
|
import tokenLogo from '../../assets/images/token-logo.png'
|
||||||
import {
|
import {
|
||||||
@ -14,7 +15,6 @@ import {
|
|||||||
} from '../../state/application/hooks'
|
} from '../../state/application/hooks'
|
||||||
import { ApplicationModal } from '../../state/application/reducer'
|
import { ApplicationModal } from '../../state/application/reducer'
|
||||||
import { useUserHasAvailableClaim, useUserUnclaimedAmount } from '../../state/claim/hooks'
|
import { useUserHasAvailableClaim, useUserUnclaimedAmount } from '../../state/claim/hooks'
|
||||||
import { ThemedText } from '../../theme'
|
|
||||||
import { ButtonPrimary } from '../Button'
|
import { ButtonPrimary } from '../Button'
|
||||||
import { AutoColumn } from '../Column'
|
import { AutoColumn } from '../Column'
|
||||||
import { CardBGImage, CardNoise } from '../earn/styled'
|
import { CardBGImage, CardNoise } from '../earn/styled'
|
||||||
|
@ -16,7 +16,7 @@ import { X } from 'react-feather'
|
|||||||
import { useOrder } from 'state/signatures/hooks'
|
import { useOrder } from 'state/signatures/hooks'
|
||||||
import { useTransaction } from 'state/transactions/hooks'
|
import { useTransaction } from 'state/transactions/hooks'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { EllipsisStyle, ThemedText } from 'theme'
|
import { EllipsisStyle, ThemedText } from 'theme/components'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
||||||
|
|
||||||
|
@ -9,12 +9,12 @@ import { ChevronDown, ChevronUp } from 'react-feather'
|
|||||||
import { Link } from 'react-router-dom'
|
import { Link } from 'react-router-dom'
|
||||||
import { Text } from 'rebass'
|
import { Text } from 'rebass'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { BIG_INT_ZERO } from '../../constants/misc'
|
import { BIG_INT_ZERO } from '../../constants/misc'
|
||||||
import { useColor } from '../../hooks/useColor'
|
import { useColor } from '../../hooks/useColor'
|
||||||
import { useTotalSupply } from '../../hooks/useTotalSupply'
|
import { useTotalSupply } from '../../hooks/useTotalSupply'
|
||||||
import { useTokenBalance } from '../../state/connection/hooks'
|
import { useTokenBalance } from '../../state/connection/hooks'
|
||||||
import { ExternalLink, ThemedText } from '../../theme'
|
|
||||||
import { currencyId } from '../../utils/currencyId'
|
import { currencyId } from '../../utils/currencyId'
|
||||||
import { unwrappedToken } from '../../utils/unwrappedToken'
|
import { unwrappedToken } from '../../utils/unwrappedToken'
|
||||||
import { ButtonEmpty, ButtonPrimary, ButtonSecondary } from '../Button'
|
import { ButtonEmpty, ButtonPrimary, ButtonSecondary } from '../Button'
|
||||||
|
@ -14,7 +14,8 @@ import { useMemo } from 'react'
|
|||||||
import { Link } from 'react-router-dom'
|
import { Link } from 'react-router-dom'
|
||||||
import { Bound } from 'state/mint/v3/actions'
|
import { Bound } from 'state/mint/v3/actions'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { HideSmall, MEDIA_WIDTHS, SmallOnly, ThemedText } from 'theme'
|
import { MEDIA_WIDTHS } from 'theme'
|
||||||
|
import { HideSmall, SmallOnly, ThemedText } from 'theme/components'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
import { unwrappedToken } from 'utils/unwrappedToken'
|
import { unwrappedToken } from 'utils/unwrappedToken'
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ import JSBI from 'jsbi'
|
|||||||
import { ReactNode, useCallback, useState } from 'react'
|
import { ReactNode, useCallback, useState } from 'react'
|
||||||
import { Bound } from 'state/mint/v3/actions'
|
import { Bound } from 'state/mint/v3/actions'
|
||||||
import { useTheme } from 'styled-components'
|
import { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
import { unwrappedToken } from 'utils/unwrappedToken'
|
import { unwrappedToken } from 'utils/unwrappedToken'
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@ import Row, { AutoRow, RowBetween } from 'components/Row'
|
|||||||
import { useEffect, useRef } from 'react'
|
import { useEffect, useRef } from 'react'
|
||||||
import { ArrowDown, Info, X } from 'react-feather'
|
import { ArrowDown, Info, X } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { isMobile } from 'utils/userAgent'
|
import { isMobile } from 'utils/userAgent'
|
||||||
|
|
||||||
import { useModalIsOpen, useTogglePrivacyPolicy } from '../../state/application/hooks'
|
import { useModalIsOpen, useTogglePrivacyPolicy } from '../../state/application/hooks'
|
||||||
|
@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro'
|
|||||||
import { ButtonOutlined } from 'components/Button'
|
import { ButtonOutlined } from 'components/Button'
|
||||||
import { AutoRow } from 'components/Row'
|
import { AutoRow } from 'components/Row'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const Button = styled(ButtonOutlined).attrs(() => ({
|
const Button = styled(ButtonOutlined).attrs(() => ({
|
||||||
padding: '6px',
|
padding: '6px',
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { InterfaceTrade, QuoteMethod } from 'state/routing/types'
|
import { InterfaceTrade, QuoteMethod } from 'state/routing/types'
|
||||||
import { isUniswapXTrade } from 'state/routing/utils'
|
import { isUniswapXTrade } from 'state/routing/utils'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import UniswapXRouterLabel from './UniswapXRouterLabel'
|
import UniswapXRouterLabel from './UniswapXRouterLabel'
|
||||||
|
|
||||||
|
@ -9,7 +9,7 @@ import Row, { AutoRow } from 'components/Row'
|
|||||||
import { useTokenInfoFromActiveList } from 'hooks/useTokenInfoFromActiveList'
|
import { useTokenInfoFromActiveList } from 'hooks/useTokenInfoFromActiveList'
|
||||||
import { Box } from 'rebass'
|
import { Box } from 'rebass'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { Z_INDEX } from 'theme/zIndex'
|
import { Z_INDEX } from 'theme/zIndex'
|
||||||
import { RoutingDiagramEntry } from 'utils/getRoutingDiagramEntries'
|
import { RoutingDiagramEntry } from 'utils/getRoutingDiagramEntries'
|
||||||
|
|
||||||
|
@ -12,10 +12,10 @@ import { Check } from 'react-feather'
|
|||||||
import { FixedSizeList } from 'react-window'
|
import { FixedSizeList } from 'react-window'
|
||||||
import { Text } from 'rebass'
|
import { Text } from 'rebass'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { useIsUserAddedToken } from '../../../hooks/Tokens'
|
import { useIsUserAddedToken } from '../../../hooks/Tokens'
|
||||||
import { WrappedTokenInfo } from '../../../state/lists/wrappedTokenInfo'
|
import { WrappedTokenInfo } from '../../../state/lists/wrappedTokenInfo'
|
||||||
import { ThemedText } from '../../../theme'
|
|
||||||
import Column, { AutoColumn } from '../../Column'
|
import Column, { AutoColumn } from '../../Column'
|
||||||
import CurrencyLogo from '../../Logo/CurrencyLogo'
|
import CurrencyLogo from '../../Logo/CurrencyLogo'
|
||||||
import Row, { RowFixed } from '../../Row'
|
import Row, { RowFixed } from '../../Row'
|
||||||
|
@ -17,10 +17,10 @@ import AutoSizer from 'react-virtualized-auto-sizer'
|
|||||||
import { FixedSizeList } from 'react-window'
|
import { FixedSizeList } from 'react-window'
|
||||||
import { Text } from 'rebass'
|
import { Text } from 'rebass'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { CloseIcon, ThemedText } from 'theme/components'
|
||||||
import { UserAddedToken } from 'types/tokens'
|
import { UserAddedToken } from 'types/tokens'
|
||||||
|
|
||||||
import { useDefaultActiveTokens, useIsUserAddedToken, useSearchInactiveTokenLists, useToken } from '../../hooks/Tokens'
|
import { useDefaultActiveTokens, useIsUserAddedToken, useSearchInactiveTokenLists, useToken } from '../../hooks/Tokens'
|
||||||
import { CloseIcon, ThemedText } from '../../theme'
|
|
||||||
import { isAddress } from '../../utils'
|
import { isAddress } from '../../utils'
|
||||||
import Column from '../Column'
|
import Column from '../Column'
|
||||||
import Row, { RowBetween } from '../Row'
|
import Row, { RowBetween } from '../Row'
|
||||||
|
@ -7,7 +7,7 @@ import React, { useState } from 'react'
|
|||||||
import { useUserSlippageTolerance } from 'state/user/hooks'
|
import { useUserSlippageTolerance } from 'state/user/hooks'
|
||||||
import { SlippageTolerance } from 'state/user/types'
|
import { SlippageTolerance } from 'state/user/types'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { CautionTriangle, ThemedText } from 'theme'
|
import { CautionTriangle, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { Input, InputContainer } from '../Input'
|
import { Input, InputContainer } from '../Input'
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@ import Row from 'components/Row'
|
|||||||
import { useUserSlippageTolerance } from 'state/user/hooks'
|
import { useUserSlippageTolerance } from 'state/user/hooks'
|
||||||
import { SlippageTolerance } from 'state/user/types'
|
import { SlippageTolerance } from 'state/user/types'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import validateUserSlippageTolerance, { SlippageValidationResult } from 'utils/validateUserSlippageTolerance'
|
import validateUserSlippageTolerance, { SlippageValidationResult } from 'utils/validateUserSlippageTolerance'
|
||||||
|
|
||||||
const Icon = styled(Settings)`
|
const Icon = styled(Settings)`
|
||||||
|
@ -11,7 +11,7 @@ import { RouterPreference } from 'state/routing/types'
|
|||||||
import { useRouterPreference, useUserDisabledUniswapX } from 'state/user/hooks'
|
import { useRouterPreference, useUserDisabledUniswapX } from 'state/user/hooks'
|
||||||
import { updateDisabledUniswapX } from 'state/user/reducer'
|
import { updateDisabledUniswapX } from 'state/user/reducer'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { Divider, ExternalLink, ThemedText } from 'theme'
|
import { Divider, ExternalLink, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const InlineLink = styled(ThemedText.BodySmall)`
|
const InlineLink = styled(ThemedText.BodySmall)`
|
||||||
color: ${({ theme }) => theme.accent1};
|
color: ${({ theme }) => theme.accent1};
|
||||||
|
@ -7,7 +7,7 @@ import { DEFAULT_DEADLINE_FROM_NOW } from 'constants/misc'
|
|||||||
import ms from 'ms'
|
import ms from 'ms'
|
||||||
import React, { useState } from 'react'
|
import React, { useState } from 'react'
|
||||||
import { useUserTransactionTTL } from 'state/user/hooks'
|
import { useUserTransactionTTL } from 'state/user/hooks'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
enum DeadlineError {
|
enum DeadlineError {
|
||||||
InvalidInput = 'InvalidInput',
|
InvalidInput = 'InvalidInput',
|
||||||
|
@ -17,7 +17,7 @@ import { ApplicationModal } from 'state/application/reducer'
|
|||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import { isUniswapXTrade } from 'state/routing/utils'
|
import { isUniswapXTrade } from 'state/routing/utils'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { Divider, ThemedText } from 'theme'
|
import { Divider, ThemedText } from 'theme/components'
|
||||||
import { Z_INDEX } from 'theme/zIndex'
|
import { Z_INDEX } from 'theme/zIndex'
|
||||||
|
|
||||||
import MaxSlippageSettings from './MaxSlippageSettings'
|
import MaxSlippageSettings from './MaxSlippageSettings'
|
||||||
|
@ -2,10 +2,10 @@ import { Trans } from '@lingui/macro'
|
|||||||
import { useLocationLinkProps } from 'hooks/useLocationLinkProps'
|
import { useLocationLinkProps } from 'hooks/useLocationLinkProps'
|
||||||
import { useMemo } from 'react'
|
import { useMemo } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
|
import { StyledInternalLink, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { DEFAULT_LOCALE, LOCALE_LABEL, SupportedLocale } from '../../constants/locales'
|
import { DEFAULT_LOCALE, LOCALE_LABEL, SupportedLocale } from '../../constants/locales'
|
||||||
import { navigatorLocale, useActiveLocale } from '../../hooks/useActiveLocale'
|
import { navigatorLocale, useActiveLocale } from '../../hooks/useActiveLocale'
|
||||||
import { StyledInternalLink, ThemedText } from '../../theme'
|
|
||||||
|
|
||||||
const Container = styled(ThemedText.DeprecatedSmall)`
|
const Container = styled(ThemedText.DeprecatedSmall)`
|
||||||
opacity: ${({ theme }) => theme.opacity.hover};
|
opacity: ${({ theme }) => theme.opacity.hover};
|
||||||
|
@ -4,7 +4,7 @@ import { useTokenWarningColor, useTokenWarningTextColor } from 'hooks/useTokenWa
|
|||||||
import { AlertTriangle, Slash } from 'react-feather'
|
import { AlertTriangle, Slash } from 'react-feather'
|
||||||
import { Text } from 'rebass'
|
import { Text } from 'rebass'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink } from 'theme'
|
import { ExternalLink } from 'theme/components'
|
||||||
|
|
||||||
const Label = styled.div<{ color: string; backgroundColor: string }>`
|
const Label = styled.div<{ color: string; backgroundColor: string }>`
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
@ -17,7 +17,7 @@ import { ExternalLink as LinkIconFeather } from 'react-feather'
|
|||||||
import { Text } from 'rebass'
|
import { Text } from 'rebass'
|
||||||
import { useAddUserToken } from 'state/user/hooks'
|
import { useAddUserToken } from 'state/user/hooks'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ButtonText, CopyLinkIcon, ExternalLink } from 'theme'
|
import { ButtonText, CopyLinkIcon, ExternalLink } from 'theme/components'
|
||||||
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
||||||
|
|
||||||
const Wrapper = styled.div`
|
const Wrapper = styled.div`
|
||||||
|
@ -4,7 +4,7 @@ import { getChainInfo } from 'constants/chainInfo'
|
|||||||
import { darken } from 'polished'
|
import { darken } from 'polished'
|
||||||
import { useState } from 'react'
|
import { useState } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { textFadeIn } from 'theme/styles'
|
import { textFadeIn } from 'theme/styles'
|
||||||
|
|
||||||
import Resource from './Resource'
|
import Resource from './Resource'
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { Trans } from '@lingui/macro'
|
import { Trans } from '@lingui/macro'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { CopyContractAddress, ThemedText } from 'theme'
|
import { CopyContractAddress, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const ContractAddressSection = styled.div`
|
const ContractAddressSection = styled.div`
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -7,7 +7,7 @@ import { asSupportedChain } from 'constants/chains'
|
|||||||
import { useStablecoinValue } from 'hooks/useStablecoinPrice'
|
import { useStablecoinValue } from 'hooks/useStablecoinPrice'
|
||||||
import useCurrencyBalance from 'lib/hooks/useCurrencyBalance'
|
import useCurrencyBalance from 'lib/hooks/useCurrencyBalance'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
const BalancesCard = styled.div`
|
const BalancesCard = styled.div`
|
||||||
|
@ -6,7 +6,7 @@ import { getChainInfo } from 'constants/chainInfo'
|
|||||||
import useSelectChain from 'hooks/useSelectChain'
|
import useSelectChain from 'hooks/useSelectChain'
|
||||||
import { useNavigate } from 'react-router-dom'
|
import { useNavigate } from 'react-router-dom'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { ReactComponent as EyeIcon } from '../../../assets/svg/eye.svg'
|
import { ReactComponent as EyeIcon } from '../../../assets/svg/eye.svg'
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@ import { CHAIN_ID_TO_BACKEND_NAME } from 'graphql/data/util'
|
|||||||
import { useStablecoinValue } from 'hooks/useStablecoinPrice'
|
import { useStablecoinValue } from 'hooks/useStablecoinPrice'
|
||||||
import useCurrencyBalance from 'lib/hooks/useCurrencyBalance'
|
import useCurrencyBalance from 'lib/hooks/useCurrencyBalance'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { StyledInternalLink } from 'theme'
|
import { StyledInternalLink } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
const Wrapper = styled.div`
|
const Wrapper = styled.div`
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { darken } from 'polished'
|
import { darken } from 'polished'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink } from 'theme'
|
import { ExternalLink } from 'theme/components'
|
||||||
|
|
||||||
const ResourceLink = styled(ExternalLink)`
|
const ResourceLink = styled(ExternalLink)`
|
||||||
display: flex;
|
display: flex;
|
||||||
|
@ -10,13 +10,12 @@ import { Link, Twitter } from 'react-feather'
|
|||||||
import { useModalIsOpen, useToggleModal } from 'state/application/hooks'
|
import { useModalIsOpen, useToggleModal } from 'state/application/hooks'
|
||||||
import { ApplicationModal } from 'state/application/reducer'
|
import { ApplicationModal } from 'state/application/reducer'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ClickableStyle, CopyHelperRefType } from 'theme'
|
|
||||||
import { colors } from 'theme/colors'
|
import { colors } from 'theme/colors'
|
||||||
|
import { ClickableStyle, CopyHelperRefType } from 'theme/components'
|
||||||
|
import { CopyHelper } from 'theme/components'
|
||||||
import { opacify } from 'theme/utils'
|
import { opacify } from 'theme/utils'
|
||||||
import { Z_INDEX } from 'theme/zIndex'
|
import { Z_INDEX } from 'theme/zIndex'
|
||||||
|
|
||||||
import { CopyHelper } from '../../../theme'
|
|
||||||
|
|
||||||
const TWITTER_WIDTH = 560
|
const TWITTER_WIDTH = 560
|
||||||
const TWITTER_HEIGHT = 480
|
const TWITTER_HEIGHT = 480
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@ import { SwapSkeleton } from 'components/swap/SwapSkeleton'
|
|||||||
import { ArrowLeft } from 'react-feather'
|
import { ArrowLeft } from 'react-feather'
|
||||||
import { useParams } from 'react-router-dom'
|
import { useParams } from 'react-router-dom'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { textFadeIn } from 'theme/styles'
|
import { textFadeIn } from 'theme/styles'
|
||||||
|
|
||||||
import { LoadingBubble } from '../loading'
|
import { LoadingBubble } from '../loading'
|
||||||
|
@ -4,7 +4,7 @@ import { MouseoverTooltip } from 'components/Tooltip'
|
|||||||
import { getChainInfo } from 'constants/chainInfo'
|
import { getChainInfo } from 'constants/chainInfo'
|
||||||
import { ReactNode } from 'react'
|
import { ReactNode } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { textFadeIn } from 'theme/styles'
|
import { textFadeIn } from 'theme/styles'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ import { useNavigate, useParams } from 'react-router-dom'
|
|||||||
import { useModalIsOpen, useToggleModal } from 'state/application/hooks'
|
import { useModalIsOpen, useToggleModal } from 'state/application/hooks'
|
||||||
import { ApplicationModal } from 'state/application/reducer'
|
import { ApplicationModal } from 'state/application/reducer'
|
||||||
import styled, { css, useTheme } from 'styled-components'
|
import styled, { css, useTheme } from 'styled-components'
|
||||||
import { EllipsisStyle } from 'theme'
|
import { EllipsisStyle } from 'theme/components'
|
||||||
|
|
||||||
import FilterOption from './FilterOption'
|
import FilterOption from './FilterOption'
|
||||||
|
|
||||||
|
@ -15,7 +15,8 @@ import { ForwardedRef, forwardRef } from 'react'
|
|||||||
import { CSSProperties, ReactNode } from 'react'
|
import { CSSProperties, ReactNode } from 'react'
|
||||||
import { Link, useParams } from 'react-router-dom'
|
import { Link, useParams } from 'react-router-dom'
|
||||||
import styled, { css, useTheme } from 'styled-components'
|
import styled, { css, useTheme } from 'styled-components'
|
||||||
import { BREAKPOINTS, ClickableStyle } from 'theme'
|
import { BREAKPOINTS } from 'theme'
|
||||||
|
import { ClickableStyle } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import {
|
import {
|
||||||
|
@ -9,12 +9,12 @@ import { ReactNode, useCallback, useState } from 'react'
|
|||||||
import { AlertCircle, ArrowUpCircle, CheckCircle } from 'react-feather'
|
import { AlertCircle, ArrowUpCircle, CheckCircle } from 'react-feather'
|
||||||
import { useIsTransactionConfirmed, useTransaction } from 'state/transactions/hooks'
|
import { useIsTransactionConfirmed, useTransaction } from 'state/transactions/hooks'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
|
import { CloseIcon, CustomLightSpinner } from 'theme/components'
|
||||||
import { isL2ChainId } from 'utils/chains'
|
import { isL2ChainId } from 'utils/chains'
|
||||||
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from 'utils/getExplorerLink'
|
||||||
|
|
||||||
import Circle from '../../assets/images/blue-loader.svg'
|
import Circle from '../../assets/images/blue-loader.svg'
|
||||||
import { ExternalLink, ThemedText } from '../../theme'
|
|
||||||
import { CloseIcon, CustomLightSpinner } from '../../theme'
|
|
||||||
import { TransactionSummary } from '../AccountDetails/TransactionSummary'
|
import { TransactionSummary } from '../AccountDetails/TransactionSummary'
|
||||||
import { ButtonLight, ButtonPrimary } from '../Button'
|
import { ButtonLight, ButtonPrimary } from '../Button'
|
||||||
import { AutoColumn, ColumnCenter } from '../Column'
|
import { AutoColumn, ColumnCenter } from '../Column'
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { Trans } from '@lingui/macro'
|
import { Trans } from '@lingui/macro'
|
||||||
import { AutoColumn } from 'components/Column'
|
import { AutoColumn } from 'components/Column'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const TextWrapper = styled.div`
|
const TextWrapper = styled.div`
|
||||||
border: 1px solid ${({ theme }) => theme.neutral3};
|
border: 1px solid ${({ theme }) => theme.neutral3};
|
||||||
|
@ -4,7 +4,7 @@ import { ButtonEmpty, ButtonPrimary } from 'components/Button'
|
|||||||
import { ActivationStatus, useActivationState } from 'connection/activate'
|
import { ActivationStatus, useActivationState } from 'connection/activate'
|
||||||
import { AlertTriangle } from 'react-feather'
|
import { AlertTriangle } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { flexColumnNoWrap } from 'theme/styles'
|
import { flexColumnNoWrap } from 'theme/styles'
|
||||||
|
|
||||||
const Wrapper = styled.div`
|
const Wrapper = styled.div`
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { Trans } from '@lingui/macro'
|
import { Trans } from '@lingui/macro'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const StyledLink = styled(ExternalLink)`
|
const StyledLink = styled(ExternalLink)`
|
||||||
font-weight: 535;
|
font-weight: 535;
|
||||||
|
@ -8,7 +8,7 @@ import { ActivationStatus, useActivationState } from 'connection/activate'
|
|||||||
import { isSupportedChain } from 'constants/chains'
|
import { isSupportedChain } from 'constants/chains'
|
||||||
import { useEffect } from 'react'
|
import { useEffect } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { flexColumnNoWrap } from 'theme/styles'
|
import { flexColumnNoWrap } from 'theme/styles'
|
||||||
|
|
||||||
import ConnectionErrorView from './ConnectionErrorView'
|
import ConnectionErrorView from './ConnectionErrorView'
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { Trans } from '@lingui/macro'
|
import { Trans } from '@lingui/macro'
|
||||||
import { AlertTriangle } from 'react-feather'
|
import { AlertTriangle } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
const ExplainerText = styled.div`
|
const ExplainerText = styled.div`
|
||||||
color: ${({ theme }) => theme.neutral2};
|
color: ${({ theme }) => theme.neutral2};
|
||||||
|
@ -5,6 +5,7 @@ import { useWeb3React } from '@web3-react/core'
|
|||||||
import { useState } from 'react'
|
import { useState } from 'react'
|
||||||
import { Text } from 'rebass'
|
import { Text } from 'rebass'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
|
import { CloseIcon, CustomLightSpinner, ExternalLink, ThemedText, UniTokenAnimated } from 'theme/components'
|
||||||
import { shortenAddress } from 'utils'
|
import { shortenAddress } from 'utils'
|
||||||
|
|
||||||
import Circle from '../../assets/images/blue-loader.svg'
|
import Circle from '../../assets/images/blue-loader.svg'
|
||||||
@ -12,7 +13,6 @@ import tokenLogo from '../../assets/images/token-logo.png'
|
|||||||
import useENS from '../../hooks/useENS'
|
import useENS from '../../hooks/useENS'
|
||||||
import { useClaimCallback, useUserHasAvailableClaim, useUserUnclaimedAmount } from '../../state/claim/hooks'
|
import { useClaimCallback, useUserHasAvailableClaim, useUserUnclaimedAmount } from '../../state/claim/hooks'
|
||||||
import { useIsTransactionPending } from '../../state/transactions/hooks'
|
import { useIsTransactionPending } from '../../state/transactions/hooks'
|
||||||
import { CloseIcon, CustomLightSpinner, ExternalLink, ThemedText, UniTokenAnimated } from '../../theme'
|
|
||||||
import { ExplorerDataType, getExplorerLink } from '../../utils/getExplorerLink'
|
import { ExplorerDataType, getExplorerLink } from '../../utils/getExplorerLink'
|
||||||
import AddressInputPanel from '../AddressInputPanel'
|
import AddressInputPanel from '../AddressInputPanel'
|
||||||
import { ButtonPrimary } from '../Button'
|
import { ButtonPrimary } from '../Button'
|
||||||
|
@ -9,9 +9,9 @@ import { ZERO_PERCENT } from 'constants/misc'
|
|||||||
import useNativeCurrency from 'lib/hooks/useNativeCurrency'
|
import useNativeCurrency from 'lib/hooks/useNativeCurrency'
|
||||||
import { ClassicTrade, InterfaceTrade } from 'state/routing/types'
|
import { ClassicTrade, InterfaceTrade } from 'state/routing/types'
|
||||||
import { getTransactionCount, isClassicTrade } from 'state/routing/utils'
|
import { getTransactionCount, isClassicTrade } from 'state/routing/utils'
|
||||||
|
import { ExternalLink, Separator, ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import { ExternalLink, Separator, ThemedText } from '../../theme'
|
|
||||||
import Column from '../Column'
|
import Column from '../Column'
|
||||||
import RouterLabel from '../RouterLabel'
|
import RouterLabel from '../RouterLabel'
|
||||||
import { RowBetween, RowFixed } from '../Row'
|
import { RowBetween, RowFixed } from '../Row'
|
||||||
|
@ -25,7 +25,7 @@ import { InterfaceTrade, TradeFillType } from 'state/routing/types'
|
|||||||
import { Field } from 'state/swap/actions'
|
import { Field } from 'state/swap/actions'
|
||||||
import { useIsTransactionConfirmed, useSwapTransactionStatus } from 'state/transactions/hooks'
|
import { useIsTransactionConfirmed, useSwapTransactionStatus } from 'state/transactions/hooks'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import invariant from 'tiny-invariant'
|
import invariant from 'tiny-invariant'
|
||||||
import { isL2ChainId } from 'utils/chains'
|
import { isL2ChainId } from 'utils/chains'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
@ -6,7 +6,7 @@ import { ReactNode } from 'react'
|
|||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import { isClassicTrade, isUniswapXTrade } from 'state/routing/utils'
|
import { isClassicTrade, isUniswapXTrade } from 'state/routing/utils'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { Divider, ExternalLink, ThemedText } from 'theme'
|
import { Divider, ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
const Container = styled(AutoColumn)`
|
const Container = styled(AutoColumn)`
|
||||||
|
@ -10,7 +10,7 @@ import { SUPPORTED_GAS_ESTIMATE_CHAIN_IDS } from 'constants/chains'
|
|||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import { isUniswapXTrade } from 'state/routing/utils'
|
import { isUniswapXTrade } from 'state/routing/utils'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import { GasBreakdownTooltip } from './GasBreakdownTooltip'
|
import { GasBreakdownTooltip } from './GasBreakdownTooltip'
|
||||||
|
@ -5,7 +5,7 @@ import QuestionHelper from 'components/QuestionHelper'
|
|||||||
import Row from 'components/Row'
|
import Row from 'components/Row'
|
||||||
import { AlertTriangle } from 'react-feather'
|
import { AlertTriangle } from 'react-feather'
|
||||||
import { useTheme } from 'styled-components'
|
import { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { PendingModalContainer } from '.'
|
import { PendingModalContainer } from '.'
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@ import Row from 'components/Row'
|
|||||||
import { ArrowRight } from 'react-feather'
|
import { ArrowRight } from 'react-feather'
|
||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import { useTheme } from 'styled-components'
|
import { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
export function TradeSummary({ trade }: { trade: Pick<InterfaceTrade, 'inputAmount' | 'postTaxOutputAmount'> }) {
|
export function TradeSummary({ trade }: { trade: Pick<InterfaceTrade, 'inputAmount' | 'postTaxOutputAmount'> }) {
|
||||||
|
@ -15,7 +15,7 @@ import { useOrder } from 'state/signatures/hooks'
|
|||||||
import { UniswapXOrderDetails } from 'state/signatures/types'
|
import { UniswapXOrderDetails } from 'state/signatures/types'
|
||||||
import { useIsTransactionConfirmed, useSwapTransactionStatus } from 'state/transactions/hooks'
|
import { useIsTransactionConfirmed, useSwapTransactionStatus } from 'state/transactions/hooks'
|
||||||
import styled, { css, keyframes } from 'styled-components'
|
import styled, { css, keyframes } from 'styled-components'
|
||||||
import { ExternalLink } from 'theme'
|
import { ExternalLink } from 'theme/components'
|
||||||
import { ThemedText } from 'theme/components/text'
|
import { ThemedText } from 'theme/components/text'
|
||||||
import { getExplorerLink } from 'utils/getExplorerLink'
|
import { getExplorerLink } from 'utils/getExplorerLink'
|
||||||
import { ExplorerDataType } from 'utils/getExplorerLink'
|
import { ExplorerDataType } from 'utils/getExplorerLink'
|
||||||
|
@ -5,7 +5,7 @@ import { ColumnCenter } from 'components/Column'
|
|||||||
import Row from 'components/Row'
|
import Row from 'components/Row'
|
||||||
import { AlertTriangle } from 'react-feather'
|
import { AlertTriangle } from 'react-feather'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { CloseIcon, ThemedText } from 'theme'
|
import { CloseIcon, ThemedText } from 'theme/components'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import Modal from '../Modal'
|
import Modal from '../Modal'
|
||||||
|
@ -2,10 +2,10 @@ import { Trans } from '@lingui/macro'
|
|||||||
import { Percent } from '@uniswap/sdk-core'
|
import { Percent } from '@uniswap/sdk-core'
|
||||||
import { OutlineCard } from 'components/Card'
|
import { OutlineCard } from 'components/Card'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
import { opacify } from 'theme/utils'
|
import { opacify } from 'theme/utils'
|
||||||
import { useFormatter } from 'utils/formatNumbers'
|
import { useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
import { ThemedText } from '../../theme'
|
|
||||||
import { AutoColumn } from '../Column'
|
import { AutoColumn } from '../Column'
|
||||||
import { RowBetween, RowFixed } from '../Row'
|
import { RowBetween, RowFixed } from '../Row'
|
||||||
import { MouseoverTooltip } from '../Tooltip'
|
import { MouseoverTooltip } from '../Tooltip'
|
||||||
|
@ -7,7 +7,7 @@ import { ButtonText } from 'components/Button'
|
|||||||
import { MouseoverTooltip } from 'components/Tooltip'
|
import { MouseoverTooltip } from 'components/Tooltip'
|
||||||
import { useCallback, useEffect, useState } from 'react'
|
import { useCallback, useEffect, useState } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ExternalLink } from 'theme'
|
import { ExternalLink } from 'theme/components'
|
||||||
|
|
||||||
import { useFiatOnrampAvailability, useOpenModal } from '../../state/application/hooks'
|
import { useFiatOnrampAvailability, useOpenModal } from '../../state/application/hooks'
|
||||||
import { ApplicationModal } from '../../state/application/reducer'
|
import { ApplicationModal } from '../../state/application/reducer'
|
||||||
|
@ -11,7 +11,7 @@ import { useState } from 'react'
|
|||||||
import { ChevronDown } from 'react-feather'
|
import { ChevronDown } from 'react-feather'
|
||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import styled, { keyframes, useTheme } from 'styled-components'
|
import styled, { keyframes, useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { AdvancedSwapDetails } from './AdvancedSwapDetails'
|
import { AdvancedSwapDetails } from './AdvancedSwapDetails'
|
||||||
import GasEstimateTooltip from './GasEstimateTooltip'
|
import GasEstimateTooltip from './GasEstimateTooltip'
|
||||||
|
@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro'
|
|||||||
import { Percent } from '@uniswap/sdk-core'
|
import { Percent } from '@uniswap/sdk-core'
|
||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { RowBetween, RowFixed } from '../Row'
|
import { RowBetween, RowFixed } from '../Row'
|
||||||
import SettingsTab from '../Settings'
|
import SettingsTab from '../Settings'
|
||||||
|
@ -15,7 +15,7 @@ import { ClassicTrade, InterfaceTrade, RouterPreference } from 'state/routing/ty
|
|||||||
import { getTransactionCount, isClassicTrade } from 'state/routing/utils'
|
import { getTransactionCount, isClassicTrade } from 'state/routing/utils'
|
||||||
import { useRouterPreference, useUserSlippageTolerance } from 'state/user/hooks'
|
import { useRouterPreference, useUserSlippageTolerance } from 'state/user/hooks'
|
||||||
import styled, { DefaultTheme, useTheme } from 'styled-components'
|
import styled, { DefaultTheme, useTheme } from 'styled-components'
|
||||||
import { ExternalLink, ThemedText } from 'theme'
|
import { ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { FormatterRule, NumberType, SIX_SIG_FIGS_NO_COMMAS, useFormatter } from 'utils/formatNumbers'
|
import { FormatterRule, NumberType, SIX_SIG_FIGS_NO_COMMAS, useFormatter } from 'utils/formatNumbers'
|
||||||
import getRoutingDiagramEntries from 'utils/getRoutingDiagramEntries'
|
import getRoutingDiagramEntries from 'utils/getRoutingDiagramEntries'
|
||||||
import { formatSwapButtonClickEventProperties } from 'utils/loggingFormatters'
|
import { formatSwapButtonClickEventProperties } from 'utils/loggingFormatters'
|
||||||
|
@ -5,7 +5,7 @@ import { useUSDPrice } from 'hooks/useUSDPrice'
|
|||||||
import { InterfaceTrade } from 'state/routing/types'
|
import { InterfaceTrade } from 'state/routing/types'
|
||||||
import { Field } from 'state/swap/actions'
|
import { Field } from 'state/swap/actions'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { Divider, ThemedText } from 'theme'
|
import { Divider, ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { SwapModalHeaderAmount } from './SwapModalHeaderAmount'
|
import { SwapModalHeaderAmount } from './SwapModalHeaderAmount'
|
||||||
|
|
||||||
|
@ -8,7 +8,8 @@ import { PropsWithChildren, ReactNode } from 'react'
|
|||||||
import { TextProps } from 'rebass'
|
import { TextProps } from 'rebass'
|
||||||
import { Field } from 'state/swap/actions'
|
import { Field } from 'state/swap/actions'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { BREAKPOINTS, ThemedText } from 'theme'
|
import { BREAKPOINTS } from 'theme'
|
||||||
|
import { ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
export const Label = styled(ThemedText.BodySmall)<{ cursor?: string }>`
|
export const Label = styled(ThemedText.BodySmall)<{ cursor?: string }>`
|
||||||
|
@ -6,7 +6,7 @@ import RoutingDiagram from 'components/RoutingDiagram/RoutingDiagram'
|
|||||||
import { SUPPORTED_GAS_ESTIMATE_CHAIN_IDS } from 'constants/chains'
|
import { SUPPORTED_GAS_ESTIMATE_CHAIN_IDS } from 'constants/chains'
|
||||||
import useAutoRouterSupported from 'hooks/useAutoRouterSupported'
|
import useAutoRouterSupported from 'hooks/useAutoRouterSupported'
|
||||||
import { ClassicTrade } from 'state/routing/types'
|
import { ClassicTrade } from 'state/routing/types'
|
||||||
import { Separator, ThemedText } from 'theme'
|
import { Separator, ThemedText } from 'theme/components'
|
||||||
import getRoutingDiagramEntries from 'utils/getRoutingDiagramEntries'
|
import getRoutingDiagramEntries from 'utils/getRoutingDiagramEntries'
|
||||||
|
|
||||||
import RouterLabel from '../RouterLabel'
|
import RouterLabel from '../RouterLabel'
|
||||||
|
@ -2,7 +2,7 @@ import { Trans } from '@lingui/macro'
|
|||||||
import { ArrowContainer } from 'pages/Swap'
|
import { ArrowContainer } from 'pages/Swap'
|
||||||
import { ArrowDown } from 'react-feather'
|
import { ArrowDown } from 'react-feather'
|
||||||
import styled, { useTheme } from 'styled-components'
|
import styled, { useTheme } from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
|
|
||||||
import { ArrowWrapper } from './styled'
|
import { ArrowWrapper } from './styled'
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@ import { useUSDPrice } from 'hooks/useUSDPrice'
|
|||||||
import tryParseCurrencyAmount from 'lib/utils/tryParseCurrencyAmount'
|
import tryParseCurrencyAmount from 'lib/utils/tryParseCurrencyAmount'
|
||||||
import { useCallback, useMemo, useState } from 'react'
|
import { useCallback, useMemo, useState } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { ThemedText } from 'theme'
|
import { ThemedText } from 'theme/components'
|
||||||
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
import { NumberType, useFormatter } from 'utils/formatNumbers'
|
||||||
|
|
||||||
interface TradePriceProps {
|
interface TradePriceProps {
|
||||||
|
@ -9,7 +9,7 @@ import Modal from 'components/Modal'
|
|||||||
import { AutoRow, RowBetween } from 'components/Row'
|
import { AutoRow, RowBetween } from 'components/Row'
|
||||||
import { useState } from 'react'
|
import { useState } from 'react'
|
||||||
import styled from 'styled-components'
|
import styled from 'styled-components'
|
||||||
import { CloseIcon, ExternalLink, ThemedText } from 'theme'
|
import { CloseIcon, ExternalLink, ThemedText } from 'theme/components'
|
||||||
import { Z_INDEX } from 'theme/zIndex'
|
import { Z_INDEX } from 'theme/zIndex'
|
||||||
|
|
||||||
import { useUnsupportedTokens } from '../../hooks/Tokens'
|
import { useUnsupportedTokens } from '../../hooks/Tokens'
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user