Fixed: Issue with link/tags icon to drop a line on movie details mobile (#4667)

#4523
pull/4796/head
nitsua 4 years ago committed by GitHub
parent ff7e929387
commit c07b370569
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -4,14 +4,17 @@ import Icon from 'Components/Icon';
import { icons } from 'Helpers/Props';
import styles from './HeartRating.css';
function HeartRating({ rating, iconSize }) {
function HeartRating({ rating, iconSize, hideHeart }) {
return (
<span>
<Icon
className={styles.heart}
name={icons.HEART}
size={iconSize}
/>
{
!hideHeart &&
<Icon
className={styles.heart}
name={icons.HEART}
size={iconSize}
/>
}
{rating * 10}%
</span>
@ -20,7 +23,8 @@ function HeartRating({ rating, iconSize }) {
HeartRating.propTypes = {
rating: PropTypes.number.isRequired,
iconSize: PropTypes.number.isRequired
iconSize: PropTypes.number.isRequired,
hideHeart: PropTypes.bool
};
HeartRating.defaultProps = {

@ -206,4 +206,13 @@
.movieNavigationButtons {
display: none;
}
.certification,
.links,
.tags,
.rating,
.year,
.runtime {
margin-right: 10px;
}
}

@ -1,4 +1,5 @@
import _ from 'lodash';
import moment from 'moment';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { Tab, TabList, TabPanel, Tabs } from 'react-tabs';
@ -280,6 +281,7 @@ class MovieDetails extends Component {
} = this.state;
const marqueeWidth = isSmallScreen ? titleWidth : (titleWidth - 150);
const friendlyRuntime = moment.utc((runtime * 60) * 1000).format('h[h] m[m]');
return (
<PageContent title={title}>
@ -424,7 +426,7 @@ class MovieDetails extends Component {
{
!!runtime &&
<span className={styles.runtime}>
{runtime} Minutes
{friendlyRuntime}
</span>
}
@ -434,6 +436,7 @@ class MovieDetails extends Component {
<HeartRating
rating={ratings.value}
iconSize={20}
hideHeart={isSmallScreen}
/>
</span>
}

@ -238,7 +238,7 @@ MovieFileEditorRow.propTypes = {
customFormats: PropTypes.arrayOf(PropTypes.object).isRequired,
qualityCutoffNotMet: PropTypes.bool.isRequired,
languages: PropTypes.arrayOf(PropTypes.object).isRequired,
mediaInfo: PropTypes.object.isRequired,
mediaInfo: PropTypes.object,
onDeletePress: PropTypes.func.isRequired
};

@ -47,7 +47,7 @@ function FileDetailsModal(props) {
FileDetailsModal.propTypes = {
isOpen: PropTypes.bool.isRequired,
onModalClose: PropTypes.func.isRequired,
mediaInfo: PropTypes.object.isRequired
mediaInfo: PropTypes.object
};
export default FileDetailsModal;

Loading…
Cancel
Save