From a794193cb36aafe7aea2e7d959eb098c56d7c244 Mon Sep 17 00:00:00 2001 From: SergeyEzhin <41478103+SergeyEzhin@users.noreply.github.com> Date: Wed, 29 Dec 2021 20:22:43 +0300 Subject: [PATCH] [DE PE SSE mobile] Fix Bug 54632 (#1454) --- apps/documenteditor/mobile/src/controller/Main.jsx | 2 +- apps/presentationeditor/mobile/src/controller/Main.jsx | 2 +- apps/spreadsheeteditor/mobile/src/controller/Main.jsx | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/documenteditor/mobile/src/controller/Main.jsx b/apps/documenteditor/mobile/src/controller/Main.jsx index 1a35b24b7..c6c253a30 100644 --- a/apps/documenteditor/mobile/src/controller/Main.jsx +++ b/apps/documenteditor/mobile/src/controller/Main.jsx @@ -689,7 +689,7 @@ class MainController extends Component { const { t } = this.props; if (found) { - f7.dialog.alert(null, !(found - replaced > 0) ? Common.Utils.String.format(t('Main.textReplaceSuccess'), replaced) : Common.Utils.String.format(t('Main.textReplaceSkipped'), found - replaced)); + f7.dialog.alert(null, !(found - replaced > 0) ? t('Main.textReplaceSuccess').replace(/\{0\}/, `${replaced}`) : t('Main.textReplaceSkipped').replace(/\{0\}/, `${found - replaced}`)); } else { f7.dialog.alert(null, t('Main.textNoTextFound')); } diff --git a/apps/presentationeditor/mobile/src/controller/Main.jsx b/apps/presentationeditor/mobile/src/controller/Main.jsx index 2c49ee791..1c2d676f9 100644 --- a/apps/presentationeditor/mobile/src/controller/Main.jsx +++ b/apps/presentationeditor/mobile/src/controller/Main.jsx @@ -422,7 +422,7 @@ class MainController extends Component { const { t } = this.props; if (found) { - f7.dialog.alert(null, !(found - replaced > 0) ? Common.Utils.String.format(t('Controller.Main.textReplaceSuccess'), replaced) : Common.Utils.String.format(t('Controller.Main.textReplaceSkipped'), found - replaced)); + f7.dialog.alert(null, !(found - replaced > 0) ? t('Controller.Main.textReplaceSuccess').replace(/\{0\}/, `${replaced}`) : t('Controller.Main.textReplaceSkipped').replace(/\{0\}/, `${found - replaced}`)); } else { f7.dialog.alert(null, t('Controller.Main.textNoTextFound')); } diff --git a/apps/spreadsheeteditor/mobile/src/controller/Main.jsx b/apps/spreadsheeteditor/mobile/src/controller/Main.jsx index 2116ebef0..56df7d9c4 100644 --- a/apps/spreadsheeteditor/mobile/src/controller/Main.jsx +++ b/apps/spreadsheeteditor/mobile/src/controller/Main.jsx @@ -427,7 +427,7 @@ class MainController extends Component { const { t } = this.props; if (this.api.isReplaceAll) { - f7.dialog.alert(null, (found) ? ((!found - replaced) ? Common.Utils.String.format(t('Controller.Main.textReplaceSuccess'), replaced) : Common.Utils.String.format(t('Controller.Main.textReplaceSkipped'), found - replaced)) : t('Controller.Main.textNoTextFound')); + f7.dialog.alert(null, (found) ? ((!found - replaced) ? t('Controller.Main.textReplaceSuccess').replace(/\{0\}/, `${replaced}`) : t('Controller.Main.textReplaceSkipped').replace(/\{0\}/, `${found - replaced}`)) : t('Controller.Main.textNoTextFound')); } }