Skip to content

Commit

Permalink
fix: remove shapeshift legacy wallet (#8903)
Browse files Browse the repository at this point in the history
  • Loading branch information
NeOMakinG authored Feb 20, 2025
1 parent 47c3079 commit ff6a7af
Show file tree
Hide file tree
Showing 19 changed files with 3 additions and 642 deletions.
1 change: 0 additions & 1 deletion .env.base
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ REACT_APP_FEATURE_THORCHAIN_LENDING_BORROW=false
REACT_APP_FEATURE_THORCHAIN_LENDING_REPAY=false
REACT_APP_FEATURE_THORCHAINSWAP_LONGTAIL=true
REACT_APP_FEATURE_THORCHAINSWAP_L1_TO_LONGTAIL=true
REACT_APP_FEATURE_SHAPESHIFT_MOBILE_WALLET=false
REACT_APP_FEATURE_THORCHAIN_LP=true
REACT_APP_FEATURE_THORCHAIN_LP_DEPOSIT=true
REACT_APP_FEATURE_THORCHAIN_LP_WITHDRAW=true
Expand Down
1 change: 0 additions & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,6 @@ const validators = {
REACT_APP_FEATURE_THORCHAIN_LP_WITHDRAW: bool({ default: false }),
REACT_APP_FEATURE_THORCHAINSWAP_LONGTAIL: bool({ default: false }),
REACT_APP_FEATURE_THORCHAINSWAP_L1_TO_LONGTAIL: bool({ default: false }),
REACT_APP_FEATURE_SHAPESHIFT_MOBILE_WALLET: bool({ default: false }),
REACT_APP_FEATURE_ACCOUNT_MANAGEMENT: bool({ default: false }),
REACT_APP_FEATURE_ACCOUNT_MANAGEMENT_LEDGER: bool({ default: false }),
REACT_APP_FEATURE_RFOX: bool({ default: false }),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ export const MobileCreate: React.FC<MobileCreateProps> = props => {
try {
setIsSaving(true)
vault.label = label
history.push('/mobile/create-test', { vault, isLegacyWallet: false })
history.push('/mobile/create-test', { vault })
} catch (e) {
console.log(e)
} finally {
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,24 +1,15 @@
import { ArrowForwardIcon } from '@chakra-ui/icons'
import type { ResponsiveValue } from '@chakra-ui/react'
import { Button, Divider, Flex, ModalBody, ModalHeader, Stack } from '@chakra-ui/react'
import type { Property } from 'csstype'
import { Button, Divider, ModalBody, ModalHeader, Stack } from '@chakra-ui/react'
import { useCallback, useEffect, useState } from 'react'
import { useTranslate } from 'react-polyglot'
import type { RouteComponentProps } from 'react-router'
import { Text } from 'components/Text'
import { useFeatureFlag } from 'hooks/useFeatureFlag/useFeatureFlag'

import { getWalletCount } from '../mobileMessageHandlers'

const directionProp: ResponsiveValue<Property.FlexDirection> = ['column', 'row']
const mlProp = [0, 1.5]

const arrowForwardIcon = <ArrowForwardIcon />

export const MobileStart = ({ history }: RouteComponentProps) => {
const isShapeShiftMobileWalletEnabled = useFeatureFlag('ShapeShiftMobileWallet')
const [hasLocalWallet, setHasLocalWallet] = useState<boolean>(false)
const translate = useTranslate()

useEffect(() => {
;(async () => {
Expand All @@ -35,7 +26,6 @@ export const MobileStart = ({ history }: RouteComponentProps) => {
const handleLoad = useCallback(() => history.push('/mobile/load'), [history])
const handleCreate = useCallback(() => history.push('/mobile/create'), [history])
const handleImport = useCallback(() => history.push('/mobile/import'), [history])
const handleLogin = useCallback(() => history.push('/mobile/legacy/login'), [history])

return (
<>
Expand Down Expand Up @@ -83,29 +73,6 @@ export const MobileStart = ({ history }: RouteComponentProps) => {
>
<Text translation={'walletProvider.shapeShift.start.import'} />
</Button>
{isShapeShiftMobileWalletEnabled && (
<>
<Divider mt={4} />
<Flex
direction={directionProp}
mt={2}
pt={4}
justifyContent='center'
alignItems='center'
>
<Text translation={'walletProvider.shapeShift.legacy.haveMobileWallet'} />
<Button
variant='link'
ml={mlProp}
borderTopRadius='none'
colorScheme='blue'
onClick={handleLogin}
>
{translate('common.login')}
</Button>
</Flex>
</>
)}
</Stack>
</ModalBody>
</>
Expand Down
1 change: 0 additions & 1 deletion src/context/WalletProvider/MobileWallet/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ export type RevocableObject<T> = T & crypto.Isolation.Engines.Default.Revocable
export interface MobileLocationState {
// This is passed between setup screens and then revoked when done
vault?: RevocableWallet
isLegacyWallet?: boolean
error?: {
message: string
}
Expand Down

This file was deleted.

Loading

0 comments on commit ff6a7af

Please sign in to comment.