Skip to content

Commit ff54941

Browse files
HristoP96HristoP96
authored andcommitted
Merge branch 'hPopov/new-component' of https://github.com/IgniteUI/igniteui-angular into hPopov/new-component
2 parents 603c046 + 33e3ef2 commit ff54941

File tree

9 files changed

+35
-13
lines changed

9 files changed

+35
-13
lines changed

package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
"classlist.js": "^1.1.20150312",
5959
"core-js": "^2.6.2",
6060
"hammerjs": "^2.0.8",
61-
"igniteui-trial-watermark": "^1.0.2",
61+
"igniteui-trial-watermark": "^1.0.3",
6262
"jszip": "^3.3.0",
6363
"resize-observer-polyfill": "^1.5.1",
6464
"rxjs": "^6.5.4",

projects/igniteui-angular/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
"hammerjs": "^2.0.8",
7272
"jszip": "^3.3.0",
7373
"resize-observer-polyfill": "^1.5.1",
74-
"igniteui-trial-watermark": "^1.0.2"
74+
"igniteui-trial-watermark": "^1.0.3"
7575
},
7676
"peerDependencies": {
7777
"@angular/common": "^9.0.0",

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

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6288,6 +6288,18 @@ export class IgxGridBaseDirective extends DisplayDensityBase implements
62886288
});
62896289
}
62906290
}
6291+
6292+
/**
6293+
* @hidden
6294+
* @internal
6295+
*/
6296+
public endRowEdit(commit = true, event?: Event) {
6297+
this.endEdit(commit, event);
6298+
const activeCell = this.navigation.activeNode;
6299+
if (activeCell && activeCell.row !== -1) {
6300+
this.tbody.nativeElement.focus();
6301+
}
6302+
}
62916303
/**
62926304
* @hidden
62936305
*/

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -434,7 +434,7 @@ describe('IgxGrid - Keyboard navigation #grid', () => {
434434
fix.detectChanges();
435435

436436
UIInteractions.triggerKeyDownEvtUponElem('end', cell.nativeElement, true, false, false, true);
437-
await wait(100);
437+
await wait(150);
438438
fix.detectChanges();
439439

440440
cell = grid.getCellByColumn(499, '49');

projects/igniteui-angular/src/lib/grids/grid/grid-mrl-keyboard-nav.spec.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1693,6 +1693,7 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
16931693
{ field: 'Fax', rowStart: 2, colStart: 1, colEnd: 3, rowEnd: 4 }
16941694
]
16951695
}];
1696+
await wait(DEBOUNCETIME);
16961697
fix.detectChanges();
16971698

16981699
setupGridScrollDetection(fix, fix.componentInstance.grid);
@@ -1704,6 +1705,8 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
17041705
GridFunctions.simulateGridContentKeydown(fix, 'end', false, false, true);
17051706
await wait(200);
17061707
fix.detectChanges();
1708+
await wait(200);
1709+
fix.detectChanges();
17071710

17081711
expect(fix.componentInstance.selectedCell.value)
17091712
.toEqual(fix.componentInstance.data[fix.componentInstance.data.length - 1].Fax);
@@ -1712,6 +1715,8 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
17121715
GridFunctions.simulateGridContentKeydown(fix, 'home', false, false, true);
17131716
await wait(200);
17141717
fix.detectChanges();
1718+
await wait(200);
1719+
fix.detectChanges();
17151720

17161721
expect(fix.componentInstance.selectedCell.value).toEqual(fix.componentInstance.data[0].CompanyName);
17171722
expect(fix.componentInstance.selectedCell.column.field).toMatch('CompanyName');
@@ -1816,6 +1821,7 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
18161821
{ field: 'Fax', rowStart: 2, colStart: 1, colEnd: 3, rowEnd: 4 }
18171822
]
18181823
}];
1824+
await wait(DEBOUNCETIME);
18191825
fix.detectChanges();
18201826
setupGridScrollDetection(fix, fix.componentInstance.grid);
18211827
// last cell from first layout
@@ -1828,13 +1834,15 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
18281834
GridFunctions.simulateGridContentKeydown(fix, 'End', false, false, true);
18291835
await wait(200);
18301836
fix.detectChanges();
1837+
await wait(200);
1838+
fix.detectChanges();
18311839

