Personal-site/components/CaseCard.js

27 lines
660 B
JavaScript
Raw Normal View History

import React from "react";
import PropTypes from "prop-types";
import styles from "./modules/CaseCard.module.css";
export default function CaseCard(props) {
const study = props.study;
return (
<div className={styles.container}>
<img
className={`${styles.cover}`}
src={props.study.cover}
alt="The one and only bongo cat!"
/>
<div className={styles.cardInfo}>
<b className={styles.title}>{study.title}</b>
<p className={styles.description}>{study.short_description}</p>
<b>{study.date}</b>
</div>
</div>
);
}
CaseCard.propTypes = {
study: PropTypes.object.isRequired,
};