diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 1d2f7617..803b18e4 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -4726,4 +4726,4 @@ } } } -} +} \ No newline at end of file diff --git a/frontend/package.json b/frontend/package.json index b1609003..4397c832 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -29,4 +29,4 @@ "typescript": "^5.2.2", "vite": "^5.1.4" } -} +} \ No newline at end of file diff --git a/frontend/src/assets/styles/table.css b/frontend/src/assets/styles/table.css new file mode 100644 index 00000000..be8bb6d8 --- /dev/null +++ b/frontend/src/assets/styles/table.css @@ -0,0 +1,27 @@ +.title_lines { + position: relative; + font-size: 25px; + z-index: 1; + overflow: hidden; + text-align: center; +} + +.title_lines:before, .title_lines:after { + position: absolute; + top: 51%; + overflow: hidden; + width: 48%; + height: 1px; + content: '\a0'; + background-color: #cccccc; + margin-left: 2%; +} + +.title_lines:before { + margin-left: -50%; + text-align: right; +} + +body { + padding: 50px 0; +} \ No newline at end of file diff --git a/frontend/src/components/RegularButton.tsx b/frontend/src/components/RegularButton.tsx new file mode 100644 index 00000000..f0f00f22 --- /dev/null +++ b/frontend/src/components/RegularButton.tsx @@ -0,0 +1,15 @@ +import {JSX} from "react"; +import {IoMdAdd} from "react-icons/io"; + +export function RegularButton(props: { placeholder: string, add: boolean }): JSX.Element { + return ( + + ); +} \ No newline at end of file diff --git a/frontend/src/components/SearchBar.tsx b/frontend/src/components/SearchBar.tsx new file mode 100644 index 00000000..a1d17e5c --- /dev/null +++ b/frontend/src/components/SearchBar.tsx @@ -0,0 +1,15 @@ +import {JSX} from "react"; +import { FaSearch } from "react-icons/fa"; + +export function SearchBar(props: {placeholder: string}): JSX.Element { + return ( +
+

+ + + + +

+
+ ); +} \ No newline at end of file diff --git a/frontend/src/components/Table.tsx b/frontend/src/components/Table.tsx new file mode 100644 index 00000000..e27a3e7c --- /dev/null +++ b/frontend/src/components/Table.tsx @@ -0,0 +1,48 @@ +import {JSX} from "react"; +import "../assets/styles/table.css" + +const TableData: { "Naam": string, "Aantal projecten": number, "Kortste deadline": string }[] = [ + { + "Naam": "Automaten, berekenbaarheid & complexiteit", + "Aantal projecten": 3, + "Kortste deadline": "17:00 - 23/02/2024" + }, + { + "Naam": "Computationele Biologie", + "Aantal projecten": 2, + "Kortste deadline": "19:00 - 25/02/2024" + } +]; + +interface TableRow { + "Naam": string; + "Aantal projecten": number; + "Kortste deadline": string; +} + +export function Table(props: { title: string, keys: (keyof TableRow)[] }): JSX.Element { + return ( + <> +
{props.title}
+ + + + {props.keys.map((field, index) => ( + + ))} + + + + {TableData.map((row, rowIndex) => ( + + {props.keys.map((field, colIndex) => ( + + ))} + + ))} + +
{field}
{row[field]}
+ + + ); +} \ No newline at end of file