UNPKG

292 BTypeScriptView Raw
1/**
2 * Returns the relative position of a given element.
3 *
4 * @param node the element
5 * @param offsetParent the offset parent
6 */
7export default function position(node: HTMLElement, offsetParent?: HTMLElement): {
8 top: number;
9 left: number;
10 height: number;
11 width: number;
12};