1
0
mirror of https://github.com/bitwarden/browser synced 2024-12-28 02:43:04 +01:00

[CL-524] Ignore flaky elements in Chromatic tests

This commit is contained in:
Vicki League 2024-12-23 11:31:45 -05:00
parent 23210f4a39
commit 6961f5a271
No known key found for this signature in database
GPG Key ID: 6A900B42463EAC13
3 changed files with 6 additions and 3 deletions

View File

@ -36,7 +36,7 @@ export class MenuTriggerForDirective implements OnDestroy {
private defaultMenuConfig: OverlayConfig = {
panelClass: "bit-menu-panel",
hasBackdrop: true,
backdropClass: "cdk-overlay-transparent-backdrop",
backdropClass: ["cdk-overlay-transparent-backdrop", "bit-menu-panel-backdrop"],
scrollStrategy: this.overlay.scrollStrategies.reposition(),
positionStrategy: this.overlay
.position()

View File

@ -10,9 +10,9 @@ import { TableDataSource, TableModule } from "../../../table";
selector: "dialog-virtual-scroll-block",
standalone: true,
imports: [DialogModule, IconButtonModule, SectionComponent, TableModule, ScrollingModule],
template: ` <bit-section>
template: /*html*/ `<bit-section>
<cdk-virtual-scroll-viewport scrollWindow itemSize="47">
<bit-table [dataSource]="dataSource">
<bit-table [dataSource]="dataSource" data-chromatic="ignore">
<ng-container header>
<tr>
<th bitCell bitSortable="id" default>Id</th>

View File

@ -130,6 +130,9 @@ export const MenuOpen: Story = {
const menuButton = getAllByRole(table, "button")[0];
await userEvent.click(menuButton);
},
parameters: {
chromatic: { ignoreSelectors: [".bit-menu-panel-backdrop"] },
},
};
export const DefaultDialogOpen: Story = {