119 questions
0
votes
0
answers
62
views
Angular CDK Virtual Scroll with Ionic Grid – Items shuffle position when scrolling in grid view
I am using Angular CDK Virtual Scroll together with Ionic Grid to render a list of cards.
The requirement is:
On mobile, show 2 cards per row.
On tablet/desktop, show 3 cards per row.
Support ...
0
votes
0
answers
78
views
Angular 13 Material <mat-select multiple> with cdk-virtual-scroll-viewport loses selection state after scrolling
I’m implementing a multi-select dropdown using Angular Material’s <mat-select multiple> and cdk-virtual-scroll-viewport for performance with large datasets.
Problem:
When I select multiple ...
0
votes
1
answer
120
views
Mat-Autocomplete with cdk-virtual-scroll-viewport (large data) arrow-keys didnt work
I am trying to use mat-autocomplete with large data. For the large data aspect im using a cdk-virtual-scroll-viewport with mat-autocomplete. Everything works except the Arrow-Key Navigation.
<mat-...
1
vote
1
answer
179
views
How to test CDK virtual scroll in a mat-select?
I have a <mat-select> displaying 100k items in a <cdk-virtual-scroll-viewport> and I would like to test it:
<mat-select
hideSingleSelectionIndicator
[formControl]="selectedItem&...
1
vote
0
answers
86
views
Scroll Sync between 2 Cdk virtual viewports header and row
I'm using a separate CDK virtual scroll viewport for the header and need to keep it synchronized with the main row viewport. Currently, I'm using the elementScrolled event of the row viewport to track ...
0
votes
0
answers
287
views
the virtual scroll CDK with dynamic size (Angular 18)
I use CDK virtual scroll to optimize the display of my data. I've even tested CDK experimental with autosizing, which obviously doesn't work in Angular 18.
My items have a minimum size of 26px, which ...
0
votes
1
answer
625
views
I am using cdk virtual scroll appendOnly mode, but its jerking on scroll
I am using cdk virtual scroll appendOnly mode with angular 13, but its jerking on scroll.
<cdk-virtual-scroll-viewport appendOnly
class="container-fluid table-grid h-100 ...
0
votes
1
answer
1k
views
CDK Virtual Scrolling Issue with maxBufferPx not displaying full list
I'm implementing CDK Virtual Scrolling for a large list, and while scrolling works smoothly with just minBufferPx, I'm having issues when adding maxBufferPx. Without it, I get this console error:
...
1
vote
0
answers
258
views
Use virtual scroll in Angular CDK table
I use Angular CDK table(ver. 15) to build a large table.
I want to improve the preformance by using cdk-virtual-scroll-viewport.
how can i combain the *cdkRowDef of CDK table with *cdkVirtualFor of ...
2
votes
1
answer
461
views
Angular: cdk-virtual-scroll-viewport- scrollWindow attribute not working in angular ssr (universal), giving error- document is not defined
On using cdk-virtual-scroll-viewport in Angular SSR app and adding scrollWindow attribute, I am getting the following error:-
document is not defined
at _CdkVirtualScrollableWindow (...\...
1
vote
1
answer
2k
views
cdk-virtual-scroll-viewport with search doesn't display the value
It has been days that I am trying to fix some angular 15 code but I can't find the solution.
I am using a mat-select(Legacy) with ngx-mat-select-search and virtual scroll cdk-virtual-scroll-viewport.
...
1
vote
1
answer
2k
views
CDK Virtual Scrolling wrong values seen when scrolling due to components having injected properties
I have an Angular16 Application that is using Angular's CDK virtual scrolling module - https://material.angular.io/cdk/scrolling/overview.
The components being scrolled (lets say ProductComponent) ...
0
votes
0
answers
359
views
Angular CDK Virtual Scroll causing memory issues
I've the following code:
<cdk-virtual-scroll-viewport #scrollSection id="scrollSection"
[itemSize]="generalSettings.rowHeight"
[attr.data-...
0
votes
1
answer
257
views
Why the "ExpressionChangedAfterItHasBeenCheckedError" occurs in my angular app?
I just did a carousel like component and I used it like a child in a parent component that passes it an Observable. Here is the code, first the child:
<div #container *ngIf="name && (...
1
vote
1
answer
2k
views
Custom scrollToIndex for mixed height items in a virtual scroll viewport
I'm using CDK virtual scrolling to display a list of items on a page. Worst case scenario for number of items is around 2K.
I'm using the default fixed size scrolling strategy.
The source for the data ...
1
vote
0
answers
265
views
Fast scroll with cdk-virtual-scroll-viewport shown empty spaces, any solution with Angular15+?
Fast scroll with cdk-virtual-scroll-viewport shown empty spaces, any solution with Angular15+ ?
0
votes
0
answers
134
views
angular grid slowness using mat-table having 150 editable columns and 1500 rows
We have requirement to show grid which can have 1500 rows and each row can have update 150 columns
This grid is implemented using angular mat-table, on-load entire grid is read only
Problem is, when ...
2
votes
2
answers
676
views
How to implement the pull to refresh in CDK virtual scrolled angular application
Currently I am using CDK virtual scroll in the DOM, but when scrolling fast there is glitch happening in the DOM , so I am planning to implement the Pull to refresh method, so how to implement this ...
0
votes
0
answers
577
views
cdkVirtualFor doesn't work with FormArray
I have problem with cdkVirtualFor with FormArray. It doesn't generate any items.
My html:
<cdk-virtual-scroll-viewport
[itemSize]="100"
class="viewport-container"
[...
2
votes
0
answers
91
views
VsCode Angular IntelliSense doesnt' work with cdkVirtualFor
I've installed the VsCode Angular Language Service Extension and I enabled strictTemplates in my .tsconfig.
It works almost like a charm. But I have a strange case. If you take a look at the images ...
3
votes
0
answers
322
views
angular material virtual scroll not showing selected value from second page
I am using angular material library virtual scroll widget 'cdk-virtual-scroll-viewport' and am able to load data in paginated basis on the scroll of it.
But here am facing a problem, how I can show ...
0
votes
2
answers
2k
views
How to mock 'CdkVirtualScrollViewport' for infinite scrolling in Angular?
@ViewChild('scroller')
scroller!: CdkVirtualScrollViewport;
constructor(private ngZone: NgZone) { }
ngAfterViewInit(): void {
this.unsub = this.scroller.elementScrolled().pipe(
map(()...
0
votes
1
answer
1k
views
Cdk virtual scroll taking time rendering items after scrolling
I am using an expansion panel inside cdk-virtual-scroll.
In the header of the expansion panel, I have to show 4 values, which is causing a delay of nearly one second in rendering items while scrolling....
0
votes
0
answers
790
views
Use multiple cdk-virtual-scroll-viewport in the same page
cdk-virtual-scroll-viewport is not working properly when I use more than two cdk-virtual-scroll-viewport in the same page.
Stackblitz example
In the above example, first dropdown is working properly. ...
1
vote
2
answers
2k
views
CdkVirtualScrollViewport header is not fixed
In my angular application, I want to keep my table header at fixed position and display the scrollbar to the body part only.
I am using CdkVirtualScrollViewport library from angular to plot the table ...
1
vote
1
answer
2k
views
cdk virtual scroll issue when ever scrolling it down items are getting displayed slowly and sometimes blank for 2 secs
i am using angular virtual scroll in project so when ever i am scrolling it down items are loading but flickering for micro sec
trying with maxBufferPx and minBufferPx and positions to fix but not ...
0
votes
1
answer
725
views
Height and width in Percentage is not working for cdk-virtual-scroll-viewport
I have a cdk-virtual-scroll-viewport in my application where height and width are provided in percentage.
<div class="wrapper">
<cdk-virtual-scroll-viewport itemSize="5&...
2
votes
2
answers
2k
views
How to use cdk-virtual-scroll with ngx-infinite-scroll
I've upgraded my Angular project dependencies:
@angular/core: ^14.2.9
@angular/cdk: ^14.2.9
@angular/material: ^14.2.6
ngx-infinite-scroll: ~14.0.1
And after that, the infinite scroll (with ...
1
vote
2
answers
10k
views
CDK Virtual Scroll for Angular Material Table not working
I have an angular material table that has millions of records, I have added pagination which has options like 10, 25, 50, 100, 500, and 1000, and the max length of the records, which I select 1000 or ...
5
votes
1
answer
2k
views
cdk-virtual-scroll-viewport messes up scrolling
I have faced similar problem like this one https://github.com/angular/components/issues/16330#issuecomment-514591282
, but it happened not only while scrolling but when I tried filtering data. I used ...
1
vote
1
answer
2k
views
Angular Material CdkVirtualScrollViewport getRenderedRange() method always return {start : 0, end: 0}
I'm trying to implement Angular Material virtual scrolling, but my items have different sizes. So I must code a custom implementation of VirtualScrollStrategy.
The thing is, I need to use the ...
4
votes
1
answer
4k
views
Angular cdk-virtual-scroll-viewport not taking max height until screen is resized
TLDR: have a list of items that need to be in a virtual scroll. It works fine, but only takes up ~30% of the space available until the screen size is changed. (make the dev tools larger).
On initial ...
1
vote
1
answer
1k
views
Angular Material Virtual Scroll height not adjusting correctly
I have a virtual scroll element within an Angular Material Sidenav but it seems this causes the virtual scroll to render incorrectly. I suspect that because the scroll is created "off screen"...
2
votes
2
answers
6k
views
How to resize angular cdk virtual viewport height when viewport size changes
I'm working on Angular cdk virtual viewport. Is there any way to automatically adjust height of scroll viewport?
So in my case When viewport size increases there is a blank space displays at the ...
2
votes
1
answer
2k
views
Scroll flickering issue - using cdk-virtual-scroll with scroll-snap-type
I am using cdk-virtual-scroll.
It is working fine without using the css property scroll-snap-type .
When I use scroll-snap-type it is flickering few seconds. herewith I attached the code sample
https:...
1
vote
0
answers
1k
views
PrimeNg table row grouping and virtual scrolling
Row Group feature works well until I set virtual scrolling to true it stops working. I inspected the table element and found that the group header row totally disappears in virtual scrolling mode. I ...
0
votes
3
answers
6k
views
Primeng table virtual scroll header jumping while scrolling up
I have a large set of data that needs virtual scrolling and I use PrimeNg v13.4.0 with angular/cdk v13.3.7. I have exactly the same issue with PrimeNg demo. When scrolling down, the sticky header ...
3
votes
0
answers
890
views
Angular - Horizontal virtual scrolling with multiple columns
I would like to build the attached functionality, where I have around 20k items. I have tried mat cdk virtual scroller, but it is not working as it provides a single column with a horizontal scroll.
...
0
votes
1
answer
2k
views
how to make cdk virtual scroll render items of the table
I'm using CDK VIRTUAL SCROLL in a table that loads a service (API) that returns me a list, with this list I can remove or return their columns respectively as well as their items, but when I remove ...
1
vote
1
answer
2k
views
How to fit non-list items into virtual scroll using Angular Material CDK
I am currently trying to understand the concepts of virtual scrolling and for that I extensively used the Angular documentation on Angular's CDK. I found out that they implemented virtual scrolling ...
0
votes
2
answers
2k
views
How to track the scroll event of individual cdk-virtual-scroll-viewport
I am using cdk-virtual-scroll-viewport to build pagination scroll in my app. I have two instances of cdk-virtual-scroll-viewport, Want to track individual scroll events and make API call for the ...
0
votes
0
answers
620
views
mat-nav-list inside cdk-virtual-scroll-viewport not getting updated with the HTTP data
I am getting list of "incident_ids" from a HTTP get call as shown in the ts file and populating in the HTML in the mat-nav-list. Problem is mat-nav-list inside cdk-virtual-scroll-viewport ...
2
votes
0
answers
2k
views
NG-ZORRO and Angular CDK infinite scroll is not working well
I'm using cdk virtual scrolling in an Angular project with Ng-zorro. I have a list of collapse component and in that list is where I use the virtual scrolling.
The problem is that when I open a ...
1
vote
2
answers
2k
views
How can I Collapse/Expand Multiple Divs in ngx-virtual-scroll?
https://stackblitz.com/edit/angular-ngx-virtual-scroller-byykpn
Here is what I have done so far, now I need to Expand/Collapse all divs which is after the group header.
1
vote
1
answer
1k
views
Why is @angular/core/core has no exported member 'ɵɵFactoryDeclaration'. error thrown when using angular cdk virtual scroller
I installed CDK Virtual Scroller in my ionic 5.3.3 project:
npm add @angular/cdk
The version is: "@angular/cdk": "^13.0.2"
The scroller viewport wraps a ion-item-group:
<ng-...
4
votes
1
answer
3k
views
Angular virtual scroll not working correctly for nested for loop
The Angular Material cdk-virtual-scroll-viewport property is not working correctly for nested *cdkVirtualFor or *ngFor. The viewport is split into two and the scroll does not work as expected. Please ...
2
votes
0
answers
3k
views
Angular infinite virtual scrolling minBufferPx and maxBufferPx
According to the official documentation of angular virtual scrolling minBufferBx and maxBufferPx
Supposed that we have the following parameters: itemSize = 50,
minBufferPx = 100, maxBufferPx = 250. ...
2
votes
0
answers
1k
views
How to extend the CdkVirtualScrollViewport angular material component?
I currently have a use case where I would like to extend the CdkVirtualScrollViewport component so I could have access to its rendered template.
The specific case is that the base template renders a &...
2
votes
0
answers
867
views
Setting number of items for cdk-virtual-scroll-viewport
I have found a number of tutorials for using the cdk-virtual-scroll-viewport, but there is one thing missing from every single tutorial I have found so far: how do I tell the viewport how many items ...
0
votes
1
answer
657
views
Angular cdk-virtual-scroll-viewport return 0 when calling getBoundingClientRect
I have a table component which is contained inside cdk-virtual-scroll-viewport. One of the column cell contains
'..more'
option that expands the entire row. But when scrolled up/down the row ...