Potential calendar time dateFormat bug #2244
Labels
Type: Bug
Issue contains a bug related to a specific component. Something about the component is not working
Milestone
I'm submitting a ...
[x] bug report
Plunkr Case (Bug Reports)
Here is an example of the issue: http://plnkr.co/edit/Vf8t96?p=preview On load the hour is
13
but clicking the up arrow changes is to2
.Current behavior
If
hourFormat
is set to12
and the default time is past 12pm, the time shows as a 24hr clock until the first interaction. When changing the hour, it immediately switches to 12hr format.Expected behavior
On initial load, it should show
1pm
if it is1pm
(rather than13:00
)if (this.hourFormat === '12') {
should beif (this.hourFormat == '12') {
Minimal reproduction of the problem with instructions
hourFormat
to12
defaultDate
to any time past 12pmshowTime
totrue
http://plnkr.co/edit/Vf8t96?p=preview
What is the motivation / use case for changing the behavior?
So that it doesn't jump between 24 and 12 hour clocks.
Please tell us about your environment:
@angular/cli: 1.0.0-beta.32
node: 6.9.5
os: darwin x64
@angular/common: 2.4.9
@angular/compiler: 2.4.9
@angular/core: 2.4.9
@angular/forms: 2.4.9
@angular/http: 2.4.9
@angular/material: 2.0.0-beta.1
@angular/platform-browser: 2.4.9
@angular/platform-browser-dynamic: 2.4.9
@angular/router: 3.4.9
@angular/cli: 1.0.0-beta.32
@angular/compiler-cli: 2.4.9
ngprime: 2.0.2
Browser: all
Language: all
Note: The first plunker that the 'new issue notes' points to is broken: This boilerplate plunker is currently broken: http://plnkr.co/edit/D1AK7i
The text was updated successfully, but these errors were encountered: