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

Fix E2E icon display in room header #12545

Merged
merged 3 commits into from
May 20, 2024
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
22 changes: 22 additions & 0 deletions playwright/e2e/room/room-header.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -276,4 +276,26 @@ test.describe("Room Header", () => {
await expect(header).toMatchScreenshot("room-header-with-apps-button-not-highlighted.png");
});
});

test.describe("with encryption", () => {
test("should render the E2E icon and the buttons", async ({ page, app, user }) => {
// Create an encrypted room
await app.client.createRoom({
name: "Test Encrypted Room",
initial_state: [
{
type: "m.room.encryption",
state_key: "",
content: {
algorithm: "m.megolm.v1.aes-sha2",
},
},
],
});
await app.viewRoomByName("Test Encrypted Room");

const header = page.locator(".mx_LegacyRoomHeader");
await expect(header).toMatchScreenshot("encrypted-room-header.png");
});
});
});
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions res/css/views/rooms/_LegacyRoomHeader.pcss
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,11 @@ limitations under the License.
.mx_BetaCard_betaPill {
margin-right: $spacing-8;
}

/* The container of E2EIcon in the legacy header needs to have its height set */
& > span {
height: 100%;
}
}

.mx_LegacyRoomHeader_name {
Expand Down
Loading