also set max-height so you can't make a sublist bigger than the content

pull/21833/head
Bruno Windels 2018-10-18 16:58:23 +02:00
parent 44b92eb071
commit 197dd57461
1 changed files with 5 additions and 1 deletions

View File

@ -371,8 +371,12 @@ const RoomSubList = React.createClass({
</div>;
} else {
const heightEstimation = (len * 40) + 31;
const style = {
flexBasis: `${heightEstimation}px`,
maxHeight: `${heightEstimation}px`,
};
const GeminiScrollbarWrapper = sdk.getComponent("elements.GeminiScrollbarWrapper");
return <div className={"mx_RoomSubList"} style={{flexBasis: heightEstimation}}>
return <div className={"mx_RoomSubList"} style={style}>
{this._getHeaderJsx()}
<GeminiScrollbarWrapper>
{ content }