angular-ui/ui-grid

scrollToIfNecessary sets bottomBound as NaN

已關閉

#3,849 建立於 2015年6月24日

 (9 則留言) (1 個反應) (1 位負責人)JavaScript (2,496 個分叉)batch import
help wantedneeds: analysis

倉庫指標

星標
 (5,395 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

In ui-grid - v3.0.0-rc.22 I am trying to execute the scrollTo functionality. When I hit line 5280:

var bottomBound = self.renderContainers.body.prevScrollTop + self.gridHeight - self.renderContainers.body.headerHeight - self.footerHeight - self.scrollbarWidth;

the value for 'self.renderContainers.body.headerHeight' is undefined which causes the 'bottomBound' to be set to 'NaN'. It seems like the value used here should instead be 'self.headerHeight' which is used to set the 'topBound' on line 5270.

Am I either incorrect in that the value should be switched or am I doing something else that causes self.renderContainers.body.headerHeight to be 'undefined'?

貢獻者指南