lawnstarter / react-native-picker-select

🔽 A Picker component for React Native which emulates the native <select> interfaces for iOS and Android
https://npmjs.com/package/react-native-picker-select
MIT License
1.73k stars 491 forks source link

Add `PickerAvoidingView` and `PickerStateProvider` for better iOS modal handling #507

Closed cubuspl42 closed 12 months ago

cubuspl42 commented 1 year ago

This PR introduces two new components, PickerAvoidingView and PickerStateProvider. These components aim to improve the user experience on iOS by ensuring that the picker is not obstructed by its own modal. The PickerAvoidingView handles proper positioning of the picker, while the PickerStateProvider manages the state and interactions between multiple pickers. This update enhances the overall usability of the picker component on iOS devices.

Note: This PR is stacked on top of https://github.com/lawnstarter/react-native-picker-select/pull/496, so that one needs to be merged first