'use client'; import { type ComponentRenderProps } from '@json-render/react'; export function Card({ element, children }: ComponentRenderProps) { const { title, description, padding } = element.props as { title?: string | null; description?: string | null; padding?: string | null; }; const paddings: Record = { none: '0', sm: '12px', lg: '24px' }; return (
{(title || description) && (
{title &&

{title}

} {description &&

{description}

}
)}
{children}
); }