You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: compute date picker dimensions in native (#656)
* Compute date picker width
* Showcase width with Text
* fix: use UIDatePickerStyle value for dimension measurements
* refactor: remove unnecessary code for height detection
* Remove no longer relevant test
* Remove unused mock
Co-authored-by: Vojtech Novak <vonovak@gmail.com>
@@ -80,18 +78,6 @@ export default function Picker({
80
78
[onChange,value],
81
79
);
82
80
83
-
React.useEffect(
84
-
functionensureCorrectHeight(){
85
-
constheight=getPickerHeightStyle(display,mode);
86
-
if(heightinstanceofPromise){
87
-
height.then(setHeightStyle);
88
-
}else{
89
-
setHeightStyle(height);
90
-
}
91
-
},
92
-
[display,mode],
93
-
);
94
-
95
81
const_onChange=(event: NativeEventIOS)=>{
96
82
consttimestamp=event.nativeEvent.timestamp;
97
83
// $FlowFixMe Cannot assign object literal to `unifiedEvent` because number [1] is incompatible with undefined [2] in property `nativeEvent.timestamp`.
@@ -104,11 +90,6 @@ export default function Picker({
104
90
105
91
invariant(value,'A date or time should be specified as `value`.');
0 commit comments