Skip to content

Commit

Permalink
Renamed add account button and fixes its condition
Browse files Browse the repository at this point in the history
  • Loading branch information
hirad-deriv committed Jul 8, 2022
1 parent c1a9dc5 commit bfbc081
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/cfd/src/Components/cfd-account-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const account_icons: { [key: string]: TAccountIconValues } = {
},
};

const AddTradeServerButton = React.forwardRef<
const AddAccountButton = React.forwardRef<
HTMLDivElement,
{ onSelectAccount: () => void; is_disabled?: boolean; type: string }
>(({ onSelectAccount, is_disabled, type }, ref) => {
Expand All @@ -55,7 +55,7 @@ const AddTradeServerButton = React.forwardRef<
);
});

AddTradeServerButton.displayName = 'AddTradeServerButton';
AddAccountButton.displayName = 'AddAccountButton';

const SpecBox = ({ value, is_bold }: TSpecBoxProps) => (
<div className='cfd-account-card__spec-box'>
Expand Down Expand Up @@ -510,7 +510,7 @@ const CFDAccountCardComponent = ({
<React.Fragment>
{is_logged_in && existing_data && (
<MobileWrapper>
<AddTradeServerButton
<AddAccountButton
ref={button_ref}
onSelectAccount={onSelectAccount}
is_disabled={has_cfd_account_error}
Expand All @@ -522,7 +522,7 @@ const CFDAccountCardComponent = ({
</div>
{is_logged_in && existing_data && (
<DesktopWrapper>
<AddTradeServerButton
<AddAccountButton
ref={button_ref}
onSelectAccount={onSelectAccount}
is_disabled={has_cfd_account_error}
Expand Down

0 comments on commit bfbc081

Please sign in to comment.