Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Conversation

crisbeto
Copy link
Member

@crisbeto crisbeto commented Apr 21, 2016

By default the datepicker would insert the date into the view after passing it through toLocaleDateString.
This means that if the user's locale date string couldn't be parsed by new Date (e.g. their locale is European which formats the dates as DD/MM/YYYY), the datepicker would have inserted an invalid date.
This change switches to using the US date format by default, because it is parse-able by the Date constructor. This shouldn't be unexpected, because the documentation states that users should override the date functions if they're dealing with different kinds of date formats.

Fixes #7456.
Fixes #7404.
Fixes #8275.

@crisbeto crisbeto added needs: review This PR is waiting on review from the team needs: work and removed needs: review This PR is waiting on review from the team labels Apr 21, 2016
@crisbeto crisbeto force-pushed the fix/datepicker-keyb branch from daaf47e to 32ef0c6 Compare April 21, 2016 17:49
@crisbeto crisbeto added needs: review This PR is waiting on review from the team and removed needs: work labels Apr 21, 2016
@crisbeto crisbeto force-pushed the fix/datepicker-keyb branch from 32ef0c6 to bddb688 Compare April 21, 2016 19:07
@crisbeto crisbeto force-pushed the fix/datepicker-keyb branch from bddb688 to dac2b88 Compare April 29, 2016 14:13
@crisbeto crisbeto force-pushed the fix/datepicker-keyb branch from dac2b88 to 49510cb Compare June 1, 2016 17:54
By default the datepicker would insert the date into the view after passing it through toLocaleDateString.
This means that if the user's locale date string couldn't be parsed by `new Date` (e.g. their locale is European which formats the dates as DD/MM/YYYY), the datepicker would have inserted an invalid date.
This change switches to using the US date format by default, because it is parse-able by the Date constructor. This shouldn't be unexpected, because the documentation states that users should override the date functions if they're dealing with different kinds of date formats.

Fixes angular#7456.
Fixes angular#7404.
Fixes angular#8275.
@ferchoman09
Copy link

When can I get this Fix in an release version?

@volodymyrlut
Copy link

Why the PR is closed, and how can we help to get it merged?

@devversion
Copy link
Member

@ferchoman09 @volodymyrlut This fix is already in 1.1.0-rc.5

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

needs: review This PR is waiting on review from the team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants