Initial frontend draft
This commit is contained in:
parent
1606d1faf0
commit
b6293beeec
21 changed files with 4105 additions and 150 deletions
28
frontend/app/Components/Libraries/LibraryCard.tsx
Normal file
28
frontend/app/Components/Libraries/LibraryCard.tsx
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
import { Card } from "react-bootstrap";
|
||||
import { useNavigate } from "react-router";
|
||||
import type Library from "~/Models/Library";
|
||||
|
||||
interface Props {
|
||||
library: Library;
|
||||
}
|
||||
|
||||
const LibraryCard = ({ library }: Props) => {
|
||||
const navigate = useNavigate();
|
||||
|
||||
function handleClick() {
|
||||
navigate(`/Library/${library.id}`);
|
||||
}
|
||||
|
||||
return (
|
||||
<Card onClick={handleClick}>
|
||||
<Card.Header>
|
||||
<Card.Img />
|
||||
</Card.Header>
|
||||
<Card.Body>
|
||||
<Card.Title>{library.name}</Card.Title>
|
||||
</Card.Body>
|
||||
</Card>
|
||||
);
|
||||
}
|
||||
|
||||
export default LibraryCard;
|
||||
Loading…
Add table
Add a link
Reference in a new issue