is24Hour not working on iOS 13
See original GitHub issueBug report
Summary
I set the is24Hour to true, but it still give me 12 hours picker
Environment info
react-native info
output:
System: OS: macOS 10.15.3 CPU: (4) x64 Intel® Core™ i5-4278U CPU @ 2.60GHz Memory: 435.51 MB / 8.00 GB Shell: 5.7.1 - /bin/zsh Binaries: Node: 14.2.0 - ~/.nvm/versions/node/v14.2.0/bin/node Yarn: Not Found npm: 6.14.5 - ~/.nvm/versions/node/v14.2.0/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman Managers: CocoaPods: 1.9.3 - /usr/local/bin/pod SDKs: iOS SDK: Platforms: iOS 13.4, DriverKit 19.0, macOS 10.15, tvOS 13.4, watchOS 6.2 Android SDK: Not Found IDEs: Android Studio: 3.6 AI-192.7142.36.36.6392135 Xcode: 11.4/11E146 - /usr/bin/xcodebuild Languages: Java: 1.8.0_241 - /usr/bin/javac Python: 2.7.16 - /usr/bin/python npmPackages: @react-native-community/cli: Not Found react: 16.13.1 => 16.13.1 react-native: 0.63.0 => 0.63.0 npmGlobalPackages: react-native: Not Found
Library version: 2.6.0
Steps to reproduce
try this code
<DateTimePicker
testID = "dateTimePicker"
value = {new Date()}
mode = 'datetime'
is24Hour = {true}
/>
on my machine still showing 12 hours option of picker and am/pm options
- Install properly the library
- try the code
Describe what you expected to happen:
- when using is24Hour props to true, the picker should showing 24 hours options of picker
Reproducible sample code
<DateTimePicker
testID = "dateTimePicker"
value = {new Date()}
mode = 'datetime'
is24Hour = {true}
/>
Issue Analytics
- State:
- Created 3 years ago
- Comments:6
Top GitHub Comments
Yo. Faced the same issue but setting the
locale
property solved it, I.e:Yup Locale=“en-UK” also works for me.