Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions docs/src/api/class-page.md
Original file line number Diff line number Diff line change
Expand Up @@ -3183,7 +3183,7 @@ page.get_by_role("button", name="Start here").click()

```python async
# Setup the handler.
def handler():
async def handler():
await page.get_by_role("button", name="No thanks").click()
await page.add_locator_handler(page.get_by_text("Sign up to the newsletter"), handler)

Expand Down Expand Up @@ -3240,7 +3240,7 @@ page.get_by_role("button", name="Start here").click()

```python async
# Setup the handler.
def handler():
async def handler():
await page.get_by_role("button", name="Remind me later").click()
await page.add_locator_handler(page.get_by_text("Confirm your security details"), handler)

Expand Down Expand Up @@ -3297,7 +3297,7 @@ page.get_by_role("button", name="Start here").click()

```python async
# Setup the handler.
def handler():
async def handler():
await page.evaluate("window.removeObstructionsForTestIfNeeded()")
await page.add_locator_handler(page.locator("body"), handler, no_wait_after=True)

Expand Down Expand Up @@ -3338,7 +3338,7 @@ page.add_locator_handler(page.get_by_label("Close"), handler, times=1)
```

```python async
def handler(locator):
async def handler(locator):
await locator.click()
await page.add_locator_handler(page.get_by_label("Close"), handler, times=1)
```
Expand Down
Loading