From 174061db570fb4266e57e1d8a61907e537c65174 Mon Sep 17 00:00:00 2001 From: Luke Barnard Date: Wed, 28 Feb 2018 18:16:37 +0000 Subject: [PATCH 1/2] Add setting to disable TagPanel --- src/components/structures/BottomLeftMenu.js | 5 +++++ src/components/structures/LeftPanel.js | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/components/structures/BottomLeftMenu.js b/src/components/structures/BottomLeftMenu.js index 5557e74b..3271d5ae 100644 --- a/src/components/structures/BottomLeftMenu.js +++ b/src/components/structures/BottomLeftMenu.js @@ -168,6 +168,10 @@ module.exports = React.createClass({ const RoomDirectoryButton = sdk.getComponent('elements.RoomDirectoryButton'); const CreateRoomButton = sdk.getComponent('elements.CreateRoomButton'); const SettingsButton = sdk.getComponent('elements.SettingsButton'); + const GroupsButton = sdk.getComponent('elements.GroupsButton'); + + const groupsButton = SettingsStore.getValue("TagPanel.disableTagPanel") ? + : null; return (
@@ -182,6 +186,7 @@ module.exports = React.createClass({
+ { groupsButton } diff --git a/src/components/structures/LeftPanel.js b/src/components/structures/LeftPanel.js index 7f59db7d..83fbfc48 100644 --- a/src/components/structures/LeftPanel.js +++ b/src/components/structures/LeftPanel.js @@ -194,7 +194,9 @@ var LeftPanel = React.createClass({ } ); - const tagPanelEnabled = SettingsStore.isFeatureEnabled("feature_tag_panel"); + const tagPanelEnabled = + SettingsStore.isFeatureEnabled("feature_tag_panel") && + !SettingsStore.getValue("TagPanel.disableTagPanel"); const tagPanel = tagPanelEnabled ? :
; const containerClasses = classNames( From d23c02b1967c93b8abae209437a94bbc6c64aa5b Mon Sep 17 00:00:00 2001 From: Luke Barnard Date: Wed, 28 Feb 2018 18:19:12 +0000 Subject: [PATCH 2/2] gen-i18n --- src/i18n/strings/en_EN.json | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index bbb94a60..4374ca87 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -133,7 +133,6 @@ "Online": "Online", "Away": "Away", "Appear Offline": "Appear Offline", - "Failed to remove tag %(tagName)s from room": "Failed to remove tag %(tagName)s from room", "Failed to set Direct Message status of room": "Failed to set Direct Message status of room", "unknown error code": "unknown error code", "Failed to forget room %(errCode)s": "Failed to forget room %(errCode)s", @@ -190,7 +189,6 @@ "Search for a room": "Search for a room", "#example": "#example", "more": "more", - "Failed to add tag %(tagName)s to room": "Failed to add tag %(tagName)s to room", "Expand panel": "Expand panel", "Collapse panel": "Collapse panel", "Filter room names": "Filter room names",