diff --git a/src/common/MetaPreview/MetaPreview.js b/src/common/MetaPreview/MetaPreview.js index 37997b889..82fbd5c82 100644 --- a/src/common/MetaPreview/MetaPreview.js +++ b/src/common/MetaPreview/MetaPreview.js @@ -10,7 +10,7 @@ const MetaLinks = require('./MetaLinks'); const MetaPreviewPlaceholder = require('./MetaPreviewPlaceholder'); const styles = require('./styles'); -const MetaPreview = ({ className, compact, id, type, name, logo, background, duration, releaseInfo, released, description, genres, writers, directors, cast, imdbId, imdbRating, trailer, share, inLibrary, toggleInLibrary }) => { +const MetaPreview = ({ className, compact, id, type, name, logo, background, runtime, releaseInfo, released, description, genres, writers, directors, cast, imdbId, imdbRating, trailer, share, inLibrary, toggleInLibrary }) => { const [shareModalOpen, openShareModal, closeShareModal] = useBinaryState(false); const genresLinks = React.useMemo(() => { return Array.isArray(genres) ? @@ -95,8 +95,8 @@ const MetaPreview = ({ className, compact, id, type, name, logo, background, dur null } { - (typeof releaseInfo === 'string' && releaseInfo.length > 0) || (released instanceof Date && !isNaN(released.getTime())) || (typeof duration === 'string' && duration.length > 0) ? -
+ (typeof releaseInfo === 'string' && releaseInfo.length > 0) || (released instanceof Date && !isNaN(released.getTime())) || (typeof runtime === 'string' && runtime.length > 0) ? +
{ typeof releaseInfo === 'string' && releaseInfo.length > 0 ?
{releaseInfo}
@@ -107,8 +107,8 @@ const MetaPreview = ({ className, compact, id, type, name, logo, background, dur null } { - typeof duration === 'string' && duration.length > 0 ? -
{duration}
+ typeof runtime === 'string' && runtime.length > 0 ? +
{runtime}
: null } @@ -231,7 +231,7 @@ MetaPreview.propTypes = { name: PropTypes.string, logo: PropTypes.string, background: PropTypes.string, - duration: PropTypes.string, + runtime: PropTypes.string, releaseInfo: PropTypes.string, released: PropTypes.instanceOf(Date), description: PropTypes.string, diff --git a/src/common/MetaPreview/styles.less b/src/common/MetaPreview/styles.less index 2291a2756..e5f7b655f 100644 --- a/src/common/MetaPreview/styles.less +++ b/src/common/MetaPreview/styles.less @@ -14,10 +14,10 @@ object-position: center; } - .duration-release-info-container { + .runtime-release-info-container { justify-content: space-evenly; - .duration-label, .release-info-label { + .runtime-label, .release-info-label { margin: 1rem 0.4rem; } } @@ -56,8 +56,9 @@ .logo, .logo-placeholder-icon { display: block; max-width: 100%; - height: 7rem; + height: 8rem; margin-top: 1rem; + padding: 1rem; background-color: var(--color-surfacedarker20); } @@ -67,17 +68,16 @@ } .logo-placeholder-icon { - padding: 1rem; fill: var(--color-surfacelight); } - .duration-release-info-container { + .runtime-release-info-container { display: flex; flex-direction: row; flex-wrap: wrap; margin-top: 1rem; - .duration-label, .release-info-label { + .runtime-label, .release-info-label { flex-grow: 0; flex-shrink: 1; flex-basis: auto;