From a7314f876ea528fdec0fb0a2adaa36a01afcdf38 Mon Sep 17 00:00:00 2001 From: sct Date: Mon, 1 Feb 2021 12:13:01 +0000 Subject: [PATCH] fix(frontend): correctly show 4k download tracker activity --- src/components/DownloadBlock/index.tsx | 15 +++++++++++++-- src/components/MovieDetails/index.tsx | 8 ++++++++ src/components/RequestList/RequestItem/index.tsx | 2 +- src/components/TvDetails/index.tsx | 8 ++++++++ 4 files changed, 30 insertions(+), 3 deletions(-) diff --git a/src/components/DownloadBlock/index.tsx b/src/components/DownloadBlock/index.tsx index 3783d8c25..42deaad14 100644 --- a/src/components/DownloadBlock/index.tsx +++ b/src/components/DownloadBlock/index.tsx @@ -5,9 +5,13 @@ import Badge from '../Common/Badge'; interface DownloadBlockProps { downloadItem: DownloadingItem; + is4k?: boolean; } -const DownloadBlock: React.FC = ({ downloadItem }) => { +const DownloadBlock: React.FC = ({ + downloadItem, + is4k = false, +}) => { return (
@@ -36,7 +40,14 @@ const DownloadBlock: React.FC = ({ downloadItem }) => {
- {downloadItem.status} + + {is4k && ( + + 4K + + )} + {downloadItem.status} + ETA{' '} {downloadItem.estimatedCompletionTime ? ( diff --git a/src/components/MovieDetails/index.tsx b/src/components/MovieDetails/index.tsx index afe92a85f..29fd784c3 100644 --- a/src/components/MovieDetails/index.tsx +++ b/src/components/MovieDetails/index.tsx @@ -163,6 +163,14 @@ const MovieDetails: React.FC = ({ movie }) => { ))} + {data.mediaInfo?.downloadStatus4k?.map((status, index) => ( +
  • + +
  • + ))}
    diff --git a/src/components/RequestList/RequestItem/index.tsx b/src/components/RequestList/RequestItem/index.tsx index 807555ef7..435a6eb85 100644 --- a/src/components/RequestList/RequestItem/index.tsx +++ b/src/components/RequestList/RequestItem/index.tsx @@ -193,7 +193,7 @@ const RequestItem: React.FC = ({ ) : ( = ({ tv }) => { ))} + {data.mediaInfo?.downloadStatus4k?.map((status, index) => ( +
  • + +
  • + ))}