Sign up (with export icon)

PositioningFunction

Api-typedef icon typedef

Parameters

elementRect : Rect

The rect of the element to be positioned.

targetRect : Rect

The rect of the target the element (its rect) is relatively positioned to.

viewportRect : Rect

The rect of the visual browser viewport.

[ limiterRect ] : Rect

Returns

DomPositioningFunctionResult | null

When the function returns null, it will not be considered by getOptimalPosition.