You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
58 lines
1.5 KiB
58 lines
1.5 KiB
import React from 'react';
|
|
import Image from 'next/image';
|
|
import {ButtonImg, Button } from '../../../UI'
|
|
|
|
type PizzaBlockProps = {
|
|
id: string;
|
|
title: string;
|
|
price: number;
|
|
imageUrl: string;
|
|
sizes: number[];
|
|
types: number[];
|
|
rating: number;
|
|
};
|
|
|
|
export const PizzaBlock: React.FC<PizzaBlockProps> = ({
|
|
id,
|
|
title,
|
|
imageUrl,
|
|
compound,
|
|
types,
|
|
}) => {
|
|
|
|
const onClickAdd = () => {
|
|
console.log('ok');
|
|
};
|
|
|
|
return (
|
|
<li className={"vendor-item " + " "+ " product_card"}>
|
|
<div className='vendor-item__link"'>
|
|
<Image
|
|
className = {'vendor-item__images'}
|
|
src={imageUrl}
|
|
alt={title}
|
|
width={187}
|
|
height={188}
|
|
/>
|
|
</div>
|
|
<span className={'product_card_box'} >
|
|
<h3>{title}</h3>
|
|
<p className={'product_card_text'}>{compound}</p>
|
|
<span className={'product_card_video'}>
|
|
<ButtonImg img={'video'}>Видос</ButtonImg>
|
|
</span>
|
|
<span className={'product_card_footer'}>
|
|
<p className={'product_card_price'}>{price}</p>
|
|
<Button
|
|
styles={'yellow button_size_32'}
|
|
align={'button_align_right'}
|
|
onClick={() => onClickAdd()}
|
|
>Добавить
|
|
</Button>
|
|
</span>
|
|
</span>
|
|
</li>
|
|
);
|
|
};
|
|
|
|
|
|
|