DatePicker doesn't blur properly
Closed this issue · 0 comments
KohanTorabi commented
Describe the bug
I use antd input as custom input; When I click outside the date picker, it isn't closed. So it seems the blur function doesn't work well
<DatePicker
value={selectedDateRange}
onChange={onSelectDateRange}
wrapperClassName="market-trades-date-picker-wrapper"
renderInput={(props) => (
<Input
readOnly
ref={props.ref}
type={"string"}
className={"ant-calendar-date-panel"}
style={{ width: "100%" }}
value={
selectedDateRange.from || selectedDateRange.to
? `${strings.t.from} ${formatDate(selectedDateRange.from)} ${
strings.t.to
} ${formatDate(selectedDateRange.to)}`
: undefined
}
/>
)}
calendarClassName={"verification-birthday"}
locale={SELECTED_LANGUAGE}
/>
Expected behavior
When I click outside the date picker, The date picker should be closed