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
feat(rn, security) added flag for controlling security options button visibility
Calinteodor9b5eae7a607f
diff --git a/react/features/base/flags/constants.js b/react/features/base/flags/constants.jsindex f3acc2be1a..8e6deba521 100644--- a/react/features/base/flags/constants.js+++ b/react/features/base/flags/constants.js@@ -104,6 +104,12 @@ export const KICK_OUT_ENABLED = 'kick-out.enabled';*/export const LIVE_STREAMING_ENABLED = 'live-streaming.enabled';+/**+ * Flag indicating if lobby mode button should be enabled.+ * Default: enabled.+ */+export const LOBBY_MODE_ENABLED = 'lobby-mode.enabled';+/*** Flag indicating if displaying the meeting name should be enabled.* Default: enabled (true).@@ -113,7 +119,7 @@ export const MEETING_NAME_ENABLED = 'meeting-name.enabled';/*** Flag indicating if the meeting password button should be enabled.* Note that this flag just decides on the button, if a meeting has a password- * set, the password ddialog will still show up.+ * set, the password dialog will still show up.* Default: enabled (true).*/export const MEETING_PASSWORD_ENABLED = 'meeting-password.enabled';@@ -155,6 +161,12 @@ export const RECORDING_ENABLED = 'recording.enabled';*/export const RESOLUTION = 'resolution';+/**+ * Flag indicating if the security options button should be enabled.+ * Default: enabled (true)+ */+export const SECURITY_OPTIONS_ENABLED = 'security-options.enabled';+/*** Flag indicating if server URL change is enabled.* Default: enabled (true)diff --git a/react/features/security/components/security-dialog/SecurityDialogButton.js b/react/features/security/components/security-dialog/SecurityDialogButton.jsindex a7da1520a3..6704824ef5 100644--- a/react/features/security/components/security-dialog/SecurityDialogButton.js+++ b/react/features/security/components/security-dialog/SecurityDialogButton.js@@ -3,8 +3,15 @@import type { Dispatch } from 'redux';import { createToolbarEvent, sendAnalytics } from '../../../analytics';+import {+ getFeatureFlag,+ LOBBY_MODE_ENABLED,+ MEETING_PASSWORD_ENABLED,+ SECURITY_OPTIONS_ENABLED+} from '../../../base/flags';import { translate } from '../../../base/i18n';import { IconSecurityOff, IconSecurityOn } from '../../../base/icons';+import { isLocalParticipantModerator } from '../../../base/participants';import { connect } from '../../../base/redux';import { AbstractButton, type AbstractButtonProps } from '../../../base/toolbox/components';import { toggleSecurityDialog } from '../../actions';@@ -62,11 +69,19 @@ class SecurityDialogButton extends AbstractButton<Props, *> {* @returns {Props}*/function mapStateToProps(state: Object) {+ const { conference } = state['features/base/conference'];+ const { hideLobbyButton } = state['features/base/config'];const { locked } = state['features/base/conference'];const { lobbyEnabled } = state['features/lobby'];+ const lobbySupported = conference && conference.isLobbySupported();+ const lobby = lobbySupported && isLocalParticipantModerator(state) && !hideLobbyButton;+ const enabledFlag = getFeatureFlag(state, SECURITY_OPTIONS_ENABLED, true);+ const enabledLobbyModeFlag = getFeatureFlag(state, LOBBY_MODE_ENABLED, true) && lobby;+ const enabledMeetingPassFlag = getFeatureFlag(state, MEETING_PASSWORD_ENABLED, true);return {- _locked: locked || lobbyEnabled+ _locked: locked || lobbyEnabled,+ visible: enabledFlag || (enabledLobbyModeFlag || enabledMeetingPassFlag)};}