Skip to content

Commit

Permalink
update datepicker
Browse files Browse the repository at this point in the history
  • Loading branch information
stanislaw-zakrzewski committed Apr 10, 2024
1 parent a15ae3e commit d3a0982
Showing 1 changed file with 8 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -207,21 +207,18 @@ export function DateField(props: DateFieldProps): JSX.Element {
data-testid={props.name}
label={props.label}
format="yyyy/MM/dd"
// mask="____/__/__"
minDate={new Date('2019/12/01')}
disableFuture
value={dateValue}
name={props.name}
onChange={props.onChange}
// renderInput={(params) => ( // TODO check if this is needed
// <MuiTextField
// {...params}
// name={props.name}
// fullWidth
// // Non formik component needs different error handling
// error={!!props.errorMessage}
// helperText={props.errorMessage}
// />
// )}
slotProps={{
textField: {
name: props.name,
error: !!props.errorMessage,
helperText: props.errorMessage,
},
}}
/>
</LocalizationProvider>
{props.required && <RequiredHelperText name={props.name} />}
Expand Down

0 comments on commit d3a0982

Please sign in to comment.