Skip to content

Commit a72848f

Browse files
authored
Merge pull request #16926 from IgniteUI/iminchev/elements-cell-activation-21.1.x
1 parent 95224f3 commit a72848f

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

projects/igniteui-angular/grids/core/src/cell.component.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ import {
5555
IgxTextSelectionDirective,
5656
IgxFocusDirective,
5757
IgxTextHighlightDirective
58-
} from 'igniteui-angular/directives';
58+
} from 'igniteui-angular/directives';
5959
import { fadeOut, scaleInCenter } from 'igniteui-angular/animations';
6060
import { IgxChipComponent } from 'igniteui-angular/chips';
6161
import { IgxInputDirective, IgxInputGroupComponent, IgxPrefixDirective, IgxSuffixDirective } from 'igniteui-angular/input-group';
@@ -1181,6 +1181,7 @@ export class IgxGridCellComponent implements OnInit, OnChanges, OnDestroy, CellT
11811181
if (this.grid.isCellSelectable && shouldEmitSelection) {
11821182
this.zone.run(() => this.grid.selected.emit({ cell: this.getCellType(), event }));
11831183
}
1184+
11841185
}
11851186

11861187
/**

projects/igniteui-angular/grids/core/src/grid-navigation.service.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,10 +105,16 @@ export class IgxGridNavigationService {
105105
this.grid.selectionService.keyboardStateOnKeydown(this.activeNode, shift, shift && key === 'tab');
106106
}
107107
const position = this.getNextPosition(this.activeNode.row, this.activeNode.column, key, shift, ctrl, event);
108+
const shouldNotifyVirtualizedKeyboardSelection =
109+
ctrl && (key === 'arrowup' || key === 'up' || key === 'arrowdown' || key === 'down') &&
110+
this.shouldPerformVerticalScroll(position.rowIndex, position.colIndex);
108111
if (NAVIGATION_KEYS.has(key)) {
109112
event.preventDefault();
110113
this.navigateInBody(position.rowIndex, position.colIndex, (obj) => {
111114
obj.target.activate(event);
115+
if (shouldNotifyVirtualizedKeyboardSelection) {
116+
this.grid.notifyChanges();
117+
}
112118
});
113119
}
114120
}

0 commit comments

Comments
 (0)