Queue status/timeleft improvements
New: Queue status icon is purple when download is waiting to import or importing Fixed: Timeleft on Queue won't show when completed Closes #3743
This commit is contained in:
parent
5951992bd5
commit
910de6d94a
|
@ -51,10 +51,6 @@ function QueueStatusCell(props) {
|
||||||
let iconKind = kinds.DEFAULT;
|
let iconKind = kinds.DEFAULT;
|
||||||
let title = 'Downloading';
|
let title = 'Downloading';
|
||||||
|
|
||||||
if (hasWarning) {
|
|
||||||
iconKind = kinds.WARNING;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (status === 'paused') {
|
if (status === 'paused') {
|
||||||
iconName = icons.PAUSED;
|
iconName = icons.PAUSED;
|
||||||
title = 'Paused';
|
title = 'Paused';
|
||||||
|
@ -71,17 +67,24 @@ function QueueStatusCell(props) {
|
||||||
|
|
||||||
if (trackedDownloadState === 'importPending') {
|
if (trackedDownloadState === 'importPending') {
|
||||||
title += ' - Waiting to Import';
|
title += ' - Waiting to Import';
|
||||||
|
iconKind = kinds.PURPLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (trackedDownloadState === 'importing') {
|
if (trackedDownloadState === 'importing') {
|
||||||
title += ' - Importing';
|
title += ' - Importing';
|
||||||
|
iconKind = kinds.PURPLE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (trackedDownloadState === 'failedPending') {
|
if (trackedDownloadState === 'failedPending') {
|
||||||
title += ' - Waiting to Process';
|
title += ' - Waiting to Process';
|
||||||
|
iconKind = kinds.DANGER;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (hasWarning) {
|
||||||
|
iconKind = kinds.WARNING;
|
||||||
|
}
|
||||||
|
|
||||||
if (status === 'delay') {
|
if (status === 'delay') {
|
||||||
iconName = icons.PENDING;
|
iconName = icons.PENDING;
|
||||||
title = 'Pending';
|
title = 'Pending';
|
||||||
|
|
|
@ -19,7 +19,7 @@ function TimeleftCell(props) {
|
||||||
timeFormat
|
timeFormat
|
||||||
} = props;
|
} = props;
|
||||||
|
|
||||||
if (status === 'Delay') {
|
if (status === 'delay') {
|
||||||
const date = getRelativeDate(estimatedCompletionTime, shortDateFormat, showRelativeDates);
|
const date = getRelativeDate(estimatedCompletionTime, shortDateFormat, showRelativeDates);
|
||||||
const time = formatTime(estimatedCompletionTime, timeFormat, { includeMinuteZero: true });
|
const time = formatTime(estimatedCompletionTime, timeFormat, { includeMinuteZero: true });
|
||||||
|
|
||||||
|
@ -33,7 +33,7 @@ function TimeleftCell(props) {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (status === 'DownloadClientUnavailable') {
|
if (status === 'downloadClientUnavailable') {
|
||||||
const date = getRelativeDate(estimatedCompletionTime, shortDateFormat, showRelativeDates);
|
const date = getRelativeDate(estimatedCompletionTime, shortDateFormat, showRelativeDates);
|
||||||
const time = formatTime(estimatedCompletionTime, timeFormat, { includeMinuteZero: true });
|
const time = formatTime(estimatedCompletionTime, timeFormat, { includeMinuteZero: true });
|
||||||
|
|
||||||
|
@ -47,7 +47,7 @@ function TimeleftCell(props) {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!timeleft) {
|
if (!timeleft || status === 'completed' || status === 'failed') {
|
||||||
return (
|
return (
|
||||||
<TableRowCell className={styles.timeleft}>
|
<TableRowCell className={styles.timeleft}>
|
||||||
-
|
-
|
||||||
|
|
|
@ -25,3 +25,7 @@
|
||||||
.warning {
|
.warning {
|
||||||
color: $warningColor;
|
color: $warningColor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.purple {
|
||||||
|
color: $purple;
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue