You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
in this code if i put multiple={false} the date picker is still allowing user to select multiple dates. is this a bug in the library itself. iam using datepicker with react-hookforms and controller
The text was updated successfully, but these errors were encountered:
What type of value do you enter to DatePicker as initial value? If type of initial value is array, even if you set multiple to false., The DatePicker considers multiple to true.
const FormMultipleDatePicker: FunctionComponent = ({
displayName, name, placeholder, menuPortalTarget, minDate, maxDate,
className="", asterisk = true, variant="", isEdit, isMultiDatePickerDisabled = false,
placeHolderText = ""
}) => {
const {errors, control} = useFormContext();
// @ts-ignore
return <FlexColumn className={className + " px-2 mb-3"}>
{displayName}{asterisk? * :''}
<Controller
control={control}
name={name}
placeholder={placeholder}
menuPortalTarget={menuPortalTarget}
render={({onChange, value}) => (
isEdit ?
:
)}
/>
{errors[name] && errors[name].message}
};
in this code if i put multiple={false} the date picker is still allowing user to select multiple dates. is this a bug in the library itself. iam using datepicker with react-hookforms and controller
The text was updated successfully, but these errors were encountered: