calendar fix contd
This commit was merged in pull request #11.
This commit is contained in:
@@ -1,14 +1,15 @@
|
||||
import React, { useCallback, useState } from "react";
|
||||
import BreadcrumbComBS from "../breadcrumb/BreadcrumbComBS";
|
||||
import EventCalendar from "./EventCalendar";
|
||||
import ExternalDraggable from "./ExternalDraggable";
|
||||
|
||||
|
||||
export default function Calendar(){
|
||||
|
||||
const [draggedEvent, setDraggedEvent] = useState('undroppable')
|
||||
const handleDragStart = (event) => {
|
||||
setDraggedEvent(event)
|
||||
}
|
||||
// const [draggedEvent, setDraggedEvent] = useState('undroppable')
|
||||
// const handleDragStart = (event) => {
|
||||
// setDraggedEvent(event)
|
||||
// }
|
||||
|
||||
const dummyEvents = [
|
||||
{id: '1111', title: 'Family Vacation', color: 'fc-event-primary', start: new Date('2025-01-18')},
|
||||
@@ -38,7 +39,7 @@ export default function Calendar(){
|
||||
<p className="mt-3">
|
||||
Drag and drop your event or click in the calendar.
|
||||
</p>
|
||||
{dummyEvents.map((item, index) => (
|
||||
{/* {dummyEvents.map((item, index) => (
|
||||
<div key={index} className={`fc-event ${item.color}`} data-color={`${item.color}`}
|
||||
draggable="true"
|
||||
onDragStart={() =>
|
||||
@@ -47,7 +48,8 @@ export default function Calendar(){
|
||||
>
|
||||
<span></span> {item.title}
|
||||
</div>
|
||||
))}
|
||||
))} */}
|
||||
<ExternalDraggable dummyEvents={dummyEvents} />
|
||||
<div className="form-check">
|
||||
<input className="form-check-input" type="checkbox" value=""
|
||||
id="defaultCheck1" />
|
||||
@@ -60,7 +62,7 @@ export default function Calendar(){
|
||||
<div className="col-xl-9">
|
||||
<div className="event-calendar">
|
||||
{/* <EventCalendar draggedEvent={draggedEvent} setDraggedEvent={setDraggedEvent} /> */}
|
||||
<EventCalendar draggedEvent={draggedEvent} setDraggedEvent={setDraggedEvent} />
|
||||
<EventCalendar />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user