- Issue created by @penyaskito
- Merge request !10353Issue #3490066: Update announcements date format β (Open) created by penyaskito
- π¦πΊAustralia pameeela
Thanks for progressing this. I'm sure it needs tests :)
I think the ideal for announcements would be
j F Y
(this is the format on d.o) which is already Olivero Medium, but we can't use it because Olivero won't necessarily be always installed.We could create 'Default medium date only' instead but this would be slightly different from 'Default medium' which uses
j M Y
which seems a bit confusing. But this could replace Olivero Medium? A can of worms as usual! - πΈπ°Slovakia poker10
Creating a new format just for this one specific place is a bit weird. When you install Drupal on standard profile, 12 formats are already created. If the time is a problem, cannot we use here the existing
html_date
format instead and then maybe just change its date representation in Drupal CMS toj F Y
? - π¦πΊAustralia pameeela
I do agree there are already a lot of formats. But it's not really a Drupal CMS issue, it's just that's how it surfaced. We added a new feature to core for announcements and we don't have an appropriate date format for it, outside of Olivero.
Of course, there are ways we can override it in Drupal CMS. But I think in this case, what's best for Drupal CMS is best for core. I don't feel that strongly about it either way though.
- ππΊHungary GΓ‘bor Hojtsy Hungary
Re changing
html_date
in Drupal CMS, core'shtml_date
isY-m-d
, which is to be used for HTML output, eg. datetime attributes and input elements for date input. See https://developer.mozilla.org/en-US/docs/Web/HTML/Date_and_time_formats, so I don't think changing that to something user facing is a good idea, browsers may not understand the updated format where it is actually used in the HTML source as intended.In general we should stay away from messing with the
html_...
date formats, they are spec defined :)So that leaves us with the long, medium and short date format in core, and all of them contain the time. I agree a date format in core for date only (without time) would be good.