// components import SingleBoard from "components/project/cycles/board-view/single-board"; // ui import { Spinner } from "ui"; // types import { IIssue, IProjectMember, NestedKeyOf, Properties } from "types"; import useUser from "lib/hooks/useUser"; type Props = { groupedByIssues: { [key: string]: IIssue[]; }; properties: Properties; selectedGroup: NestedKeyOf | null; members: IProjectMember[] | undefined; openCreateIssueModal: (issue?: IIssue, actionType?: "create" | "edit" | "delete") => void; openIssuesListModal: (cycleId: string) => void; removeIssueFromCycle: (cycleId: string, bridgeId: string) => void; }; const CyclesBoardView: React.FC = ({ groupedByIssues, properties, selectedGroup, members, openCreateIssueModal, openIssuesListModal, removeIssueFromCycle, }) => { const { states } = useUser(); return ( <> {groupedByIssues ? (
{Object.keys(groupedByIssues).map((singleGroup) => ( m.member.id === singleGroup)?.member.first_name ?? "loading..." : null } groupedByIssues={groupedByIssues} bgColor={ selectedGroup === "state_detail.name" ? states?.find((s) => s.name === singleGroup)?.color : undefined } properties={properties} removeIssueFromCycle={removeIssueFromCycle} openIssuesListModal={openIssuesListModal} openCreateIssueModal={openCreateIssueModal} /> ))}
) : (
)} ); }; export default CyclesBoardView;