Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion js/bootstrap-select.js
Original file line number Diff line number Diff line change
Expand Up @@ -2250,7 +2250,8 @@
// This is useful for smaller menus, where there might be plenty of room
// below the button without setting dropup, but we can't know
// the exact height of the menu until createView is called later
estimate = liHeight * this.selectpicker.current.data.length + menuPadding.vert;
var dropDownLength = this.options.size !== 'auto' ? this.options.size : this.selectpicker.current.data.length;
estimate = liHeight * dropDownLength + menuPadding.vert;

isDropup = this.sizeInfo.selectOffsetTop - this.sizeInfo.selectOffsetBot > this.sizeInfo.menuExtras.vert && estimate + this.sizeInfo.menuExtras.vert + 50 > this.sizeInfo.selectOffsetBot;

Expand Down