diff --git a/src/components/structures/RightPanel.js b/src/components/structures/RightPanel.js
index c58d3c62..6b7633ad 100644
--- a/src/components/structures/RightPanel.js
+++ b/src/components/structures/RightPanel.js
@@ -44,7 +44,6 @@ class HeaderButton extends React.Component {
render() {
const TintableSvg = sdk.getComponent("elements.TintableSvg");
const AccessibleButton = sdk.getComponent("elements.AccessibleButton");
- const isHighlighted = this.props.phases.includes(this.props.currentPhase);
return }
- { isHighlighted ? : }
+ { this.props.isHighlighted ? : }
;
}
}
HeaderButton.propTypes = {
- // If currentPhase is one of the specified phases, the button will be highlighted
- phases: PropTypes.arrayOf(PropTypes.string).isRequired,
- // The currentPhase of the RightPanel
- currentPhase: PropTypes.string.isRequired,
+ // Whether this button is highlighted
+ isHighlighted: PropTypes.bool.isRequired,
// The phase to swap to when the button is clicked
clickPhase: PropTypes.string.isRequired,
// The source file of the icon to display
@@ -243,22 +240,18 @@ module.exports = React.createClass({
if (this.props.roomId) {
headerButtons = [
,
,
,
];