[new Ranking Pages] Add 18n messages for ranking page titles with "the World"#6239
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces new internationalization (i18n) message definitions to support localized titles for ranking pages that reference 'the World'. These changes prepare the codebase for upcoming translation submissions without altering existing UI behavior or functionality. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request adds several new internationalization message keys for world-level ranking titles in i18n_ranking_messages.ts and updates a TODO comment in html.py regarding the localization strategy for 'the World' page titles. A review comment suggested refining the TODO text to more accurately reflect that the message keys have now been defined and the next step is to update the frontend to utilize them.
| }, | ||
| topPlacesWorldTitle: { | ||
| id: "ranking-subtitle_top_world", | ||
| defaultMessage: "Top {rankSize} {pluralPlaceType} in the World", |
There was a problem hiding this comment.
With {placeName}, this gets interpolated as a link. Here with the raw text, as it is the "the World" will not be wrapped in an anchor.
We'll only deal with the actual link creation later, but to prepare for it before these get translated, we can wrap "the World" in a rich text tag: Top {rankSize} {pluralPlaceType} in <worldLink>the World</worldLink>.
The translators will then be able to rearrange the string as they see fit for their languages (i.e. {pluralPlaceType} del <worldLink>mundo</worldLink>)
There was a problem hiding this comment.
Great callout! Wrapped "the World" with <worldLink> and updated the descriptions.
As a followup to the comments in #6235 discussing translations, this PR adds translation strings for ranking page titles that contain "the World", so that they will be translated the next time we submit strings for translation. There is no change to UI or functionality.