We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4f31aba commit 9962aa0Copy full SHA for 9962aa0
projects/angular2gridster/src/lib/gridster.service.ts
@@ -456,8 +456,8 @@ export class GridsterService {
456
height: parseInt(item.$element.style.height, 10) - 1
457
};
458
459
- let colSize = itemSize.width / this.cellWidth;
460
- let rowSize = itemSize.height / this.cellHeight;
+ let colSize = Math.round(itemSize.width / this.cellWidth);
+ let rowSize = Math.round(itemSize.height / this.cellHeight);
461
462
// Keep item minimum 1
463
colSize = Math.max(colSize, 1);
0 commit comments