From 5aa9e7e0f62db55dea95dd2af2cfc00442dd210c Mon Sep 17 00:00:00 2001 From: Mike Bishop Date: Tue, 10 May 2022 14:05:38 -0400 Subject: [PATCH 1/3] Add showTimeToday option --- modules/default/calendar/calendar.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/default/calendar/calendar.js b/modules/default/calendar/calendar.js index 34d720d3..080e10b9 100644 --- a/modules/default/calendar/calendar.js +++ b/modules/default/calendar/calendar.js @@ -37,6 +37,7 @@ Module.register("calendar", { hidePrivate: false, hideOngoing: false, hideTime: false, + showTimeToday: false, colored: false, coloredSymbolOnly: false, customEvents: [], // Array of {keyword: "", symbol: "", color: ""} where Keyword is a regexp and symbol/color are to be applied for matched @@ -368,7 +369,7 @@ Module.register("calendar", { } else { timeWrapper.innerHTML = this.capFirst( moment(event.startDate, "x").calendar(null, { - sameDay: "[" + this.translate("TODAY") + "]", + sameDay: this.config.showTimeToday ? "LT" : "[" + this.translate("TODAY") + "]", nextDay: "[" + this.translate("TOMORROW") + "]", nextWeek: "dddd", sameElse: event.fullDayEvent ? this.config.fullDayEventDateFormat : this.config.dateFormat From be9761146cbf2506d6322ec1ee04dfaa756e1429 Mon Sep 17 00:00:00 2001 From: Mike Bishop Date: Mon, 25 Jul 2022 14:09:56 -0400 Subject: [PATCH 2/3] CHANGELOG --- CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4268310f..e7be6d7c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,9 @@ _This release is scheduled to be released on 2022-10-01._ ## Added +- New `showTimeToday` option in calendar module shows time for current-day + events even if `timeFormat` is `"relative"` + ## Updated ## Fixed From c3339b47bb6ccfc8bdf927f9582d40217332a5ad Mon Sep 17 00:00:00 2001 From: Mike Bishop Date: Mon, 25 Jul 2022 18:34:24 -0400 Subject: [PATCH 3/3] Remove newline to re-run tests --- CHANGELOG.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e7be6d7c..afd59eda 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,8 +11,7 @@ _This release is scheduled to be released on 2022-10-01._ ## Added -- New `showTimeToday` option in calendar module shows time for current-day - events even if `timeFormat` is `"relative"` +- New `showTimeToday` option in calendar module shows time for current-day events even if `timeFormat` is `"relative"` ## Updated