nullifyTransforms

Commons
stable

Returns the bounding rect of an element after undoing its CSS transform (matrix / matrix3d). Used to get the true layout position regardless of applied transforms.

API

Signature

Full TypeScript signature sourced from the util file.

typescript

API

Parameters

Input parameters accepted by this util.

el
required
HTMLElement
The element whose transform-corrected bounding rect is computed.

API

Return value

The value returned by this util.

An IBox (top, left, width, height, bottom, right) representing the element's position in the viewport as if no transform had been applied.

Usage

Examples

Ready-to-paste usage snippets.

Get layout position ignoring CSS transforms

typescript