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
Fix issue with watermarks
Ilya Daynatovich5bb53ba036c7
diff --git a/react/features/conference/components/Conference.web.js b/react/features/conference/components/Conference.web.jsindex 2b9257b5dc..c1f522e11c 100644--- a/react/features/conference/components/Conference.web.js+++ b/react/features/conference/components/Conference.web.js@@ -1,3 +1,4 @@+/* global interfaceConfig */import React, { Component } from 'react';/**@@ -13,6 +14,30 @@ const DISPLAY_NONE_STYLE = {*/export default class Conference extends Component {+ /**+ * Initializes Conference component instance.+ *+ * @param {Object} props - The read-only properties with which the new+ * instance is to be initialized.+ */+ constructor(props) {+ super(props);++ const showBrandWatermark = interfaceConfig.SHOW_BRAND_WATERMARK;+ const showJitsiWatermark = interfaceConfig.SHOW_JITSI_WATERMARK;++ this.state = {+ ...this.state,+ showBrandWatermark,+ showJitsiWatermark,+ brandWatermarkLink:+ showBrandWatermark ? interfaceConfig.BRAND_WATERMARK_LINK : '',+ jitsiWatermarkLink:+ showJitsiWatermark ? interfaceConfig.JITSI_WATERMARK_LINK : '',+ showPoweredBy: interfaceConfig.SHOW_POWERED_BY+ };+ }+/*** Implements React's {@link Component#render()}.*@@ -55,18 +80,15 @@ export default class Conference extends Component {<div id = 'sharedVideoIFrame' /></div><div id = 'etherpad' />- <a target = '_new'>- <div className = 'watermark leftwatermark' />- </a>- <a target = '_new'>- <div className = 'watermark rightwatermark' />- </a>- <a- className = 'poweredby hide'- href = 'http://jitsi.org'- target = '_new'>- <span data-i18n = 'poweredby' /> jitsi.org- </a>+ {+ this._renderJitsiWatermark()+ }+ {+ this._renderBrandWatermark()+ }+ {+ this._renderPoweredBy()+ }<div id = 'dominantSpeaker'><div className = 'dynamic-shadow' /><img@@ -130,4 +152,65 @@ export default class Conference extends Component {</div>);}++ /**+ * Method that returns brand watermark element if it is enabled.+ *+ * @returns {ReactElement|null}+ * @private+ */+ _renderBrandWatermark() {+ if (this.state.showBrandWatermark) {+ return (+ <a+ href = { this.state.brandWatermarkLink }+ target = '_new'>+ <div className = 'watermark rightwatermark' />+ </a>+ );+ }++ return null;+ }++ /**+ * Method that returns jitsi watermark element if it is enabled.+ *+ * @returns {ReactElement|null}+ * @private+ */+ _renderJitsiWatermark() {+ if (this.state.jitsiWatermarkLink) {+ return (+ <a+ href = { this.state.jitsiWatermarkLink }+ target = '_new'>+ <div className = 'watermark leftwatermark' />+ </a>+ );+ }++ return null;+ }++ /**+ * Renders powered by block if it is enabled.+ *+ * @returns {ReactElement|null}+ * @private+ */+ _renderPoweredBy() {+ if (this.state.showPoweredBy) {+ return (+ <a+ className = 'poweredby hide'+ href = 'http://jitsi.org'+ target = '_new'>+ <span data-i18n = 'poweredby' /> jitsi.org+ </a>+ );+ }++ return null;+ }}