Add decoration to space hierarchy for tiles which have already been j… (#6969)
This commit is contained in:
parent
fabbf6c48a
commit
ead2a5152f
3 changed files with 31 additions and 2 deletions
|
@ -172,8 +172,15 @@ const Tile: React.FC<ITileProps> = ({
|
|||
description += " · " + topic;
|
||||
}
|
||||
|
||||
let joinedSection;
|
||||
if (joinedRoom) {
|
||||
joinedSection = <div className="mx_SpaceHierarchy_roomTile_joined">
|
||||
{ _t("Joined") }
|
||||
</div>;
|
||||
}
|
||||
|
||||
let suggestedSection;
|
||||
if (suggested) {
|
||||
if (suggested && (!joinedRoom || hasPermissions)) {
|
||||
suggestedSection = <InfoTooltip tooltip={_t("This room is suggested as a good one to join")}>
|
||||
{ _t("Suggested") }
|
||||
</InfoTooltip>;
|
||||
|
@ -183,6 +190,7 @@ const Tile: React.FC<ITileProps> = ({
|
|||
{ avatar }
|
||||
<div className="mx_SpaceHierarchy_roomTile_name">
|
||||
{ name }
|
||||
{ joinedSection }
|
||||
{ suggestedSection }
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue