From 881f666fbf0ffb788a6a08b53b01a4cfb5ba61e6 Mon Sep 17 00:00:00 2001 From: Zhiting Lin Date: Mon, 25 Feb 2019 14:40:01 +0800 Subject: [PATCH] add the transaltion for generatedTX page --- .../components/GeneratedTxHex/GeneratedTxHex.jsx | 12 +++++++----- src/locales/en/translation.json | 6 +++++- src/locales/zh/translation.json | 6 +++++- 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/src/features/transactions/components/GeneratedTxHex/GeneratedTxHex.jsx b/src/features/transactions/components/GeneratedTxHex/GeneratedTxHex.jsx index b53a020..d934a44 100644 --- a/src/features/transactions/components/GeneratedTxHex/GeneratedTxHex.jsx +++ b/src/features/transactions/components/GeneratedTxHex/GeneratedTxHex.jsx @@ -3,24 +3,26 @@ import { connect } from 'react-redux' import { NotFound, PageContent, PageTitle } from 'features/shared/components' import styles from './GeneratedTxHex.scss' import { copyToClipboard } from 'utility/clipboard' +import {withNamespaces} from 'react-i18next' class Generated extends React.Component { render() { - if (!this.props.hex) return + const t = this.props.t + if (!this.props.hex) return return (
- +
-

Use the following JSON string as the transaction to sign by another account:

+

{t('transaction.advance.generated.lead')}

{this.props.hex}
@@ -39,4 +41,4 @@ export default connect( if (found) return {hex: found.hex} return {} } -)(Generated) +)(withNamespaces('translations') ( Generated) ) diff --git a/src/locales/en/translation.json b/src/locales/en/translation.json index 7d082b1..c26f729 100644 --- a/src/locales/en/translation.json +++ b/src/locales/en/translation.json @@ -264,7 +264,11 @@ "showDetails":"Show transaction details", "transactionContent":"Transaction Content", "normalView":"Normal View", - "jsonView":"Json View" + "jsonView":"Json View", + "generated":{ + "title":"Generated Transaction", + "lead":"Use the following JSON string as the transaction to sign by another account:" + } } }, "balances":{ diff --git a/src/locales/zh/translation.json b/src/locales/zh/translation.json index b9bc1fb..fead1bd 100644 --- a/src/locales/zh/translation.json +++ b/src/locales/zh/translation.json @@ -263,7 +263,11 @@ "showDetails":"展示交易内容", "transactionContent":"交易内容", "normalView":"普通展示", - "jsonView":"Json格式" + "jsonView":"Json格式", + "generated":{ + "title":"生成的交易", + "lead":"请将下面的JSON交易发送给其他账户进行签名:" + } } }, "balances":{ -- 2.11.0