import React from "react";
import propTypes from "prop-types";
import MatchInfoCard from "./MatchInfoCard";
import "../styles/MatchInfoCardDisplay.css";
export default class MatchInfoCardDisplay extends React.Component {
    constructor(props) {
        super(props);
    }
    render() {
        let matches = null;
        if (this.props.recommendedmatches.length > 0) {
            matches = this.props.recommendedmatches.map((match) => <MatchInfoCard key={match._id} match={match}></MatchInfoCard>);
        }
        return (
            <div className="horizontal-scroller">
                {matches}
            </div>
        );
    }
}

MatchInfoCardDisplay.propTypes = {
    recommendedmatches: propTypes.array,
};