Skip to content

Commit 34f5909

Browse files
feat(ccr): support evm coins to eth ccr recovery transaction
Ticket: COIN-111
1 parent 5e06563 commit 34f5909

File tree

12 files changed

+493
-384
lines changed

12 files changed

+493
-384
lines changed

src/components/CryptocurrencyIcon/CryptocurrencyIcon.tsx

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ export interface CryptocurrencyIconProps {
3333
| 'zec'
3434
| 'zeta'
3535
| 'hbar'
36-
| 'algo';
36+
| 'algo'
37+
| 'etc';
3738
Size: 'small' | 'medium' | 'large';
3839
}
3940

@@ -1697,10 +1698,7 @@ export function CryptocurrencyIcon({
16971698
<g fill="none" fill-rule="evenodd">
16981699
<use fill="#000" filter="url(#a)" xlinkHref="#b" />
16991700
<use fill="#000" xlinkHref="#b" />
1700-
<use
1701-
fill="url(#c)"
1702-
xlinkHref="#b"
1703-
/>
1701+
<use fill="url(#c)" xlinkHref="#b" />
17041702
<circle
17051703
stroke-opacity=".097"
17061704
stroke="#000"
@@ -1721,6 +1719,35 @@ export function CryptocurrencyIcon({
17211719
</g>
17221720
</svg>
17231721
);
1722+
case 'etc':
1723+
return (
1724+
<svg
1725+
xmlns="http://www.w3.org/2000/svg"
1726+
width="32"
1727+
height="32"
1728+
viewBox="0 0 32 32"
1729+
>
1730+
<g fill="none" fill-rule="evenodd">
1731+
<circle cx="16" cy="16" r="16" fill="#328332" />
1732+
<g fill="#FFF">
1733+
<path
1734+
fill-rule="nonzero"
1735+
d="M15.989 16.553l-6.721-.577 6.72-3.802v4.379zm0 4.46v6.94C13.652 24.315 11.076 20.311 9 17.07c2.45 1.38 5.008 2.823 6.989 3.944zm0-10.068L9 14.845 15.989 4v6.945z"
1736+
/>
1737+
<path
1738+
fill-opacity=".601"
1739+
fill-rule="nonzero"
1740+
d="M22.71 15.976l-6.721.577v-4.379l6.72 3.802zm-6.721 5.038c1.98-1.12 4.537-2.564 6.988-3.944-2.076 3.242-4.652 7.246-6.988 10.882v-6.938zm0-10.069V4l6.988 10.845-6.988-3.9z"
1741+
/>
1742+
<path opacity=".2" d="M15.989 16.553l6.72-.577-6.72 3.775z" />
1743+
<path
1744+
opacity=".603"
1745+
d="M15.988 16.553l-6.721-.577 6.721 3.775z"
1746+
/>
1747+
</g>
1748+
</g>
1749+
</svg>
1750+
);
17241751
default:
17251752
return null;
17261753
}

src/containers/App.tsx

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,7 @@ import { NonBitGoRecoveryIndex } from './NonBitGoRecoveryIndex';
88
import { SuccessfulRecovery } from './SuccessfulRecovery';
99
import { WrongChainRecovery } from './WrongChainRecovery';
1010
import { EvmCrossChainRecoveryIndex } from './EvmCrossChainRecoveryIndex';
11-
import { EvmCrossChainRecoveryCoin } from './EvmCrossChainRecoveryCoin';
12-
import { EvmCrossChainRecoveryWallet } from './EvmCrossChainRecoveryWallet/EvmCrossChainRecoveryWallet';
11+
import { EvmCrossChainRecoveryWallet } from './EvmCrossChainRecoveryWallet';
1312
import { BuildUnsignedConsolidationIndex } from './BuildUnsignedConsolidation';
1413
import { BuildUnsignedConsolidationCoin } from '~/containers/BuildUnsignedConsolidation/BuildUnsignedConsolidationCoin';
1514
import { CreateBroadcastableTransactionIndex } from '~/containers/CreateBroadcastableTransaction';
@@ -101,8 +100,7 @@ export default function App() {
101100
>
102101
<Route index element={<EvmCrossChainRecoveryIndex />} />
103102
<Route path=":wallet" element={<EvmCrossChainRecoveryWallet />} />
104-
<Route path=":wallet/:coin" element={<EvmCrossChainRecoveryCoin />} />
105-
<Route path=":coin/success" element={<SuccessfulRecovery />} />
103+
<Route path=":wallet/success" element={<SuccessfulRecovery />} />
106104
</Route>
107105
<Route
108106
path="/:env/wrong-chain-recovery"

src/containers/EvmCrossChainRecoveryCoin/EvmCrossChainRecoveryBaseForm.tsx

Lines changed: 0 additions & 74 deletions
This file was deleted.

0 commit comments

Comments
 (0)