Skip to content

Commit 4d195c5

Browse files
committed
fix(pinning): blank space between pinnedRight column and the last unpinned column
Change the order of conditionals to remove blank space between the last unpinned column and the pinned right column in order to fix the availableWidth behavior This commit fixes angular-ui#4949 (pull angular-ui#6284)
1 parent 1332174 commit 4d195c5

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

packages/core/src/js/factories/GridRenderContainer.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -601,14 +601,14 @@ angular.module('ui.grid')
601601
// Skip hidden columns
602602
if (!column.visible) { return; }
603603

604-
if (pinRightColumn) {
605-
availableWidth += self.grid.scrollbarWidth;
606-
}
607-
608604
if (!pinRightColumn && column.colDef.pinnedRight) {
609605
pinRightColumn = true;
610606
}
611607

608+
if (pinRightColumn) {
609+
availableWidth += self.grid.scrollbarWidth;
610+
}
611+
612612
if (angular.isNumber(column.width)) {
613613
// pixel width, set to this value
614614
if (column.colDef.allowFloatWidth) {

0 commit comments

Comments
 (0)