From 7de2760b5d59bba8c324707a68952c902efb890a Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Wed, 12 Aug 2020 18:22:14 +0300 Subject: [PATCH] [SSE] Fix bug with math info (small browser width) --- apps/spreadsheeteditor/main/app/view/Statusbar.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/spreadsheeteditor/main/app/view/Statusbar.js b/apps/spreadsheeteditor/main/app/view/Statusbar.js index a393d21a6..484b12272 100644 --- a/apps/spreadsheeteditor/main/app/view/Statusbar.js +++ b/apps/spreadsheeteditor/main/app/view/Statusbar.js @@ -742,7 +742,9 @@ define([ this.$el.find('.over-box').removeClass('over-box'); while (width + parseInt(this.boxMath.css('width')) + 100 > widthStatusbar) { var items = this.boxMath.find('label:not(.hide, .over-box)'); - $(items[items.length - 1]).addClass('over-box'); + (items.length>0) && $(items[items.length - 1]).addClass('over-box'); + if (items.length<=1) + break; } },