Format DateTime and Date objects correctly in html5 date input fields