diff --git a/i18n/en/code.json b/i18n/en/code.json
index 8b10e554e..9fa2d6a2f 100644
--- a/i18n/en/code.json
+++ b/i18n/en/code.json
@@ -930,5 +930,263 @@
},
"Register tokens": {
"message": "Register tokens"
+ },
+ "Account type": {
+ "message": "Account type"
+ },
+ "Add new token": {
+ "message": "Add new token"
+ },
+ "Home": {
+ "message": "Home"
+ },
+ "API Explorer": {
+ "message": "API Explorer"
+ },
+ "Enter your app name.": {
+ "message": "Enter your app name."
+ },
+ "Your markup value must be equal to or above 0.00": {
+ "message": "Your markup value must be equal to or above 0.00"
+ },
+ "Your markup value must be no more than 3.00.": {
+ "message": "Your markup value must be no more than 3.00."
+ },
+ "Authorisation required": {
+ "message": "Authorisation required"
+ },
+ "Invalid JSON": {
+ "message": "Invalid JSON"
+ },
+ "Applications": {
+ "message": "Applications"
+ },
+ "API tokens": {
+ "message": "API tokens"
+ },
+ "Edit application": {
+ "message": "Edit application"
+ },
+ "Create token": {
+ "message": "Create token"
+ },
+ "Do not share tokens with the admin scope with unauthorized parties.": {
+ "message": "Do not share tokens with the admin scope with unauthorized parties."
+ },
+ "Enable admin access": {
+ "message": "Enable admin access"
+ },
+ "Are you sure you want to enable admin scope for your token?": {
+ "message": "Are you sure you want to enable admin scope for your token?"
+ },
+ "Granting admin access gives your token full control over your account and increases security risks. We recommend granting this level of access only when it's essential.": {
+ "message": "Granting admin access gives your token full control over your account and increases security risks. We recommend granting this level of access only when it's essential."
+ },
+ "Trading Information": {
+ "message": "Trading Information"
+ },
+ "App Dashboard": {
+ "message": "App Dashboard"
+ },
+ "Start using Deriv API to bring custom integrations and powerful automation to your apps.": {
+ "message": "Start using Deriv API to bring custom integrations and powerful automation to your apps."
+ },
+ "Accounts": {
+ "message": "Accounts"
+ },
+ "Account Type": {
+ "message": "Account Type"
+ },
+ "Token scopes": {
+ "message": "Token scopes"
+ },
+ "Last used": {
+ "message": "Last used"
+ },
+ "API token manager": {
+ "message": "API token manager"
+ },
+ "Access all your API token details here.": {
+ "message": "Access all your API token details here."
+ },
+ "Create new token": {
+ "message": "Create new token"
+ },
+ "Never": {
+ "message": "Never"
+ },
+ "You'll have full access to your clients' information.": {
+ "message": "You'll have full access to your clients' information."
+ },
+ "You'll be able to buy and sell contracts on your clients' behalf.": {
+ "message": "You'll be able to buy and sell contracts on your clients' behalf."
+ },
+ "You‘ll be able to view your clients’ trading information, including their account balance.": {
+ "message": "You‘ll be able to view your clients’ trading information, including their account balance."
+ },
+ "You‘ll be able to perform deposits and withdrawals on your clients’ behalf.": {
+ "message": "You‘ll be able to perform deposits and withdrawals on your clients’ behalf."
+ },
+ "Full account access, including the access to manage security tokens.": {
+ "message": "Full account access, including the access to manage security tokens."
+ },
+ "Enter your app's name": {
+ "message": "Enter your app's name"
+ },
+ "Use only letters, numbers, spaces, and underscores.": {
+ "message": "Use only letters, numbers, spaces, and underscores."
+ },
+ "Your app's name can contain up to 48 characters.": {
+ "message": "Your app's name can contain up to 48 characters."
+ },
+ "Your app's name cannot contain the words \"Binary\", \"Deriv\", or any of their variations.": {
+ "message": "Your app's name cannot contain the words \"Binary\", \"Deriv\", or any of their variations."
+ },
+ "You must accept the terms and conditions.": {
+ "message": "You must accept the terms and conditions."
+ },
+ "Filter by OAuth scopes": {
+ "message": "Filter by OAuth scopes"
+ },
+ "OAuth Scopes": {
+ "message": "OAuth Scopes"
+ },
+ "OAuth Redirect URL": {
+ "message": "OAuth Redirect URL"
+ },
+ "Select your account type:": {
+ "message": "Select your account type:"
+ },
+ "Select scopes based on the access you need:": {
+ "message": "Select scopes based on the access you need:"
+ },
+ "No keywords \"deriv\" or \"binary\" or words that look similar, e.g. \"_binary_\" or \"d3riv\" are allowed.": {
+ "message": "No keywords \"deriv\" or \"binary\" or words that look similar, e.g. \"_binary_\" or \"d3riv\" are allowed."
+ },
+ "Select an account type.": {
+ "message": "Select an account type."
+ },
+ "Enter your token name.": {
+ "message": "Enter your token name."
+ },
+ "Enter the name of the application you want to register:": {
+ "message": "Enter the name of the application you want to register:"
+ },
+ "Add a markup to the price of each trade to help you earn a commission. Enter your markup percentage below. Learn more about markup calculations in our detailed": {
+ "message": "Add a markup to the price of each trade to help you earn a commission. Enter your markup percentage below. Learn more about markup calculations in our detailed"
+ },
+ "Markup is only available for real accounts and trading applications.": {
+ "message": "Markup is only available for real accounts and trading applications."
+ },
+ "OAuth settings": {
+ "message": "OAuth settings"
+ },
+ "Log in to your app using your Deriv account without an API token. With OAuth, third-party applications can securely authorise access without requiring password sharing, enhancing both security and user control.": {
+ "message": "Log in to your app using your Deriv account without an API token. With OAuth, third-party applications can securely authorise access without requiring password sharing, enhancing both security and user control."
+ },
+ "Use OAuth if your application requires other users to sign in.": {
+ "message": "Use OAuth if your application requires other users to sign in."
+ },
+ "Authorisation URL is mandatory to enable OAuth on your app.": {
+ "message": "Authorisation URL is mandatory to enable OAuth on your app."
+ },
+ "URL Configuration": {
+ "message": "URL Configuration"
+ },
+ "To set up OAuth for your app, specify the URL where users should be redirected after authorisation.": {
+ "message": "To set up OAuth for your app, specify the URL where users should be redirected after authorisation."
+ },
+ "Authorisation URL": {
+ "message": "Authorisation URL"
+ },
+ "If your app includes verification logic, enter the email verification URL below (e.g. for account opening, verification, and password reset):": {
+ "message": "If your app includes verification logic, enter the email verification URL below (e.g. for account opening, verification, and password reset):"
+ },
+ "If provided, the verification URL will be appended with a token and sent to the user's email. Otherwise, the authorisation URL with the token will be used.": {
+ "message": "If provided, the verification URL will be appended with a token and sent to the user's email. Otherwise, the authorisation URL with the token will be used."
+ },
+ "Scopes of authorisation": {
+ "message": "Scopes of authorisation"
+ },
+ "You'll be able to process your clients’ payments.": {
+ "message": "You'll be able to process your clients’ payments."
+ },
+ "Grant admin access only when it’s essential for your app's workflow.": {
+ "message": "Grant admin access only when it’s essential for your app's workflow."
+ },
+ "Update application": {
+ "message": "Update application"
+ },
+ "Enable admin access for your app?": {
+ "message": "Enable admin access for your app?"
+ },
+ "For better security, enable admin access only when it's necessary. This approach limits access to client activities, minimising risks and safeguarding both workflow efficiency and client trust.": {
+ "message": "For better security, enable admin access only when it's necessary. This approach limits access to client activities, minimising risks and safeguarding both workflow efficiency and client trust."
+ },
+ "Enter your token name": {
+ "message": "Enter your token name"
+ },
+ "Token name": {
+ "message": "Token name"
+ },
+ "App name (A to Z)": {
+ "message": "App name (A to Z)"
+ },
+ "App name (Z to A)": {
+ "message": "App name (Z to A)"
+ },
+ "App ID (A to Z)": {
+ "message": "App ID (A to Z)"
+ },
+ "App ID (Z to A)": {
+ "message": "App ID (Z to A)"
+ },
+ "All": {
+ "message": "All"
+ },
+ "(No scope)": {
+ "message": "(No scope)"
+ },
+ "Sort by": {
+ "message": "Sort by"
+ },
+ "Apply": {
+ "message": "Apply"
+ },
+ "Error!": {
+ "message": "Error!"
+ },
+ "Success!": {
+ "message": "Success!"
+ },
+ "Ok": {
+ "message": "Ok"
+ },
+ "Configure now": {
+ "message": "Configure now"
+ },
+ "Maybe later": {
+ "message": "Maybe later"
+ },
+ "Application registered successfully!": {
+ "message": "Application registered successfully!"
+ },
+ "Ready to take the next step?": {
+ "message": "Ready to take the next step?"
+ },
+ "Optimise your app's capabilities by:": {
+ "message": "Optimise your app's capabilities by:"
+ },
+ "Creating an API token to use with your application.": {
+ "message": "Creating an API token to use with your application."
+ },
+ "Adding OAuth authentication in your app.": {
+ "message": "Adding OAuth authentication in your app."
+ },
+ "Selecting the scopes of OAuth authorisation for your app.": {
+ "message": "Selecting the scopes of OAuth authorisation for your app."
+ },
+ "Note: You can make these changes later through the dashboard.": {
+ "message": "Note: You can make these changes later through the dashboard."
}
}
diff --git a/src/components/AccountSwitcher/index.tsx b/src/components/AccountSwitcher/index.tsx
index 100247741..279ae4ae3 100644
--- a/src/components/AccountSwitcher/index.tsx
+++ b/src/components/AccountSwitcher/index.tsx
@@ -3,10 +3,10 @@ import { isNotDemoCurrency } from '@site/src/utils';
import useAuthContext from '@site/src/hooks/useAuthContext';
import useOnClickOutside from '@site/src/hooks/useOnClickOutside';
import CurrencyIcon from '../CurrencyIcon';
-import AccountDropdown from '../CustomSelectDropdown/account-dropdown/AccountDropdown';
import styles from './account_switcher.module.scss';
import { InputDropdown } from '@deriv-com/quill-ui';
import useAccountSelector from '@site/src/hooks/useAccountSelector';
+import { translate } from '@docusaurus/Translate';
const AccountSwitcher = () => {
const { onSelectAccount } = useAccountSelector();
@@ -30,7 +30,7 @@ const AccountSwitcher = () => {
return (
}
placeholder={currentLoginAccount.name}
diff --git a/src/components/ApiTokenNavbarItem/index.tsx b/src/components/ApiTokenNavbarItem/index.tsx
index 9a4c40437..3f8e10a15 100644
--- a/src/components/ApiTokenNavbarItem/index.tsx
+++ b/src/components/ApiTokenNavbarItem/index.tsx
@@ -8,6 +8,7 @@ import useAppManager from '@site/src/hooks/useAppManager';
import styles from './api_token_switcher.module.scss';
import RenderOfficialContents from '../RenderOfficialContents';
import { TDashboardTab } from '@site/src/contexts/app-manager/app-manager.context';
+import Translate from '@docusaurus/Translate';
const ApiTokenNavbarItem = () => {
const { is_logged_in, is_authorized } = useAuthContext();
@@ -39,7 +40,7 @@ const ApiTokenNavbarItem = () => {
className={styles.createToken}
to='/dashboard'
>
- Add new token
+ Add new token
)}
diff --git a/src/features/Apiexplorer/LoginDialog/index.tsx b/src/features/Apiexplorer/LoginDialog/index.tsx
index eb64560b0..fad17a52d 100644
--- a/src/features/Apiexplorer/LoginDialog/index.tsx
+++ b/src/features/Apiexplorer/LoginDialog/index.tsx
@@ -2,7 +2,7 @@ import React, { useCallback } from 'react';
import { Modal, Button } from '@deriv/ui';
import useLoginUrl from '@site/src/hooks/useLoginUrl';
import styles from './LoginDialog.module.scss';
-import Translate from '@docusaurus/Translate';
+import Translate, { translate } from '@docusaurus/Translate';
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
type TLoginDialog = {
@@ -34,7 +34,7 @@ export const LoginDialog = ({ setToggleModal }: TLoginDialog) => {
diff --git a/src/features/Apiexplorer/RequestJSONBox/index.tsx b/src/features/Apiexplorer/RequestJSONBox/index.tsx
index ca5b9f59f..4f79766c3 100644
--- a/src/features/Apiexplorer/RequestJSONBox/index.tsx
+++ b/src/features/Apiexplorer/RequestJSONBox/index.tsx
@@ -5,7 +5,7 @@ import RequestResponseRenderer from '../RequestResponseRenderer';
import style from './RequestJSONBox.module.scss';
import SubscribeRenderer from '../SubscribeRenderer';
import { TSocketSubscribableEndpointNames } from '@site/src/configs/websocket/types';
-import Translate from '@docusaurus/Translate';
+import Translate, { translate } from '@docusaurus/Translate';
interface TRequestJSONBox {
handleChange: React.ChangeEventHandler;
@@ -33,7 +33,7 @@ function RequestJSONBox({
diff --git a/src/features/Apiexplorer/ValidDialog/index.tsx b/src/features/Apiexplorer/ValidDialog/index.tsx
index 789044c74..a6a1d47fc 100644
--- a/src/features/Apiexplorer/ValidDialog/index.tsx
+++ b/src/features/Apiexplorer/ValidDialog/index.tsx
@@ -1,7 +1,7 @@
import React, { useCallback } from 'react';
import { Modal } from '@deriv/ui';
import styles from '../LoginDialog/LoginDialog.module.scss';
-import Translate from '@docusaurus/Translate';
+import Translate, { translate } from '@docusaurus/Translate';
type TValidDialog = {
setIsNotValid: React.Dispatch>;
@@ -24,7 +24,7 @@ export const ValidDialog = ({ setIsNotValid, setToggleModal }: TValidDialog) =>
diff --git a/src/features/Apiexplorer/index.tsx b/src/features/Apiexplorer/index.tsx
index 664a9a928..01e521063 100644
--- a/src/features/Apiexplorer/index.tsx
+++ b/src/features/Apiexplorer/index.tsx
@@ -7,6 +7,7 @@ import SchemaWrapper from './Schema/SchemaWrapper';
import RequestJSONBox from './RequestJSONBox';
import useDynamicImportJSON from '@site/src/hooks/useDynamicImportJSON';
import Footer from '@site/src/components/Footer';
+import Translate from '@docusaurus/Translate';
export default function ApiExplorerFeatures() {
const {
text_data,
@@ -24,12 +25,12 @@ export default function ApiExplorerFeatures() {
Home,
href: '/',
target: '_self',
},
{
- content: 'API explorer',
+ content: API explorer,
href: '/api-explorer',
target: '_self',
},
@@ -39,7 +40,7 @@ export default function ApiExplorerFeatures() {
- Are you sure you want to enable admin scope for your token?
+
+ Are you sure you want to enable admin scope for your token?
+
- Granting admin access gives your token full control over your account and increases
- security risks. We recommend granting this level of access only when it's
- essential.
+
+ Granting admin access gives your token full control over your account and increases
+ security risks. We recommend granting this level of access only when it's
+ essential.
+
diff --git a/src/features/dashboard/components/ApiTokenForm/CreateTokenField/index.tsx b/src/features/dashboard/components/ApiTokenForm/CreateTokenField/index.tsx
index afc815680..7e04825e2 100644
--- a/src/features/dashboard/components/ApiTokenForm/CreateTokenField/index.tsx
+++ b/src/features/dashboard/components/ApiTokenForm/CreateTokenField/index.tsx
@@ -8,6 +8,7 @@ import TokenCreationDialogSuccess from '../../Dialogs/TokenCreationDialogSuccess
import TokenNameRestrictions from '../../TokenNameRestrictions/TokenNameRestrictions';
import CustomErrors from './CustomErrors';
import styles from '../api-token.form.module.scss';
+import { translate } from '@docusaurus/Translate';
type TCreateTokenField = {
register: UseFormRegisterReturn;
@@ -88,8 +89,8 @@ const CreateTokenField = ({
>
diff --git a/src/features/dashboard/components/ApiTokenForm/api-token.form.tsx b/src/features/dashboard/components/ApiTokenForm/api-token.form.tsx
index f837d914e..eae4ca952 100644
--- a/src/features/dashboard/components/ApiTokenForm/api-token.form.tsx
+++ b/src/features/dashboard/components/ApiTokenForm/api-token.form.tsx
@@ -1,16 +1,16 @@
import React, { HTMLAttributes, useCallback, useEffect, useState } from 'react';
-import { Text } from '@deriv/ui';
+import * as yup from 'yup';
+import Translate, { translate } from '@docusaurus/Translate';
import { useForm } from 'react-hook-form';
-import Spinner from '@site/src/components/Spinner';
+import { Text } from '@deriv/ui';
import { yupResolver } from '@hookform/resolvers/yup';
import { scopesObjectToArray } from '@site/src/utils';
-import ApiTokenCard from '../ApiTokenCard';
+import Spinner from '@site/src/components/Spinner';
import useCreateToken from '@site/src/features/dashboard/hooks/useCreateToken';
-import * as yup from 'yup';
-import styles from './api-token.form.module.scss';
import TokenNameRestrictions from '../TokenNameRestrictions/TokenNameRestrictions';
+import ApiTokenCard from '../ApiTokenCard';
import CreateTokenField from './CreateTokenField';
-import useApiToken from '@site/src/hooks/useApiToken';
+import styles from './api-token.form.module.scss';
const schema = yup
.object({
@@ -21,17 +21,21 @@ const schema = yup
admin: yup.boolean(),
name: yup
.string()
- .min(2, 'Your token name must be atleast 2 characters long.')
- .max(32, 'Only up to 32 characters are allowed.')
+ .min(2, translate({ message: 'Your token name must be atleast 2 characters long.' }))
+ .max(32, translate({ message: 'Only up to 32 characters are allowed.' }))
.matches(/^(?=.*[a-zA-Z0-9])[a-zA-Z0-9_ ]*$/, {
- message:
- 'Only alphanumeric characters with spaces and underscores are allowed. (Example: my_application)',
+ message: translate({
+ message:
+ 'Only alphanumeric characters with spaces and underscores are allowed. (Example: my_application)',
+ }),
excludeEmptyString: true,
})
.matches(
/^(?!.*deriv|.*d3r1v|.*der1v|.*d3riv|.*b1nary|.*binary|.*b1n4ry|.*bin4ry|.*blnary|.*b\|nary).*$/i,
{
- message: 'The name cannot contain “Binary”, “Deriv”, or similar words.',
+ message: translate({
+ message: 'The name cannot contain “Binary”, “Deriv”, or similar words.',
+ }),
excludeEmptyString: true,
},
),
@@ -50,32 +54,42 @@ type TScope = {
const scopes: TScope[] = [
{
name: 'read',
- description:
- 'This scope will allow third-party apps to view your account activity, settings, limits, balance sheets, trade purchase history, and more.',
- label: 'Read',
+ description: translate({
+ message:
+ 'This scope will allow third-party apps to view your account activity, settings, limits, balance sheets, trade purchase history, and more.',
+ }),
+ label: translate({ message: 'Read' }),
},
{
name: 'trade',
- description:
- 'This scope will allow third-party apps to buy and sell contracts for you, renew your expired purchases, and top up your demo accounts.',
- label: 'Trade',
+ description: translate({
+ message:
+ 'This scope will allow third-party apps to buy and sell contracts for you, renew your expired purchases, and top up your demo accounts.',
+ }),
+ label: translate({ message: 'Trade' }),
},
{
name: 'payments',
- description:
- 'This scope will allow third-party apps to withdraw to payment agents and make inter-account transfers for you.',
- label: 'Payments',
+ description: translate({
+ message:
+ 'This scope will allow third-party apps to withdraw to payment agents and make inter-account transfers for you.',
+ }),
+ label: translate({ message: 'Payments' }),
},
{
name: 'trading_information',
- description: 'This scope will allow third-party apps to view your trading history.',
- label: 'Trading Information',
+ description: translate({
+ message: 'This scope will allow third-party apps to view your trading history.',
+ }),
+ label: translate({ message: 'Trading Information' }),
},
{
name: 'admin',
- description:
- 'This scope will allow third-party apps to open accounts for you, manage your settings and token usage, and more.',
- label: 'Admin',
+ description: translate({
+ message:
+ 'This scope will allow third-party apps to open accounts for you, manage your settings and token usage, and more.',
+ }),
+ label: translate({ message: 'Admin' }),
},
];
@@ -133,8 +147,8 @@ const ApiTokenForm = (props: HTMLAttributes) => {
{isCreatingToken && }
-
- Select scopes based on the access you need.
+
+ Select scopes based on the access you need.
);
diff --git a/src/features/dashboard/components/AppDashboardContainer/index.tsx b/src/features/dashboard/components/AppDashboardContainer/index.tsx
index e4876f3e4..d447bca25 100644
--- a/src/features/dashboard/components/AppDashboardContainer/index.tsx
+++ b/src/features/dashboard/components/AppDashboardContainer/index.tsx
@@ -1,8 +1,9 @@
import React from 'react';
import { Heading, Text } from '@deriv-com/quill-ui';
-import './app-dashboard-container.scss';
+import Translate from '@docusaurus/Translate';
import useAppManager from '@site/src/hooks/useAppManager';
import { TDashboardTab } from '@site/src/contexts/app-manager/app-manager.context';
+import './app-dashboard-container.scss';
const hideHeaderForTabs = [TDashboardTab.UPDATE_APP, TDashboardTab.REGISTER_TOKENS];
@@ -14,10 +15,14 @@ const AppDashboardContainer: React.FC<{ children: React.ReactNode }> = ({ childr
{!hideHeaderForTabs.includes(currentTab) && (
- App Dashboard
+
+ App Dashboard
+
- Start using Deriv API to bring custom integrations and powerful automation to your
- apps.
+
+ Start using Deriv API to bring custom integrations and powerful automation to your
+ apps.
+
)}
diff --git a/src/features/dashboard/components/AppForm/index.tsx b/src/features/dashboard/components/AppForm/index.tsx
index b2b88c899..164d1bea2 100644
--- a/src/features/dashboard/components/AppForm/index.tsx
+++ b/src/features/dashboard/components/AppForm/index.tsx
@@ -1,9 +1,10 @@
-import React, { Dispatch, ReactNode, SetStateAction, useEffect, useMemo, useState } from 'react';
-import { Button, Text } from '@deriv/ui';
+import React, { Dispatch, ReactNode, SetStateAction, useEffect, useState } from 'react';
+import clsx from 'clsx';
import { useForm } from 'react-hook-form';
-import { isNotDemoCurrency } from '@site/src/utils';
+import { Button, Text } from '@deriv/ui';
+import Translate, { translate } from '@docusaurus/Translate';
import { yupResolver } from '@hookform/resolvers/yup';
-import { appRegisterSchema, appEditSchema, IRegisterAppForm } from '../../types';
+import useWS from '@site/src/hooks/useWs';
import useApiToken from '@site/src/hooks/useApiToken';
import useAuthContext from '@site/src/hooks/useAuthContext';
import CustomSelectDropdown from '@site/src/components/CustomSelectDropdown';
@@ -12,11 +13,10 @@ import TokenDropdown from '@site/src/components/CustomSelectDropdown/token-dropd
import SelectedAccount from '@site/src/components/CustomSelectDropdown/account-dropdown/SelectedAccount';
import AccountDropdown from '@site/src/components/CustomSelectDropdown/account-dropdown/AccountDropdown';
import CustomCheckbox from '@site/src/components/CustomCheckbox';
-import styles from './app-form.module.scss';
-import clsx from 'clsx';
import useAppManager from '@site/src/hooks/useAppManager';
-import useWS from '@site/src/hooks/useWs';
+import { appRegisterSchema, appEditSchema, IRegisterAppForm } from '../../types';
import RestrictionsAppname from '../RestrictionsAppname';
+import styles from './app-form.module.scss';
type TAppFormProps = {
initialValues?: Partial;
@@ -93,7 +93,9 @@ const AppForm = ({
{!accountHasAdminToken() && (
- This account doesn't have API tokens with the admin scope. Choose another account.
+
+ This account doesn't have API tokens with the admin scope. Choose another account.
+
)}
@@ -110,7 +112,11 @@ const AppForm = ({
}}
size='large'
>
- {is_update_mode ? 'Update Application' : 'Register Application'}
+ {is_update_mode ? (
+ Update Application
+ ) : (
+ Register Application
+ )}
{is_update_mode && cancelButton()}
@@ -125,10 +131,12 @@ const AppForm = ({
-
App information
+
+ App information
+
{!is_update_mode && (
- Select your api token ( it should have admin scope )
+ Select your api token ( it should have admin scope )
)}
@@ -136,7 +144,7 @@ const AppForm = ({
-
+
{errors && errors.name ? (
@@ -183,7 +193,7 @@ const AppForm = ({
) : !is_update_mode && app_name_exists ? (
- That name is taken. Choose another.
+ That name is taken. Choose another.
) : (
display_restrictions &&
@@ -191,16 +201,22 @@ const AppForm = ({
-
Markup
+
+ Markup
+
- You can earn commission by adding a markup to the price of each trade. Enter your
- markup percentage here.
+
+ You can earn commission by adding a markup to the price of each trade. Enter
+ your markup percentage here.
+
- Note: Markup is only available for real accounts.
+
+ Note: Markup is only available for real accounts.
+
- Enter 0 if you don‘t want to earn a markup. Max markup: 3%
+
+ Enter 0 if you don‘t want to earn a markup. Max markup: 3%
+
{errors && errors.app_markup_percentage && (
@@ -234,11 +254,15 @@ const AppForm = ({
-
OAuth details
+
+ OAuth details
+
- This allows clients to log in to your app using their Deriv accounts without an
- API token.
+
+ This allows clients to log in to your app using their Deriv accounts without an
+ API token.
+
- Please note that this URL will be used as the OAuth redirect URL for the OAuth
- authorization.
+
+ Please note that this URL will be used as the OAuth redirect URL for the OAuth
+ authorization.
+
{errors && errors?.redirect_uri && (
{errors.redirect_uri?.message}
@@ -276,7 +304,9 @@ const AppForm = ({
type='text'
placeholder=' '
/>
-
+
- By registering your application, you acknowledge that you‘ve read and accepted
- the Deriv API{' '}
+
+ By registering your application, you acknowledge that you‘ve read and
+ accepted the Deriv API
+ {' '}
- terms and conditions
+
+ terms and conditions
+
{renderButtons &&
{renderButtons()}
}
diff --git a/src/features/dashboard/components/AppRegister/index.tsx b/src/features/dashboard/components/AppRegister/index.tsx
index a74c7b4e1..15c4bc43c 100644
--- a/src/features/dashboard/components/AppRegister/index.tsx
+++ b/src/features/dashboard/components/AppRegister/index.tsx
@@ -1,8 +1,8 @@
import React from 'react';
-import { Button } from '@deriv-com/quill-ui';
import { useForm } from 'react-hook-form';
+import { Button } from '@deriv-com/quill-ui';
import { yupResolver } from '@hookform/resolvers/yup';
-import './app-register.scss';
+import CustomCheckbox from '@site/src/components/CustomCheckbox';
import {
IBaseRegisterAppForm,
TAppRegisterProps,
@@ -11,21 +11,26 @@ import {
baseAppRegisterSchema,
app_name_error_map,
} from './types';
-import CustomCheckbox from '@site/src/components/CustomCheckbox';
+import './app-register.scss';
+import Translate, { translate } from '@docusaurus/Translate';
const TermsAndConditions: React.FC = ({ register }) => {
return (
You have successfully registered your application.
diff --git a/src/features/dashboard/components/Dialogs/TokenCreationDialogSuccess/index.tsx b/src/features/dashboard/components/Dialogs/TokenCreationDialogSuccess/index.tsx
index 457e059fd..0835bff9d 100644
--- a/src/features/dashboard/components/Dialogs/TokenCreationDialogSuccess/index.tsx
+++ b/src/features/dashboard/components/Dialogs/TokenCreationDialogSuccess/index.tsx
@@ -1,4 +1,5 @@
import React, { useEffect, useState } from 'react';
+import Translate, { translate } from '@docusaurus/Translate';
import { Modal, Heading, Text } from '@deriv-com/quill-ui';
import styles from '../../ApiTokenTable/token-cell.module.scss';
import useApiToken from '@site/src/hooks/useApiToken';
@@ -43,7 +44,7 @@ export const TokenCreationDialogSuccess = ({
showHandleBar
disableCloseOnOverlay
isMobile={deviceType !== 'desktop'}
- primaryButtonLabel='Ok'
+ primaryButtonLabel={translate({ message: 'Ok' })}
primaryButtonCallback={handleToggle}
>
- Token created successfully!
+
+ Token created successfully!
+
- Please save this token key. For security reasons, it can't be viewed or copied
- again. If you lose this key, you'll need to generate a new token.
+
+ Please save this token key. For security reasons, it can't be viewed or copied
+ again. If you lose this key, you'll need to generate a new token.
+
- Enable admin access for your app?
+
+ Enable admin access for your app?
+
- For better security, enable admin access only when it's necessary. This approach
- limits access to client activities, minimising risks and safeguarding both workflow
- efficiency and client trust.
+
+ For better security, enable admin access only when it's necessary. This approach
+ limits access to client activities, minimising risks and safeguarding both workflow
+ efficiency and client trust.
+
diff --git a/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx b/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx
index 99cf26f3e..31d551a80 100644
--- a/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx
+++ b/src/theme/Navbar/MobileSidebar/PrimaryMenu/index.tsx
@@ -14,6 +14,7 @@ import {
import useDocusaurusContext from '@docusaurus/useDocusaurusContext';
import { useLocation } from '@docusaurus/router';
import classnames from 'classnames';
+import Translate from '@docusaurus/Translate';
export function useNavbarItems() {
return useThemeConfig().navbar.items;
@@ -61,7 +62,7 @@ const SidebarBottomAction: React.FC = ({ mobileSidebar }) => {