From 1a4c7a9c369b2671fa1f539308c9906c0a4ca7b3 Mon Sep 17 00:00:00 2001 From: drafish Date: Wed, 14 Dec 2022 15:37:57 +0800 Subject: [PATCH] terminal intl patch --- apps/remix-ide/src/app/tabs/locales/en/terminal.json | 2 ++ apps/remix-ide/src/app/tabs/locales/zh/terminal.json | 2 ++ .../terminal/src/lib/components/RenderKnownTransactions.tsx | 3 ++- .../terminal/src/lib/components/RenderUnknownTransactions.tsx | 3 ++- libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx | 4 ++-- 5 files changed, 10 insertions(+), 4 deletions(-) diff --git a/apps/remix-ide/src/app/tabs/locales/en/terminal.json b/apps/remix-ide/src/app/tabs/locales/en/terminal.json index 9086bcc8ac..a175436686 100644 --- a/apps/remix-ide/src/app/tabs/locales/en/terminal.json +++ b/apps/remix-ide/src/app/tabs/locales/en/terminal.json @@ -1,7 +1,9 @@ { "terminal.listen": "listen on all transactions", + "terminal.listenTitle": "If checked Remix will listen on all transactions mined in the current environment and not only transactions created by you", "terminal.search": "Search with transaction hash or address", "terminal.used": "used", + "terminal.debug": "Debug", "terminal.welcomeText1": "Welcome to", "terminal.welcomeText2": "Your files are stored in", "terminal.welcomeText3": "You can use this terminal to", diff --git a/apps/remix-ide/src/app/tabs/locales/zh/terminal.json b/apps/remix-ide/src/app/tabs/locales/zh/terminal.json index 65e3092e84..87e1b4e9a4 100644 --- a/apps/remix-ide/src/app/tabs/locales/zh/terminal.json +++ b/apps/remix-ide/src/app/tabs/locales/zh/terminal.json @@ -1,7 +1,9 @@ { "terminal.listen": "监听所有交易", + "terminal.listenTitle": "如果选中,Remix 将监听在当前环境中挖掘到的所有交易,而不仅仅是您创建的交易", "terminal.search": "按交易哈希或地址搜索", "terminal.used": "已使用", + "terminal.debug": "调试", "terminal.welcomeText1": "欢迎使用", "terminal.welcomeText2": "您的文件储存在", "terminal.welcomeText3": "您可使用此终端", diff --git a/libs/remix-ui/terminal/src/lib/components/RenderKnownTransactions.tsx b/libs/remix-ui/terminal/src/lib/components/RenderKnownTransactions.tsx index 3d3b1a2d8e..acf402a100 100644 --- a/libs/remix-ui/terminal/src/lib/components/RenderKnownTransactions.tsx +++ b/libs/remix-ui/terminal/src/lib/components/RenderKnownTransactions.tsx @@ -1,5 +1,6 @@ import React from 'react' // eslint-disable-line +import { FormattedMessage } from 'react-intl' import CheckTxStatus from './ChechTxStatus' // eslint-disable-line import Context from './Context' // eslint-disable-line import showTable from './Table' @@ -31,7 +32,7 @@ const RenderKnownTransactions = ({ tx, receipt, resolvedData, logs, index, plugi data-shared='txLoggerDebugButton' data-id={`txLoggerDebugButton${tx.hash}`} onClick={(event) => debug(event, tx)} - >Debug + > diff --git a/libs/remix-ui/terminal/src/lib/components/RenderUnknownTransactions.tsx b/libs/remix-ui/terminal/src/lib/components/RenderUnknownTransactions.tsx index 9400d83b4a..923fb19557 100644 --- a/libs/remix-ui/terminal/src/lib/components/RenderUnknownTransactions.tsx +++ b/libs/remix-ui/terminal/src/lib/components/RenderUnknownTransactions.tsx @@ -1,4 +1,5 @@ import React, { useState } from 'react' // eslint-disable-line +import { FormattedMessage } from 'react-intl' import CheckTxStatus from './ChechTxStatus' // eslint-disable-line import Context from './Context' // eslint-disable-line import showTable from './Table' @@ -27,7 +28,7 @@ const RenderUnKnownTransactions = ({ tx, receipt, index, plugin, showTableHash, data-shared='txLoggerDebugButton' data-id={`txLoggerDebugButton${tx.hash}`} onClick={(event) => debug(event, tx)} - >Debug + > diff --git a/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx b/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx index 3a4fb13882..0743efc56e 100644 --- a/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx +++ b/libs/remix-ui/terminal/src/lib/remix-ui-terminal.tsx @@ -464,11 +464,11 @@ export const RemixUiTerminal = (props: RemixUiTerminalProps) => { id="listenNetworkCheck" onChange={listenOnNetwork} type="checkbox" - title="If checked Remix will listen on all transactions mined in the current environment and not only transactions created by you" + title={intl.formatMessage({ id: 'terminal.listenTitle' })} />