Task 3: Backend

This commit is contained in:
RobinB27
2025-11-16 14:45:18 +01:00
parent 3a61b72642
commit f65cf176f9
9 changed files with 6492 additions and 34 deletions

View File

@@ -35,30 +35,37 @@ const DataTable = (props: {data: CSV_Data}) => {
}
return (
<table id="table-content">
<thead>
<tr>
{
header.map( (col) => (
<ColHeader col={col} sortingHandle={sortingHandler} isSelected={col == sortCol} sortType={sortType}></ColHeader>
))
}
</tr>
</thead>
<tbody>
{
props.data.map( (row, i) => (
<tr key={i}>
{
header.map( (col) => (
<Row col={col} content={row[col] as String}></Row>
))
}
<article className="table-container">
<header>
<h2>Data table</h2>
</header>
<div className="table-scroll-wrapper">
<table id="table-content">
<thead>
<tr>
{
header.map( (col) => (
<ColHeader col={col} sortingHandle={sortingHandler} isSelected={col == sortCol} sortType={sortType}></ColHeader>
))
}
</tr>
))
}
</tbody>
</table>
</thead>
<tbody>
{
props.data.map( (row, i) => (
<tr key={i}>
{
header.map( (col) => (
<Row col={col} content={row[col] as String}></Row>
))
}
</tr>
))
}
</tbody>
</table>
</div>
</article>
)
}