feat: replace menu with new design (#4012)

Co-authored-by: Alex Yang <himself65@outlook.com>
This commit is contained in:
Qi
2023-09-06 12:36:43 +08:00
committed by GitHub
parent ef3d3a34e2
commit d8c9f10bc1
51 changed files with 611 additions and 739 deletions
+3 -11
View File
@@ -200,20 +200,12 @@ export const createPageWithTag = async (
await page.keyboard.press('Escape');
};
export const changeFilter = async (page: Page, to: string | RegExp) => {
export const changeFilter = async (page: Page, to: string) => {
await page.getByTestId('filter-name').click();
await page
.getByTestId('filter-name-select')
.locator('button', { hasText: to })
.click();
await page.getByTestId(`filler-tag-${to}`).click();
};
export async function selectTag(page: Page, name: string | RegExp) {
await page.getByTestId('filter-arg').click();
await page
.getByTestId('multi-select')
.getByTestId('select-option')
.getByText(name, { exact: true })
.click();
await page.getByTestId('filter-arg').click();
await page.getByTestId(`multi-select-${name}`).click();
}