Skip to content

Commit 189fefa

Browse files
MKirovaMKirova
authored andcommitted
fix(igxGrid): When col size is % round calculations for when to show hScrollbar.
1 parent f563acd commit 189fefa

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5494,7 +5494,7 @@ export abstract class IgxGridBaseDirective implements GridType,
54945494
let sum = 0;
54955495
for (const col of fc) {
54965496
if (col.level === 0) {
5497-
sum += parseInt(col.calcWidth, 10);
5497+
sum += parseFloat(col.calcWidth);
54985498
}
54995499
}
55005500
if (this.isPinningToStart) {
@@ -6235,7 +6235,7 @@ export abstract class IgxGridBaseDirective implements GridType,
62356235
* @hidden @internal
62366236
*/
62376237
public hasHorizontalScroll() {
6238-
return this.totalWidth - this.unpinnedWidth > 0 && this.width !== null;
6238+
return Math.round(this.totalWidth - this.unpinnedWidth) > 0 && this.width !== null;
62396239
}
62406240

62416241
/**

0 commit comments

Comments
 (0)