You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-13 08:02:38 +03:00
Don't include empty badge container in minimized view
Fixes https://github.com/vector-im/riot-web/issues/14294 It takes up space, and it won't hold anything anyways.
This commit is contained in:
@@ -369,11 +369,15 @@ export default class RoomTile2 extends React.Component<IProps, IState> {
|
|||||||
|
|
||||||
let badge: React.ReactNode;
|
let badge: React.ReactNode;
|
||||||
if (!this.props.isMinimized) {
|
if (!this.props.isMinimized) {
|
||||||
badge = <NotificationBadge
|
badge = (
|
||||||
notification={this.state.notificationState}
|
<div className="mx_RoomTile2_badgeContainer">
|
||||||
forceCount={false}
|
<NotificationBadge
|
||||||
roomId={this.props.room.roomId}
|
notification={this.state.notificationState}
|
||||||
/>;
|
forceCount={false}
|
||||||
|
roomId={this.props.room.roomId}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: the original RoomTile uses state for the room name. Do we need to?
|
// TODO: the original RoomTile uses state for the room name. Do we need to?
|
||||||
@@ -429,9 +433,7 @@ export default class RoomTile2 extends React.Component<IProps, IState> {
|
|||||||
>
|
>
|
||||||
{roomAvatar}
|
{roomAvatar}
|
||||||
{nameContainer}
|
{nameContainer}
|
||||||
<div className="mx_RoomTile2_badgeContainer">
|
{badge}
|
||||||
{badge}
|
|
||||||
</div>
|
|
||||||
{this.renderNotificationsMenu()}
|
{this.renderNotificationsMenu()}
|
||||||
{this.renderGeneralMenu()}
|
{this.renderGeneralMenu()}
|
||||||
</AccessibleButton>
|
</AccessibleButton>
|
||||||
|
|||||||
Reference in New Issue
Block a user