mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-16 05:04:57 +08:00
Hide room list show less button if it would do nothing
Signed-off-by: ☕ Tim <tim@wants.coffee> On the new rooms list, if the show less button wouldn't result in a smaller list, don't show it. Fixes vector-im/riot-web#14219
This commit is contained in:
parent
5172c7b205
commit
c8381021b8
@ -393,7 +393,7 @@ export default class RoomSublist2 extends React.Component<IProps, IState> {
|
||||
{showMoreText}
|
||||
</div>
|
||||
);
|
||||
} else if (tiles.length <= nVisible && tiles.length > this.props.layout.minVisibleTiles) {
|
||||
} else if (tiles.length <= nVisible && tiles.length > this.props.layout.defaultVisibleTiles) {
|
||||
// we have all tiles visible - add a button to show less
|
||||
let showLessText = (
|
||||
<span className='mx_RoomSublist2_showNButtonText'>
|
||||
|
Loading…
Reference in New Issue
Block a user