import * as React from 'react' import { cva, type VariantProps } from 'class-variance-authority' import { cn } from '@/lib/utils' const sectionVariants = cva('py-16', { variants: { variant: { default: '', highlighted: 'bg-muted', accent: 'bg-primary/5', }, width: { narrow: 'max-w-3xl mx-auto', default: 'max-w-5xl mx-auto', wide: 'max-w-7xl mx-auto', full: 'w-full', }, }, defaultVariants: { variant: 'default', width: 'default', }, }) interface SectionProps extends React.ComponentProps<'section'>, VariantProps { title?: string description?: string } function Section({ className, variant, width, title, description, children, ...props }: SectionProps) { return (
{(title || description) && (
{title && (

{title}

)} {description && (

{description}

)}
)} {children}
) } export { Section, sectionVariants }