import React from 'react' import './VideoCard.css' import { getSeasonsOrMovieLength } from 'utils/time' const videoCard = (props) => { const { name, poster_path, genres, runtime, seasons, vote_average } = props const image = `url(https://image.tmdb.org/t/p/w500/${poster_path})` const styles = { backgroundImage: image, backgroundSize: 'cover', } let timeSpan = getSeasonsOrMovieLength(seasons, runtime) const genreList = genres && genres.map((genre, index) => ( {genre.name} {index !== genres.length - 1 ? '●' : null} )) return (