fix onNavigate function

This commit is contained in:
Yann Normand
2018-11-09 16:33:24 +10:00
parent fe1169f35d
commit 6ffd9f2bc6
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -178,7 +178,7 @@ export interface BigCalendarProps<TEvent extends Event = Event, TResource extend
now?: Date;
view?: View;
events?: TEvent[];
onNavigate?: (newDate: Date, action: Navigate) => void;
onNavigate?: (newDate: Date, view: View, action: Navigate) => void;
onView?: (view: View) => void;
onDrillDown?: (date: Date, view: View) => void;
onSelectSlot?: (slotInfo: { start: stringOrDate, end: stringOrDate, slots: Date[] | string[], action: 'select' | 'click' | 'doubleClick' }) => void;
@@ -71,7 +71,7 @@ class CalendarResource {
date={new Date()}
view={'day'}
events={getEvents()}
onNavigate={(newDate: Date, action: Navigate) => { }}
onNavigate={(newDate: Date, view: View, action: Navigate) => { }}
onView={(view: View) => { }}
onSelectSlot={(slotInfo) => {
const start = slotInfo.start;