Содержимое обеих таблиц данных должно перемещаться вместе, когда я прокручиваю таблицу 1 или таблицу 2. То есть прокрутка обеих таблиц данных должна быть синхронизирована. .
HTML-код приведен ниже:
Код: Выделить всё
Код: Выделить всё
this.agGrid1._nativeElement.onscroll = function() {
this.agGrid2._nativeElement.scrollTop=this.agGrid1._nativeElement.scrollTop;
}
this.agGrid2._nativeElement.onscroll = function() {
this.agGrid1._nativeElement.scrollTop=this.agGrid2._nativeElement.scrollTop;
}
https://stackblitz.com/edit/angular-ag- ... Fapp%2Fapp .comComponent.ts
https://angular-ag-grid-common-scroll.stackblitz.io
Подробнее здесь: https://stackoverflow.com/questions/609 ... er-ag-grid
Мобильная версия