MCPcopy Create free account
hub / github.com/angular/components / withScrollableParents

Method withScrollableParents

src/cdk/drag-drop/drop-list-ref.ts:394–402  ·  view source on GitHub ↗

* Sets which parent elements are can be scrolled while the user is dragging. * @param elements Elements that can be scrolled.

(elements: HTMLElement[])

Source from the content-addressed store, hash-verified

392 * @param elements Elements that can be scrolled.
393 */
394 withScrollableParents(elements: HTMLElement[]): this {
395 const element = this._container;
396
397 // We always allow the current element to be scrollable
398 // so we need to ensure that it's in the array.
399 this._scrollableElements =
400 elements.indexOf(element) === -1 ? [element, ...elements] : elements.slice();
401 return this;
402 }
403
404 /**
405 * Configures the drop list so that a different element is used as the container for the

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected