From 5c00b9fa5791503a791f6b5283ca2035bd8f8be7 Mon Sep 17 00:00:00 2001 From: SergeyEzhin Date: Fri, 26 Aug 2022 14:17:55 +0300 Subject: [PATCH 1/4] [DE mobile] Corrected infinite doc placeholder --- apps/documenteditor/mobile/src/page/main.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/documenteditor/mobile/src/page/main.jsx b/apps/documenteditor/mobile/src/page/main.jsx index 6f4c36713..fb1ab6285 100644 --- a/apps/documenteditor/mobile/src/page/main.jsx +++ b/apps/documenteditor/mobile/src/page/main.jsx @@ -203,4 +203,4 @@ class MainPage extends Component { } } -export default inject("storeAppOptions")(observer(withTranslation()(MainPage))); \ No newline at end of file +export default withTranslation()(inject("storeAppOptions")(observer(MainPage))); \ No newline at end of file From a83c32c7938b77754333e39146efcb76b6351d3f Mon Sep 17 00:00:00 2001 From: SergeyEzhin Date: Fri, 26 Aug 2022 19:24:26 +0300 Subject: [PATCH 2/4] [DE mobile] Correct opening snackbar --- .../mobile/src/controller/settings/Settings.jsx | 10 +++++----- .../mobile/src/view/settings/Settings.jsx | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/apps/documenteditor/mobile/src/controller/settings/Settings.jsx b/apps/documenteditor/mobile/src/controller/settings/Settings.jsx index 202a24362..951ff7d87 100644 --- a/apps/documenteditor/mobile/src/controller/settings/Settings.jsx +++ b/apps/documenteditor/mobile/src/controller/settings/Settings.jsx @@ -81,15 +81,15 @@ const Settings = props => { }, 0); }; - const onChangeMobileView = () => { - const api = Common.EditorApi.get() + const onChangeMobileView = async () => { + const api = Common.EditorApi.get(); const appOptions = props.storeAppOptions; - appOptions.changeMobileView(); - api.ChangeReaderMode(); + await appOptions.changeMobileView(); + await api.ChangeReaderMode(); if(Device.phone) { - closeModal(); + await closeModal(); } } diff --git a/apps/documenteditor/mobile/src/view/settings/Settings.jsx b/apps/documenteditor/mobile/src/view/settings/Settings.jsx index 4b263f1e7..e31ead9b7 100644 --- a/apps/documenteditor/mobile/src/view/settings/Settings.jsx +++ b/apps/documenteditor/mobile/src/view/settings/Settings.jsx @@ -166,9 +166,9 @@ const SettingsList = inject("storeAppOptions", "storeReview")(observer(props => { props.onChangeMobileView(); props.openOptions('snackbar'); - setTimeout( () => { + setTimeout(() => { props.closeOptions('snackbar'); - }, 1000); + }, 1000); }} /> } From 7efe1b6e152f34503241b369445a20b2a01982db Mon Sep 17 00:00:00 2001 From: SergeyEzhin Date: Fri, 26 Aug 2022 19:39:33 +0300 Subject: [PATCH 3/4] [DE mobile] For Bug 58670 --- apps/documenteditor/mobile/src/view/Toolbar.jsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/documenteditor/mobile/src/view/Toolbar.jsx b/apps/documenteditor/mobile/src/view/Toolbar.jsx index fc5a4dc29..902fcb977 100644 --- a/apps/documenteditor/mobile/src/view/Toolbar.jsx +++ b/apps/documenteditor/mobile/src/view/Toolbar.jsx @@ -57,11 +57,11 @@ const ToolbarView = props => { } {props.isEdit && isAvailableExt && !isViewer && EditorUIController.getToolbarOptions && EditorUIController.getToolbarOptions({ - disabled: disableEditBtn || props.disabledControls, - onEditClick: e => props.openOptions('edit'), - onAddClick: e => props.openOptions('add') + disabled: disableEditBtn || props.disabledControls, + onEditClick: e => props.openOptions('edit'), + onAddClick: e => props.openOptions('add') })} - {isViewer && isAvailableExt && props.turnOffViewerMode()}>} + {isViewer && isAvailableExt && props.isEdit && props.turnOffViewerMode()}>} {Device.phone ? null : } {props.displayCollaboration && window.matchMedia("(min-width: 360px)").matches ? props.openOptions('coauth')}> : null} props.openOptions('settings')}> From d545f86c3b8d90b064a7704d02a7651bd920bde7 Mon Sep 17 00:00:00 2001 From: SergeyEzhin Date: Fri, 26 Aug 2022 20:07:18 +0300 Subject: [PATCH 4/4] [DE mobile] Fix Bug 58662 --- .../src/view/settings/ApplicationSettings.jsx | 15 ++++++++------- .../mobile/src/view/settings/Settings.jsx | 10 ++++------ 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/apps/documenteditor/mobile/src/view/settings/ApplicationSettings.jsx b/apps/documenteditor/mobile/src/view/settings/ApplicationSettings.jsx index 03ecb2f8b..e529f4a1f 100644 --- a/apps/documenteditor/mobile/src/view/settings/ApplicationSettings.jsx +++ b/apps/documenteditor/mobile/src/view/settings/ApplicationSettings.jsx @@ -24,13 +24,14 @@ const PageApplicationSettings = props => { // set mode const appOptions = props.storeAppOptions; + const isViewer = appOptions.isViewer; const _isEdit = appOptions.isEdit; const _isShowMacros = (!appOptions.isDisconnected && appOptions.customization) ? appOptions.customization.macros !== false : true; return ( - {_isEdit && + {_isEdit && !isViewer && {_t.textUnitOfMeasurement} @@ -90,7 +91,6 @@ const PageApplicationSettings = props => { /> - { - - - - - + {!isViewer && + + + + } {_isShowMacros && } - {!isViewer && - - - - } + + + {_canDownload &&