Skip to content

Commit a936eb3

Browse files
cheeaunscottgonzalez
authored andcommitted
Datepicker: Hightlight the curerent date, not the selected date. Fixes #5984 - Datepicker showing multiple months highlights selected day in all of them
1 parent d380099 commit a936eb3

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
@@ -1493,7 +1493,7 @@ $.extend(Datepicker.prototype, {
14931493
(otherMonth && !showOtherMonths ? ' ' : // display for other months
14941494
(unselectable ? '<span class="ui-state-default">' + printDate.getDate() + '</span>' : '<a class="ui-state-default' +
14951495
(printDate.getTime() == today.getTime() ? ' ui-state-highlight' : '') +
1496-
(printDate.getTime() == selectedDate.getTime() ? ' ui-state-active' : '') + // highlight selected day
1496+
(printDate.getTime() == currentDate.getTime() ? ' ui-state-active' : '') + // highlight selected day
14971497
(otherMonth ? ' ui-priority-secondary' : '') + // distinguish dates from other months
14981498
'" href="#">' + printDate.getDate() + '</a>')) + '</td>'; // display selectable date
14991499
printDate.setDate(printDate.getDate() + 1);

0 commit comments

Comments
 (0)