@eturnity/eturnity_reusable_components 7.51.15-EPDM-9631.1 → 7.51.15-EPDM-9631.2
Sign up to get free protection for your applications and to get access to all the features.
package/package.json
CHANGED
@@ -35,12 +35,16 @@ export const toLocaleTime = ({
|
|
35
35
|
locale = localStorage.getItem('lang'),
|
36
36
|
value,
|
37
37
|
}) => {
|
38
|
-
const
|
38
|
+
const nonDefaultFormatting = {
|
39
|
+
'es-es': { hour: '2-digit' },
|
40
|
+
'cs-es': { hour: '2-digit' },
|
41
|
+
}
|
39
42
|
|
40
43
|
const localeLC = locale.toLowerCase()
|
41
44
|
const options = {
|
42
|
-
hour:
|
45
|
+
hour: 'numeric',
|
43
46
|
minute: 'numeric',
|
47
|
+
...nonDefaultFormatting[localeLC],
|
44
48
|
}
|
45
49
|
|
46
50
|
return new Intl.DateTimeFormat(localeLC, options).format(Date.parse(value))
|