ABSTRACT sidebar buttons
This commit is contained in:
23
frontend/src/components/buttons/SidebarButton.tsx
Normal file
23
frontend/src/components/buttons/SidebarButton.tsx
Normal file
@@ -0,0 +1,23 @@
|
||||
import MenuButton from "./MenuButton.tsx";
|
||||
import { Link } from "react-router-dom";
|
||||
|
||||
type props = {
|
||||
url: string;
|
||||
logo: React.ReactNode;
|
||||
label: String;
|
||||
}
|
||||
|
||||
const SidebarButton = ({url, logo, label}: props) => {
|
||||
return (
|
||||
<Link
|
||||
className={"w-full"}
|
||||
to={url}
|
||||
>
|
||||
<MenuButton className={"flex items-center gap-2 w-full"}>
|
||||
{logo}{label}
|
||||
</MenuButton>
|
||||
</Link>
|
||||
)
|
||||
}
|
||||
|
||||
export default SidebarButton;
|
||||
Reference in New Issue
Block a user