Skip to content

Commit b7c6162

Browse files
authored
Merge pull request #10855 from ogroppo/fix-small-date-doc
[DateInput] Fix example doc
2 parents a85c822 + 3314d95 commit b7c6162

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/ra-ui-materialui/src/input/DateInput.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,12 @@ import { useForkRef } from '@mui/material';
4343
*
4444
* @example
4545
* // If you want to manipulate the value from the field to adjust its timezone, use the format prop
46-
* <DateInput source="published_at" format={value => new Date(value).toISOString().split("T")[0} />
46+
* <DateInput source="published_at" format={value => new Date(value).toISOString().split("T")[0]} />
4747
* // The input will display the UTC day regardless of the browser timezone.
4848
*
4949
* @example
5050
* // If you want the returned value to be a Date, you must pass a custom parse method
51-
* to convert the form value (which is always a date string) back to a Date object.
51+
* // to convert the form value (which is always a date string) back to a Date object.
5252
* <DateInput source="published_at" parse={val => new Date(val)} />
5353
*/
5454
export const DateInput = (props: DateInputProps) => {

0 commit comments

Comments
 (0)