Skip to content

Commit

Permalink
Update the Datepicker to show value
Browse files Browse the repository at this point in the history
  • Loading branch information
tan12082001 committed Dec 14, 2023
1 parent 8e5f94e commit 24ef800
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 2 additions & 0 deletions src/components/Form/FormField.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,10 @@ export const DateField = ({
/* eslint-disable react/jsx-props-no-spreading */
{...field}
{...props}
selected={field.value}
onChange={handleDatePickerChange}
onBlur={() => helpers.setTouched(true)}
minDate={new Date()}
/>
{meta.touched && meta.error ? (
<FieldErrorInfo>{meta.error}</FieldErrorInfo>
Expand Down
3 changes: 1 addition & 2 deletions src/pages/UserDashboard/DashboardHome.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,9 @@ const Container = styled.div`
margin: 3.5rem;
@media (max-width: 380px) {
width: 80%;
margin-left: 2.5rem;
}
@media (max-width: 768px) {
margin-left: 0;
margin-left: 2.5rem;
}
`;

Expand Down

0 comments on commit 24ef800

Please sign in to comment.