You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Post Date block has a variety of date format options, including the option to enter a custom date format, but it would be nice to have the option to show the publish date as relative to the current date, something like:
I'm not familiar enough with how the Date block works to know if this feature is in or out of scope for that block's intended use.
Currently, the Custom format only allows for a date/time format string and does not support free-form text, which makes total sense. But, if you wanted to display something like Published x days ago then that brings up some questions:
Is the user allowed to append free-form text to the number of days since publishing? Adding custom text before and/or after the number of days seems like the most friendly approach for no or low code users. Though it would be nice to be able to programmatically filter that text.
Any accompanying text strings, whether hard-coded or user-generated would need to account for singular/plural day/days, depending on context (e.g., 1 day ago, 2 days ago. And internationalization would need to be accounted for, of course.
What would would you call it? Perhaps between the various date formats and the Custom option there's an option called Relative Date (see mock image)
The text was updated successfully, but these errors were encountered:
What problem does this address?
The Post Date block has a variety of date format options, including the option to enter a custom date format, but it would be nice to have the option to show the publish date as relative to the current date, something like:
Published x days ago
This was a possible feature request noted a few times in #38751 by @kjellr, @ramonjd, and @jasmussen. As @mtias pointed out in #38751 (comment), that enhancement was out of scope for that ticket.
What is your proposed solution?
I'm not familiar enough with how the Date block works to know if this feature is in or out of scope for that block's intended use.
Currently, the
Custom
format only allows for a date/time format string and does not support free-form text, which makes total sense. But, if you wanted to display something likePublished x days ago
then that brings up some questions:1 day ago
,2 days ago
. And internationalization would need to be accounted for, of course.Custom
option there's an option calledRelative Date
(see mock image)The text was updated successfully, but these errors were encountered: