From e29227db4e44b71d9529dc6ac0378253075926a3 Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Fri, 2 Nov 2018 15:27:17 +0100 Subject: [PATCH] bring back "filter rooms" field this does the filtering in RoomList instead of RoomSubList, so we can hide sections that don't have any results. The filtering does happen with every rerender of RoomList, but only does something while searching, so the performance implications are probably negligible. --- src/components/structures/LeftPanel.js | 9 +-- src/components/structures/RoomSubList.js | 37 +++-------- src/components/views/rooms/RoomList.js | 80 ++++++++++++++---------- 3 files changed, 57 insertions(+), 69 deletions(-) diff --git a/src/components/structures/LeftPanel.js b/src/components/structures/LeftPanel.js index 247b12dc88..989644304b 100644 --- a/src/components/structures/LeftPanel.js +++ b/src/components/structures/LeftPanel.js @@ -179,13 +179,9 @@ const LeftPanel = React.createClass({ const RoomList = sdk.getComponent('rooms.RoomList'); const TagPanel = sdk.getComponent('structures.TagPanel'); const TopLeftMenuButton = sdk.getComponent('structures.TopLeftMenuButton'); + const SearchBox = sdk.getComponent('structures.SearchBox'); const CallPreview = sdk.getComponent('voip.CallPreview'); - const topBox = ; -/* - const SearchBox = sdk.getComponent('structures.SearchBox'); - const topBox = ; -*/ const tagPanelEnabled = !SettingsStore.getValue("TagPanel.disableTagPanel"); const tagPanel = tagPanelEnabled ? :
; @@ -202,7 +198,8 @@ const LeftPanel = React.createClass({
{ tagPanel }