Ensure interface gradually reduces visible buttons when viewport shrinks (#33477)

* Rewrite Measured to be a functional component

* Add tests to cover narrow viewports

* lint

* breakpoint is optional

* Cleanup

* Provide default value

* Fixup

* fix two snaps

* Update screenshot

* and the other one

* unfake CIDER

* Update snaps AGAIN
This commit is contained in:
Will Hunt
2026-05-14 16:15:43 +01:00
committed by GitHub
parent cff2c4cd25
commit ab904bb6ca
16 changed files with 66 additions and 51 deletions
@@ -327,19 +327,19 @@ test.describe("Threads", () => {
test.describe("with larger viewport", async () => {
// Increase viewport size so that voice messages fit
test.use({ viewport: { width: 1280, height: 720 } });
test.use({ viewport: { width: 1440, height: 720 } });
test.beforeEach(async ({ page }) => {
// Increase right-panel size, so that voice messages fit
await page.addInitScript(() => {
window.localStorage.setItem("mx_rhs_size", "600");
window.localStorage.setItem("mx_rhs_size", "700");
});
});
test("can send voice messages", { tag: ["@no-firefox", "@no-webkit"] }, async ({ page, app, user }) => {
// Increase right-panel size, so that voice messages fit
await page.evaluate(() => {
window.localStorage.setItem("mx_rhs_size", "600");
window.localStorage.setItem("mx_rhs_size", "700");
});
const roomId = await app.client.createRoom({});