diff --git a/src/components/structures/RightPanel.tsx b/src/components/structures/RightPanel.tsx index 67634c63d2..5b12e542bd 100644 --- a/src/components/structures/RightPanel.tsx +++ b/src/components/structures/RightPanel.tsx @@ -269,7 +269,7 @@ export default class RightPanel extends React.Component { case RightPanelPhases.EncryptionPanel: panel = { defaultDispatcher.dispatch({ action: Action.SetRightPanelPhase, phase: RightPanelPhases.SpaceMemberList, - refireParams: { space: space }, + refireParams: { space }, }); onFinished(); }; diff --git a/src/components/views/right_panel/UserInfo.tsx b/src/components/views/right_panel/UserInfo.tsx index d15f349d62..f90643f1df 100644 --- a/src/components/views/right_panel/UserInfo.tsx +++ b/src/components/views/right_panel/UserInfo.tsx @@ -1278,7 +1278,9 @@ const BasicUserInfo: React.FC<{ // hide the Roles section for DMs as it doesn't make sense there if (!DMRoomMap.shared().getUserIdForRoomId((member as RoomMember).roomId)) { memberDetails =
-

{ _t("Role") }

+

{ _t("Role in ", {}, { + RoomName: () => { room.name }, + }) }

= ({ // We have no previousPhase for when viewing a UserInfo from a Group or without a Room at this time if (room && phase === RightPanelPhases.EncryptionPanel) { previousPhase = RightPanelPhases.RoomMemberInfo; - refireParams = { member: member }; + refireParams = { member }; + } else if (room?.isSpaceRoom() && SpaceStore.spacesEnabled) { + previousPhase = previousPhase = RightPanelPhases.SpaceMemberList; + refireParams = { space: room }; } else if (room) { - previousPhase = previousPhase = SpaceStore.spacesEnabled && room.isSpaceRoom() - ? RightPanelPhases.SpaceMemberList - : RightPanelPhases.RoomMemberList; + previousPhase = RightPanelPhases.RoomMemberList; } const onEncryptionPanelClose = () => { diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index 9ccec8d047..25797f41a2 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -1866,7 +1866,7 @@ "Deactivating this user will log them out and prevent them from logging back in. Additionally, they will leave all the rooms they are in. This action cannot be reversed. Are you sure you want to deactivate this user?": "Deactivating this user will log them out and prevent them from logging back in. Additionally, they will leave all the rooms they are in. This action cannot be reversed. Are you sure you want to deactivate this user?", "Deactivate user": "Deactivate user", "Failed to deactivate user": "Failed to deactivate user", - "Role": "Role", + "Role in ": "Role in ", "This client does not support end-to-end encryption.": "This client does not support end-to-end encryption.", "Edit devices": "Edit devices", "Security": "Security",