search

goog.positioning.MenuAnchoredPosition

Provided By
Extends

Encapsulates a popup position where the popup is anchored at a corner of an element. The positioning behavior changes based on the values of opt_adjust and opt_resize.

When using this positioning object it's recommended that the movable element be absolutely positioned.

new MenuAnchoredPosition( anchorElement, corner, opt_adjust, opt_resize )

Parameters
anchorElement(Element|null)

Element the movable element should be anchored against.

cornergoog.positioning.Corner

Corner of anchored element the movable element should be positioned at.

opt_adjustboolean=

Whether the positioning should be adjusted until the element fits inside the viewport even if that means that the anchored corners are ignored.

opt_resizeboolean=

Whether the positioning should be adjusted until the element fits inside the viewport on the X axis and its height is resized so if fits in the viewport. This take precedence over opt_adjust.

Instance Methods

Instance Properties