react-native-datepicker icon indicating copy to clipboard operation
react-native-datepicker copied to clipboard

Change language for datetime picker

Open AmusedMe opened this issue 8 years ago • 17 comments

Thank you for your time. I look through all the issues, just one about language. I still not find how to specific one language.

AmusedMe avatar Mar 01 '17 08:03 AmusedMe

I just use the react native Component, I think the component's language is same as your mobile system.

feyy avatar Mar 02 '17 08:03 feyy

Yes it's strange, when the modal is open, the language is support but when the value is printed in the component, it's in English!

jonathanroze avatar Jun 25 '17 20:06 jonathanroze

https://github.com/facebook/react-native/pull/15635/files

You can examine this pull request.

ozsirma avatar Nov 16 '17 07:11 ozsirma

@ozsirma, is it merge to main? I see that it only targeted to iOS, why not to Android as well?

b-asaf avatar Feb 01 '18 09:02 b-asaf

It is usable with v0.52.0 that merged the pull request. @assafb81

ozsirma avatar Feb 01 '18 09:02 ozsirma

how RN v0.52.0 is relevant? I thought it is react-native-datepicker issue

@ozsirma

b-asaf avatar Feb 01 '18 09:02 b-asaf

react native datePicker component for both Android and IOS, using DatePickerAndroid, TimePickerAndroid and DatePickerIOS

DatePickerIOS is native component for iOS. Therefore if you use this feature, you should use v52.0 or you should change files manually in your node_modules. @assafb81

ozsirma avatar Feb 01 '18 10:02 ozsirma

@ozsirma thanks

b-asaf avatar Feb 01 '18 14:02 b-asaf

My fork include this feature: https://github.com/pablo-albaladejo/react-native-datepicker

<DatePicker locale={'es'} date={this.state.date} mode='date' format="DD-MM-YYYY">

pablo-albaladejo avatar Feb 23 '18 19:02 pablo-albaladejo

Nice, @pablo-albaladejo :)

However, I need support for Android too. This should be supported by RN. Upvote this feature request to help push this feature through :D

jenskuhrjorgensen avatar Mar 06 '18 13:03 jenskuhrjorgensen

Thanks @jenskuhrjorgensen,

There is no issue at the Android Datepicker locale; it just read the system locale. Screenshots of the component:

locale_es locale_en

pablo-albaladejo avatar Mar 06 '18 14:03 pablo-albaladejo

Yes @pablo-albaladejo, but I would like to set it manually - is that possible?

jenskuhrjorgensen avatar Mar 06 '18 15:03 jenskuhrjorgensen

I'm also wondering how to manually set locale

fhadsheikh avatar Apr 13 '18 18:04 fhadsheikh

Thanks @jenskuhrjorgensen,

There is no issue at the Android Datepicker locale; it just read the system locale. Screenshots of the component:

locale_es locale_en

karthikeyan110798 avatar Jul 24 '19 11:07 karthikeyan110798

Hello sir , Iam trying to change the language of date picker based on user selection , could you suggest some examples. Thanks a lot!

karthikeyan110798 avatar Jul 24 '19 11:07 karthikeyan110798

Can I set a customize date picker locale to follow my app language not system language on Android is there any available solution or work around?

AhmSaeed avatar Apr 13 '20 20:04 AhmSaeed

Has anyone got this solution for ANDROID Language change Manually

even community Library has same issue for android

ZainaliSyed avatar Oct 18 '20 12:10 ZainaliSyed