Skip to content

Commit

Permalink
add math.floor hoverElemAt
Browse files Browse the repository at this point in the history
  • Loading branch information
KearseTrevor committed Nov 14, 2024
1 parent 8fcea3a commit b6dcbca
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/browser/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export async function hoverElem(elem) {

export async function hoverElemAt(elem, offsetX = 0, offsetY = 0) {
const position = getElementPosition(elem);
return hoverAt(position.left + offsetX, position.top + offsetY);
return hoverAt(Math.floor(position.left + offsetX), Math.floor(position.top + offsetY));
}

export async function sendKeys(action, keys) {
Expand Down

0 comments on commit b6dcbca

Please sign in to comment.