import { StyleSheet, Text, View } from "react-native";
import { Picker } from '@react-native-picker/picker';
import React from "react";
const AppPicker: React.FC<{
label: string;
selectedValue: string | undefined;
onValueChange: (value: string | undefined) => void;
items: string[];
}> = ({ label, selectedValue, onValueChange, items }) => (
<>
{label}
{items.map((item: string) => (
))}
>
);
const styles = StyleSheet.create({
label: {
fontWeight: 'bold',
marginTop: 10,
color: '#333',
width: '100%',
},
pickerContainer: {
width: '100%',
borderColor: '#ccc',
borderWidth: 1,
borderRadius: 8,
marginTop: 5,
marginBottom: 10,
backgroundColor: '#f9f9f9',
justifyContent: 'center',
},
picker: {
width: '100%',
height: 50,
},
});
export default AppPicker;