import StarSVG, { StarSVG1 } from "../../images/SVG/Star";
import styles from "./styles.module.scss";

interface IStarsProps {
  stars?: number;
  starVariant?: "0" | "1";
}

function Stars({ stars = 5, starVariant = "0" }: IStarsProps) {
  return (
    <div className={styles.container}>
      {Array.from({ length: stars }).map((_, index) => {
        if (starVariant === "1") {
          return <StarSVG1 key={index} />;
        }
        return <StarSVG key={index} />;
      })}
    </div>
  );
}

export default Stars;
