Internationalization: PostScheduleLabel format cannot easily be translated and makes for incorrect English phrases #67487
Labels
Internationalization (i18n)
Issues or PRs related to internationalization efforts
[Type] Bug
An existing feature does not function as intended
Description
The
PostScheduleLabel
component does not always display a full date ; in some scenarios it uses words, like "Today", or "Tomorrow":gutenberg/packages/editor/src/components/post-schedule/label.js
Lines 60 to 95 in 7e9e53d
This is not ideal as the date can be used as part of a sentence in the post-publish panel:
gutenberg/packages/editor/src/components/post-publish-panel/postpublish.js
Lines 110 to 113 in a6212c8
It becomes hard for translators to translate that phrase (not all languages are built that way) and even make for incorrect phrases in English.
Ideally, I think this should be broken into different strings based on the type of string outputted by
PostScheduleLabel
.This was also discussed here:
#56854 (comment)
Step-by-step reproduction instructions
Screenshots, screen recording, code snippet
Environment info
Note that your site's timezone in Settings > General must match your own.
Please confirm that you have searched existing issues in the repo.
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Please confirm which theme type you used for testing.
The text was updated successfully, but these errors were encountered: