feat: denier titre publié dans le select lors de la création d'article
This commit is contained in:
@@ -4,7 +4,7 @@ import InputLabel from '@mui/material/InputLabel'
|
||||
import FormControl from '@mui/material/FormControl'
|
||||
import NativeSelect from '@mui/material/NativeSelect'
|
||||
|
||||
export default function ListItems({items, selectLabel, setSelectValue}) {
|
||||
export default function ListItems({items, selectLabel, selectValue, setSelectValue}) {
|
||||
const handleChange = event => {
|
||||
setSelectValue(event.target.value)
|
||||
}
|
||||
@@ -16,7 +16,7 @@ export default function ListItems({items, selectLabel, setSelectValue}) {
|
||||
{selectLabel}
|
||||
</InputLabel>
|
||||
<NativeSelect
|
||||
defaultValue=''
|
||||
value={selectValue}
|
||||
inputProps={{
|
||||
name: 'content',
|
||||
id: 'titre',
|
||||
@@ -35,5 +35,6 @@ export default function ListItems({items, selectLabel, setSelectValue}) {
|
||||
ListItems.propTypes = {
|
||||
items: PropTypes.array.isRequired,
|
||||
selectLabel: PropTypes.string.isRequired,
|
||||
selectValue: PropTypes.string.isRequired,
|
||||
setSelectValue: PropTypes.func.isRequired
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user