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

Fix/missing editor script translations #234

Merged

Conversation

petitphp
Copy link
Contributor

@petitphp petitphp commented Feb 18, 2022

Context

Summary

This PR can be summarized in the following changelog entry:

  • Fixes a bug where translations where missing in the buttons and the notices in the Block Editor. Props to @petitphp.

Relevant technical choices:

Test instructions

Test instructions for the acceptance test before the PR gets merged

This PR can be acceptance tested by following these steps:

Reproduce the error

  • Switch WordPress to a locale other than default english (en_US), use one which is almost complete such as Italian or Dutch.
  • Ensure translations files for the plugin are installed,
  • Edit a published page,
  • In the Publish panel on the sidebar duplicate post action links are still displayed in english Copy to a new draft and Rewrite & Republish.
  • Create a Rewrite & Republish copy from a published post and see the notice is not translated

Test the patch

  • Switch to the branch and build
  • Switch WordPress to a locale other than default english (en_US), use one which is almost complete such as Italian or Dutch.
  • Edit a published page,
  • In the Publish panel on the sidebar duplicate post action links are correctly translated in current locale.
  • Create a Rewrite & Republish copy from a published post and see the notice is now translated.

Test instructions for QA when the code is in the RC

  • QA should use the same steps as above.

QA can test this PR by following these steps:

Impact check

This PR affects the following parts of the plugin, which may require extra testing:

  • The function use to load the translations for the editor is available since WordPress 5.0. A check has been added to ensure the function is only called if available to avoid breaking older WordPress install.

UI changes

  • This PR changes the UI in the plugin. I have added the 'UI change' label to this PR.

Documentation

  • I have written documentation for this change.

Quality assurance

  • I have tested this code to the best of my abilities
  • I have added unittests to verify the code works as intended

Fixes #233

@enricobattocchi enricobattocchi force-pushed the fix/missing-editor-script-translations branch from 9b6ce90 to 9e816b2 Compare March 15, 2024 12:43
@enricobattocchi enricobattocchi added this to the 4.6 milestone Mar 15, 2024
Copy link
Member

@enricobattocchi enricobattocchi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CR & Acceptance test OK!
Thanks @petitphp for your contribution and sorry for the delay, we aim to release the fix soon.

@enricobattocchi enricobattocchi merged commit bf33f90 into Yoast:trunk Mar 15, 2024
22 checks passed
@petitphp petitphp deleted the fix/missing-editor-script-translations branch March 15, 2024 13:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing translations in Gutenberg editor
3 participants