diff --git a/src/components/structures/RoomView.js b/src/components/structures/RoomView.js
index 96d915e9de..99f13dcd35 100644
--- a/src/components/structures/RoomView.js
+++ b/src/components/structures/RoomView.js
@@ -1647,6 +1647,7 @@ module.exports = React.createClass({
let aux = null;
let previewBar;
let hideCancel = false;
+ let hideRightPanel = false;
if (this.state.forwardingEvent !== null) {
aux = ;
} else if (this.state.searching) {
@@ -1690,6 +1691,8 @@ module.exports = React.createClass({
{ previewBar }
);
+ } else {
+ hideRightPanel = true;
}
} else if (hiddenHighlightCount > 0) {
aux = (
@@ -1861,14 +1864,16 @@ module.exports = React.createClass({
},
);
- const rightPanel = this.state.room ? : undefined;
+ const rightPanel = !hideRightPanel && this.state.room &&
+ ;
+ const collapsedRhs = hideRightPanel || this.props.collapsedRhs;
return (