diff --git a/src/hooks/screen/Transaction/useTransactionV2.ts b/src/hooks/screen/Transaction/useTransactionV2.ts index d51be6030..d401aa175 100644 --- a/src/hooks/screen/Transaction/useTransactionV2.ts +++ b/src/hooks/screen/Transaction/useTransactionV2.ts @@ -112,7 +112,7 @@ export const useTransaction = { appModalContext.setConfirmModal({ visible: true, - message: i18n.common.enableChainMessage(chainInfoMap[chain].name), + message: i18n.formatString(i18n.common.enableChainMessage, chainInfoMap[chain].name), title: i18n.common.enableChain, onCancelModal: () => { appModalContext.hideConfirmModal(); diff --git a/src/screens/Confirmations/parts/Detail/Substrate/Transaction.tsx b/src/screens/Confirmations/parts/Detail/Substrate/Transaction.tsx index a14494add..4065fc0d9 100644 --- a/src/screens/Confirmations/parts/Detail/Substrate/Transaction.tsx +++ b/src/screens/Confirmations/parts/Detail/Substrate/Transaction.tsx @@ -55,9 +55,11 @@ const mortalityAsString = (era: ExtrinsicEra, hexBlockNumber: string): string => const blockNumber = bnToBn(hexBlockNumber); const mortal = era.asMortalEra; - return i18n.confirmation.lifeTimeContent - .replace('{{birth}}', formatNumber(mortal.birth(blockNumber))) - .replace('{{death}}', formatNumber(mortal.death(blockNumber))); + return i18n.formatString( + i18n.confirmation.lifeTimeContent, + formatNumber(mortal.birth(blockNumber)), + formatNumber(mortal.death(blockNumber)), + ); }; const SubstrateTransactionDetail: React.FC = (props: Props) => { diff --git a/src/utils/i18n/en_US.json b/src/utils/i18n/en_US.json index f2ad86f4c..95be3be71 100644 --- a/src/utils/i18n/en_US.json +++ b/src/utils/i18n/en_US.json @@ -908,7 +908,7 @@ "requestWithAccount": "You are approving a request with account", "messageDetail": "Message details", "transactionDetail": "Transaction details", - "lifeTimeContent": "mortal, valid from {{0}} to {{1}}", + "lifeTimeContent": "mortal, valid from {0} to {1}", "addNetworkRequest": "Add network request", "addTokenRequest": "Add token request", "providerUrl": "Provider URL",