diff --git a/src/components/DatePicker/DateTime/index.tsx b/src/components/DatePicker/DateTime/index.tsx index 61a5027..dfa44bb 100644 --- a/src/components/DatePicker/DateTime/index.tsx +++ b/src/components/DatePicker/DateTime/index.tsx @@ -35,6 +35,7 @@ export function DateTime({ locale={LOCALE[language]} selected={newDate} onChange={date => setNewDate(date)} + required={inputProps?.required} customInput={ { onChange(date!); }} diff --git a/src/stories/DatePicker.stories.tsx b/src/stories/DatePicker.stories.tsx index 68ed933..f4dd7df 100644 --- a/src/stories/DatePicker.stories.tsx +++ b/src/stories/DatePicker.stories.tsx @@ -106,6 +106,38 @@ export function DateTime() { ); } +export function InputStyle() { + const [singleDate, setSingleDate] = useState(null); + const [dateTime, setDateTime] = useState(null); + + return ( + + + + + ); +} + const Container = styled.div` width: 100%; height: 100%;