Mouse

import {Mouse} from 'cabbie-async';

Mouse commands relative to a DOM-element

Methods

buttonDown(button?): Promise<void>

Click and hold any mouse button at the center of the element

buttonDownAt(xOffset, yOffset, button?): Promise<void>

xOffset
number
yOffset
number
button
MouseButton

Click and hold any mouse button at a specified offset of the element

buttonUp(button?): Promise<void>

Releases a mouse button at the center of the element

buttonUpAt(xOffset, yOffset, button?): Promise<void>

xOffset
number
yOffset
number
button
MouseButton

Releases a mouse button at a specified offset of the element

click(button?): Promise<void>

Click any mouse button at the center of the element

clickAt(xOffset, yOffset, button?): Promise<void>

xOffset
number
yOffset
number
button
MouseButton

Click any mouse button at a specified offset of the element

doubleClick(): Promise<void>

Double-clicks the element at the center of the element

doubleClickAt(xOffset, yOffset): Promise<void>

xOffset
number
yOffset
number

Double-clicks the element at a specified offset of the element

moveTo(xOffset, yOffset): Promise<void>

xOffset
number
yOffset
number

Move the mouse by an offset of the element

moveToCenter(): Promise<void>

Move the mouse to the center of the element