|
| None | move (self, float x, float y, *typing.Optional[int] steps=None) |
| |
| None | down (self, *typing.Optional[Literal["left", "middle", "right"]] button=None, typing.Optional[int] click_count=None) |
| |
| None | up (self, *typing.Optional[Literal["left", "middle", "right"]] button=None, typing.Optional[int] click_count=None) |
| |
| None | click (self, float x, float y, *typing.Optional[float] delay=None, typing.Optional[Literal["left", "middle", "right"]] button=None, typing.Optional[int] click_count=None) |
| |
| None | dblclick (self, float x, float y, *typing.Optional[float] delay=None, typing.Optional[Literal["left", "middle", "right"]] button=None) |
| |
| None | wheel (self, float delta_x, float delta_y) |
| |
| None | __init__ (self, Any impl_obj) |
| |
|
str | __str__ (self) |
| |
| None | on (self, Any event, Any f) |
| |
| None | once (self, Any event, Any f) |
| |
| None | remove_listener (self, Any event, Any f) |
| |
|
str | __repr__ (self) |
| |
|
|
Callable[..., None] | _wrap_handler (self, Union[Callable[..., Any], Any] handler) |
| |
|
| _loop |
| |
|
| _impl_obj |
| |
◆ click()
| None playwright.async_api._generated.Mouse.click |
( |
|
self, |
|
|
float |
x, |
|
|
float |
y, |
|
|
*typing.Optional[float] |
delay = None, |
|
|
typing.Optional[Literal["left", "middle", "right"]] |
button = None, |
|
|
typing.Optional[int] |
click_count = None |
|
) |
| |
Mouse.click
Shortcut for `mouse.move()`, `mouse.down()`, `mouse.up()`.
Parameters
----------
x : float
X coordinate relative to the main frame's viewport in CSS pixels.
y : float
Y coordinate relative to the main frame's viewport in CSS pixels.
delay : Union[float, None]
Time to wait between `mousedown` and `mouseup` in milliseconds. Defaults to 0.
button : Union["left", "middle", "right", None]
Defaults to `left`.
click_count : Union[int, None]
defaults to 1. See [UIEvent.detail].
◆ dblclick()
| None playwright.async_api._generated.Mouse.dblclick |
( |
|
self, |
|
|
float |
x, |
|
|
float |
y, |
|
|
*typing.Optional[float] |
delay = None, |
|
|
typing.Optional[Literal["left", "middle", "right"]] |
button = None |
|
) |
| |
Mouse.dblclick
Shortcut for `mouse.move()`, `mouse.down()`, `mouse.up()`, `mouse.down()` and
`mouse.up()`.
Parameters
----------
x : float
X coordinate relative to the main frame's viewport in CSS pixels.
y : float
Y coordinate relative to the main frame's viewport in CSS pixels.
delay : Union[float, None]
Time to wait between `mousedown` and `mouseup` in milliseconds. Defaults to 0.
button : Union["left", "middle", "right", None]
Defaults to `left`.
◆ down()
| None playwright.async_api._generated.Mouse.down |
( |
|
self, |
|
|
*typing.Optional[Literal["left", "middle", "right"]] |
button = None, |
|
|
typing.Optional[int] |
click_count = None |
|
) |
| |
Mouse.down
Dispatches a `mousedown` event.
Parameters
----------
button : Union["left", "middle", "right", None]
Defaults to `left`.
click_count : Union[int, None]
defaults to 1. See [UIEvent.detail].
◆ move()
| None playwright.async_api._generated.Mouse.move |
( |
|
self, |
|
|
float |
x, |
|
|
float |
y, |
|
|
*typing.Optional[int] |
steps = None |
|
) |
| |
Mouse.move
Dispatches a `mousemove` event.
Parameters
----------
x : float
X coordinate relative to the main frame's viewport in CSS pixels.
y : float
Y coordinate relative to the main frame's viewport in CSS pixels.
steps : Union[int, None]
Defaults to 1. Sends `n` interpolated `mousemove` events to represent travel between Playwright's current cursor
position and the provided destination. When set to 1, emits a single `mousemove` event at the destination location.
◆ up()
| None playwright.async_api._generated.Mouse.up |
( |
|
self, |
|
|
*typing.Optional[Literal["left", "middle", "right"]] |
button = None, |
|
|
typing.Optional[int] |
click_count = None |
|
) |
| |
Mouse.up
Dispatches a `mouseup` event.
Parameters
----------
button : Union["left", "middle", "right", None]
Defaults to `left`.
click_count : Union[int, None]
defaults to 1. See [UIEvent.detail].
◆ wheel()
| None playwright.async_api._generated.Mouse.wheel |
( |
|
self, |
|
|
float |
delta_x, |
|
|
float |
delta_y |
|
) |
| |
Mouse.wheel
Dispatches a `wheel` event. This method is usually used to manually scroll the page. See
[scrolling](https://playwright.dev/python/docs/input#scrolling) for alternative ways to scroll.
**NOTE** Wheel events may cause scrolling if they are not handled, and this method does not wait for the scrolling
to finish before returning.
Parameters
----------
delta_x : float
Pixels to scroll horizontally.
delta_y : float
Pixels to scroll vertically.
The documentation for this class was generated from the following file:
- docs/help/help-venv/lib/python3.12/site-packages/playwright/async_api/_generated.py