File

core/common/virtual-scroll/virtual-scroll-window-strategy.ts

Implements

VirtualScrollStrategy

Index

Properties
Methods

Constructor

constructor(itemSizePx: number, offsetSizePx: number, minBufferPx: number, maxBufferPx: number)
Parameters :
Name Type Optional
itemSizePx number No
offsetSizePx number No
minBufferPx number No
maxBufferPx number No

Properties

scrolledIndexChange
Type : Observable<number>

Methods

attach
attach(viewport: CdkVirtualScrollViewport)

Attaches this scroll strategy to a viewport.

Parameters :
Name Type Optional Description
viewport CdkVirtualScrollViewport No

The viewport to attach this strategy to.

Returns : void
detach
detach()

Detaches this scroll strategy from the currently attached viewport.

Returns : void
onContentRendered
onContentRendered()
Returns : void
onContentScrolled
onContentScrolled()
Returns : void
onDataLengthChanged
onDataLengthChanged()
Returns : void
onRenderedOffsetChanged
onRenderedOffsetChanged()
Returns : void
scrollToIndex
scrollToIndex(index: number, behavior: ScrollBehavior)

Scroll to the offset for the given index.

Parameters :
Name Type Optional Description
index number No

The index of the element to scroll to.

behavior ScrollBehavior No

The ScrollBehavior to use when scrolling.

Returns : void
updateItemAndBufferSize
updateItemAndBufferSize(itemSize: number, offsetSizePx: number, minBufferPx: number, maxBufferPx: number)

Update the item size and buffer size.

Parameters :
Name Type Optional Description
itemSize number No

The size of the items in the virtually scrolling list.

offsetSizePx number No

The size of the offset (in pixels)..

minBufferPx number No

The minimum amount of buffer (in pixels) before needing to render more

maxBufferPx number No

The amount of buffer (in pixels) to render when rendering more.

Returns : void

results matching ""

    No results matching ""