lumada-design / hv-uikit-react

UI library for the Next Design System.
https://lumada-design.github.io/uikit/master
Apache License 2.0
39 stars 20 forks source link

HvTimeAgo doesn't support date format? #4324

Open shadahm-he opened 6 days ago

shadahm-he commented 6 days ago

Latest version

No Hitachi confidential content

Summary 💡

We are using your library for our project in Hitachi Energy.

There is one state where it goes something like: Yesterday at 1:44 PM

We can't find a way to make this in 24h time (i.e: showing 13:44 instead), and that's the more popular time format where we are.

Am I missing something or this is a feature request?

Examples 🌈

No response

Motivation 🔦

No response

plagoa commented 6 days ago

Hey @shadahm-he, thanks for opening the issue. We'll take a look into this.

zettca commented 4 days ago

Hey @shadahm-he

We do have issues with i18n which we're now addressing 👍

Regarding the 24-hour question, just to clarify, do you need a custom date locale independent of the defined locale? For instance, in english the en-US uses 12-hour format, but en-UK uses the 24-hour format. eg:

en-GB > 16:12:10
en-US > 4:12:10 PM

Are you looking to customise it beyond the default locale rules? eg. 16:12:10 when users have en-US configured