Skip to content

Commit

Permalink
fix(requiredCompletions): force 1 at least requiredCompletion
Browse files Browse the repository at this point in the history
  • Loading branch information
Clm-Roig committed Apr 9, 2022
1 parent ef931be commit 2ebe150
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,11 @@ const RequiredCompletionsForm: FC<Props> = ({ append, control, fields, gridProps
{...gridProps}>
<Grid item xs={2} sx={{ display: 'flex', justifyContent: 'space-between', mb: 1 }}>
<Typography variant="subtitle1">Objectif n°{index + 1}</Typography>
<IconButton onClick={() => remove(index)} sx={{ p: 0 }}>
<DeleteIcon color="error" />
</IconButton>
{fields.length > 1 && (
<IconButton onClick={() => remove(index)} sx={{ p: 0 }}>
<DeleteIcon color="error" />
</IconButton>
)}
</Grid>
<Grid item xs={1}>
<Controller
Expand Down

0 comments on commit 2ebe150

Please sign in to comment.