From 53bdddfcdd95ff908e143d695c18004426d9e07c Mon Sep 17 00:00:00 2001 From: Jorik Schellekens Date: Wed, 8 Jul 2020 16:07:38 +0100 Subject: [PATCH] Fix discrepancies with style --- res/css/views/rooms/_RoomTile2.scss | 1 - src/components/views/rooms/RoomTile2.tsx | 11 +++++++---- src/i18n/strings/en_EN.json | 1 + 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/res/css/views/rooms/_RoomTile2.scss b/res/css/views/rooms/_RoomTile2.scss index c6947e91c5..380a3ab9c7 100644 --- a/res/css/views/rooms/_RoomTile2.scss +++ b/res/css/views/rooms/_RoomTile2.scss @@ -225,7 +225,6 @@ limitations under the License. } .mx_RoomTile2_iconFavorite::before { - background-color: $accent-color; mask-image: url('$(res)/img/feather-customised/favourites.svg'); } diff --git a/src/components/views/rooms/RoomTile2.tsx b/src/components/views/rooms/RoomTile2.tsx index 8f00e2d085..aae731cf49 100644 --- a/src/components/views/rooms/RoomTile2.tsx +++ b/src/components/views/rooms/RoomTile2.tsx @@ -364,7 +364,9 @@ export default class RoomTile2 extends React.Component { const roomTags = RoomListStore.instance.getTagsForRoom(this.props.room); const isFavorite = roomTags.includes(DefaultTagID.Favourite); - const favoriteClassName = isFavorite ? "mx_RoomTile2_iconFavorite" : "mx_RoomTile2_iconStar"; + const favouriteIconClassName = isFavorite ? "mx_RoomTile2_iconFavorite" : "mx_RoomTile2_iconStar"; + const favouriteLabelClassName = isFavorite ? "mx_RoomTile2_contextMenu_activeRow" : ""; + const favouriteLabel = isFavorite ? _t("Favourited") : _t("Favourite"); let contextMenu = null; if (this.state.generalMenuPosition) { @@ -373,12 +375,13 @@ export default class RoomTile2 extends React.Component {
this.onTagRoom(e, DefaultTagID.Favourite)} active={isFavorite} - label={_t("Favourite")} + label={favouriteLabel} > - - {_t("Favourite")} + + {favouriteLabel} diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index e576411323..5e1b1c4397 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -1226,6 +1226,7 @@ "All messages": "All messages", "Mentions & Keywords": "Mentions & Keywords", "Notification options": "Notification options", + "Favourited": "Favourited", "Favourite": "Favourite", "Leave Room": "Leave Room", "Room options": "Room options",