From af011765a42c5769cf986ddaa6b5f4415251b25d Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Sat, 5 Mar 2022 14:03:50 +0300 Subject: [PATCH] [SSE] Fix Bug 55829 --- apps/spreadsheeteditor/mobile/src/controller/Statusbar.jsx | 7 +++++++ apps/spreadsheeteditor/mobile/src/less/statusbar.less | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/apps/spreadsheeteditor/mobile/src/controller/Statusbar.jsx b/apps/spreadsheeteditor/mobile/src/controller/Statusbar.jsx index 1ccff00de..91341e8a8 100644 --- a/apps/spreadsheeteditor/mobile/src/controller/Statusbar.jsx +++ b/apps/spreadsheeteditor/mobile/src/controller/Statusbar.jsx @@ -366,6 +366,13 @@ const Statusbar = inject('sheets', 'storeAppOptions', 'users')(observer(props => api.asc_showWorksheet(sheetIndex); f7.popover.close('#idx-all-list'); } + + const tab = $$('.sheet-tabs .tab').eq(sheetIndex); + if(tab.offset().left < 0) { + $$('.sheet-tabs').scrollLeft( $$('.sheet-tabs').scrollLeft() + tab.offset().left - 96, 500); + } else { + $$('.sheet-tabs').scrollLeft( $$('.sheet-tabs').scrollLeft() + (tab.offset().left + tab.width() - $$('.sheet-tabs').width()/1.5), 500); + } }; return ( diff --git a/apps/spreadsheeteditor/mobile/src/less/statusbar.less b/apps/spreadsheeteditor/mobile/src/less/statusbar.less index f01a7287a..9e04d31e6 100644 --- a/apps/spreadsheeteditor/mobile/src/less/statusbar.less +++ b/apps/spreadsheeteditor/mobile/src/less/statusbar.less @@ -46,8 +46,8 @@ padding: 0; margin: 0; height: 100%; - white-space: pre; - // overflow: hidden; + white-space: nowrap; + overflow-x: scroll; // position: absolute; // left: 0; // top: 0;