Skip to content

Commit e98280f

Browse files
committed
fix(grid): using computed style for restrict resize
1 parent 082b896 commit e98280f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

projects/igniteui-angular/src/lib/grids/resizing/resizing.service.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ export class IgxColumnResizingService {
6161
* Returns the minimal possible width to which the column can be resized.
6262
*/
6363
public get restrictResizeMin(): number {
64-
const actualWidth = this.getColumnHeaderRenderedWidth();
64+
const actualWidth = parseFloat(window.getComputedStyle(this.column.headerCell.nativeElement).width);
6565
const minWidth = this.column.minWidthPx < actualWidth ? this.column.minWidthPx : actualWidth;
6666

6767
return actualWidth - minWidth;
@@ -71,7 +71,7 @@ export class IgxColumnResizingService {
7171
* Returns the maximal possible width to which the column can be resized.
7272
*/
7373
public get restrictResizeMax(): number {
74-
const actualWidth = this.getColumnHeaderRenderedWidth();
74+
const actualWidth = parseFloat(window.getComputedStyle(this.column.headerCell.nativeElement).width);
7575
const maxWidth = this.column.maxWidthPx;
7676
if (this.column.maxWidth) {
7777
return maxWidth - actualWidth;

0 commit comments

Comments
 (0)