Change Relative Time Formatter options to 'always' (#6240)

This commit is contained in:
Abass 🍉 2025-10-23 22:59:32 +03:00 committed by GitHub
parent 49f8f8d803
commit 9a3613856c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -219,7 +219,7 @@ class RelativeTimeFormatter {
* Default locale and options for Relative Time Formatter
*/
constructor() {
this.options = { numeric: "auto" };
this.options = { numeric: "always" };
this.instance = new Intl.RelativeTimeFormat(currentLocale(), this.options);
}
@ -267,7 +267,7 @@ class RelativeTimeFormatter {
};
if (days > 0) {
toFormattedPart(days, "days");
toFormattedPart(days, "day");
}
if (hours > 0) {
toFormattedPart(hours, "hour");