I have the following (dummy) components:
const OwnerList = () => {
return (
<Box
sx={{
display: 'flex',
}}
className="owner-container"
>
<Avatar src='https://hips.hearstapps.com/hmg-prod.s3.amazonaws.com/images/actor-robert-pattinson-attends-the-opening-ceremony-of-the-news-photo-1588147075.jpg?crop=1.00xw:0.669xh;0,0.0920xh&resize=480:*' sx={{ width: 70, height: 70 }}>
</Avatar>
<Box
className='testz'
>
<Typography sx={{ fontSize: 14 }}>
Robert Douglas Thomas Pattinson
</Typography>
</Box>
<Box className='owner-iconbutton-container'>
<IconButton className='owner-iconbutton' size="large">
<SwapVertIcon />
</IconButton>
</Box>
</Box>
)
}
export const OwnerListDropdown = () => {
return (
<Box sx={{ minWidth: 120 }}>
<FormControl fullWidth>
<InputLabel variant="standard" htmlFor="uncontrolled-native">
User
</InputLabel>
<NativeSelect
defaultValue={30}
inputProps={{
name: 'User',
id: 'uncontrolled-native',
}}
>
<option value={10}><OwnerList /></option>
<option value={20}><OwnerList /></option>
<option value={30}><OwnerList /></option>
</NativeSelect>
</FormControl>
</Box>
)
}
My intention is to generate a dropdown that contains multiple card items and allow the user to select the card (or at least have some item like Avatar - info). Sadly (and perhaps obviously) with my current approach i'm not achieving this goal. When the is called, it just display the following:
Is there a way to make a personalized dropdown that works as intended?
