Skip to content

Commit 1cd4636

Browse files
authored
Merge branch 'master' into apetrov/fix-tabs-demo-icon
2 parents b3330c2 + 07e2f05 commit 1cd4636

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

projects/igniteui-angular/src/lib/grids/grid-base.directive.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4106,7 +4106,10 @@ export abstract class IgxGridBaseDirective implements GridType,
41064106
return this._activeRowIndexes;
41074107
} else {
41084108
const activeRow = this.navigation.activeNode?.row;
4109-
const selectedCellIndexes = (this.selectionService.selection?.keys() as any)?.toArray();
4109+
4110+
const selectedCellIndexes = this.selectionService.selection
4111+
? Array.from(this.selectionService.selection.keys())
4112+
: [];
41104113
this._activeRowIndexes = [activeRow, ...selectedCellIndexes];
41114114
return this._activeRowIndexes;
41124115
}

projects/igniteui-angular/src/lib/grids/grid/grid-filtering-ui.spec.ts

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6580,27 +6580,24 @@ describe('IgxGrid - Filtering actions - Excel style filtering #grid', () => {
65806580

65816581
// Scroll the search list to the bottom.
65826582
let scrollbar = GridFunctions.getExcelStyleSearchComponentScrollbar(fix);
6583+
expect(scrollbar.scrollTop).toBe(0);
6584+
let listItems = GridFunctions.getExcelStyleSearchComponentListItems(fix);
6585+
expect(listItems[0].innerText).toBe('Select All');
6586+
65836587
scrollbar.scrollTop = 3000;
65846588
await wait();
65856589
fix.detectChanges();
6590+
expect(listItems[0].innerText).not.toBe('Select All');
6591+
expect(scrollbar.scrollTop).toBeGreaterThan(300);
65866592

65876593
// Select another column
65886594
GridFunctions.clickExcelFilterIcon(fix, 'Downloads');
65896595
await wait();
65906596
fix.detectChanges();
65916597

65926598
// Update scrollbar
6593-
const searchComponent = GridFunctions.getExcelStyleSearchComponent(fix);
65946599
scrollbar = GridFunctions.getExcelStyleSearchComponentScrollbar(fix);
6595-
await wait();
6596-
fix.detectChanges();
6597-
6598-
// Get the display container and its parent and verify that the display container is at start
6599-
const displayContainer = searchComponent.querySelector('igx-display-container');
6600-
const displayContainerRect = displayContainer.getBoundingClientRect();
6601-
const parentContainerRect = displayContainer.parentElement.getBoundingClientRect();
6602-
6603-
expect(displayContainerRect.top - parentContainerRect.top <= 1).toBe(true, 'search scrollbar did not reset');
6600+
expect(scrollbar.scrollTop).toBe(0, 'search scrollbar did not reset');
66046601
});
66056602
});
66066603

0 commit comments

Comments
 (0)