Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove hover effect from user name on a DM creation UI #10887

Merged
merged 1 commit into from
May 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions cypress/e2e/invite/invite-dialog.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,15 @@ describe("Invite dialog", function () {
// Assert that the invite dialog disappears
cy.get(".mx_InviteDialog_other").should("not.exist");

// Assert that the hovered user name on invitation UI does not have background color
// TODO: implement the test on room-header.spec.ts
cy.get(".mx_RoomHeader").within(() => {
cy.get(".mx_RoomHeader_name--textonly")
.realHover()
.get(".mx_RoomHeader_name--textonly:hover")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like this might cause flakiness.

.should("have.css", "background-color", "rgba(0, 0, 0, 0)");
});

// Send a message to invite the bots
cy.getComposer().type("Hello{enter}");

Expand Down
15 changes: 10 additions & 5 deletions res/css/views/rooms/_RoomHeader.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ limitations under the License.
padding: 1px 4px;
display: flex;
user-select: none;
cursor: pointer;

&:hover {
background-color: $quinary-content;
Expand All @@ -102,6 +103,14 @@ limitations under the License.
background-color: $tertiary-content;
}

&.mx_RoomHeader_name--textonly {
cursor: unset;

&:hover {
background-color: unset;
}
}

&[aria-expanded="true"] {
background-color: $quinary-content;

Expand All @@ -120,11 +129,6 @@ limitations under the License.
opacity: 0.6;
}

.mx_RoomHeader_name:not(.mx_RoomHeader_name--textonly),
.mx_RoomHeader_avatar {
cursor: pointer;
}

.mx_RoomTopic {
position: relative;
cursor: pointer;
Expand Down Expand Up @@ -157,6 +161,7 @@ limitations under the License.
flex: 0;
margin: 0 7px;
position: relative;
cursor: pointer;
}

.mx_RoomHeader_avatar .mx_BaseAvatar_image {
Expand Down
Loading