Skip to content

Commit

Permalink
feat: change options & multipliers to options
Browse files Browse the repository at this point in the history
  • Loading branch information
sergei-deriv committed May 23, 2024
1 parent e47e6db commit 06f7551
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion packages/appstore/src/helpers/account-helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,6 @@ export const getSortedAccountList = (account_list: TAccountProps, accounts: TAcc
};

export const getPlatformToggleOptions = (is_eu_title: boolean) => [
{ text: is_eu_title ? localize('Multipliers') : localize('Options & Multipliers'), value: 'options' },
{ text: is_eu_title ? localize('Multipliers') : localize('Options'), value: 'options' },
{ text: localize('CFDs'), value: 'cfd' },
];
11 changes: 4 additions & 7 deletions packages/appstore/src/modules/traders-hub/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,9 @@ import MainTitleBar from 'Components/main-title-bar';
import OptionsAndMultipliersListing from 'Components/options-multipliers-listing';
import ButtonToggleLoader from 'Components/pre-loader/button-toggle-loader';
import classNames from 'classnames';
import './traders-hub.scss';
import { useContentFlag, useGrowthbookFeatureFlag } from '@deriv/hooks';
import { getPlatformToggleOptions } from 'Helpers';
import './traders-hub.scss';

const TradersHub = observer(() => {
const { traders_hub, client, ui } = useStore();
Expand Down Expand Up @@ -80,12 +81,8 @@ const TradersHub = observer(() => {
}, []);

const eu_title = is_eu_demo || is_eu_real || is_eu_user;
const getPlatformToggleOptions = () => [
{ text: eu_title ? localize('Multipliers') : localize('Options'), value: 'options' },
{ text: localize('CFDs'), value: 'cfd' },
];
const platform_toggle_options = getPlatformToggleOptions();
const platform_toggle_options_eu = getPlatformToggleOptions().reverse();
const platform_toggle_options = getPlatformToggleOptions(eu_title);
const platform_toggle_options_eu = getPlatformToggleOptions(eu_title).reverse();

const platformTypeChange = (event: {
target: {
Expand Down

0 comments on commit 06f7551

Please sign in to comment.