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

Add CFBundleLocalizations key to Info.plist #6567

Merged

Conversation

surfdude29
Copy link
Contributor

Even though Bluesky has been localized into more than 20 languages, the App Store listing still shows it as only available in English:

IMG_1163

After some research, it appears that including the list of supported languages in a CFBundleLocalizations key in the Info.plist file might enable all the supported languages to be displayed in the App Store listing. (source 1, source 2, source 3)

This will also hopefully fix #6162 and enable the TextInput context menus to be localized on iOS (they currently always display in English).

@@ -93,6 +93,30 @@ module.exports = function (config) {
NSPhotoLibraryUsageDescription:
'Used for profile pictures, posts, and other kinds of content',
CFBundleSpokenName: 'Blue Sky',
CFBundleLocalizations: [
Copy link
Collaborator

Choose a reason for hiding this comment

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

can we automate these?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't quite follow?

Copy link
Contributor

Choose a reason for hiding this comment

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

I think @gaearon may refer to the fact that it would be even better to automatically generate the list of localizations based on Object.keys(APP_LANGUAGES) (APP_LANGUAGES being imported from src/locale/languages.ts)!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah I see. That might indeed be better, I wouldn't have a clue how to do it though, I'm afraid :)

Copy link
Contributor

Choose a reason for hiding this comment

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

To be fair, it would be quite hard to do as-is, as the app.config.js is written in JS, and we would need to rewrite it in Typescript as app.config.ts (and make sure the toolchain uses ts-node according to Expo's documentation) to be able to import APP_LANGUAGES here.

I recommand to keep the automatisation for a follow-up pull request by a more seasoned developer 😅

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sounds fine to me! :)

@andreazllin
Copy link

Are all those values valid? Taking a look at CFBundleLocalizations docs, seems like Apple only marked some as possibile values, not sure if it's an oversight on their side or not.

@surfdude29
Copy link
Contributor Author

Yes I thought that was rather confusing, but I'm pretty sure those are just examples of language codes, rather than all possible values. It would be really weird not to allow developers to localize their apps in Spanish, for instance, which isn't listed.

@andreazllin
Copy link

andreazllin commented Nov 20, 2024

Yeah that makes sense! 👍🏻

Apple should've specified the standard they're using for that property or specify the entire list for it

@gaearon gaearon merged commit 058a29c into bluesky-social:main Nov 22, 2024
6 checks passed
@surfdude29 surfdude29 deleted the add-CFBundleLocalizations-key branch November 22, 2024 12:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add Localizations for Context Menus in TextInput(Copy, Paste, AutoFill, etc) in CFBundleLocalizations for iOS
4 participants