Fix: [2.7] Breakout room invitation option missing from user dropdown (#20691)

* Fix: [2.7] Breakout room invitation option missing from user dropdown

* removing unnecessary code

* Translation key re-name

* modal Change
This commit is contained in:
André Castro 2024-07-17 14:39:09 -03:00 committed by GitHub
parent fa0ad14c35
commit 4c6e0289d4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 20 additions and 2 deletions

View File

@ -133,7 +133,11 @@ const intlMessages = defineMessages({
newTab: {
id: 'app.modal.newTab',
description: 'label used in aria description',
}
},
invitationLabel: {
id: 'app.userList.userOptions.breakoutRoomInvitationLabel',
description: 'Invitation item',
},
});
const USER_STATUS_ENABLED = Meteor.settings.public.userStatus.enabled;
@ -226,6 +230,10 @@ class UserOptions extends PureComponent {
&& !hasBreakoutRoom
&& isBreakoutRoomsEnabled();
const canInviteUsers = amIModerator
&& !meetingIsBreakout
&& hasBreakoutRoom
const { locale } = intl;
this.menuItems = [];
@ -318,6 +326,15 @@ class UserOptions extends PureComponent {
});
}
if (canInviteUsers && isMeteorConnected) {
this.menuItems.push({
key: this.createBreakoutId,
icon: 'rooms',
label: intl.formatMessage(intlMessages.invitationLabel),
onClick: this.onInvitationUsers,
dataTest: 'inviteBreakoutRooms',
})
}
if (amIModerator && CaptionsService.isCaptionsEnabled()) {
this.menuItems.push({
icon: 'closed_caption',
@ -413,7 +430,7 @@ class UserOptions extends PureComponent {
}}
/>
{this.renderModal(isCreateBreakoutRoomModalOpen, this.setCreateBreakoutRoomModalIsOpen, "medium",
CreateBreakoutRoomContainer, {isBreakoutRecordable, isInvitation})}
CreateBreakoutRoomContainer, {isBreakoutRecordable, isInvitation, isUpdate: isInvitation})}
{this.renderModal(isGuestPolicyModalOpen, this.setGuestPolicyModalIsOpen, "low",
GuestPolicyContainer)}
{this.renderModal(isWriterMenuModalOpen, this.setWriterMenuModalIsOpen, "low",

View File

@ -177,6 +177,7 @@
"app.userList.userOptions.clearAllLabel": "Clear all status icons",
"app.userList.userOptions.clearAllDesc": "Clears all status icons from users",
"app.userList.userOptions.clearAllReactionsLabel": "Clear all reactions",
"app.userList.userOptions.breakoutRoomInvitationLabel": "Breakout room invitation",
"app.userList.userOptions.clearAllReactionsDesc": "Clears all reaction emojis from users",
"app.userList.userOptions.muteAllExceptPresenterLabel": "Mute all users except presenter",
"app.userList.userOptions.muteAllExceptPresenterDesc": "Mutes all users in the meeting except the presenter",