mirror of https://github.com/vector-im/riot-web
improve the fix for https://github.com/vector-im/vector-web/issues/917
parent
9d3b0f6075
commit
0a37f1c478
|
@ -140,6 +140,7 @@ var SearchableEntityList = React.createClass({
|
|||
}
|
||||
|
||||
var list;
|
||||
if (this.state.results.length) {
|
||||
if (this.props.truncateAt) { // caller wants list truncated
|
||||
var TruncatedList = sdk.getComponent("elements.TruncatedList");
|
||||
list = (
|
||||
|
@ -161,13 +162,15 @@ var SearchableEntityList = React.createClass({
|
|||
</div>
|
||||
);
|
||||
}
|
||||
list = <GeminiScrollbar autoshow={true} className="mx_SearchableEntityList_listWrapper">
|
||||
{ list }
|
||||
</GeminiScrollbar>;
|
||||
}
|
||||
|
||||
return (
|
||||
<div className={ "mx_SearchableEntityList " + (this.state.query.length ? "mx_SearchableEntityList_expanded" : "") }>
|
||||
{ inputBox }
|
||||
<GeminiScrollbar autoshow={true} className="mx_SearchableEntityList_listWrapper">
|
||||
{ list }
|
||||
</GeminiScrollbar>
|
||||
{ this.state.query.length ? <div className="mx_SearchableEntityList_hrWrapper"><hr/></div> : '' }
|
||||
</div>
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue