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

Phone number country code defaults to 🇬🇧 United Kingdom (+44) which isn't accurate for every other country #22825

Closed
MadLittleMods opened this issue Jul 12, 2022 · 2 comments
Labels
A-User-Settings O-Occasional Affects or can be seen by some users regularly or most users rarely S-Tolerable Low/no impact on users T-Enhancement

Comments

@MadLittleMods
Copy link
Contributor

Your use case

What would you like to do?

Default phone number country code to the country I'm in. Settings -> General -> Phone numbers

Why would you like to do it?

Currently, the phone number country code defaults to 🇬🇧 United Kingdom (+44). It stands out in the settings as someone who lives in the US:

The picker already has the United States (+1) as the second option by default:

How would you like to achieve it?

Instead of pulling from location or based off of IP, maybe we can infer a bit from window.navigator.language since it's en-US for me in the US. Obviously not applicable for all situations since people can change their language to whatever but it's an easy heuristic for the majority in the US.

Have you considered any alternatives?

No response

Additional context

No response

@MadLittleMods MadLittleMods added S-Tolerable Low/no impact on users T-Enhancement O-Occasional Affects or can be seen by some users regularly or most users rarely labels Jul 12, 2022
@t3chguy
Copy link
Member

t3chguy commented Jul 13, 2022

Language codes don't map 1:1 to a country. E.g en_GB (default) can be mapped to many dialing country codes in the dropdown.
image

Similar goes for French, Spanish, and other more widely spoken languages.

@t3chguy
Copy link
Member

t3chguy commented Sep 25, 2023

Fixed by matrix-org/matrix-react-sdk#10627 as much as the granularity of language codes allows

@t3chguy t3chguy closed this as completed Sep 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-User-Settings O-Occasional Affects or can be seen by some users regularly or most users rarely S-Tolerable Low/no impact on users T-Enhancement
Projects
None yet
Development

No branches or pull requests

3 participants