// Dismiss the cookie-consent banner if it's showing. It is fixed to the bottom // of the viewport and intercepts pointer events over the catalog footer (where // row-select checkboxes live), so tests that click there must clear it first. export async function dismissCookies(page) { const banner = page.locator('.cookie-consent-banner') if (await banner.count()) { await page.getByRole('button', { name: 'Save choice' }).click().catch(() => {}) await banner.waitFor({ state: 'hidden' }).catch(() => {}) } }