Skip to content

Commit 68d88e0

Browse files
authored
Merge pull request #8434 from IgniteUI/mdragnev/fix-8426
fix(addRow): Fix keyboard combination for IE and Edge
2 parents 3b25190 + 9667aab commit 68d88e0

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

projects/igniteui-angular/src/lib/core/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ export const NAVIGATION_KEYS = new Set([
328328
]);
329329
export const ROW_EXPAND_KEYS = new Set('right down arrowright arrowdown'.split(' '));
330330
export const ROW_COLLAPSE_KEYS = new Set('left up arrowleft arrowup'.split(' '));
331-
export const SUPPORTED_KEYS = new Set([...Array.from(NAVIGATION_KEYS), 'enter', 'f2', 'escape', 'esc', 'pagedown', 'pageup', '+']);
331+
export const SUPPORTED_KEYS = new Set([...Array.from(NAVIGATION_KEYS), 'enter', 'f2', 'escape', 'esc', 'pagedown', 'pageup', '+', 'add']);
332332
export const HEADER_KEYS = new Set([...Array.from(NAVIGATION_KEYS), 'escape', 'esc' , 'l']);
333333

334334
/**

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ export class IgxGridNavigationService {
5151
!this.grid.crudService.rowEditingBlocked && !this.grid.rowInEditMode) { return; }
5252
const shift = event.shiftKey;
5353
const ctrl = event.ctrlKey;
54-
const alt = event.altKey;
5554
if (NAVIGATION_KEYS.has(key) && this.pendingNavigation) { event.preventDefault(); return; }
5655

5756
const type = this.isDataRow(this.activeNode.row) ? 'dataCell' :
@@ -631,6 +630,6 @@ export class IgxGridNavigationService {
631630
}
632631

633632
private isAddKey(key: string): boolean {
634-
return key === '+';
633+
return key === '+' || key === 'add'; // add is for IE and Edge
635634
}
636635
}

0 commit comments

Comments
 (0)