Skip to content

Commit 1d6ef46

Browse files
committed
[docs] Add information about new human date renderers
1 parent 336bd9e commit 1d6ef46

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

docs/devupdate.md

+14
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,20 @@ The course navigation has been updated to include a new link to the activity ove
1717

1818
See the [Activity overview page integration](./apis/plugintypes/mod/courseoverview) documentation for more information.
1919

20+
## Calendar: New human date renderers
21+
22+
<Since version="5.0" issueNumber="MDL-83873" />
23+
24+
To improve date readability and user experience, the Calendar subsystem is transitioning from deprecated date rendering methods, such as `calendar_format_event_time` or `calendar_time_representation`, to a new suite of human date renderers. It enhances date display by:
25+
26+
- Using relative terms like "Today," "Yesterday," and "Tomorrow" for nearby dates.
27+
- Applying alert styling to dates nearing deadlines or events.
28+
29+
This update introduces two primary renderers:
30+
31+
- `humandate`: This renderer presents single dates and times in a user-friendly format, automatically adapting to the user's preferred 12-hour or 24-hour time display (`CALENDAR_TF_12`/`CALENDAR_TF_24`).
32+
- `humantimeperiod`: Designed for displaying date/time ranges, this renderer optimizes information presentation. When the start and end dates fall on the same day, it shows the full start date and time, but only the end time, eliminating redundant date information. This logic mirrors the existing functionality of the deprecated functions, ensuring a consistent user experience.
33+
2034
## Course formats
2135

2236
<Since version="5.0" issueNumber="MDL-83527" />

0 commit comments

Comments
 (0)