Skip to content

Commit d3e21cf

Browse files
committed
Merge pull request jquery#223 from kzys/trac-7043
Fixed #7043 - Datepicker: Using multiple months always renders 6 rows of dates even if only 5 are neededf
2 parents 1298f93 + ac459ff commit d3e21cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ui/jquery.ui.datepicker.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1489,7 +1489,7 @@ $.extend(Datepicker.prototype, {
14891489
if (drawYear == inst.selectedYear && drawMonth == inst.selectedMonth)
14901490
inst.selectedDay = Math.min(inst.selectedDay, daysInMonth);
14911491
var leadDays = (this._getFirstDayOfMonth(drawYear, drawMonth) - firstDay + 7) % 7;
1492-
var numRows = (isMultiMonth ? 6 : Math.ceil((leadDays + daysInMonth) / 7)); // calculate the number of rows to generate
1492+
var numRows = Math.ceil((leadDays + daysInMonth) / 7); // calculate the number of rows to generate
14931493
var printDate = this._daylightSavingAdjust(new Date(drawYear, drawMonth, 1 - leadDays));
14941494
for (var dRow = 0; dRow < numRows; dRow++) { // create date picker rows
14951495
calender += '<tr>';

0 commit comments

Comments
 (0)