react-native-ui-lib
Version:
[](https://stand-with-ukraine.pp.ua)
38 lines (37 loc) • 1.93 kB
JSON
{
"name": "Picker.Item",
"category": "form",
"description": "Picker.Item, for configuring the Picker's selectable options",
"example": "https://github.com/wix/react-native-ui-lib/blob/master/demo/src/screens/componentScreens/PickerScreen.tsx",
"images": [
"https://github.com/wix/react-native-ui-lib/blob/master/demo/showcase/Picker/Default.gif?raw=true",
"https://github.com/wix/react-native-ui-lib/blob/master/demo/showcase/Picker/MultiPicker.gif?raw=true",
"https://github.com/wix/react-native-ui-lib/blob/master/demo/showcase/Picker/DialogPicker.gif?raw=true",
"https://github.com/wix/react-native-ui-lib/blob/master/demo/showcase/Picker/CustomPicker.gif?raw=true"
],
"props": [
{"name": "value", "type": "string | number", "description": "Item's value"},
{"name": "label", "type": "string", "description": "Item's label"},
{"name": "labelStyle", "type": "ViewStyle", "description": "Item's label style"},
{
"name": "getItemLabel",
"type": "(value: string | number) => string",
"description": "Custom function for the item label"
},
{"name": "isSelected", "type": "boolean", "description": "Is the item selected"},
{"name": "selectedIcon", "type": "string", "description": "Pass to change the selected icon"},
{"name": "selectedIconColor", "type": "ImageSource", "description": "Pass to change the selected icon color"},
{"name": "disabled", "type": "boolean", "description": "Is the item disabled"},
{
"name": "onPress",
"type": "(selected: boolean | undefined, props: any) => void | Promise<boolean>;",
"description": "Callback for onPress action, will stop selection if false is returned"
},
{
"name": "onSelectedLayout",
"type": "(event: LayoutChangeEvent) => void",
"description": "Callback for onLayout event"
}
],
"snippet": ["<Picker.Item key={index$1} value={item$2}/>"]
}