Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit 50f7317

Browse files
authored
Remove hover effect from user name on a DM creation UI (#10887)
1 parent 938aefc commit 50f7317

File tree

2 files changed

+19
-5
lines changed

2 files changed

+19
-5
lines changed

cypress/e2e/invite/invite-dialog.spec.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,15 @@ describe("Invite dialog", function () {
164164
// Assert that the invite dialog disappears
165165
cy.get(".mx_InviteDialog_other").should("not.exist");
166166

167+
// Assert that the hovered user name on invitation UI does not have background color
168+
// TODO: implement the test on room-header.spec.ts
169+
cy.get(".mx_RoomHeader").within(() => {
170+
cy.get(".mx_RoomHeader_name--textonly")
171+
.realHover()
172+
.get(".mx_RoomHeader_name--textonly:hover")
173+
.should("have.css", "background-color", "rgba(0, 0, 0, 0)");
174+
});
175+
167176
// Send a message to invite the bots
168177
cy.getComposer().type("Hello{enter}");
169178

res/css/views/rooms/_RoomHeader.pcss

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ limitations under the License.
8080
padding: 1px 4px;
8181
display: flex;
8282
user-select: none;
83+
cursor: pointer;
8384

8485
&:hover {
8586
background-color: $quinary-content;
@@ -102,6 +103,14 @@ limitations under the License.
102103
background-color: $tertiary-content;
103104
}
104105

106+
&.mx_RoomHeader_name--textonly {
107+
cursor: unset;
108+
109+
&:hover {
110+
background-color: unset;
111+
}
112+
}
113+
105114
&[aria-expanded="true"] {
106115
background-color: $quinary-content;
107116

@@ -120,11 +129,6 @@ limitations under the License.
120129
opacity: 0.6;
121130
}
122131

123-
.mx_RoomHeader_name:not(.mx_RoomHeader_name--textonly),
124-
.mx_RoomHeader_avatar {
125-
cursor: pointer;
126-
}
127-
128132
.mx_RoomTopic {
129133
position: relative;
130134
cursor: pointer;
@@ -157,6 +161,7 @@ limitations under the License.
157161
flex: 0;
158162
margin: 0 7px;
159163
position: relative;
164+
cursor: pointer;
160165
}
161166

162167
.mx_RoomHeader_avatar .mx_BaseAvatar_image {

0 commit comments

Comments
 (0)