You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When AmPm format is selected for the TimePicker, the hours have a leading zero, which is generally not used (in the US, at least).
e.g.
05:45 PM
would normally be written as:
5:45 PM
I believe this also prevents confusion, as I, as a 24hr clock guy, might read "05:45 PM" as "05:45" in the morning because of the leading zero.
For reference, the en-US culture ShortTimePattern string is "h:mm tt", i.e. only one h rather than hh. I'm not sure if this is universal for all countries which use 12-hour format, so perhaps a better solution would be to allow the time format string to be passed in, rather than a simple boolean for AmPm, much like the DateFormat works for the datepicker.
The text was updated successfully, but these errors were encountered:
Also, when TimePicker is set to AmPm format, and bound to a value, the value will initially show in 24hr format in the textbox. It only switches to 12hr format once the value is changed via the picker.
e.g.
Timespan "00:01" with AmPm set to true <MudTimePicker Time="TimeSpan.FromSeconds(60)" AmPm="true" />
Value displays initially as:
(should show as "12:01 am")
Once the picker is used and a value selected via the picker, the correct format shows:
When AmPm format is selected for the TimePicker, the hours have a leading zero, which is generally not used (in the US, at least).
e.g.
05:45 PM
would normally be written as:
5:45 PM
I believe this also prevents confusion, as I, as a 24hr clock guy, might read "05:45 PM" as "05:45" in the morning because of the leading zero.
For reference, the en-US culture ShortTimePattern string is "h:mm tt", i.e. only one h rather than hh. I'm not sure if this is universal for all countries which use 12-hour format, so perhaps a better solution would be to allow the time format string to be passed in, rather than a simple boolean for AmPm, much like the DateFormat works for the datepicker.
The text was updated successfully, but these errors were encountered: