StudyPlanCard.js 1.02 KB
Newer Older
Choi Ga Young's avatar
Choi Ga Young committed
1
import { Link } from "react-router-dom";
Kim, Subin's avatar
Kim, Subin committed
2
import PlanLineList from "./PlanLineList";
Choi Ga Young's avatar
Choi Ga Young committed
3

Choi Ga Young's avatar
Choi Ga Young committed
4
const StudyPlanCard = ({ renList }) => {
Kim, Subin's avatar
Kim, Subin committed
5
  
Choi Ga Young's avatar
Choi Ga Young committed
6
  return (
Kim, Subin's avatar
Kim, Subin committed
7
8
9
10
11
12
13
    <Link className="card text-decoration-none link-dark mb-3" style={{ width: "20rem" }} to={`/studyplan/${renList.id}`}>
      <div className="card-body">
        <div className="d-flex">
          <h5 className="card-title col-10 text-nowrap" style={{ overflow: "hidden", textOverflow: "ellipsis" }}>{renList.name}</h5>
          <div className="col-2 d-flex justify-content-end">
            <Link className="text-decoration-none link-dark" to={`/subject/edit/${renList.id}`}><i className="bi bi-pencil-square pe-2"></i></Link>
            <i className="bi bi-trash"></i>
Choi Ga Young's avatar
Choi Ga Young committed
14
          </div>
Choi Ga Young's avatar
Choi Ga Young committed
15
        </div>
Kim, Subin's avatar
Kim, Subin committed
16
17
18
19
        <p className="card-subtitle ms-1 mb-2 text-muted">{renList.prof && renList.room ? renList.prof + ' - ' + renList.room : (renList.prof || renList.room)}</p>
        <PlanLineList subjectId={renList.id} planList={renList.planList} />
      </div>
    </Link>
Choi Ga Young's avatar
Choi Ga Young committed
20
21
22
  )
}

Choi Ga Young's avatar
Choi Ga Young committed
23
export default StudyPlanCard;