Skip to content

Commit f7c0b62

Browse files
authored
Merge pull request #61 from AnalogMemory/fix/format-returned-value
[bug] Format date values with expected format
2 parents 55569d8 + 60c0c2a commit f7c0b62

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

pages/index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ export default function Playground() {
3434
const handleChange = (value, e) => {
3535
setValue(value);
3636
console.log(e);
37+
console.log("value", value);
3738
};
3839
return (
3940
<div className="px-4 py-8">

src/components/Calendar/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,8 +121,8 @@ const Calendar: React.FC<Props> = ({
121121
const ipt = input?.current;
122122
changeDatepickerValue(
123123
{
124-
startDate: start,
125-
endDate: end
124+
startDate: dayjs(start).format("YYYY-MM-DD"),
125+
endDate: dayjs(end).format("YYYY-MM-DD")
126126
},
127127
ipt
128128
);

0 commit comments

Comments
 (0)