|
|
|
@ -1,11 +1,14 @@
|
|
|
|
|
import PropTypes from 'prop-types';
|
|
|
|
|
import React from 'react';
|
|
|
|
|
import Button from 'Components/Link/Button';
|
|
|
|
|
import { kinds } from 'Helpers/Props';
|
|
|
|
|
import translate from 'Utilities/String/translate';
|
|
|
|
|
import styles from './NoMovie.css';
|
|
|
|
|
|
|
|
|
|
function NoMovie(props) {
|
|
|
|
|
interface NoMovieProps {
|
|
|
|
|
totalItems: number;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function NoMovie(props: NoMovieProps) {
|
|
|
|
|
const { totalItems } = props;
|
|
|
|
|
|
|
|
|
|
if (totalItems > 0) {
|
|
|
|
@ -20,24 +23,16 @@ function NoMovie(props) {
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<div>
|
|
|
|
|
<div className={styles.message}>
|
|
|
|
|
{translate('NoMoviesExist')}
|
|
|
|
|
</div>
|
|
|
|
|
<div className={styles.message}>{translate('NoMoviesExist')}</div>
|
|
|
|
|
|
|
|
|
|
<div className={styles.buttonContainer}>
|
|
|
|
|
<Button
|
|
|
|
|
to="/add/import"
|
|
|
|
|
kind={kinds.PRIMARY}
|
|
|
|
|
>
|
|
|
|
|
<Button to="/add/import" kind={kinds.PRIMARY}>
|
|
|
|
|
{translate('ImportExistingMovies')}
|
|
|
|
|
</Button>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className={styles.buttonContainer}>
|
|
|
|
|
<Button
|
|
|
|
|
to="/add/new"
|
|
|
|
|
kind={kinds.PRIMARY}
|
|
|
|
|
>
|
|
|
|
|
<Button to="/add/new" kind={kinds.PRIMARY}>
|
|
|
|
|
{translate('AddNewMovie')}
|
|
|
|
|
</Button>
|
|
|
|
|
</div>
|
|
|
|
@ -45,8 +40,4 @@ function NoMovie(props) {
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
NoMovie.propTypes = {
|
|
|
|
|
totalItems: PropTypes.number.isRequired
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
export default NoMovie;
|