fix(ios): time-picker and date-picker for iOS 14#8877
Conversation
|
Nice work @asharghi 👏 thank you - we'll test with the changeset this week 👍 |
|
@NathanWalker Thanks! |
|
I see this is released in 7.0.4. We are still on 6.5.x - will it be backported? |
|
It is backported @ian-s-mac . You can upgrade your |
|
|
||
| export * from './date-picker-common'; | ||
|
|
||
| const SUPPORT_DATE_PICKER_STYLE = parseFloat(Device.os) >= 14.0; |
There was a problem hiding this comment.
Shouldn't it be Device.osVersion?
The documentations says:
export interface IDevice {
...
/**
* Gets the OS of the device.
* For example: "Android" or "iOS".
*/
os: string;
...
}
/**
* Gets the OS version.
* For example: 4.4.4(android), 8.1(ios)
*/
osVersion: string;
|
I think you are right. when using "device.os", both SUPPORT_DATE_PICKER_STYLE an SUPPORT_TEXT_COLOR always equal false. And the date picker on iOS 14 looks like this If I edit the code to use osVersion, then SUPPORT_DATE_PICKER_STYLE correctly resolve to true and is set on iOS 14 and the date picker looks like this |
|
You are right. That's my bad. But now that I think about it, do we want to override the default behavior of the os and always use the old style as default? |
|
To have a quick fix, I would do it this way. |
|
What do you guys think about this #8899 |




PR Checklist
What is the current behavior?
TimePicker/DatePicker crashes on iOS 14
What is the new behavior?
Does not crash
Fixes/Implements/Closes #8862 #8880