Skip to content
This repository has been archived by the owner on Sep 27, 2024. It is now read-only.

feat: deadline table made for students #82

Merged
merged 1 commit into from
Mar 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions frontend/src/assets/styles/students_components.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
.student-main {
width: 96vw;
}

.student-left {
width: 60vw;
flex-wrap: wrap;
overflow-y: scroll;
Expand All @@ -16,4 +20,31 @@

.p-positive {
color: green;
}

.student-right {
width: 36vw;
}

.deadline {
background-color: #e0e3ff;
width: 15vw;
height: 75vh;
border-radius: 0.50rem;
}

.deadline-head {
background-color: #5f63c8;
border-radius: 0.50rem 0.50rem 0 0;
}

.deadline-elements {
height: 100%;
overflow-y: scroll;
border-radius: 0 0 0.50rem 0.50rem;
}

.deadline-card {
background-color: #9c9afd;
border-bottom: thin solid;
}
7 changes: 0 additions & 7 deletions frontend/src/components/ProjectCard.tsx

This file was deleted.

34 changes: 34 additions & 0 deletions frontend/src/pages/student/DeadlineTable.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import {JSX} from "react";
import { FaArrowRightLong } from "react-icons/fa6";

function DeadlineElement(): JSX.Element {
return (
<div className={"deadline-card is-flex is-flex-direction-column is-align-items-center py-2"}>
<p>17:00 - 23/02</p>
<div className={"is-flex is-flex-direction-row is-align-items-center"}>
<FaArrowRightLong/>
<p className={"pl-2"}>Markov Decision Diagram</p>
</div>
</div>
)
}

function DeadlineTable(): JSX.Element {
return (
<div className={"deadline"}>
<div className={"deadline-head is-flex is-justify-content-center py-2"}>
<p>komende deadlines</p>
</div>
<div className={"deadline-elements"}>
<DeadlineElement/>
<DeadlineElement/>
<DeadlineElement/>
<DeadlineElement/>
<DeadlineElement/>
<DeadlineElement/>
</div>
</div>
)
}

export default DeadlineTable;
30 changes: 18 additions & 12 deletions frontend/src/pages/student/HomeStudent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import ProjectCardStudent from "./ProjectCardStudent.tsx";
import '../../assets/styles/students_components.css'
import {useRouteLoaderData} from "react-router-dom";
import {studentLoaderObject} from "../../dataloaders/StudentLoader.ts";
import DeadlineTable from "./DeadlineTable.tsx";

export default function HomeStudent(): JSX.Element {

Expand All @@ -21,18 +22,23 @@ export default function HomeStudent(): JSX.Element {
<div className={"side-bar is-flex is-justify-content-center"}>
<Sidebar/>
</div>
<div className={"student-main px-5 py-5 mx-5 my-5 is-flex is-justify-content-space-evenly"}>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<div className={"student-main is-flex"}>
<div className={"student-left px-5 py-5 mx-5 my-5 is-flex is-justify-content-space-evenly"}>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
<ProjectCardStudent/>
</div>
<div className={"student-right is-flex is-justify-content-center is-align-items-center"}>
<DeadlineTable/>
</div>
</div>
</div>
</>
Expand Down