import { useRouter } from "next/router"; import { observer } from "mobx-react-lite"; // hooks import { useCycle, useModule, useProject } from "hooks/store"; // helpers import { renderEmoji } from "helpers/emoji.helper"; import { renderFormattedDate } from "helpers/date-time.helper"; // constants import { NETWORK_CHOICES } from "constants/project"; export const CustomAnalyticsSidebarHeader = observer(() => { const router = useRouter(); const { projectId, cycleId, moduleId } = router.query; const { getProjectById } = useProject(); const { getCycleById } = useCycle(); const { getModuleById } = useModule(); const cycleDetails = cycleId ? getCycleById(cycleId.toString()) : undefined; const moduleDetails = moduleId ? getModuleById(moduleId.toString()) : undefined; const projectDetails = projectId ? getProjectById(projectId.toString()) : undefined; return ( <> {projectId ? ( cycleDetails ? (