Emulate TabbedView's actual min and max widths on user settings tabs (#10737)

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
This commit is contained in:
Suguru Hirahara 2023-04-28 08:13:04 +00:00 committed by GitHub
parent 1281c0746b
commit 30ac950523
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 1 deletions

View file

@ -40,6 +40,14 @@ describe("Preferences user settings tab", () => {
cy.findByTestId("preferences").should("have.text", "Preferences").should("be.visible");
});
cy.get(".mx_SettingsTab.mx_PreferencesUserSettingsTab").percySnapshotElement("User settings tab - Preferences");
cy.get(".mx_SettingsTab.mx_PreferencesUserSettingsTab").percySnapshotElement(
"User settings tab - Preferences",
{
// Emulate TabbedView's actual min and max widths
// 580: '.mx_UserSettingsDialog .mx_TabbedView' min-width
// 796: 1036 (mx_TabbedView_tabsOnLeft actual width) - 240 (mx_TabbedView_tabPanel margin-right)
widths: [580, 796],
},
);
});
});