I am trying from the last 3 hours but not able to find any method to localize it. I am using iOS 10.0 means UNUserNotificationCenter. I want to localize it in Spanish-Mexico(es-MX) Language.
The only post I have found is Customizing the iOS permission dialog for push notifications Unfortunately, it is not possible to change the text / localisation of the message.
You can change the messages for location permission, camera usage description, photo library usage description etc by adding a new file InfoPlist.strings and add strings for supported languages against keys NS*UsageDescription in the above file.
You won't see any change in system alert when you run the app in the simulator it will be in English try running it in a real device after changing device language. Now the system alert for push notification will be in device language. Hope it helps:)
You need to add the following lines into Info.plist:
<key>CFBundleDevelopmentRegion</key>
<string>en,ru</string>
Value must contain at least two languages (it doesn't matter which ones).
来源:https://stackoverflow.com/questions/41343699/how-to-localize-push-notification-permission-dialog-alert
