Page MenuHomePhabricator

DateTimeInputWidget does not show the default value as selected in the calendar upon page load
Closed, ResolvedPublicBUG REPORT

Description

When a datetime HTMLForm field has a default value (either specified manually via default, or taken from the request parameters) and the page loads, the field shows the selected date; however, upon clicking it, the day is not selected in the calendar. Below are reproduction steps for a specific instance of this bug, but really this isn't specific to any page.

Steps to replicate the issue (include links if applicable):

  • Go to Special:AbuseLog
  • In the search field, select any date as start date (you can also leave the default selection that is made when you click on the field)
  • Click "Search"
  • Once the page loads, click on the field again

What happens?:
No date is selected in the calendar.

What should have happened instead?:
The selected date should be highlighted in blue.

Event Timeline

Change #1047604 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):

[mediawiki/core@master] Initialize calendar with default date in DateTimeInputWidget

https://gerrit.wikimedia.org/r/1047604

Change #1047604 merged by jenkins-bot:

[mediawiki/core@master] Initialize calendar with default date in DateTimeInputWidget

https://gerrit.wikimedia.org/r/1047604