fix: explicit country code handling for client-side localization#19841
Closed
RUTUPARNk wants to merge 2 commits intomozilla:mainfrom
Closed
fix: explicit country code handling for client-side localization#19841RUTUPARNk wants to merge 2 commits intomozilla:mainfrom
RUTUPARNk wants to merge 2 commits intomozilla:mainfrom
Conversation
Refactor ClientFormatter to be locale-agnostic and return countryCode. Update DeviceInfoBlock to use Intl.DisplayNames. Update RemoteMetadata type.
Author
|
@MagentaManifold can you review now? |
Contributor
|
Sorry for the long delay! I just came back from vacation. I just ran CI on your PR, but sadly it still does not compile. You can see the error messages yourself by clicking on the failed CI tasks (LMK if you don't have access to them). |
Author
|
@MagentaManifold I can't access CI tasks. |
Contributor
To be honest you should see these if you actually attempted to build the repo locally |
Contributor
|
Closing due to inactivity. Feel free to open a new PR if you still want to fix it |
Author
|
Hi,
I'm still working on it. I need some time.
…On Wed, 11 Feb, 2026, 00:39 Mingyuan Zhao, ***@***.***> wrote:
Closed #19841 <#19841>.
—
Reply to this email directly, view it on GitHub
<#19841 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AF7OZSOFZIYUDHQQOAPT7VL4LIUGRAVCNFSM6AAAAACP4PUMYWVHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMRSGY4DGNZRGQYDSMA>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Author
|
Okay, Thank you Team
…On Wed, 11 Feb, 2026, 01:15 Mingyuan Zhao, ***@***.***> wrote:
*MagentaManifold* left a comment (mozilla/fxa#19841)
<#19841 (comment)>
Closing due to inactivity. Feel free to open a new PR if you still want to
fix it
—
Reply to this email directly, view it on GitHub
<#19841 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AF7OZSK65WL7I3HZP6XB5E34LIYN5AVCNFSM6AAAAACP4PUMYWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTQOBQGE2DONBUGI>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Author
|
Hi Mingyuan,
I hope you're doing well.
I’ve just submitted a Pull Request to address Issue #18859 (User
City/Country displaying in incorrect language when doing Windows to Android
Sync).
I have staged the fix and verified that the commits are now GPG-signed and
corrected with the proper identity. You can find the PR here: PR Link
<#20080>
Looking forward to your feedback!
Best regards,
Rutuparn Puranik
On Wed, Feb 11, 2026 at 1:15 AM Mingyuan Zhao ***@***.***> wrote:
MagentaManifold left a comment (mozilla/fxa#19841)
Closing due to inactivity. Feel free to open a new PR if you still want
to fix it
…
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.
Message ID: ***@***.***>
|
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.
Changes -
Backend (fxa-shared)
Locale-Agnostic ClientFormatter
ClientFormatter.ts: Removed CLDR dependency and server-side localization logic.
formatLocation
now returns the canonical countryCode (from the existing
Location
type) and the raw country string.
No changes to
AttachedClient.ts
.
Frontend (fxa-settings)
Client-Side Localization
types.ts
: Added countryCode to
RemoteMetadata
.
DeviceInfoBlock
: uses Intl.DisplayNames to localize the country name based on the user's current locale, falling back to the raw name.
Tests
Updated
fxa-shared/test/connected-services/formatters.ts
to assert countryCode presence and verify that country strings are passed through without server-side localization.
Closes: (#18859)
Checklist:
[x] My commit is GPG signed.
Logic: Static analysis confirms the data flow:
Geodb->Location(with countryCode) ->ClientFormatter(passes countryCode) ->API->Frontend->Intl->UI.API Contract: The backend now strictly follows the "canonical identifier" contract.
Build: Local build was skipped due to environment issues, but the code changes are now stripped of any risky type redefinitions.