From 8e77a6716caad5af60e17bdedc3f2e2c8ee2ef77 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Mon, 26 Nov 2018 14:49:30 +0100 Subject: [PATCH] don't set initial size based on item count anymore --- src/components/structures/RoomSubList.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/components/structures/RoomSubList.js b/src/components/structures/RoomSubList.js index 6399fd80d9..91b29d4665 100644 --- a/src/components/structures/RoomSubList.js +++ b/src/components/structures/RoomSubList.js @@ -318,20 +318,17 @@ const RoomSubList = React.createClass({ if (len) { const subListClasses = classNames({ "mx_RoomSubList": true, + "mx_RoomSubList_hidden": this.state.hidden, "mx_RoomSubList_nonEmpty": len && !this.state.hidden, }); if (this.state.hidden) { - return
+ return
{this._getHeaderJsx()}
; } else { - const heightEstimation = (len * 44) + 31 + (8 + 8); - const style = { - maxHeight: `${heightEstimation}px`, - }; const tiles = this.makeRoomTiles(); tiles.push(...this.props.extraTiles); - return
+ return
{this._getHeaderJsx()} { tiles }