Skip to content

Commit

Permalink
Hirad/94054/Added localize to demo text (deriv-com#8395)
Browse files Browse the repository at this point in the history
* fix: added localize to demo text

* fix: added localize to the selected account type

---------

Co-authored-by: Farrah Mae Ochoa <82315152+farrah-deriv@users.noreply.github.com>
Co-authored-by: Nijil Nirmal <62882794+nijil-deriv@users.noreply.github.com>
  • Loading branch information
3 people authored May 1, 2023
1 parent 48ac0b4 commit 46df180
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React from 'react';
import classNames from 'classnames';
import { getStatusBadgeConfig } from '@deriv/account';
import { Text, StatusBadge } from '@deriv/components';
import TradigPlatformIconProps from 'Assets/svgs/trading-platform';
Expand All @@ -8,7 +9,7 @@ import TradingAppCardActions, { Actions } from './trading-app-card-actions';
import { AvailableAccount, TDetailsOfEachMT5Loginid } from 'Types';
import { useStores } from 'Stores/index';
import { observer } from 'mobx-react-lite';
import classNames from 'classnames';
import { localize } from '@deriv/translations';
import { CFD_PLATFORMS, ContentFlag, getStaticUrl } from '@deriv/shared';

const TradingAppCard = ({
Expand Down Expand Up @@ -70,7 +71,7 @@ const TradingAppCard = ({
<div className='trading-app-card__details'>
<div>
<Text className='title' size='xs' line_height='s' color='prominent'>
{!is_real && sub_title ? `${sub_title} Demo` : sub_title}
{!is_real && sub_title ? `${sub_title} ${localize('Demo')}` : sub_title}
</Text>
{short_code_and_region && (
<Text
Expand All @@ -90,7 +91,7 @@ const TradingAppCard = ({
weight='bold'
color={action_type === 'trade' ? 'prominent' : 'general'}
>
{!is_real && !sub_title && !is_deriv_platform ? `${name} Demo` : name}
{!is_real && !sub_title && !is_deriv_platform ? `${name} ${localize('Demo')}` : name}
</Text>
<Text className='description' color={'general'} size='xxs' line_height='m'>
{app_desc}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const DemoAccountCard = () => {
icon='VIRTUAL'
title={
<Text className='demo-account-card__title' size='xs' line_height='s'>
{selected_account_type}
{localize(selected_account_type)}
</Text>
}
actions={
Expand Down

0 comments on commit 46df180

Please sign in to comment.