diff --git a/frontend/src/Movie/Details/MovieStatusLabel.css b/frontend/src/Movie/Details/MovieStatusLabel.css index 04470753b..fff54bd98 100644 --- a/frontend/src/Movie/Details/MovieStatusLabel.css +++ b/frontend/src/Movie/Details/MovieStatusLabel.css @@ -8,7 +8,7 @@ border-left: 4px solid $successColor; } -.unreleased { +.notAvailable { padding-left: 2px; border-left: 4px solid $primaryColor; } diff --git a/frontend/src/Movie/Details/MovieStatusLabel.js b/frontend/src/Movie/Details/MovieStatusLabel.js index cbb03826c..c605bb91d 100644 --- a/frontend/src/Movie/Details/MovieStatusLabel.js +++ b/frontend/src/Movie/Details/MovieStatusLabel.js @@ -1,6 +1,7 @@ import PropTypes from 'prop-types'; import React from 'react'; import getQueueStatusText from 'Utilities/Movie/getQueueStatusText'; +import firstCharToUpper from 'Utilities/String/firstCharToUpper'; import translate from 'Utilities/String/translate'; import styles from './MovieStatusLabel.css'; @@ -10,22 +11,25 @@ function getMovieStatus(hasFile, isMonitored, isAvailable, queueDetails = false) const queueStatus = queueDetails.items[0].status; const queueState = queueDetails.items[0].trackedDownloadStatus; const queueStatusText = getQueueStatusText(queueStatus, queueState); - return queueStatusText.longText; + + if (queueStatusText) { + return queueStatusText; + } } if (hasFile) { - return translate('Downloaded'); + return 'downloaded'; } if (!isMonitored) { - return translate('Unmonitored'); + return 'unmonitored'; } if (isAvailable && !hasFile) { - return translate('Missing'); + return 'missing'; } - return translate('NotAvailable'); + return 'notAvailable'; } function MovieStatusLabel(props) { @@ -38,6 +42,7 @@ function MovieStatusLabel(props) { const status = getMovieStatus(hasMovieFiles, monitored, isAvailable, queueDetails); let statusClass = status; + if (queueDetails.items.length) { statusClass = 'queue'; } @@ -46,7 +51,7 @@ function MovieStatusLabel(props) { - {status} + {translate(firstCharToUpper(status))} ); } diff --git a/frontend/src/Movie/Index/ProgressBar/MovieIndexProgressBar.js b/frontend/src/Movie/Index/ProgressBar/MovieIndexProgressBar.js index 8bbcda882..3d7aad8ec 100644 --- a/frontend/src/Movie/Index/ProgressBar/MovieIndexProgressBar.js +++ b/frontend/src/Movie/Index/ProgressBar/MovieIndexProgressBar.js @@ -46,7 +46,7 @@ function MovieIndexProgressBar(props) { size={detailedProgressBar ? sizes.MEDIUM : sizes.SMALL} showText={detailedProgressBar} width={posterWidth} - text={(queueStatusText) ? queueStatusText.shortText : translate(movieStatus)} + text={(queueStatusText) ? queueStatusText : translate(movieStatus)} /> ); } diff --git a/frontend/src/Movie/MovieFileStatus.js b/frontend/src/Movie/MovieFileStatus.js index c66f8584a..7c6be4825 100644 --- a/frontend/src/Movie/MovieFileStatus.js +++ b/frontend/src/Movie/MovieFileStatus.js @@ -25,10 +25,10 @@ function MovieFileStatus(props) { return (