import { useTranslation } from 'react-i18next'; import { HardDriveDownload, HardDriveUpload, X } from 'lucide-react'; interface Props { isCollapsed: boolean; activeJobsCount: number; cancelAllDownloads: () => void; isSyncing: boolean; syncJobDone: number; syncJobSkip: number; syncJobFail: number; syncJobTotal: number; } export default function SidebarActiveJobs({ isCollapsed, activeJobsCount, cancelAllDownloads, isSyncing, syncJobDone, syncJobSkip, syncJobFail, syncJobTotal, }: Props) { const { t } = useTranslation(); return ( <> {activeJobsCount > 0 && (
{!isCollapsed && ( {t('sidebar.downloadingTracks', { n: activeJobsCount })} )}
)} {isSyncing && (
{!isCollapsed && ( {t('sidebar.syncingTracks', { done: syncJobDone + syncJobSkip + syncJobFail, total: syncJobTotal })} )}
)} ); }