Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dates and relative times of the snapshot tab not translated #660

Open
fflorent opened this issue Sep 5, 2023 · 1 comment
Open

Dates and relative times of the snapshot tab not translated #660

fflorent opened this issue Sep 5, 2023 · 1 comment
Labels

Comments

@fflorent
Copy link
Collaborator

fflorent commented Sep 5, 2023

Despite having a UI localized in a certain language, the dates and the relative times are not translated

Steps to reproduce:

  1. Ensure to set the language localized to a different language than English
  2. Ensure to activate snapshots
  3. Open or create a new document
  4. Click to open the document history
  5. In the right panel open the snapshots tab

Actual behavior

Despite having set the UI in another language than English (like French), we have dates and relative times ("a few seconds ago") that are not localized:
2023-09-05_15-47

Expected behavior

These strings should be localized. In French, this should display: "mar. 5 sept. 2023" and "il y a quelques secondes".

Other considerations

Moment supports the localization: https://momentjs.com/docs/#/i18n/instance-locale/

PS: I hesitated but decided to not set the good first issue tag, as it requires to understand S3 and setup Minio. Still hesitating a bit though.

@fflorent fflorent assigned fflorent and unassigned fflorent Sep 5, 2023
@fflorent
Copy link
Collaborator Author

fflorent commented Sep 5, 2023

Not that simple, due to the removal of localization support except for english client-side:

// To strip all locales except “en”
new MomentLocalesPlugin()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: No status
Development

No branches or pull requests

1 participant