commerce/components/home-page/button-link.tsx
Chloe 9e9573c7be
feat: implement browse by manufacturers section
Signed-off-by: Chloe <pinkcloudvnn@gmail.com>
2024-06-09 12:30:18 +07:00

19 lines
533 B
TypeScript

import Image from 'next/image';
import Link from 'next/link';
const ButtonLink = ({ link }: { link: { text: string; url: string } }) => {
return (
<Link href={link.url} className="relative w-fit px-5 py-2 text-white">
<Image
src="/background.svg"
alt="button background"
className="absolute inset-0 -z-10 h-full w-full rounded object-cover"
fill
/>
<div className="text-sm font-medium leading-5 tracking-wide">{link.text}</div>
</Link>
);
};
export default ButtonLink;