18321840
expect(fix.componentInstance.selectedCell.value)
18331841
.toEqual(fix.componentInstance.data[fix.componentInstance.data.length - 1].Fax);
18341842
expect(fix.componentInstance.selectedCell.column.field).toMatch('Fax');
18351843

18361844
GridFunctions.simulateGridContentKeydown(fix, 'Home', false, false, true);
1837-
await wait(100);
1845+
await wait(200);
18381846
fix.detectChanges();
18391847

18401848
expect(fix.componentInstance.selectedCell.value).toEqual(fix.componentInstance.data[0].CompanyName);
@@ -1872,6 +1880,7 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
18721880
{ field: 'Fax', rowStart: 2, colStart: 1, colEnd: 3, rowEnd: 4 }
18731881
]
18741882
}];
1883+
await wait(DEBOUNCETIME);
18751884
fix.detectChanges();
18761885
const firstCell = fix.debugElement.queryAll(By.css(CELL_CSS_CLASS))[0];
18771886

@@ -1931,6 +1940,7 @@ describe('IgxGrid Multi Row Layout - Keyboard navigation #grid', () => {
19311940
{ field: 'Fax', rowStart: 2, colStart: 1, colEnd: 3, rowEnd: 4 }
19321941
]
19331942
}];
1943+
await wait(DEBOUNCETIME);
19341944
fix.detectChanges();
19351945
const rows = fix.debugElement.queryAll(By.css(ROW_CSS_CLASS));
19361946
const firstCell = rows[2].queryAll(By.css(CELL_CSS_CLASS))[0];

projects/igniteui-angular/src/lib/grids/grid/grid.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -292,8 +292,8 @@
292292
</ng-template>
293293

294294
<ng-template #defaultRowEditActions>
295-
<button igxButton igxRowEditTabStop (click)="endEdit(false, $event)">Cancel</button>
296-
<button igxButton igxRowEditTabStop (click)="endEdit(true, $event)">Done</button>
295+
<button igxButton igxRowEditTabStop (click)="endRowEdit(false, $event)">Cancel</button>
296+
<button igxButton igxRowEditTabStop (click)="endRowEdit(true, $event)">Done</button>
297297
</ng-template>
298298

299299
<ng-template #defaultRowEditTemplate>

projects/igniteui-angular/src/lib/grids/hierarchical-grid/hierarchical-grid.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,8 +238,8 @@
238238
You have {{ rowChangesCount }} changes in this row
239239
</ng-template>
240240
<ng-template #defaultRowEditActions>
241-
<button igxButton igxRowEditTabStop (click)="endEdit(false, $event)">Cancel</button>
242-
<button igxButton igxRowEditTabStop (click)="endEdit(true, $event)">Done</button>
241+
<button igxButton igxRowEditTabStop (click)="endRowEdit(false, $event)">Cancel</button>
242+
<button igxButton igxRowEditTabStop (click)="endRowEdit(true, $event)">Done</button>
243243
</ng-template>
244244
<ng-template #defaultRowEditTemplate>
245245
<div class="igx-banner__message">

projects/igniteui-angular/src/lib/grids/tree-grid/tree-grid.component.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,8 +207,8 @@
207207
</ng-template>
208208

209209
<ng-template #defaultRowEditActions>
210-
<button igxButton igxRowEditTabStop (click)="endEdit(false, $event)">Cancel</button>
211-
<button igxButton igxRowEditTabStop (click)="endEdit(true, $event)">Done</button>
210+
<button igxButton igxRowEditTabStop (click)="endRowEdit(false, $event)">Cancel</button>
211+
<button igxButton igxRowEditTabStop (click)="endRowEdit(true, $event)">Done</button>
212212
</ng-template>
213213

214214
<ng-template #defaultRowEditTemplate>

0 commit comments

Comments
 (0)