ng-virtual-list 0.5.1 → 0.6.0
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.
- package/README.md +4 -3
- package/fesm2022/ng-virtual-list.mjs +549 -88
- package/fesm2022/ng-virtual-list.mjs.map +1 -1
- package/lib/components/ng-virtual-list-item.component.d.ts +2 -0
- package/lib/const/index.d.ts +2 -0
- package/lib/models/render-item-config.model.d.ts +1 -0
- package/lib/ng-virtual-list.component.d.ts +21 -11
- package/lib/utils/cacheMap.d.ts +31 -0
- package/lib/utils/eventEmitter.d.ts +37 -0
- package/lib/utils/index.d.ts +3 -1
- package/lib/utils/trackBox.d.ts +78 -0
- package/lib/utils/tracker.d.ts +38 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
# NgVirtualList
|
|
2
|
-
|
|
2
|
+
Maximum performance for extremely large lists.
|
|
3
|
+
It is based on algorithms for virtualization of screen objects.
|
|
3
4
|
|
|
4
5
|
Angular version 19.X.X.
|
|
5
6
|
|
|
@@ -58,7 +59,7 @@ export class AppComponent {
|
|
|
58
59
|
Template:
|
|
59
60
|
```html
|
|
60
61
|
<ng-virtual-list class="list" direction="hotizontal" [items]="horizontalGroupItems" [itemRenderer]="horizontalGroupItemRenderer"
|
|
61
|
-
[itemsOffset]="50" [stickyMap]="horizontalGroupItemsStickyMap" [itemSize]="54"></ng-virtual-list>
|
|
62
|
+
[itemsOffset]="50" [stickyMap]="horizontalGroupItemsStickyMap" [itemSize]="54" [snap]="true"></ng-virtual-list>
|
|
62
63
|
|
|
63
64
|
<ng-template #horizontalGroupItemRenderer let-data="data">
|
|
64
65
|
@if (data) {
|
|
@@ -362,7 +363,7 @@ Inputs
|
|
|
362
363
|
|---|---|---|
|
|
363
364
|
| id | number | Readonly. Returns the unique identifier of the component. |
|
|
364
365
|
| items | [IVirtualListCollection](https://github.com/DjonnyX/ng-virtual-list/blob/main/projects/ng-virtual-list/src/lib/models/collection.model.ts) | Collection of list items. |
|
|
365
|
-
| itemSize | number | If direction = 'vertical', then the height of a typical element. If direction = 'horizontal', then the width of a typical element. |
|
|
366
|
+
| itemSize | number | If direction = 'vertical', then the height of a typical element. If direction = 'horizontal', then the width of a typical element. Ignored if the dynamicSize property is true. |
|
|
366
367
|
| itemsOffset | number? | Number of elements outside the scope of visibility. Default value is 2. |
|
|
367
368
|
| itemRenderer | TemplateRef | Rendering element template. |
|
|
368
369
|
| stickyMap | [IVirtualListStickyMap?](https://github.com/DjonnyX/ng-virtual-list/blob/main/projects/ng-virtual-list/src/lib/models/sticky-map.model.ts) | Dictionary zIndex by id of the list element. If the value is not set or equal to 0, then a simple element is displayed, if the value is greater than 0, then the sticky position mode is enabled for the element. |
|