From 1d7c67a984b89f4db2bea7483a7bfa9d047aad68 Mon Sep 17 00:00:00 2001 From: Konstantin Kireyev Date: Tue, 19 Mar 2024 22:00:28 +0500 Subject: [PATCH] [se] embed: fix undefined color in worksheet selector --- .../embed/js/ApplicationController.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/spreadsheeteditor/embed/js/ApplicationController.js b/apps/spreadsheeteditor/embed/js/ApplicationController.js index 20104d0c10..80c412de53 100644 --- a/apps/spreadsheeteditor/embed/js/ApplicationController.js +++ b/apps/spreadsheeteditor/embed/js/ApplicationController.js @@ -201,12 +201,12 @@ SSE.ApplicationController = new(function(){ var styleAttr = ""; var color = api.asc_getWorksheetTabColor(i); + if (color) { - styleAttr = 'style="box-shadow: inset 0 4px 0 rgba({r}, {g}, {b}, {a})"' - .replace(/\{r}/, color.r) - .replace(/\{g}/, color.g) - .replace(/\{b}/, color.b) - .replace(/\{a}/, color.a); + styleAttr = 'style="box-shadow: inset 0 4px 0 rgb({r}, {g}, {b})"' + .replace(/\{r}/, color.get_r()) + .replace(/\{g}/, color.get_g()) + .replace(/\{b}/, color.get_b()); } // escape html