Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 20s
Build & Deploy / 🧪 QA (push) Failing after 34s
Build & Deploy / 🏗️ Build (push) Has started running
Build & Deploy / 🚀 Deploy (push) Has been cancelled
Build & Deploy / 🧪 Smoke Test (push) Has been cancelled
Build & Deploy / ⚡ Lighthouse (push) Has been cancelled
Build & Deploy / 🔔 Notify (push) Has been cancelled
26 lines
721 B
Plaintext
26 lines
721 B
Plaintext
import type { ClientRect } from '../../types';
|
|
interface Options {
|
|
ignoreTransform?: boolean;
|
|
}
|
|
/**
|
|
* Returns the bounding client rect of an element relative to the viewport.
|
|
*/
|
|
export declare function getClientRect(element: Element, options?: Options): {
|
|
top: number;
|
|
left: number;
|
|
width: number;
|
|
height: number;
|
|
bottom: number;
|
|
right: number;
|
|
};
|
|
/**
|
|
* Returns the bounding client rect of an element relative to the viewport.
|
|
*
|
|
* @remarks
|
|
* The ClientRect returned by this method does not take into account transforms
|
|
* applied to the element it measures.
|
|
*
|
|
*/
|
|
export declare function getTransformAgnosticClientRect(element: Element): ClientRect;
|
|
export {};
|