fln-espranza 1.1.14 → 1.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -19,14 +19,12 @@ interface IProps {
|
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
export default function EDateInput({ label, value, style, maxDate, minDate, onChange }: IProps) {
|
|
22
|
-
// const [date, setDate] = useState(new Date());
|
|
23
22
|
const [show, setShow] = useState(false);
|
|
24
23
|
|
|
25
24
|
const handleOnChange = (event: any, selectedDate: any) => {
|
|
26
25
|
const currentDate = selectedDate;
|
|
27
26
|
setShow(false);
|
|
28
|
-
|
|
29
|
-
onChange(moment(currentDate).format(" MMM DD, YYYY"));
|
|
27
|
+
onChange(currentDate)
|
|
30
28
|
}
|
|
31
29
|
|
|
32
30
|
return (
|
|
@@ -39,7 +37,7 @@ export default function EDateInput({ label, value, style, maxDate, minDate, onCh
|
|
|
39
37
|
>
|
|
40
38
|
<EText size={"sm"} style={tw`font-normal`}>
|
|
41
39
|
{
|
|
42
|
-
value ? value : "Select Date"
|
|
40
|
+
value ? moment(value).format("DD/MM/YYYY") : "Select Date"
|
|
43
41
|
}
|
|
44
42
|
</EText>
|
|
45
43
|
{show ? <DateTimePicker
|