Fix extensions panel style (#29273)
* Stop empty state scrolling * Fix separator inset, separator vertical spacing and margin above the add extensions button * Add screenshot for add extensions button spacing * Add variable for add extensions overlap * use data-testid * Fix snapshots
This commit is contained in:
@@ -81,10 +81,12 @@ test.describe("RightPanel", () => {
|
|||||||
await expect(page.locator(".mx_RightPanel")).toMatchScreenshot("with-leave-room.png");
|
await expect(page.locator(".mx_RightPanel")).toMatchScreenshot("with-leave-room.png");
|
||||||
});
|
});
|
||||||
|
|
||||||
test("should handle clicking add widgets", async ({ page, app }) => {
|
test("should handle clicking add widgets", { tag: "@screenshot" }, async ({ page, app }) => {
|
||||||
await viewRoomSummaryByName(page, app, ROOM_NAME);
|
await viewRoomSummaryByName(page, app, ROOM_NAME);
|
||||||
|
|
||||||
await page.getByRole("menuitem", { name: "Extensions" }).click();
|
await page.getByRole("menuitem", { name: "Extensions" }).click();
|
||||||
|
await expect(page.getByTestId("right-panel")).toMatchScreenshot("with-extensions.png");
|
||||||
|
|
||||||
await page.getByRole("button", { name: "Add extensions" }).click();
|
await page.getByRole("button", { name: "Add extensions" }).click();
|
||||||
await expect(page.locator(".mx_IntegrationManager")).toBeVisible();
|
await expect(page.locator(".mx_IntegrationManager")).toBeVisible();
|
||||||
});
|
});
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 77 KiB |
@@ -7,12 +7,11 @@ Please see LICENSE files in the repository root for full details.
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
.mx_ExtensionsCard {
|
.mx_ExtensionsCard {
|
||||||
--cpd-separator-inset: var(--cpd-space-4x);
|
--cpd-separator-spacing: var(--cpd-space-6x);
|
||||||
--cpd-separator-spacing: var(--cpd-space-4x);
|
--AddExtension-overlap: -76px;
|
||||||
|
|
||||||
.mx_AutoHideScrollbar {
|
.mx_AutoHideScrollbar {
|
||||||
padding: 0 var(--cpd-space-4x);
|
padding: 0 var(--cpd-space-4x);
|
||||||
margin-top: var(--cpd-space-3x);
|
margin-top: var(--cpd-space-6x);
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
|
||||||
/* Styling for the "Add extensions" button */
|
/* Styling for the "Add extensions" button */
|
||||||
@@ -128,6 +127,11 @@ Please see LICENSE files in the repository root for full details.
|
|||||||
|
|
||||||
.mx_EmptyState::before {
|
.mx_EmptyState::before {
|
||||||
/* Overlap the Add extensions button */
|
/* Overlap the Add extensions button */
|
||||||
top: -76px;
|
top: var(--AddExtension-overlap);
|
||||||
|
}
|
||||||
|
|
||||||
|
.mx_EmptyState {
|
||||||
|
/* Stop empty state scrolling */
|
||||||
|
height: calc(100% + var(--AddExtension-overlap));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -282,7 +282,7 @@ export default class RightPanel extends React.Component<Props, IState> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<aside className="mx_RightPanel" id="mx_RightPanel">
|
<aside className="mx_RightPanel" id="mx_RightPanel" data-testid="right-panel">
|
||||||
{card}
|
{card}
|
||||||
</aside>
|
</aside>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -2121,6 +2121,7 @@ exports[`RoomView video rooms should render joined video room view 1`] = `
|
|||||||
>
|
>
|
||||||
<aside
|
<aside
|
||||||
class="mx_RightPanel"
|
class="mx_RightPanel"
|
||||||
|
data-testid="right-panel"
|
||||||
id="mx_RightPanel"
|
id="mx_RightPanel"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ exports[`AppTile destroys non-persisted right panel widget on room change 1`] =
|
|||||||
<DocumentFragment>
|
<DocumentFragment>
|
||||||
<aside
|
<aside
|
||||||
class="mx_RightPanel"
|
class="mx_RightPanel"
|
||||||
|
data-testid="right-panel"
|
||||||
id="mx_RightPanel"
|
id="mx_RightPanel"
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
|
|||||||
Reference in New Issue
Block a user