mirror of
https://github.com/vercel/commerce.git
synced 2025-05-17 15:06:59 +00:00
24 lines
550 B
TypeScript
24 lines
550 B
TypeScript
import type { CustomField } from '@commerce/types/common'
|
|
|
|
interface Props {
|
|
customFields: CustomField[]
|
|
}
|
|
|
|
const ProductCustomFields: React.FC<Props> = ({ customFields }) => {
|
|
return (
|
|
<>
|
|
{customFields.map((field) => (
|
|
<div
|
|
key={field.id}
|
|
className="flex gap-2 border-b py-3 border-accent-2 border-dashed last:border-b-0"
|
|
>
|
|
<strong className="leading-7">{field.name}:</strong>
|
|
<span>{field.value}</span>
|
|
</div>
|
|
))}
|
|
</>
|
|
)
|
|
}
|
|
|
|
export default ProductCustomFields
|