Skip to content

A platform for community discussion. Free, open, simple.

UX: clarify old dates with YYYY instead of 'YY (#25661)

Kris037def862475
diff --git a/app/assets/javascripts/discourse/tests/unit/lib/formatter-test.js b/app/assets/javascripts/discourse/tests/unit/lib/formatter-test.js
index 97c357f73ae..dd1f4ac5409 100644
--- a/app/assets/javascripts/discourse/tests/unit/lib/formatter-test.js
+++ b/app/assets/javascripts/discourse/tests/unit/lib/formatter-test.js
@@ -56,7 +56,7 @@ module("Unit | Utility | formatter", function (hooks) {
});
test("formatting medium length dates", function (assert) {
- const shortDateYear = shortDateTester("MMM D, 'YY");
+ const shortDateYear = shortDateTester("MMM D, YYYY");
assert.strictEqual(
strip(formatMins(1.4, { format: "medium", leaveAgo: true })),
@@ -152,7 +152,7 @@ module("Unit | Utility | formatter", function (hooks) {
test("formatting tiny dates", function (assert) {
const siteSettings = getOwner(this).lookup("service:site-settings");
- const shortDateYear = shortDateTester("MMM 'YY");
+ const shortDateYear = shortDateTester("MMM YYYY");
siteSettings.relative_date_duration = 14;
assert.strictEqual(formatMins(0), "1m");
diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml
index 0b423d1354b..f1ff60b9e99 100644
--- a/config/locales/client.en.yml
+++ b/config/locales/client.en.yml
@@ -42,15 +42,15 @@ en:
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
full_with_year_no_time: "MMMM Do, YYYY"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
- long_date_with_year: "MMM D, 'YY LT"
+ long_date_with_year: "MMM D, YYYY LT"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
long_date_without_year: "MMM D, LT"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
- long_date_with_year_without_time: "MMM D, 'YY"
+ long_date_with_year_without_time: "MMM D, YYYY"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
long_date_without_year_with_linebreak: "MMM D <br/>LT"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
- long_date_with_year_with_linebreak: "MMM D, 'YY <br/>LT"
+ long_date_with_year_with_linebreak: "MMM D, YYYY <br/>LT"
wrap_ago: "%{date} ago"
wrap_on: "on %{date}"
@@ -90,7 +90,7 @@ en:
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
date_month: "MMM D"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
- date_year: "MMM 'YY"
+ date_year: "MMM YYYY"
medium:
less_than_x_minutes:
one: "less than %{count} min"
@@ -120,7 +120,7 @@ en:
one: "almost %{count} year"
other: "almost %{count} years"
# Use Moment.js format string: https://momentjs.com/docs/#/displaying/format/
- date_year: "MMM D, 'YY"
+ date_year: "MMM D, YYYY"
medium_with_ago:
x_minutes:
one: "%{count} min ago"