Problem with datepicker dateFormat #2061
Description
It seems the datepicker is not consistently using the dateFilter to parse the entered dates.
See the following Plunkr:
http://plnkr.co/edit/MLbIplS5L8tQdZy597GJ?p=preview
Its the documentation example except that I changed the dateformat to 'dd.MM.yyyy'.
Now when you change the entered date by changing the textfield using the keyboard the datepicker looses track of the date value. It becomes undefined in the $moduleValue. You can also see that the entered date is not highlighted in the calendar widget.
The reason to me seems to be the use of new Date(stringValue) to parse the date:
https://github.com/angular-ui/bootstrap/blob/master/src/datepicker/datepicker.js#L503
I think is should use the dateFilter like it is done here:
https://github.com/angular-ui/bootstrap/blob/master/src/datepicker/datepicker.js#L540