feat: open contact modal from vendor card

This commit is contained in:
Zotov Ivan Yuryevich
2026-04-21 22:19:29 +03:00
parent c9a199da91
commit 83330e9fd7
9 changed files with 57 additions and 12 deletions

View File

@@ -8,15 +8,22 @@ interface Vendor {
interface VendorsProps {
vendors?: Vendor[]
onVendorLearnMore?: (vendorName?: string) => void
}
export function Vendors({ vendors }: VendorsProps) {
export function Vendors({ vendors, onVendorLearnMore }: VendorsProps) {
if (vendors && vendors.length > 0) {
return (
<div className="max-w-400 mx-auto px-6 xl:px-12 2xl:px-16 py-20">
<div className="grid md:grid-cols-2 lg:grid-cols-3 gap-8">
{vendors.map(({ name, description, products }, index) => (
<VendorCard key={index} name={name} description={description} products={products} />
<VendorCard
key={index}
name={name}
description={description}
products={products}
onLearnMore={onVendorLearnMore}
/>
))}
</div>
</div>