You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-13 08:02:38 +03:00
Fix discrepancies with style
This commit is contained in:
@@ -225,7 +225,6 @@ limitations under the License.
|
|||||||
}
|
}
|
||||||
|
|
||||||
.mx_RoomTile2_iconFavorite::before {
|
.mx_RoomTile2_iconFavorite::before {
|
||||||
background-color: $accent-color;
|
|
||||||
mask-image: url('$(res)/img/feather-customised/favourites.svg');
|
mask-image: url('$(res)/img/feather-customised/favourites.svg');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -364,7 +364,9 @@ export default class RoomTile2 extends React.Component<IProps, IState> {
|
|||||||
const roomTags = RoomListStore.instance.getTagsForRoom(this.props.room);
|
const roomTags = RoomListStore.instance.getTagsForRoom(this.props.room);
|
||||||
|
|
||||||
const isFavorite = roomTags.includes(DefaultTagID.Favourite);
|
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;
|
let contextMenu = null;
|
||||||
if (this.state.generalMenuPosition) {
|
if (this.state.generalMenuPosition) {
|
||||||
@@ -373,12 +375,13 @@ export default class RoomTile2 extends React.Component<IProps, IState> {
|
|||||||
<div className="mx_IconizedContextMenu mx_IconizedContextMenu_compact mx_RoomTile2_contextMenu">
|
<div className="mx_IconizedContextMenu mx_IconizedContextMenu_compact mx_RoomTile2_contextMenu">
|
||||||
<div className="mx_IconizedContextMenu_optionList">
|
<div className="mx_IconizedContextMenu_optionList">
|
||||||
<MenuItemCheckbox
|
<MenuItemCheckbox
|
||||||
|
className={favouriteLabelClassName}
|
||||||
onClick={(e) => this.onTagRoom(e, DefaultTagID.Favourite)}
|
onClick={(e) => this.onTagRoom(e, DefaultTagID.Favourite)}
|
||||||
active={isFavorite}
|
active={isFavorite}
|
||||||
label={_t("Favourite")}
|
label={favouriteLabel}
|
||||||
>
|
>
|
||||||
<span className={classNames("mx_IconizedContextMenu_icon", favoriteClassName)} />
|
<span className={classNames("mx_IconizedContextMenu_icon", favouriteIconClassName)} />
|
||||||
<span className="mx_IconizedContextMenu_label">{_t("Favourite")}</span>
|
<span className="mx_IconizedContextMenu_label">{favouriteLabel}</span>
|
||||||
</MenuItemCheckbox>
|
</MenuItemCheckbox>
|
||||||
<MenuItem onClick={this.onOpenRoomSettings} label={_t("Settings")}>
|
<MenuItem onClick={this.onOpenRoomSettings} label={_t("Settings")}>
|
||||||
<span className="mx_IconizedContextMenu_icon mx_RoomTile2_iconSettings" />
|
<span className="mx_IconizedContextMenu_icon mx_RoomTile2_iconSettings" />
|
||||||
|
|||||||
@@ -1226,6 +1226,7 @@
|
|||||||
"All messages": "All messages",
|
"All messages": "All messages",
|
||||||
"Mentions & Keywords": "Mentions & Keywords",
|
"Mentions & Keywords": "Mentions & Keywords",
|
||||||
"Notification options": "Notification options",
|
"Notification options": "Notification options",
|
||||||
|
"Favourited": "Favourited",
|
||||||
"Favourite": "Favourite",
|
"Favourite": "Favourite",
|
||||||
"Leave Room": "Leave Room",
|
"Leave Room": "Leave Room",
|
||||||
"Room options": "Room options",
|
"Room options": "Room options",
|
||||||
|
|||||||
Reference in New Issue
Block a user