device.getParentBounds

getParentBounds(element: string | HTMLElement) → {DOMRect}

returns the size of the given HTMLElement Parent and its position relative to the viewport

See: https://developer.mozilla.org/en-US/docs/Web/API/DOMRect
Parameters:
Name Type Description
element string | HTMLElement

an HTMLElement object

Returns:
Type Description
DOMRect

the size and position of the given element parent relative to the viewport

Powered by webdoc!