v1.22.0
Highlights
-
Role selectors that allow selecting elements by their ARIA role, ARIA attributes and accessible name.
// Click a button with accessible name "log in" await page.ClickAsync("role=button[name='log in']")
Read more in our documentation.
-
New
Locator.Filter
API to filter an existing locatorvar buttons = page.Locator("role=button"); // ... var submitLocator = buttons.Filter(new LocatorFilterOptions { HasText = "Sign up" }); await submitLocator.ClickAsync();