mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 17:59:55 +02:00
20 lines
563 B
TypeScript
20 lines
563 B
TypeScript
export type Offset = {
|
|
width: number;
|
|
height: number;
|
|
left: number;
|
|
right: number;
|
|
top: number;
|
|
bottom: number;
|
|
absoluteTop: number;
|
|
absoluteLeft: number;
|
|
absoluteRight: number;
|
|
absoluteBottom: number;
|
|
};
|
|
/**
|
|
* Get an element position on the page relative to another element (or body) including scroll offset
|
|
* Thanks to `meouw`: http://stackoverflow.com/a/442474/375966
|
|
*
|
|
* @api private
|
|
* @returns Element's position info
|
|
*/
|
|
export default function getOffset(element: HTMLElement, relativeEl?: HTMLElement): Offset;
|