From 1bed0d1bf44323b0db5dc11171924822cd951303 Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Wed, 17 Feb 2021 22:09:50 +0300 Subject: [PATCH] Add api parameter customization.hideStartTips: hide theme tooltip --- apps/api/documents/api.js | 3 ++- apps/documenteditor/main/app/controller/Viewport.js | 2 +- apps/presentationeditor/main/app/controller/Viewport.js | 2 +- apps/spreadsheeteditor/main/app/controller/Viewport.js | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/api/documents/api.js b/apps/api/documents/api.js index 20ec5730d..ed61aebeb 100644 --- a/apps/api/documents/api.js +++ b/apps/api/documents/api.js @@ -156,7 +156,8 @@ plugins: true // can run plugins in document macrosMode: 'warn' // warn about automatic macros, 'enable', 'disable', 'warn', trackChanges: undefined // true/false - open editor with track changes mode on/off, - hideRulers: false, // hide or show rulers on first loading (presentation or document editor) + hideRulers: false, // hide or show rulers on first loading (presentation or document editor), + hideStartTips: false // hide help toolips on starting editors }, plugins: { autostart: ['asc.{FFE1F462-1EA2-4391-990D-4CC84940B754}'], diff --git a/apps/documenteditor/main/app/controller/Viewport.js b/apps/documenteditor/main/app/controller/Viewport.js index b9aea5f3d..ece465680 100644 --- a/apps/documenteditor/main/app/controller/Viewport.js +++ b/apps/documenteditor/main/app/controller/Viewport.js @@ -328,7 +328,7 @@ define([ mnuitemDarkTheme.setChecked(Common.UI.Themes.isDarkTheme()); }); - if (!Common.localStorage.getBool("hide-dark-theme-tip")) { + if (!Common.localStorage.getBool("hide-dark-theme-tip") && !(config.customization && config.customization.hideStartTips===true)) { me.themeTip = new Common.UI.SynchronizeTip({ target: me.header.btnOptions.$el, placement : 'bottom-left', diff --git a/apps/presentationeditor/main/app/controller/Viewport.js b/apps/presentationeditor/main/app/controller/Viewport.js index aaa09e874..c98f54fd5 100644 --- a/apps/presentationeditor/main/app/controller/Viewport.js +++ b/apps/presentationeditor/main/app/controller/Viewport.js @@ -331,7 +331,7 @@ define([ mnuitemDarkTheme.setChecked(Common.UI.Themes.isDarkTheme()); }); - if (!Common.localStorage.getBool("hide-dark-theme-tip")) { + if (!Common.localStorage.getBool("hide-dark-theme-tip") && !(config.customization && config.customization.hideStartTips===true)) { me.themeTip = new Common.UI.SynchronizeTip({ target: me.header.btnOptions.$el, placement : 'bottom-left', diff --git a/apps/spreadsheeteditor/main/app/controller/Viewport.js b/apps/spreadsheeteditor/main/app/controller/Viewport.js index 132ff930c..7a3ef1390 100644 --- a/apps/spreadsheeteditor/main/app/controller/Viewport.js +++ b/apps/spreadsheeteditor/main/app/controller/Viewport.js @@ -342,7 +342,7 @@ define([ mnuitemDarkTheme.setChecked(Common.UI.Themes.isDarkTheme()); }); - if (!Common.localStorage.getBool("hide-dark-theme-tip")) { + if (!Common.localStorage.getBool("hide-dark-theme-tip") && !(config.customization && config.customization.hideStartTips===true)) { me.themeTip = new Common.UI.SynchronizeTip({ target: me.header.btnOptions.$el, placement : 'bottom-left',