React Native Picker Modal View
React Native Module to select item picker modal.
Getting started
$ npm install react-native-picker-modal-view --save
or
$ yarn add react-native-picker-modal-view
Example
Options
Properties | Type | Description | Default |
---|---|---|---|
animationType | string |
The RN Modal animation type | "slide" |
hideAlphabetFilter | string |
Alphabets list in modal at right | "true" |
onRequestClosed | Function |
Function fired when the modal closed | |
onBackRequest | Function |
Function fired when the back key pressed | |
onSelected *required |
Function |
Function return object when selected item | "{ Id: string | number; Name: string; Value: string; [key: string]: any; CountryId?: ICity; CityId?: ITown; }" |
list *required |
array |
Array for list data | "[{ Id: string | number; Name: string; Value: string; [key: string]: any; CountryId?: ICity; CityId?: ITown; }]" |
alphabets | array |
Alphabets array to be listed | "Predefined turkish alphabets" |
placeholderTextColor | string |
Search input placeholder text color | "#252525" |
keyExtractor | Function |
Flatlist defined {key} function | "Predefined return map index" |
autoGenerateAlphabet | boolean |
Auto generate alphabets list from data list | "false" |
sortingLanguage | string |
Country ISO (Alpha 2) Code for localeCompare | "tr" |
showToTopButton | boolean |
Button for scroll to offset 0 | "true" |
onEndReached | Function |
Function fired when the list end | |
FlatListProps | object |
React Native Flatlist Props | |
SearchInputProps | object |
React Native TextInput Props | |
ModalProps | object |
React Native Modal Props | |
chooseText | string |
Select box placeholder text | "Choose one..." |
searchText | string |
Search input placeholder text | "Search..." |
defaultSelected | object |
Predefined selected object | |
autoCorrect | boolean |
Auto correct for search input | "true" |
autoSort | boolean |
Auto sort data list | "false" |
style | object |
In the future list... | |
disabled | boolean |
Select box disabled boolean | |
forceSelect | boolean |
Force the user select anyone | "false" |