From a8643ff0398f6d43453a4108c62e3d1d975d1bae Mon Sep 17 00:00:00 2001 From: Kegan Dougal Date: Mon, 18 Jan 2016 17:37:17 +0000 Subject: [PATCH] Move power level stuff to EntityTile for now --- src/components/views/rooms/EntityTile.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/components/views/rooms/EntityTile.js b/src/components/views/rooms/EntityTile.js index 268de25e14..a0135fb0c3 100644 --- a/src/components/views/rooms/EntityTile.js +++ b/src/components/views/rooms/EntityTile.js @@ -108,6 +108,15 @@ module.exports = React.createClass({ ); } + var power; + var powerLevel = this.props.powerLevel; + if (powerLevel >= 50 && powerLevel < 99) { + power = Mod; + } + if (powerLevel >= 99) { + power = Admin; + } + var MemberAvatar = sdk.getComponent('avatars.MemberAvatar'); var BaseAvatar = sdk.getComponent('avatars.BaseAvatar'); @@ -122,6 +131,7 @@ module.exports = React.createClass({ {av} { nameEl } + { power } { inviteButton } );