bug: ViewAllItem pass props link to href

This commit is contained in:
unknown 2021-08-25 11:07:18 +07:00
parent e83f3e0512
commit 9ed49d6ae7
2 changed files with 3 additions and 3 deletions

View File

@ -13,7 +13,7 @@ export default function Home() {
<ButtonCommon size={ButtonSize.large} icon={<IconBuy/>}>{ButtonSize.large} - Button default large</ButtonCommon>
<ButtonCommon icon={<IconBuy/>} disabled isIconSuffix={true}>Button with icon disabled</ButtonCommon>
<ButtonCommon icon={<IconBuy/>} type={ButonType.light}>Button with icon</ButtonCommon>
<ViewAllItem />
<ViewAllItem link="/all"/>
<ItemWishList isActive={false} />
<Logo />
<p>Go to <code>pages/index.tsx</code> to get your hand dirty!</p>

View File

@ -3,13 +3,13 @@ import s from './ViewAllItem.module.scss'
import Link from 'next/link'
interface Props {
link?: string
link: string
}
const ViewAllItem = ({ link }: Props) => {
return(
<div className={s.viewAll}>
<Link href={"/all"}>
<Link href={link}>
<a className={s.conTent}>
View All
</a>