import React from "react"; import styled from "styled-components"; import { DragDropContext, Droppable, Draggable } from "react-beautiful-dnd"; import Activity from "./Activity"; import { PlusSquare, Trash, Trash2 } from "lucide-react"; import ConfirmationModal from "@components/StyledElements/ConfirmationModal/ConfirmationModal"; function Chapter(props: any) { return ( {(provided, snapshot) => (

{props.info.list.chapter.name}

Delete } functionToExecute={() => props.deleteChapter(props.info.list.chapter.id)} status='warning' >

{(provided) => (
{props.info.list.activities.map((activity: any, index: any) => ( ))} {provided.placeholder}
{ props.openNewActivityModal(props.info.list.chapter.id); }} className="flex space-x-2 items-center py-2 my-3 rounded-md justify-center text-slate-500 outline-slate-200 bg-slate-50 hover:cursor-pointer">
Add Activity
)}
)}
); } const ChapterWrapper = styled.div` margin-bottom: 20px; padding: 4px; background-color: #ffffff9d; width: 900px; font-size: 15px; display: block; border-radius: 9px; border: 1px solid rgba(255, 255, 255, 0.19); box-shadow: 0px 13px 33px -13px rgb(0 0 0 / 12%); transition: all 0.2s ease; h3{ padding-left: 20px; padding-right: 20px; } `; const ActivitiesList = styled.div` padding: 10px; `; export default Chapter;