shijingsh / react-native-customized-image-picker

iOS/Android image picker with support for camera, video compression, multiple images and cropping
245 stars 59 forks source link

iOS translation #96

Closed apgsn closed 3 years ago

apgsn commented 3 years ago

Hi, I'd like to customize and translate this library interface to something else other than english on iOS. How should I go about it? Thank you.

liukefu2050 commented 3 years ago

https://github.com/banchichen/TZImagePickerController/issues/443 https://github.com/banchichen/TZImagePickerController/issues/929 Try whether the page can be solved, and update it later

liukefu2050 commented 3 years ago

Refer to the files in the folder and add a language if there is no language you need

https://github.com/banchichen/TZImagePickerController/tree/master/TZImagePickerController/TZImagePickerController/TZImagePickerController.bundle

Pyroboomka commented 3 years ago

Won't work because of https://github.com/banchichen/TZImagePickerController/issues/1462 Seems it's locked to 4 languages only for now.

Pyroboomka commented 3 years ago

Well, some tinkering and it seems like you can patch-package the openImagePicker and openVideoPicker methods in IOS files. Adding this line after creating vc helps imagePickerVc.languageBundle = [NSBundle bundleWithPath:[[NSBundle tz_imagePickerBundle] pathForResource:@"ru" ofType:@"lproj"]]; Can substitute @ru with bundle you need from link above.