MCPcopy Index your code
hub / github.com/angular/components / _getOverlayPositionStrategy

Method _getOverlayPositionStrategy

src/cdk/menu/menu-trigger.ts:284–295  ·  view source on GitHub ↗

Build the position strategy for the overlay which specifies where to place the menu.

()

Source from the content-addressed store, hash-verified

282
283 /** Build the position strategy for the overlay which specifies where to place the menu. */
284 private _getOverlayPositionStrategy(): FlexibleConnectedPositionStrategy {
285 const strategy = createFlexibleConnectedPositionStrategy(this._injector, this._elementRef)
286 .withLockedPosition()
287 .withFlexibleDimensions(false)
288 .withPositions(this._getOverlayPositions());
289
290 if (this.transformOriginSelector) {
291 strategy.withTransformOriginOn(this.transformOriginSelector);
292 }
293
294 return strategy;
295 }
296
297 /** Get the preferred positions for the opened menu relative to the menu item. */
298 private _getOverlayPositions(): ConnectedPosition[] {

Callers 2

ngOnChangesMethod · 0.95
_getOverlayConfigMethod · 0.95

Calls 6

_getOverlayPositionsMethod · 0.95
withPositionsMethod · 0.80
withLockedPositionMethod · 0.80
withTransformOriginOnMethod · 0.80

Tested by

no test coverage detected