ng-virtual-list 20.2.0 → 20.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/README.md +10 -10
  2. package/fesm2022/ng-virtual-list.mjs +54 -19
  3. package/fesm2022/ng-virtual-list.mjs.map +1 -1
  4. package/index.d.ts +802 -3
  5. package/package.json +1 -1
  6. package/lib/components/ng-virtual-list-item.component.d.ts +0 -34
  7. package/lib/const/index.d.ts +0 -41
  8. package/lib/enums/direction.d.ts +0 -8
  9. package/lib/enums/directions.d.ts +0 -16
  10. package/lib/enums/index.d.ts +0 -7
  11. package/lib/enums/snapping-method.d.ts +0 -10
  12. package/lib/enums/snapping-methods.d.ts +0 -16
  13. package/lib/models/collection.model.d.ts +0 -9
  14. package/lib/models/index.d.ts +0 -6
  15. package/lib/models/item.model.d.ts +0 -14
  16. package/lib/models/render-collection.model.d.ts +0 -9
  17. package/lib/models/render-item-config.model.d.ts +0 -41
  18. package/lib/models/render-item.model.d.ts +0 -33
  19. package/lib/models/scroll-direction.model.d.ts +0 -5
  20. package/lib/models/scroll-event.model.d.ts +0 -50
  21. package/lib/models/sticky-map.model.d.ts +0 -14
  22. package/lib/ng-virtual-list.component.d.ts +0 -144
  23. package/lib/types/id.d.ts +0 -7
  24. package/lib/types/index.d.ts +0 -4
  25. package/lib/types/rect.d.ts +0 -17
  26. package/lib/types/size.d.ts +0 -16
  27. package/lib/utils/browser.d.ts +0 -2
  28. package/lib/utils/cacheMap.d.ts +0 -60
  29. package/lib/utils/debounce.d.ts +0 -16
  30. package/lib/utils/eventEmitter.d.ts +0 -40
  31. package/lib/utils/index.d.ts +0 -7
  32. package/lib/utils/isDirection.d.ts +0 -8
  33. package/lib/utils/scrollEvent.d.ts +0 -39
  34. package/lib/utils/snapping-method.d.ts +0 -3
  35. package/lib/utils/toggleClassName.d.ts +0 -7
  36. package/lib/utils/trackBox.d.ts +0 -180
  37. package/lib/utils/tracker.d.ts +0 -44
  38. package/public-api.d.ts +0 -4
package/README.md CHANGED
@@ -25,10 +25,10 @@ npm i ng-virtual-list
25
25
 
26
26
  Template:
27
27
  ```html
28
- <ng-virtual-list class="list" direction="hotizontal" [items]="horizontalItems" [itemsOffset]="50"
29
- [itemRenderer]="hotizontalItemRenderer" [itemSize]="64"></ng-virtual-list>
28
+ <ng-virtual-list class="list" direction="horizontal" [items]="horizontalItems" [itemsOffset]="50"
29
+ [itemRenderer]="horizontalItemRenderer" [itemSize]="64"></ng-virtual-list>
30
30
 
31
- <ng-template #hotizontalItemRenderer let-data="data">
31
+ <ng-template #horizontalItemRenderer let-data="data">
32
32
  @if (data) {
33
33
  <div class="list__h-container" (click)="onItemClick(data)">
34
34
  <span>{{data.name}}</span>
@@ -63,7 +63,7 @@ export class AppComponent {
63
63
 
64
64
  Template:
65
65
  ```html
66
- <ng-virtual-list class="list" direction="hotizontal" [items]="horizontalGroupItems" [itemRenderer]="horizontalGroupItemRenderer"
66
+ <ng-virtual-list class="list" direction="horizontal" [items]="horizontalGroupItems" [itemRenderer]="horizontalGroupItemRenderer"
67
67
  [itemsOffset]="50" [stickyMap]="horizontalGroupItemsStickyMap" [itemSize]="54" [snap]="true"></ng-virtual-list>
