WT-856 Use Translated Text In Get/Download Firefox Buttons#1132
Draft
dchukhin wants to merge 32 commits intoWT-854-language-fallback-for-pagesfrom
Draft
WT-856 Use Translated Text In Get/Download Firefox Buttons#1132dchukhin wants to merge 32 commits intoWT-854-language-fallback-for-pagesfrom
dchukhin wants to merge 32 commits intoWT-854-language-fallback-for-pagesfrom
Conversation
…s or strings that need translation
…ew PreFooterCTASnippet label fields
…d-firefox-buttons
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## WT-854-language-fallback-for-pages #1132 +/- ##
======================================================================
- Coverage 79.24% 78.30% -0.95%
======================================================================
Files 133 134 +1
Lines 8383 8600 +217
======================================================================
+ Hits 6643 6734 +91
- Misses 1740 1866 +126 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
maribedran
reviewed
Mar 11, 2026
|
|
||
|
|
||
| def convert_pages(apps, schema_editor): | ||
| models_and_fields = [ |
Collaborator
There was a problem hiding this comment.
This list needs to be updated with the new free form page 2026
| except (json.JSONDecodeError, TypeError): | ||
| pass | ||
| if modified: | ||
| revision.save(update_fields=["content"]) |
Collaborator
There was a problem hiding this comment.
Missing the other field names
| from django.contrib.contenttypes.models import ContentType | ||
|
|
||
| page_models = [ | ||
| apps.get_model("cms", name) for name in ("HomePage", "DownloadPage", "ThanksPage", "ArticleThemePage", "FreeFormPage", "WhatsNewPage") |
- include FreeFormPage2026 in models being updated - make sure convert_revisions reads the appropriate locale and runs only for relevant page types - preserve non-English snippet custom labels
we avoid an error even if some CharFields have a None value by forcing None values to be ''
…d-firefox-buttons
maribedran
approved these changes
Mar 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
One-line summary
This pull request tries to use already-created translations for "Get Firefox" and "Download Firefox" buttons by rendering the text with ftl strings.
Significant changes and points to review
FluentOrCustomTextBlock, which allows users to choose some pretranslated text ("Get Firefox", "Download Firefox"), or use custom text:FluentOrCustomTextBlockis used in theDownloadFirefoxButtonBlockDownloadFirefoxButtonBlocks have had their text mapped to the new choicesPreFooterCTASnippetnow has acustom_labelfield for custom text that will be translated. Itslabelfield has been renamed topretranslated_label, and shows the same pre-translated choices as theFluentOrCustomTextBlock. Choosing "Custom text" allows the user to enter custom text that will be sent for translation.Issue / Bugzilla link
WT-856
Testing