forked from matrix/element-web
When collapsed a long hover on the header now shows the full tag name and room count
This commit is contained in:
parent
aee56a5bd1
commit
52bd61a2f0
|
@ -418,8 +418,18 @@ var RoomSubList = React.createClass({
|
||||||
badge = <div className={badgeClasses}>{subListNotifCount > 99 ? "99+" : subListNotifCount}</div>;
|
badge = <div className={badgeClasses}>{subListNotifCount > 99 ? "99+" : subListNotifCount}</div>;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// When collapsed, allow a long hover on the header to show user
|
||||||
|
// the full tag name and room count
|
||||||
|
var title;
|
||||||
|
if (this.props.collapsed) {
|
||||||
|
title = this.props.label;
|
||||||
|
if (roomCount !== '') {
|
||||||
|
title += " [" + roomCount + "]";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="mx_RoomSubList_labelContainer" ref="header">
|
<div className="mx_RoomSubList_labelContainer" title={ title } ref="header">
|
||||||
<div onClick={ this.onClick } className="mx_RoomSubList_label">
|
<div onClick={ this.onClick } className="mx_RoomSubList_label">
|
||||||
{ this.props.collapsed ? '' : this.props.label }
|
{ this.props.collapsed ? '' : this.props.label }
|
||||||
<div className="mx_RoomSubList_roomCount">{roomCount}</div>
|
<div className="mx_RoomSubList_roomCount">{roomCount}</div>
|
||||||
|
|
Loading…
Reference in New Issue