68
68
 
69
69
  <ng-template #horizontalGroupItemRenderer let-data="data">
@@ -488,12 +488,12 @@ Methods
488
488
 
489
489
  | Angular version | ng-virtual-list version | git | npm |
490
490
  |--|--|--|--|
491
- | 19.x | 19.3.2 | [19.x](https://github.com/DjonnyX/ng-virtual-list/tree/19.x) | [19.3.2](https://www.npmjs.com/package/ng-virtual-list/v/19.3.2) |
492
- | 18.x | 18.2.0 | [18.x](https://github.com/DjonnyX/ng-virtual-list/tree/18.x) | [18.2.0](https://www.npmjs.com/package/ng-virtual-list/v/18.2.0) |
493
- | 17.x | 17.2.0 | [17.x](https://github.com/DjonnyX/ng-virtual-list/tree/17.x) | [17.2.0](https://www.npmjs.com/package/ng-virtual-list/v/17.2.0) |
494
- | 16.x | 16.2.0 | [16.x](https://github.com/DjonnyX/ng-virtual-list/tree/16.x) | [16.2.0](https://www.npmjs.com/package/ng-virtual-list/v/16.2.0) |
495
- | 15.x | 15.2.0 | [15.x](https://github.com/DjonnyX/ng-virtual-list/tree/15.x) | [15.2.0](https://www.npmjs.com/package/ng-virtual-list/v/15.2.0) |
496
- | 14.x | 14.2.0 | [14.x](https://github.com/DjonnyX/ng-virtual-list/tree/14.x) | [14.2.0](https://www.npmjs.com/package/ng-virtual-list/v/14.2.0) |
491
+ | 19.x | 19.3.5 | [19.x](https://github.com/DjonnyX/ng-virtual-list/tree/19.x) | [19.3.5](https://www.npmjs.com/package/ng-virtual-list/v/19.3.5) |
492
+ | 18.x | 18.3.1 | [18.x](https://github.com/DjonnyX/ng-virtual-list/tree/18.x) | [18.3.1](https://www.npmjs.com/package/ng-virtual-list/v/18.3.1) |
493
+ | 17.x | 17.3.1 | [17.x](https://github.com/DjonnyX/ng-virtual-list/tree/17.x) | [17.3.1](https://www.npmjs.com/package/ng-virtual-list/v/17.3.1) |
494
+ | 16.x | 16.3.1 | [16.x](https://github.com/DjonnyX/ng-virtual-list/tree/16.x) | [16.3.1](https://www.npmjs.com/package/ng-virtual-list/v/16.3.1) |
495
+ | 15.x | 15.3.1 | [15.x](https://github.com/DjonnyX/ng-virtual-list/tree/15.x) | [15.3.1](https://www.npmjs.com/package/ng-virtual-list/v/15.3.1) |
496
+ | 14.x | 14.3.1 | [14.x](https://github.com/DjonnyX/ng-virtual-list/tree/14.x) | [14.3.1](https://www.npmjs.com/package/ng-virtual-list/v/14.3.1) |
497
497
 
498
498
  <br/>
499
499
 
@@ -1,7 +1,7 @@
1
- import * as i0 from '@angular/core';
2
- import { signal, inject, ElementRef, ChangeDetectionStrategy, Component, viewChild, output, input, ViewContainerRef, ViewChild, ViewEncapsulation } from '@angular/core';
3
1
  import * as i1 from '@angular/common';
4
2
  import { CommonModule } from '@angular/common';
3
+ import * as i0 from '@angular/core';
4
+ import { signal, inject, ElementRef, ChangeDetectionStrategy, Component, viewChild, output, input, ViewContainerRef, ViewChild, ViewEncapsulation } from '@angular/core';
5
5
  import { toObservable, takeUntilDestroyed } from '@angular/core/rxjs-interop';
6
6
  import { tap, filter, map, combineLatest, distinctUntilChanged, switchMap, of } from 'rxjs';
7
7
 
@@ -82,13 +82,22 @@ const SCROLL_END = 'scrollend';
82
82
  const CLASS_LIST_VERTICAL = 'vertical';
83
83
  const CLASS_LIST_HORIZONTAL = 'horizontal';
84
84
 
85
+ /**
86
+ * Virtual List Item Interface
87
+ * @link https://github.com/DjonnyX/ng-virtual-list/blob/20.x/projects/ng-virtual-list/src/lib/models/-basevirtual-list-item-component.ts
88
+ * @author Evgenii Grebennikov
89
+ * @email djonnyx@gmail.com
90
+ */
91
+ class BaseVirtualListItemComponent {
92
+ }
93
+
85
94
  /**
86
95
  * Virtual list item component
87
96
  * @link https://github.com/DjonnyX/ng-virtual-list/blob/20.x/projects/ng-virtual-list/src/lib/components/ng-virtual-list-item.component.ts
88
97
  * @author Evgenii Grebennikov
89
98
  * @email djonnyx@gmail.com
90
99
  */
91
- class NgVirtualListItemComponent {
100
+ class NgVirtualListItemComponent extends BaseVirtualListItemComponent {
92
101
  static __nextId = 0;
93
102
  _id;
94
103
  get id() {
@@ -128,6 +137,7 @@ class NgVirtualListItemComponent {
128
137
  return this._elementRef.nativeElement;
129
138
  }
130
139
  constructor() {
140
+ super();
131
141
  this._id = NgVirtualListItemComponent.__nextId = NgVirtualListItemComponent.__nextId === Number.MAX_SAFE_INTEGER
132
142
  ? 0 : NgVirtualListItemComponent.__nextId + 1;
133
143
  }
@@ -194,10 +204,10 @@ class NgVirtualListItemComponent {
194
204
  styles.transform = ZEROS_TRANSLATE_3D;
195
205
  styles.zIndex = HIDDEN_ZINDEX;
196
206
  }
197
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgVirtualListItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
198
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: NgVirtualListItemComponent, isStandalone: true, selector: "ng-virtual-list-item", host: { classAttribute: "ngvl__item" }, ngImport: i0, template: "@let item = data();\r\n@let renderer = itemRenderer();\r\n\r\n@if (item) {\r\n <li #listItem part=\"item\" class=\"ngvl-item__container\" [ngClass]=\"{'snapped': item.config.snapped,\r\n 'snapped-out': item.config.snappedOut}\">\r\n @if (renderer) {\r\n <ng-container [ngTemplateOutlet]=\"renderer\"\r\n [ngTemplateOutletContext]=\"{data: item.data || {}, config: item.config}\" />\r\n }\r\n </li>\r\n}", styles: [":host{display:block;position:absolute;left:0;top:0;box-sizing:border-box;overflow:hidden;will-change:scroll-position}.ngvl-item__container{margin:0;padding:0;overflow:hidden;background-color:#fff;width:inherit;height:inherit}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
207
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: NgVirtualListItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
208
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.4", type: NgVirtualListItemComponent, isStandalone: true, selector: "ng-virtual-list-item", host: { classAttribute: "ngvl__item" }, usesInheritance: true, ngImport: i0, template: "@let item = data();\r\n@let renderer = itemRenderer();\r\n\r\n@if (item) {\r\n <li #listItem part=\"item\" class=\"ngvl-item__container\" [ngClass]=\"{'snapped': item.config.snapped,\r\n 'snapped-out': item.config.snappedOut}\">\r\n @if (renderer) {\r\n <ng-container [ngTemplateOutlet]=\"renderer\"\r\n [ngTemplateOutletContext]=\"{data: item.data || {}, config: item.config}\" />\r\n }\r\n </li>\r\n}", styles: [":host{display:block;position:absolute;left:0;top:0;box-sizing:border-box;overflow:hidden;will-change:scroll-position}.ngvl-item__container{margin:0;padding:0;overflow:hidden;background-color:#fff;width:inherit;height:inherit}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
199
209
  }
200
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgVirtualListItemComponent, decorators: [{
210
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: NgVirtualListItemComponent, decorators: [{
201
211
  type: Component,
202
212
  args: [{ selector: 'ng-virtual-list-item', imports: [CommonModule], host: {
203
213
  'class': 'ngvl__item',
@@ -1102,7 +1112,7 @@ class TrackBox extends CacheMap {
1102
1112
  }
1103
1113
  }
1104
1114
  if (deletedItemsMap.hasOwnProperty(i)) {
1105
- const bounds = deletedItemsMap[i], size = bounds[sizeProperty] ?? typicalItemSize;
1115
+ const bounds = deletedItemsMap[i], size = bounds?.[sizeProperty] ?? typicalItemSize;
1106
1116
  if (y < scrollSize - size) {
1107
1117
  leftSizeOfDeletedItems += size;
1108
1118
  }
@@ -1193,6 +1203,9 @@ class TrackBox extends CacheMap {
1193
1203
  let pos = startPosition, renderItems = renderItemsLength, stickyItem, nextSticky, stickyItemIndex = -1, stickyItemSize = 0, endStickyItem, nextEndSticky, endStickyItemIndex = -1, endStickyItemSize = 0;
1194
1204
  if (snap) {
1195
1205
  for (let i = Math.min(itemsFromStartToScrollEnd > 0 ? itemsFromStartToScrollEnd : 0, totalLength - 1); i >= 0; i--) {
1206
+ if (!items[i]) {
1207
+ continue;
1208
+ }
1196
1209
  const id = items[i].id, sticky = stickyMap[id], size = dynamicSize ? this.get(id)?.[sizeProperty] || typicalItemSize : typicalItemSize;
1197
1210
  if (sticky === 1) {
1198
1211
  const measures = {
@@ -1482,6 +1495,7 @@ class NgVirtualListComponent {
1482
1495
  * Rendering element template.
1483
1496
  */
1484
1497
  itemRenderer = input.required();
1498
+ _itemRenderer = signal(undefined);
1485
1499
  /**
1486
1500
  * Dictionary zIndex by id of the list element. If the value is not set or equal to 0,
1487
1501
  * then a simple element is displayed, if the value is greater than 0, then the sticky position mode is enabled for the element.
@@ -1590,10 +1604,18 @@ class NgVirtualListComponent {
1590
1604
  * The name of the property by which tracking is performed
1591
1605
  */
1592
1606
  trackBy = input(TRACK_BY_PROPERTY_NAME);
1607
+ /**
1608
+ * Base class of the element component
1609
+ */
1610
+ _itemComponentClass = NgVirtualListItemComponent;
1611
+ /**
1612
+ * Base class trackBox
1613
+ */
1614
+ _trackBoxClass = TrackBox;
1593
1615
  /**
1594
1616
  * Dictionary of element sizes by their id
1595
1617
  */
1596
- _trackBox = new TrackBox(this.trackBy());
1618
+ _trackBox = new this._trackBoxClass(this.trackBy());
1597
1619
  _onTrackBoxChangeHandler = (v) => {
1598
1620
  this._cacheVersion.set(v);
1599
1621
  };
@@ -1650,12 +1672,19 @@ class NgVirtualListComponent {
1650
1672
  }
1651
1673
  return of(displayItems);
1652
1674
  })).subscribe();
1653
- combineLatest([this.$initialized, toObservable(this.itemRenderer)]).pipe(takeUntilDestroyed(), distinctUntilChanged(), filter(([initialized]) => !!initialized), tap(([, itemRenderer]) => {
1654
- this.resetRenderers(itemRenderer);
1655
- }));
1675
+ this.setupRenderer();
1676
+ }
1677
+ setupRenderer() {
1678
+ const $itemRenderer = toObservable(this.itemRenderer);
1679
+ $itemRenderer.pipe(takeUntilDestroyed(), distinctUntilChanged(), filter(v => !!v), tap(v => {
1680
+ this._itemRenderer.set(v);
1681
+ })).subscribe();
1656
1682
  }
1657
1683
  /** @internal */
1658
1684
  ngOnInit() {
1685
+ this.onInit();
1686
+ }
1687
+ onInit() {
1659
1688
  this._initialized.set(true);
1660
1689
  }
1661
1690
  listenCacheChangesIfNeed(value) {
@@ -1685,7 +1714,7 @@ class NgVirtualListComponent {
1685
1714
  }
1686
1715
  if (this._isSnappingMethodAdvanced && this.snap()) {
1687
1716
  if (!this._snapedDisplayComponent && this._snapContainerRef) {
1688
- const comp = this._snapContainerRef.createComponent(NgVirtualListItemComponent);
1717
+ const comp = this._snapContainerRef.createComponent(this._itemComponentClass);
1689
1718
  comp.instance.regular = true;
1690
1719
  this._snapedDisplayComponent = comp;
1691
1720
  this._trackBox.snapedDisplayComponent = this._snapedDisplayComponent;
@@ -1698,7 +1727,7 @@ class NgVirtualListComponent {
1698
1727
  const maxLength = displayItems.length, components = this._displayComponents;
1699
1728
  while (components.length < maxLength) {
1700
1729
  if (_listContainerRef) {
1701
- const comp = _listContainerRef.createComponent(NgVirtualListItemComponent);
1730
+ const comp = _listContainerRef.createComponent(this._itemComponentClass);
1702
1731
  components.push(comp);
1703
1732
  this._componentsResizeObserver.observe(comp.instance.element);
1704
1733
  }
@@ -1714,13 +1743,13 @@ class NgVirtualListComponent {
1714
1743
  const item = components[i];
1715
1744
  if (item) {
1716
1745
  const id = item.instance.id;
1717
- item.instance.renderer = itemRenderer || this.itemRenderer();
1746
+ item.instance.renderer = itemRenderer || this._itemRenderer();
1718
1747
  doMap[id] = i;
1719
1748
  }
1720
1749
  }
1721
1750
  if (this._isSnappingMethodAdvanced && this.snap() && this._snapedDisplayComponent && this._snapContainerRef) {
1722
1751
  const comp = this._snapedDisplayComponent;
1723
- comp.instance.renderer = itemRenderer || this.itemRenderer();
1752
+ comp.instance.renderer = itemRenderer || this._itemRenderer();
1724
1753
  }
1725
1754
  this._trackBox.setDisplayObjectIndexMapById(doMap);
1726
1755
  }
@@ -1838,6 +1867,9 @@ class NgVirtualListComponent {
1838
1867
  };
1839
1868
  /** @internal */
1840
1869
  ngAfterViewInit() {
1870
+ this.afterViewInit();
1871
+ }
1872
+ afterViewInit() {
1841
1873
  const containerEl = this._container();
1842
1874
  if (containerEl) {
1843
1875
  // for direction calculation
@@ -1851,6 +1883,9 @@ class NgVirtualListComponent {
1851
1883
  }
1852
1884
  /** @internal */
1853
1885
  ngOnDestroy() {
1886
+ this.dispose();
1887
+ }
1888
+ dispose() {
1854
1889
  this.clearScrollToRepeatExecutionTimeout();
1855
1890
  if (this._trackBox) {
1856
1891
  this._trackBox.dispose();
@@ -1880,10 +1915,10 @@ class NgVirtualListComponent {
1880
1915
  }
1881
1916
  }
1882
1917
  }
1883
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgVirtualListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1884
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.14", type: NgVirtualListComponent, isStandalone: true, selector: "ng-virtual-list", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, snap: { classPropertyName: "snap", publicName: "snap", isSignal: true, isRequired: false, transformFunction: null }, enabledBufferOptimization: { classPropertyName: "enabledBufferOptimization", publicName: "enabledBufferOptimization", isSignal: true, isRequired: false, transformFunction: null }, itemRenderer: { classPropertyName: "itemRenderer", publicName: "itemRenderer", isSignal: true, isRequired: true, transformFunction: null }, stickyMap: { classPropertyName: "stickyMap", publicName: "stickyMap", isSignal: true, isRequired: false, transformFunction: null }, itemSize: { classPropertyName: "itemSize", publicName: "itemSize", isSignal: true, isRequired: false, transformFunction: null }, dynamicSize: { classPropertyName: "dynamicSize", publicName: "dynamicSize", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, itemsOffset: { classPropertyName: "itemsOffset", publicName: "itemsOffset", isSignal: true, isRequired: false, transformFunction: null }, snappingMethod: { classPropertyName: "snappingMethod", publicName: "snappingMethod", isSignal: true, isRequired: false, transformFunction: null }, trackBy: { classPropertyName: "trackBy", publicName: "trackBy", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onScroll: "onScroll", onScrollEnd: "onScrollEnd" }, viewQueries: [{ propertyName: "_snappedContainer", first: true, predicate: ["snapped"], descendants: true, isSignal: true }, { propertyName: "_container", first: true, predicate: ["container"], descendants: true, isSignal: true }, { propertyName: "_list", first: true, predicate: ["list"], descendants: true, isSignal: true }, { propertyName: "_listContainerRef", first: true, predicate: ["renderersContainer"], descendants: true, read: ViewContainerRef }, { propertyName: "_snapContainerRef", first: true, predicate: ["snapRendererContainer"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "@if (snap()) {\r\n<div #snapped part=\"snapped-item\" class=\"ngvl__list-snapper\">\r\n <ng-container #snapRendererContainer></ng-container>\r\n</div>\r\n}\r\n<div #container part=\"scroller\" class=\"ngvl__scroller\">\r\n <ul #list part=\"list\" class=\"ngvl__list\">\r\n <ng-container #renderersContainer></ng-container>\r\n </ul>\r\n</div>", styles: [":host{position:relative;display:block;width:400px;overflow:hidden}:host(.horizontal){height:48px}:host(.horizontal) .ngvl__list{display:inline-flex}:host(.horizontal) .ngvl__scroller{overflow:auto hidden}:host(.vertical) .ngvl__scroller{overflow:hidden auto}:host(.vertical){height:320px}.ngvl__scroller{overflow:auto;width:100%;height:100%}.ngvl__list-snapper{pointer-events:none;position:absolute;list-style:none;left:0;top:0;z-index:1}.ngvl__list{position:relative;list-style:none;padding:0;margin:0;width:100%;height:100%}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.ShadowDom });
1918
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: NgVirtualListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1919
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.4", type: NgVirtualListComponent, isStandalone: true, selector: "ng-virtual-list", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, snap: { classPropertyName: "snap", publicName: "snap", isSignal: true, isRequired: false, transformFunction: null }, enabledBufferOptimization: { classPropertyName: "enabledBufferOptimization", publicName: "enabledBufferOptimization", isSignal: true, isRequired: false, transformFunction: null }, itemRenderer: { classPropertyName: "itemRenderer", publicName: "itemRenderer", isSignal: true, isRequired: true, transformFunction: null }, stickyMap: { classPropertyName: "stickyMap", publicName: "stickyMap", isSignal: true, isRequired: false, transformFunction: null }, itemSize: { classPropertyName: "itemSize", publicName: "itemSize", isSignal: true, isRequired: false, transformFunction: null }, dynamicSize: { classPropertyName: "dynamicSize", publicName: "dynamicSize", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null }, itemsOffset: { classPropertyName: "itemsOffset", publicName: "itemsOffset", isSignal: true, isRequired: false, transformFunction: null }, snappingMethod: { classPropertyName: "snappingMethod", publicName: "snappingMethod", isSignal: true, isRequired: false, transformFunction: null }, trackBy: { classPropertyName: "trackBy", publicName: "trackBy", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onScroll: "onScroll", onScrollEnd: "onScrollEnd" }, viewQueries: [{ propertyName: "_snappedContainer", first: true, predicate: ["snapped"], descendants: true, isSignal: true }, { propertyName: "_container", first: true, predicate: ["container"], descendants: true, isSignal: true }, { propertyName: "_list", first: true, predicate: ["list"], descendants: true, isSignal: true }, { propertyName: "_listContainerRef", first: true, predicate: ["renderersContainer"], descendants: true, read: ViewContainerRef }, { propertyName: "_snapContainerRef", first: true, predicate: ["snapRendererContainer"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "@if (snap()) {\r\n<div #snapped part=\"snapped-item\" class=\"ngvl__list-snapper\">\r\n <ng-container #snapRendererContainer></ng-container>\r\n</div>\r\n}\r\n<div #container part=\"scroller\" class=\"ngvl__scroller\">\r\n <ul #list part=\"list\" class=\"ngvl__list\">\r\n <ng-container #renderersContainer></ng-container>\r\n </ul>\r\n</div>", styles: [":host{position:relative;display:block;width:400px;overflow:hidden}:host(.horizontal){height:48px}:host(.horizontal) .ngvl__list{display:inline-flex}:host(.horizontal) .ngvl__scroller{overflow:auto hidden}:host(.vertical) .ngvl__scroller{overflow:hidden auto}:host(.vertical){height:320px}.ngvl__scroller{overflow:auto;width:100%;height:100%}.ngvl__list-snapper{pointer-events:none;position:absolute;list-style:none;left:0;top:0;z-index:1}.ngvl__list{position:relative;list-style:none;padding:0;margin:0;width:100%;height:100%}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.ShadowDom });
1885
1920
  }
1886
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImport: i0, type: NgVirtualListComponent, decorators: [{
1921
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: NgVirtualListComponent, decorators: [{
1887
1922
  type: Component,
1888
1923
  args: [{ selector: 'ng-virtual-list', imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.ShadowDom, template: "@if (snap()) {\r\n<div #snapped part=\"snapped-item\" class=\"ngvl__list-snapper\">\r\n <ng-container #snapRendererContainer></ng-container>\r\n</div>\r\n}\r\n<div #container part=\"scroller\" class=\"ngvl__scroller\">\r\n <ul #list part=\"list\" class=\"ngvl__list\">\r\n <ng-container #renderersContainer></ng-container>\r\n </ul>\r\n</div>", styles: [":host{position:relative;display:block;width:400px;overflow:hidden}:host(.horizontal){height:48px}:host(.horizontal) .ngvl__list{display:inline-flex}:host(.horizontal) .ngvl__scroller{overflow:auto hidden}:host(.vertical) .ngvl__scroller{overflow:hidden auto}:host(.vertical){height:320px}.ngvl__scroller{overflow:auto;width:100%;height:100%}.ngvl__list-snapper{pointer-events:none;position:absolute;list-style:none;left:0;top:0;z-index:1}.ngvl__list{position:relative;list-style:none;padding:0;margin:0;width:100%;height:100%}\n"] }]
1889
1924
  }], ctorParameters: () => [], propDecorators: { _listContainerRef: [{
@@ -1902,5 +1937,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.14", ngImpo
1902
1937
  * Generated bundle index. Do not edit.
1903
1938
  */
1904
1939
 
1905
- export { Directions, NgVirtualListComponent, SnappingMethods };
1940
+ export { BaseVirtualListItemComponent, Directions, NgVirtualListComponent, NgVirtualListItemComponent, SnappingMethods };
1906
1941
  //# sourceMappingURL=ng-virtual-list.mjs.map