Skip to content

Commit

Permalink
chore: remove add liquidity classic
Browse files Browse the repository at this point in the history
  • Loading branch information
viet-nv committed Mar 18, 2024
1 parent cefe203 commit baf8534
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 62 deletions.
34 changes: 1 addition & 33 deletions src/components/Menu/index.tsx
Original file line number Diff line number Diff line change
@@ -1,17 +1,7 @@
import { Trans, t } from '@lingui/macro'
import { useEffect, useState } from 'react'
import { isMobile } from 'react-device-detect'
import {
AlertOctagon,
BookOpen,
ChevronDown,
Edit,
FileText,
HelpCircle,
Info,
MessageCircle,
PieChart,
} from 'react-feather'
import { AlertOctagon, BookOpen, ChevronDown, FileText, Info, MessageCircle, PieChart } from 'react-feather'
import { NavLink, useLocation, useNavigate } from 'react-router-dom'
import { useMedia } from 'react-use'
import { Text } from 'rebass'
Expand Down Expand Up @@ -429,28 +419,6 @@ export default function Menu() {
<Trans>Privacy Policy</Trans>
</ExternalLink>
</MenuItem>
<MenuItem>
<ExternalLink
href="https://forms.gle/gLiNsi7iUzHws2BY8"
onClick={() => {
handleMenuClickMixpanel('Business Enquiries')
}}
>
<Edit />
<Trans>Business Enquiries</Trans>
</ExternalLink>
</MenuItem>
<MenuItem>
<ExternalLink
href="https://support.kyberswap.com"
onClick={() => {
handleMenuClickMixpanel('Help')
}}
>
<HelpCircle size={20} />
<Trans>Help</Trans>
</ExternalLink>
</MenuItem>
{ENV_LEVEL === ENV_TYPE.LOCAL && (
<MenuItem>
<NavLink to="/icons">
Expand Down
14 changes: 0 additions & 14 deletions src/components/PositionCard/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -743,20 +743,6 @@ export default function FullPositionCard({
</Text>
</ButtonPrimary>
)}

<ButtonPrimary
padding="10px"
style={{ fontSize: '14px' }}
as={Link}
to={`/${networkInfo.route}${APP_PATHS.CLASSIC_ADD_LIQ}/${currencyId(currency0, chainId)}/${currencyId(
currency1,
chainId,
)}/${pair.address}`}
>
<Text width="max-content">
<Trans>Add Liquidity</Trans>
</Text>
</ButtonPrimary>
</Flex>
) : (
<ButtonPrimary padding="10px" style={{ fontSize: '14px' }} as={Link} to={goToFarmPath}>
Expand Down
7 changes: 2 additions & 5 deletions src/pages/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,6 @@ const PoolFinder = lazy(() => import('./PoolFinder'))
const ElasticRemoveLiquidity = lazy(() => import('pages/RemoveLiquidityProAmm'))
const RedirectCreatePool = lazy(() => import('pages/CreatePool/RedirectCreatePool'))

// const RedirectElasticCreatePool = lazy(() => import('pages/AddLiquidityV2/RedirectElasticCreatePool'))

const AddLiquidity = lazy(() => import('pages/AddLiquidity'))
// const ElasticIncreaseLiquidity = lazy(() => import('pages/IncreaseLiquidity'))

const RemoveLiquidity = lazy(() => import('pages/RemoveLiquidity'))

const KyberDAOStakeKNC = lazy(() => import('pages/KyberDAO/StakeKNC'))
Expand Down Expand Up @@ -163,10 +158,12 @@ const RoutesWithNetworkPrefix = () => {
path={`${APP_PATHS.CLASSIC_CREATE_POOL}/:currencyIdA?/:currencyIdB?`}
element={<RedirectCreatePool />}
/>
{/*
<Route
path={`${APP_PATHS.CLASSIC_ADD_LIQ}/:currencyIdA/:currencyIdB?/:pairAddress?`}
element={<AddLiquidity />}
/>
*/}
<Route
path={`${APP_PATHS.CLASSIC_REMOVE_POOL}/:currencyIdA/:currencyIdB/:pairAddress`}
element={<RemoveLiquidity />}
Expand Down
10 changes: 0 additions & 10 deletions src/pages/PoolFinder/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import { Dots } from 'pages/MyPool/styleds'
import { usePairAdderByTokens } from 'state/user/hooks'
import { useTokenBalances } from 'state/wallet/hooks'
import { StyledInternalLink } from 'theme'
import { currencyId } from 'utils/currencyId'
import { useCurrencyConvertedToNative } from 'utils/dmm'

enum Fields {
Expand Down Expand Up @@ -160,15 +159,6 @@ export default function PoolFinder() {
</Text>
)}
</ButtonDropdownLight>
<StyledInternalLink
to={`${APP_PATHS.POOLS}/${networkInfo.route}/${!!currency0 ? currencyId(currency0, chainId) : undefined}/${
!!currency1 ? currencyId(currency1, chainId) : undefined
}?tab=classic`}
>
<Text textAlign="center">
<Trans>Add liquidity</Trans>
</Text>
</StyledInternalLink>
{pairs.filter(([pairState]) => pairState === PairState.LOADING).length > 0 && (
<LightCard padding="45px 10px">
<AutoColumn gap="sm" justify="center">
Expand Down

0 comments on commit baf8534

Please sign in to comment.