fix(vpaas) hide embed meeting for vpaas users
This commit is contained in:
parent
993ded9936
commit
ce4ef96941
|
@ -10,6 +10,7 @@ import { translate } from '../../../../base/i18n';
|
||||||
import { JitsiRecordingConstants } from '../../../../base/lib-jitsi-meet';
|
import { JitsiRecordingConstants } from '../../../../base/lib-jitsi-meet';
|
||||||
import { getLocalParticipant } from '../../../../base/participants';
|
import { getLocalParticipant } from '../../../../base/participants';
|
||||||
import { connect } from '../../../../base/redux';
|
import { connect } from '../../../../base/redux';
|
||||||
|
import { isVpaasMeeting } from '../../../../billing-counter/functions';
|
||||||
import EmbedMeetingTrigger from '../../../../embed-meeting/components/EmbedMeetingTrigger';
|
import EmbedMeetingTrigger from '../../../../embed-meeting/components/EmbedMeetingTrigger';
|
||||||
import { getActiveSession } from '../../../../recording';
|
import { getActiveSession } from '../../../../recording';
|
||||||
import { updateDialInNumbers } from '../../../actions';
|
import { updateDialInNumbers } from '../../../actions';
|
||||||
|
@ -36,6 +37,11 @@ type Props = {
|
||||||
*/
|
*/
|
||||||
_dialIn: Object,
|
_dialIn: Object,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether or not embed meeting should be visible.
|
||||||
|
*/
|
||||||
|
_embedMeetingVisible: boolean,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Whether or not invite contacts should be visible.
|
* Whether or not invite contacts should be visible.
|
||||||
*/
|
*/
|
||||||
|
@ -80,6 +86,7 @@ type Props = {
|
||||||
function AddPeopleDialog({
|
function AddPeopleDialog({
|
||||||
_conferenceName,
|
_conferenceName,
|
||||||
_dialIn,
|
_dialIn,
|
||||||
|
_embedMeetingVisible,
|
||||||
_inviteContactsVisible,
|
_inviteContactsVisible,
|
||||||
_inviteUrl,
|
_inviteUrl,
|
||||||
_liveStreamViewURL,
|
_liveStreamViewURL,
|
||||||
|
@ -152,7 +159,7 @@ function AddPeopleDialog({
|
||||||
<InviteByEmailSection
|
<InviteByEmailSection
|
||||||
inviteSubject = { inviteSubject }
|
inviteSubject = { inviteSubject }
|
||||||
inviteText = { invite } />
|
inviteText = { invite } />
|
||||||
<EmbedMeetingTrigger />
|
{ _embedMeetingVisible && <EmbedMeetingTrigger /> }
|
||||||
<div className = 'invite-more-dialog separator' />
|
<div className = 'invite-more-dialog separator' />
|
||||||
{
|
{
|
||||||
_liveStreamViewURL
|
_liveStreamViewURL
|
||||||
|
@ -191,6 +198,7 @@ function mapStateToProps(state) {
|
||||||
return {
|
return {
|
||||||
_conferenceName: getRoomName(state),
|
_conferenceName: getRoomName(state),
|
||||||
_dialIn: state['features/invite'],
|
_dialIn: state['features/invite'],
|
||||||
|
_embedMeetingVisible: !isVpaasMeeting(state),
|
||||||
_inviteContactsVisible: interfaceConfig.ENABLE_DIAL_OUT && !hideInviteContacts,
|
_inviteContactsVisible: interfaceConfig.ENABLE_DIAL_OUT && !hideInviteContacts,
|
||||||
_inviteUrl: getInviteURL(state),
|
_inviteUrl: getInviteURL(state),
|
||||||
_liveStreamViewURL:
|
_liveStreamViewURL:
|
||||||
|
|
|
@ -33,6 +33,7 @@ import {
|
||||||
import { connect, equals } from '../../../base/redux';
|
import { connect, equals } from '../../../base/redux';
|
||||||
import { OverflowMenuItem } from '../../../base/toolbox/components';
|
import { OverflowMenuItem } from '../../../base/toolbox/components';
|
||||||
import { getLocalVideoTrack, toggleScreensharing } from '../../../base/tracks';
|
import { getLocalVideoTrack, toggleScreensharing } from '../../../base/tracks';
|
||||||
|
import { isVpaasMeeting } from '../../../billing-counter/functions';
|
||||||
import { VideoBlurButton } from '../../../blur';
|
import { VideoBlurButton } from '../../../blur';
|
||||||
import { CHAT_SIZE, ChatCounter, toggleChat } from '../../../chat';
|
import { CHAT_SIZE, ChatCounter, toggleChat } from '../../../chat';
|
||||||
import { EmbedMeetingDialog } from '../../../embed-meeting';
|
import { EmbedMeetingDialog } from '../../../embed-meeting';
|
||||||
|
@ -136,6 +137,11 @@ type Props = {
|
||||||
*/
|
*/
|
||||||
_isGuest: boolean,
|
_isGuest: boolean,
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether or not the current meeting belongs to a JaaS user.
|
||||||
|
*/
|
||||||
|
_isVpaasMeeting: boolean,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The ID of the local participant.
|
* The ID of the local participant.
|
||||||
*/
|
*/
|
||||||
|
@ -971,6 +977,15 @@ class Toolbox extends Component<Props, State> {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns true if the profile button is visible and false otherwise.
|
||||||
|
*
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
_isEmbedMeetingVisible() {
|
||||||
|
return !this.props._isVpaasMeeting && this._shouldShowButton('embedmeeting');
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns true if the profile button is visible and false otherwise.
|
* Returns true if the profile button is visible and false otherwise.
|
||||||
*
|
*
|
||||||
|
@ -1047,7 +1062,7 @@ class Toolbox extends Component<Props, State> {
|
||||||
key = 'stats'
|
key = 'stats'
|
||||||
onClick = { this._onToolbarOpenSpeakerStats }
|
onClick = { this._onToolbarOpenSpeakerStats }
|
||||||
text = { t('toolbar.speakerStats') } />,
|
text = { t('toolbar.speakerStats') } />,
|
||||||
this._shouldShowButton('embedmeeting')
|
this._isEmbedMeetingVisible()
|
||||||
&& <OverflowMenuItem
|
&& <OverflowMenuItem
|
||||||
accessibilityLabel = { t('toolbar.accessibilityLabel.embedMeeting') }
|
accessibilityLabel = { t('toolbar.accessibilityLabel.embedMeeting') }
|
||||||
icon = { IconCodeBlock }
|
icon = { IconCodeBlock }
|
||||||
|
@ -1433,6 +1448,7 @@ function _mapStateToProps(state) {
|
||||||
_dialog: Boolean(state['features/base/dialog'].component),
|
_dialog: Boolean(state['features/base/dialog'].component),
|
||||||
_feedbackConfigured: Boolean(callStatsID),
|
_feedbackConfigured: Boolean(callStatsID),
|
||||||
_isGuest: state['features/base/jwt'].isGuest,
|
_isGuest: state['features/base/jwt'].isGuest,
|
||||||
|
_isVpaasMeeting: isVpaasMeeting(state),
|
||||||
_fullScreen: fullScreen,
|
_fullScreen: fullScreen,
|
||||||
_tileViewEnabled: shouldDisplayTileView(state),
|
_tileViewEnabled: shouldDisplayTileView(state),
|
||||||
_localParticipantID: localParticipant.id,
|
_localParticipantID: localParticipant.id,
|
||||||
|
|
Loading…
Reference in New Issue