datetime: Show time when date is between yesterday & tomorrow (PR #9802)

When showing formatted strings such as “today”, if the format includes time, then also include in the resulting output.

This will produce a string such as “today 7:31 AM”.



CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

JavaScript isn’t my strong suit, but this appears to achieve the desired outcome, bit rough around the edges.

Was just thinking, it may need a special-case for LLL as well, where it transforms into LT to get the time portion preserved?

Hmm, I think this may have actually been already fixed with the new LocalDateBuilder recently introduced.