Skip to content

Commit

Permalink
Merge pull request #63 from Code-Hive-GmbH/feat/select-mode
Browse files Browse the repository at this point in the history
feat: Add possibility to select initial view
  • Loading branch information
farhoudshapouran committed Feb 16, 2024
2 parents 537a0bb + b379b0b commit 653daa8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/DateTimePicker.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ const DateTimePicker = (
endDate,
dates,
onChange,
initialView = CalendarViews.day,
...rest
} = props;

Expand Down Expand Up @@ -149,7 +150,7 @@ const DateTimePicker = (
startDate,
endDate,
dates,
calendarView: CalendarViews.day,
calendarView: initialView,
currentDate,
currentYear,
}
Expand Down
1 change: 1 addition & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -91,4 +91,5 @@ export interface DatePickerBaseProps {
startDate?: DateType;
endDate?: DateType;
onChange?: SingleChange | RangeChange | MultiChange;
initialView?: CalendarViews;
}

0 comments on commit 653daa8

Please sign in to comment.