From 5ed1befc5327099fe7e316830e9c45939b1624d4 Mon Sep 17 00:00:00 2001
From: Maciek
Date: Fri, 11 Aug 2023 10:34:32 +0200
Subject: [PATCH] fix(trading): remove redundant connect wallet button (#4538)
---
libs/accounts/src/lib/transfer-container.tsx | 39 +-------------------
1 file changed, 2 insertions(+), 37 deletions(-)
diff --git a/libs/accounts/src/lib/transfer-container.tsx b/libs/accounts/src/lib/transfer-container.tsx
index 3766d9691..df41a6f21 100644
--- a/libs/accounts/src/lib/transfer-container.tsx
+++ b/libs/accounts/src/lib/transfer-container.tsx
@@ -7,21 +7,12 @@ import {
} from '@vegaprotocol/network-parameters';
import { useDataProvider } from '@vegaprotocol/data-provider';
import type { Transfer } from '@vegaprotocol/wallet';
-import {
- useVegaTransactionStore,
- useVegaWallet,
- useVegaWalletDialogStore,
-} from '@vegaprotocol/wallet';
+import { useVegaTransactionStore, useVegaWallet } from '@vegaprotocol/wallet';
import { useCallback, useMemo } from 'react';
import { accountsDataProvider } from './accounts-data-provider';
import { TransferForm } from './transfer-form';
import sortBy from 'lodash/sortBy';
-import {
- ExternalLink,
- Intent,
- Lozenge,
- Notification,
-} from '@vegaprotocol/ui-toolkit';
+import { Lozenge } from '@vegaprotocol/ui-toolkit';
export const TransferContainer = ({ assetId }: { assetId?: string }) => {
const { pubKey, pubKeys } = useVegaWallet();
@@ -32,10 +23,6 @@ export const TransferContainer = ({ assetId }: { assetId?: string }) => {
skip: !pubKey,
});
- const openVegaWalletDialog = useVegaWalletDialogStore(
- (store) => store.openVegaWalletDialog
- );
-
const create = useVegaTransactionStore((store) => store.create);
const transfer = useCallback(
@@ -74,28 +61,6 @@ export const TransferContainer = ({ assetId }: { assetId?: string }) => {
)}
{t('. If you are at all unsure, stop and seek advice.')}
- {!pubKey && (
-
-
- You need a{' '}
-
- Vega wallet
- {' '}
- to make a transfer.
-
- }
- buttonProps={{
- text: t('Connect wallet'),
- action: openVegaWalletDialog,
- dataTestId: 'order-connect-wallet',
- size: 'small',
- }}
- />
-
- )}
pk.publicKey) : null}