From bae35c0859e3e7ece4d6a25860eeeec9e1d7bc11 Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Thu, 30 Jan 2020 16:00:09 +0000 Subject: [PATCH] Change power icon to label instead --- res/css/views/rooms/_EntityTile.scss | 8 -------- src/components/views/rooms/EntityTile.js | 11 +++-------- 2 files changed, 3 insertions(+), 16 deletions(-) diff --git a/res/css/views/rooms/_EntityTile.scss b/res/css/views/rooms/_EntityTile.scss index 2b6b31acb4..92e0d5690c 100644 --- a/res/css/views/rooms/_EntityTile.scss +++ b/res/css/views/rooms/_EntityTile.scss @@ -64,14 +64,6 @@ limitations under the License. position: relative; } -.mx_EntityTile_power { - position: absolute; - width: 16px; - height: 17px; - top: 0px; - right: 6px; -} - .mx_EntityTile_name, .mx_GroupRoomTile_name { flex: 1 1 0; diff --git a/src/components/views/rooms/EntityTile.js b/src/components/views/rooms/EntityTile.js index 57db1ac240..40bf9f6d78 100644 --- a/src/components/views/rooms/EntityTile.js +++ b/src/components/views/rooms/EntityTile.js @@ -156,18 +156,13 @@ const EntityTile = createReactClass({ ); } - let power; + let powerLabel; const powerStatus = this.props.powerStatus; if (powerStatus) { - const src = { - [EntityTile.POWER_STATUS_MODERATOR]: require("../../../../res/img/mod.svg"), - [EntityTile.POWER_STATUS_ADMIN]: require("../../../../res/img/admin.svg"), - }[powerStatus]; - const alt = { + powerLabel = { [EntityTile.POWER_STATUS_MODERATOR]: _t("Moderator"), [EntityTile.POWER_STATUS_ADMIN]: _t("Admin"), }[powerStatus]; - power = {alt}; } const BaseAvatar = sdk.getComponent('avatars.BaseAvatar'); @@ -181,7 +176,7 @@ const EntityTile = createReactClass({ onClick={this.props.onClick}>
{ av } - { power } + { powerLabel }
{ nameEl } { inviteButton }