Skip to content

Commit b3a698f

Browse files
authored
Merge branch '21.0.x' into rivanova/fix-16649-21.0.x
2 parents 5b9d8e9 + 058e3d0 commit b3a698f

6 files changed

Lines changed: 27 additions & 14 deletions

File tree

projects/igniteui-angular/core/src/core/styles/components/grid/_excel-filtering-theme.scss

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,8 @@
190190
&:not(:nth-child(1)) {
191191
margin: 0;
192192
}
193+
194+
@include type-style('button');
193195
}
194196
}
195197

@@ -806,10 +808,6 @@
806808
}
807809
}
808810

809-
%igx-group-item {
810-
@include type-style('button');
811-
}
812-
813811
%grid-excel-menu__secondary--cosy {
814812
%grid-excel-menu__header > h4 {
815813
@include type-style('h6');

projects/igniteui-angular/core/src/core/styles/components/grid/_grid-theme.scss

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -185,12 +185,12 @@
185185
igx-input-group {
186186
background: var-get($theme, 'cell-editing-background');
187187

188-
input {
188+
.igx-input-group__input {
189189
height: 100%;
190190
color: var-get($theme, 'cell-editing-foreground');
191191
}
192192

193-
input:focus {
193+
.igx-input-group__input:focus {
194194
color: var-get($theme, 'cell-editing-focus-foreground');
195195
}
196196
}
@@ -270,6 +270,8 @@
270270

271271
.igx-input-group__input {
272272
padding-inline: sizable(rem(4px), rem(6px), rem(8px)) !important;
273+
margin: 0 auto;
274+
max-width: 100%;
273275
}
274276

275277
igx-date-range-picker {
@@ -280,11 +282,6 @@
280282
display: none;
281283
}
282284

283-
input {
284-
margin: 0 auto;
285-
max-width: 100%;
286-
}
287-
288285
%form-group-input {
289286
// ignore global typography
290287
font-size: $grid-cell-fs !important;

projects/igniteui-angular/core/src/core/styles/components/toast/_toast-theme.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
$text: map.get($categories, 'text');
5353

5454
%igx-toast-display,
55-
%igx-toast-display > * {
55+
%igx-toast-display > *:not(igx-icon) {
5656
@include type-style($text) {
5757
margin: 0;
5858
}

projects/igniteui-angular/grids/core/src/grid-public-row.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,12 @@ abstract class BaseRow implements RowType {
181181
return false;
182182
}
183183

184+
/**
185+
* Gets whether the row is disabled.
186+
* A disabled row represents a ghost placeholder created by row pinning.
187+
*/
184188
public get disabled(): boolean {
185-
return this.grid.isGhostRecord(this.data);
189+
return this.grid.isGhostRecordAtIndex(this.index);
186190
}
187191

188192
/**

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7871,8 +7871,10 @@ export abstract class IgxGridBaseDirective implements GridType,
78717871
* If record is pinned but is not in pinned area then it is a ghost record.
78727872
*
78737873
* @param dataViewIndex The index of that record in the data view.
7874+
* @hidden
7875+
* @internal
78747876
*/
7875-
private isGhostRecordAtIndex(dataViewIndex) {
7877+
public isGhostRecordAtIndex(dataViewIndex) {
78767878
const isPinned = this.isRecordPinned(this.dataView[dataViewIndex]);
78777879
const isInPinnedArea = this.isRecordPinnedByViewIndex(dataViewIndex);
78787880
return isPinned && !isInPinnedArea;

projects/igniteui-angular/grids/grid/src/grid-row-pinning.spec.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -397,6 +397,18 @@ describe('Row Pinning #grid', () => {
397397
expect(grid.gridAPI.get_row_by_index(1).key).toBe(fix.componentInstance.data[1]);
398398
});
399399

400+
it('should mark ghost placeholder rows as disabled in RowType API.', () => {
401+
grid.pinRow(fix.componentInstance.data[0]);
402+
fix.detectChanges();
403+
404+
const renderedRow = grid.rowList.toArray().find(r => r.index === 1);
405+
const rowType = grid.getRowByIndex(1);
406+
407+
expect(renderedRow).toBeDefined();
408+
expect(renderedRow.disabled).toBeTrue();
409+
expect(rowType.disabled).toBeTrue();
410+
});
411+
400412
it('should search in both pinned and unpinned rows.', () => {
401413
// pin 1st row
402414
let row = grid.gridAPI.get_row_by_index(0);

0 commit comments

Comments
 (0)