⭐️⭐️⭐️ Open-source, self-hosted alternative to Linear and Plane. Project management and issue tracking where teams and AI agents work side by side to plan and ship products.
TypeScript agenticagileai-agentsbug-reportingbug-trackerganttissue-trackerjirajira-alternativekanbanlinearlinear-alternativeopen-sourceproduct-managementproject-managementroadmapself-hostedsprint-planningteam-collaborationtrello-alternative
'use client';
import { useTranslations } from 'next-intl';
import type { TeamProject } from '@/lib/api/endpoints/teams';
import { useLeaveProject } from '@/services/projects.service';
import ConfirmDialog from '@/components/common/overlay/ConfirmDialog';
export default function TeamProjectLeaveDialog({
project,
userId,
onClose,
}: {
project: TeamProject;
userId: string;
onClose: () => void;
}) {
const t = useTranslations('projects.leaveDialog');
const leaveProject = useLeaveProject();
return (
<ConfirmDialog
title={t('title', { name: project.name })}
confirmLabel={t('confirm')}
onClose={onClose}
onConfirm={async () => {
await leaveProject.mutateAsync({ projectKey: project.ref, userId });
onClose();
}}
>
<p className="text-sm text-muted-foreground">
{t.rich('description', {
name: project.name,
strong: (chunks) => <span className="font-medium text-foreground">{chunks}</span>,
})}
</p>
</ConfirmDialog>
);
}