Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

24-hour time formats #8

Closed
jkhoel opened this issue Oct 14, 2020 · 2 comments
Closed

24-hour time formats #8

jkhoel opened this issue Oct 14, 2020 · 2 comments

Comments

@jkhoel
Copy link

jkhoel commented Oct 14, 2020

I notice that at least for me I get 12-hour time formats. Would like to see that forced to 24-hr formats (or selectable)

@martinco
Copy link
Owner

The fields are just type="time" which comes down to your browser / OS locale configuration

24 hour:

image

12 hour:

image

These are changed in Control Panel -> Date and Time -> Region -> Change data formats

@martinco
Copy link
Owner

On chrome, this is also influenced by chrome://settings/languages

However it's worth noting that regardless of the display format, the output will always be 24h

martinco added a commit that referenced this issue Nov 23, 2020
Time is causing trouble once again in addition to #8

Rather than struggle with explaining the field / needing to set AM/PM on a
duration under chrome depending on windows locale / chrome prefs etc. just
is a waste of time and not intuitive

As such we move it to a simple text field with a little regex:

Users can now use any of the following formats:

* 90   => just minutes            => formatted as
* 1:   => just hours              => formated to 1:00
* 1:4  => hours + minutes         => formatted as 1:04
* 1:90 => still works, just silly => formatted as 2:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants