Compare commits

...

4 Commits

+10 -10
View File
@@ -64,15 +64,15 @@ export default function EventCalendar({draggedEvent, setDraggedEvent, removeAfte
} }
function handleEventClick(clickInfo) { // function handleEventClick(clickInfo) {
if ( // if (
confirm( // confirm(
`Are you sure you want to delete the event '${clickInfo.event.title}'` // `Are you sure you want to delete the event '${clickInfo.event.title}'`
) // )
) { // ) {
clickInfo.event.remove(); // clickInfo.event.remove();
} // }
} // }
function handleEvents(events) { function handleEvents(events) {
// setCurrentEvents(events); // setCurrentEvents(events);
@@ -98,7 +98,7 @@ export default function EventCalendar({draggedEvent, setDraggedEvent, removeAfte
events={currentEvents} events={currentEvents}
select={handleDateSelect} select={handleDateSelect}
eventContent={renderEventContent} // custom render function eventContent={renderEventContent} // custom render function
eventClick={handleEventClick} // eventClick={handleEventClick}
eventsSet={handleEvents} // called after events are initialized/added/changed/removed eventsSet={handleEvents} // called after events are initialized/added/changed/removed
/* you can update a remote database when these fire: /* you can update a remote database when these fire:
eventAdd={function(){}} eventAdd={function(){}}