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

Commit a340387

Browse files
authored
Remove an obsolete CSS declaration and add a test to file-panel.spec.ts (#10498)
Signed-off-by: Suguru Hirahara <[email protected]>
1 parent 7a250f4 commit a340387

File tree

2 files changed

+16
-4
lines changed

2 files changed

+16
-4
lines changed

cypress/e2e/right-panel/file-panel.spec.ts

+16
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,22 @@ describe("FilePanel", () => {
210210
});
211211
});
212212
});
213+
214+
it("should not add inline padding to a tile when it is selected with right click", () => {
215+
// Upload a file
216+
uploadFile("cypress/fixtures/1sec.ogg");
217+
218+
cy.get(".mx_FilePanel .mx_RoomView_MessageList").within(() => {
219+
// Wait until the spinner of the audio player vanishes
220+
cy.get(".mx_InlineSpinner").should("not.exist");
221+
222+
// Right click the uploaded file to select the tile
223+
cy.get(".mx_EventTile").rightclick();
224+
225+
// Assert that inline padding is not applied
226+
cy.get(".mx_EventTile_selected .mx_EventTile_line").should("have.css", "padding-inline", "0px");
227+
});
228+
});
213229
});
214230

215231
describe("download", () => {

res/css/structures/_FilePanel.pcss

-4
Original file line numberDiff line numberDiff line change
@@ -111,10 +111,6 @@ limitations under the License.
111111
.mx_EventTile_line {
112112
margin-inline-end: 0;
113113
padding-inline-start: 0;
114-
115-
.mx_EventTile_selected & {
116-
padding-inline-start: 0;
117-
}
118114
}
119115
}
120116

0 commit comments

Comments
 (0)