files
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
import { Link, useLocation } from "react-router-dom"
|
||||
import Icons from "../../Icons"
|
||||
|
||||
export default function AsideLink({shrinkAside, name, to, icon}) {
|
||||
|
||||
const {pathname} = useLocation()
|
||||
|
||||
return (
|
||||
<Link
|
||||
className={`w-full flex items-center gap-2 px-4 py-2 my-1 text-[13px] font-semibold rounded-md hover:text-white-light hover:bg-white/10 ${pathname == to ? 'bg-white/10 text-white-light' : 'text-slate-400'}`}
|
||||
to={to}
|
||||
>
|
||||
{icon && <Icons name={icon} />}
|
||||
{shrinkAside ? '' : name}
|
||||
</Link>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user