tweak humanised time strings

This commit is contained in:
Erik 2022-07-09 16:40:05 +03:00
parent 15b62e56cc
commit 0d0c17f41f
Signed by untrusted user: Navy.gif
GPG Key ID: 811EC0CD80E7E5FB

View File

@ -17,21 +17,22 @@ const Constants = {
const StartQuotes = Object.keys(Constants.QuotePairs); const StartQuotes = Object.keys(Constants.QuotePairs);
const QuoteMarks = StartQuotes + Object.values(Constants.QuotePairs); const QuoteMarks = StartQuotes + Object.values(Constants.QuotePairs);
const humaniser = humaniseDuration.humanizer({ const humaniser = humaniseDuration;
language: 'short', // const humaniser = humaniseDuration.humanizer({
languages: { // language: 'short',
short: { // languages: {
y: () => "y", // short: {
mo: () => "mo", // y: () => "y",
w: () => "w", // mo: () => "mo",
d: () => "d", // w: () => "w",
h: () => "h", // d: () => "d",
m: () => "m", // h: () => "h",
s: () => "s", // m: () => "m",
ms: () => "ms" // s: () => "s",
} // ms: () => "ms"
} // }
}); // }
// });
const has = (o, k) => Object.prototype.hasOwnProperty.call(o, k); const has = (o, k) => Object.prototype.hasOwnProperty.call(o, k);