1
0
forked from Mapan/odoo17e
odoo17e-kedaikipas58/addons/web_grid/static/tests/helpers.js
2024-12-10 09:04:09 +07:00

17 lines
400 B
JavaScript

/** @odoo-module */
import { nextTick, triggerEvents } from "@web/../tests/helpers/utils";
/**
* @param {HTMLElement} cell
*/
export async function hoverGridCell(cell) {
const rect = cell.getBoundingClientRect();
const evAttrs = {
clientX: rect.x,
clientY: rect.y,
};
await triggerEvents(cell, null, ["mouseover", ["mousemove", evAttrs]]);
await nextTick();
}