UX: Suppress date on on timeline for previous years
This commit is contained in:
parent
b3e7c78be5
commit
d8d1c7013e
|
@ -48,7 +48,7 @@ createWidget('timeline-scroller', {
|
||||||
if (date) {
|
if (date) {
|
||||||
const format = (date.getFullYear() === new Date().getFullYear()) ?
|
const format = (date.getFullYear() === new Date().getFullYear()) ?
|
||||||
'long_no_year_no_time' :
|
'long_no_year_no_time' :
|
||||||
'long_with_year_no_time';
|
'timeline_diff_year';
|
||||||
|
|
||||||
contents.push(h('div.timeline-ago', moment(date).format(I18n.t(`dates.${format}`))));
|
contents.push(h('div.timeline-ago', moment(date).format(I18n.t(`dates.${format}`))));
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,6 +37,7 @@ en:
|
||||||
dates:
|
dates:
|
||||||
time: "h:mm a"
|
time: "h:mm a"
|
||||||
timeline_start: "MMMM YYYY"
|
timeline_start: "MMMM YYYY"
|
||||||
|
timeline_diff_year: "MMM YYYY"
|
||||||
long_no_year: "MMM D h:mm a"
|
long_no_year: "MMM D h:mm a"
|
||||||
long_no_year_no_time: "MMM D"
|
long_no_year_no_time: "MMM D"
|
||||||
full_no_year_no_time: "MMMM Do"
|
full_no_year_no_time: "MMMM Do"
|
||||||
|
|
Loading…
Reference in New Issue