import { FC } from "react"; import { observer } from "mobx-react-lite"; import { useRouter } from "next/router"; import useSWR from "swr"; // hooks import { Breadcrumbs, LayersIcon } from "@plane/ui"; import { BreadcrumbLink } from "components/common"; import { SidebarHamburgerToggle } from "components/core/sidebar/sidebar-menu-hamburger-toggle"; import { ISSUE_DETAILS } from "constants/fetch-keys"; import { renderEmoji } from "helpers/emoji.helper"; import { useProject } from "hooks/store"; // ui // types import { IssueArchiveService } from "services/issue"; import { TIssue } from "@plane/types"; // constants // services // helpers // components const issueArchiveService = new IssueArchiveService(); export const ProjectArchivedIssueDetailsHeader: FC = observer(() => { // router const router = useRouter(); const { workspaceSlug, projectId, archivedIssueId } = router.query; // store hooks const { currentProjectDetails, getProjectById } = useProject(); const { data: issueDetails } = useSWR( workspaceSlug && projectId && archivedIssueId ? ISSUE_DETAILS(archivedIssueId as string) : null, workspaceSlug && projectId && archivedIssueId ? () => issueArchiveService.retrieveArchivedIssue( workspaceSlug as string, projectId as string, archivedIssueId as string ) : null ); return (
{currentProjectDetails?.name.charAt(0)} ) } /> } /> } /> } /> } />
); });