Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.
TypeScript debiandeep-videojitsijitsi-meetscalable-video-conferencessfuvideovideo-communicationvideo-conferencingwebrtc
ref(config) move defaultLogoUrl to config object (#12087)
Avram Tudor1e9f599a3526
diff --git a/config.js b/config.jsindex f7467ee503..6f62e3fef0 100644--- a/config.js+++ b/config.js@@ -1490,4 +1490,7 @@ var config = {// 'modules/statistics/CallStats.js': 'info',// 'modules/xmpp/strophe.util.js': 'log',// },++ // Application logo url+ // defaultLogoUrl: 'images/watermark.svg',};diff --git a/interface_config.js b/interface_config.jsindex 4158fff37b..9d0e357f63 100644--- a/interface_config.js+++ b/interface_config.js@@ -27,7 +27,6 @@ var interfaceConfig = {CLOSE_PAGE_GUEST_HINT: false, // A html text to be shown to guests on the close page, false disables itDEFAULT_BACKGROUND: '#040404',- DEFAULT_LOGO_URL: 'images/watermark.svg',DEFAULT_WELCOME_PAGE_LOGO_URL: 'images/watermark.svg',DISABLE_DOMINANT_SPEAKER_INDICATOR: false,@@ -241,6 +240,9 @@ var interfaceConfig = {// Please use defaultLocalDisplayName from config.js// DEFAULT_LOCAL_DISPLAY_NAME: 'me',+ // Please use defaultLogoUrl from config.js+ // DEFAULT_LOGO_URL: 'images/watermark.svg',+// Please use defaultRemoteDisplayName from config.js// DEFAULT_REMOTE_DISPLAY_NAME: 'Fellow Jitster',diff --git a/react/features/base/config/configType.ts b/react/features/base/config/configType.tsindex 427355c6f4..f4914fbbc9 100644--- a/react/features/base/config/configType.ts+++ b/react/features/base/config/configType.ts@@ -169,6 +169,7 @@ export interface IConfig {corsAvatarURLs?: Array<string>;defaultLanguage?: string;defaultLocalDisplayName?: string;+ defaultLogoUrl?: string;defaultRemoteDisplayName?: string;deploymentInfo?: {region?: string;diff --git a/react/features/base/config/reducer.ts b/react/features/base/config/reducer.tsindex c1948e2cb4..87969d2fba 100644--- a/react/features/base/config/reducer.ts+++ b/react/features/base/config/reducer.ts@@ -273,6 +273,15 @@ function _translateInterfaceConfig(oldValue: IConfig) {newValue.defaultRemoteDisplayName = interfaceConfig.DEFAULT_REMOTE_DISPLAY_NAME;}+ if (oldValue.defaultLogoUrl === undefined) {+ if (typeof interfaceConfig === 'object'+ && interfaceConfig.hasOwnProperty('DEFAULT_LOGO_URL')) {+ newValue.defaultLogoUrl = interfaceConfig.DEFAULT_LOGO_URL;+ } else {+ newValue.defaultLogoUrl = 'images/watermark.svg';+ }+ }+return newValue;}diff --git a/react/features/base/react/components/web/Watermarks.js b/react/features/base/react/components/web/Watermarks.jsindex 90375d9013..054112386a 100644--- a/react/features/base/react/components/web/Watermarks.js+++ b/react/features/base/react/components/web/Watermarks.js@@ -232,8 +232,8 @@ function _mapStateToProps(state, ownProps) {logoImageUrl} = state['features/dynamic-branding'];const isValidRoom = state['features/base/conference'].room;+ const { defaultLogoUrl } = state['features/base/config'];const {- DEFAULT_LOGO_URL,JITSI_WATERMARK_LINK,SHOW_JITSI_WATERMARK} = interfaceConfig;@@ -249,12 +249,12 @@ function _mapStateToProps(state, ownProps) {// don't show logo if request fails or no logo set for vpaas meetings_showJitsiWatermark = !customizationFailed && Boolean(logoImageUrl);} else if (defaultBranding) {- _logoUrl = DEFAULT_LOGO_URL;+ _logoUrl = defaultLogoUrl;_logoLink = JITSI_WATERMARK_LINK;}} else {// When there is no custom branding data use defaults- _logoUrl = ownProps.defaultJitsiLogoURL || DEFAULT_LOGO_URL;+ _logoUrl = ownProps.defaultJitsiLogoURL || defaultLogoUrl;_logoLink = JITSI_WATERMARK_LINK;}