Skip to content

Commit

Permalink
remove truesight v1 (#1979)
Browse files Browse the repository at this point in the history
* remove truesight v1

* fix warning
  • Loading branch information
XiaoYhun authored Jun 13, 2023
1 parent a33fb01 commit 8346c6a
Show file tree
Hide file tree
Showing 68 changed files with 60 additions and 4,174 deletions.
1 change: 0 additions & 1 deletion .env.adpr
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ VITE_SENTRY_DNS=https://d94ee2d3c22043bdaec966758680b5a8@sentry.ops.kyberenginee

VITE_SERVICE_WORKER=true

VITE_TRUESIGHT_API=https://truesight.dev.kyberengineering.io
VITE_MIXPANEL_PROJECT_TOKEN=fca28a30cb98d872c2079f214955cd5e
VITE_REWARD_SERVICE_API=https://reward.dev.kyberengineering.io/api/v1

Expand Down
1 change: 0 additions & 1 deletion .env.dev
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ VITE_SENTRY_DNS=https://d94ee2d3c22043bdaec966758680b5a8@sentry.ops.kyberenginee

VITE_SERVICE_WORKER=true

VITE_TRUESIGHT_API=https://truesight.dev.kyberengineering.io
VITE_MIXPANEL_PROJECT_TOKEN=fca28a30cb98d872c2079f214955cd5e
VITE_REWARD_SERVICE_API=https://reward.dev.kyberengineering.io/api/v1

Expand Down
1 change: 0 additions & 1 deletion .env.production
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ VITE_SENTRY_DNS=https://d94ee2d3c22043bdaec966758680b5a8@sentry.ops.kyberenginee

VITE_SERVICE_WORKER=false

VITE_TRUESIGHT_API=https://truesight.kyberswap.com
VITE_MIXPANEL_PROJECT_TOKEN=ff1eea26c19dcf4a7c35ebbc8631e714
VITE_REWARD_SERVICE_API=https://rewards.kyberswap.com/api/v1

Expand Down
1 change: 0 additions & 1 deletion .env.stg
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ VITE_AGGREGATOR_STATS_API=https://aggregator-stats.kyberswap.com
VITE_SENTRY_DNS=https://d94ee2d3c22043bdaec966758680b5a8@sentry.ops.kyberengineering.io/4

VITE_SERVICE_WORKER=false
VITE_TRUESIGHT_API=https://truesight.stg.kyberengineering.io
VITE_MIXPANEL_PROJECT_TOKEN=ff1eea26c19dcf4a7c35ebbc8631e714
VITE_REWARD_SERVICE_API=https://reward.stg.kyberengineering.io/api/v1

Expand Down
2 changes: 1 addition & 1 deletion src/components/ApproveMessage/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@ import { ChevronDown, ChevronUp } from 'react-feather'
import { useToggle } from 'react-use'
import styled from 'styled-components'

import { TruncatedText } from 'components'
import Card from 'components/Card'
import LightBulbEffect from 'components/Icons/LightBulbEffect'
import { RowBetween } from 'components/Row'
import { useActiveWeb3React } from 'hooks/index'
import useTheme from 'hooks/useTheme'
import { TruncatedText } from 'pages/TrueSight/components/TrendingSoonLayout/TrendingSoonTokenItem'
import { ExternalLink, TYPE } from 'theme/index'
import { getEtherscanLink, isAddress, shortenAddress } from 'utils/index'

Expand Down
93 changes: 0 additions & 93 deletions src/components/ModalContractAddress/index.tsx

This file was deleted.

2 changes: 1 addition & 1 deletion src/components/SwapForm/SwapModal/SwapDetails/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { Repeat } from 'react-feather'
import { Flex, Text } from 'rebass'
import { BuildRouteData } from 'services/route/types/buildRoute'

import { TruncatedText } from 'components'
import { AutoColumn } from 'components/Column'
import { RowBetween, RowFixed } from 'components/Row'
import { useSwapFormContext } from 'components/SwapForm/SwapFormContext'
Expand All @@ -17,7 +18,6 @@ import { StyledBalanceMaxMini } from 'components/swapv2/styleds'
import { CHAINS_SUPPORT_FEE_CONFIGS } from 'constants/index'
import { useActiveWeb3React } from 'hooks'
import useTheme from 'hooks/useTheme'
import { TruncatedText } from 'pages/TrueSight/components/TrendingSoonLayout/TrendingSoonTokenItem'
import { ExternalLink, TYPE } from 'theme'
import { DetailedRouteSummary } from 'types/route'
import { formattedNum } from 'utils'
Expand Down
153 changes: 0 additions & 153 deletions src/components/TrueSightNetworkModal/index.tsx

This file was deleted.

50 changes: 50 additions & 0 deletions src/components/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
import { Text } from 'rebass'
import styled from 'styled-components'

export const TruncatedText = styled(Text)`
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
`
export const OptionsContainer = styled.div`
display: flex;
position: absolute;
bottom: -6px;
right: 0;
border-radius: 16px;
flex-direction: column;
background: ${({ theme }) => theme.tableHeader};
overflow: hidden;
z-index: 9999;
width: 100%;
box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
left: 50%;
transform: translate(-50%, 100%);
min-width: max-content;
& > * {
cursor: pointer;
padding: 12px;
&:hover {
background: ${({ theme }) => theme.background};
}
}
& div {
min-width: max-content !important;
}
.no-hover-effect {
cursor: default;
&:hover {
background: inherit;
}
}
.no-hover-effect-divider {
&:hover {
background: ${({ theme }) => theme.border};
}
}
`
2 changes: 1 addition & 1 deletion src/components/swapv2/SwapModalFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { useMemo, useState } from 'react'
import { Repeat } from 'react-feather'
import { Flex, Text } from 'rebass'

import { TruncatedText } from 'components'
import { ButtonError } from 'components/Button'
import { GreyCard } from 'components/Card'
import { AutoColumn } from 'components/Column'
Expand All @@ -14,7 +15,6 @@ import { MouseoverTooltip, TextDashed } from 'components/Tooltip'
import { Dots } from 'components/swapv2/styleds'
import { useActiveWeb3React } from 'hooks'
import useTheme from 'hooks/useTheme'
import { TruncatedText } from 'pages/TrueSight/components/TrendingSoonLayout/TrendingSoonTokenItem'
import { Field } from 'state/swap/actions'
import { useCheckStablePairSwap, useEncodeSolana } from 'state/swap/hooks'
import { useDegenModeManager } from 'state/user/hooks'
Expand Down
1 change: 0 additions & 1 deletion src/constants/env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ export const BLOCK_SERVICE_API = required('BLOCK_SERVICE_API')
export const PRICE_CHART_API = required('PRICE_CHART_API')
export const AGGREGATOR_STATS_API = required('AGGREGATOR_STATS_API')
export const NOTIFICATION_API = required('NOTIFICATION_API')
export const TRUESIGHT_API = required('TRUESIGHT_API')
export const TRANSAK_URL = required('TRANSAK_URL')
export const TRANSAK_API_KEY = required('TRANSAK_API_KEY')
export const TYPE_AND_SWAP_URL = required('TYPE_AND_SWAP_URL')
Expand Down
Loading

0 comments on commit 8346c6a

Please sign in to comment.