mirror of
https://codeberg.org/andyscott/ExerciseTracker.git
synced 2024-11-09 06:00:48 -05:00
Minor updates
This commit is contained in:
parent
67f3a70130
commit
1139da980d
2 changed files with 7 additions and 2 deletions
|
@ -10,7 +10,7 @@ function Exercise({ exercise, onDelete, onEdit }) {
|
||||||
<td>{exercise.unit}</td>
|
<td>{exercise.unit}</td>
|
||||||
<td>{exercise.date}</td>
|
<td>{exercise.date}</td>
|
||||||
<td>
|
<td>
|
||||||
<MdEdit onClick={() => onEdit(exercise._id)} />
|
<MdEdit onClick={() => onEdit(exercise)} />
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<MdDeleteForever onClick={() => onDelete(exercise._id)} />
|
<MdDeleteForever onClick={() => onDelete(exercise._id)} />
|
||||||
|
|
|
@ -17,7 +17,12 @@ function ExerciseList({ exercises, onDelete, onEdit }) {
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
{exercises.map((exercise, i) => (
|
{exercises.map((exercise, i) => (
|
||||||
<Exercise exercise={exercise} onDelete={onDelete} key={i} />
|
<Exercise
|
||||||
|
exercise={exercise}
|
||||||
|
onDelete={onDelete}
|
||||||
|
onEdit={onEdit}
|
||||||
|
key={i}
|
||||||
|
/>
|
||||||
))}
|
))}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
Loading…
Reference in a new issue