import React from 'react' import cc from 'classcat' import { StyledCardContainer } from '../../../_internals/card/Card.style' import { Button } from '../../../button' import { SpacingDivider, SpacingDividerSize } from '../../../divider/spacingDivider' import { BaseSection, SectionContentSize } from '../../../layout/section/baseSection' import { TripCardProps } from '../../../tripCard' import { StyledCardsGridSection, StyledTitle } from './CardsGridSection.style' type ChildrenProps = Array> | React.ReactElement export type CardsGridSectionProps = Readonly<{ children: ChildrenProps className?: string contentSize?: SectionContentSize title?: string | JSX.Element buttonTitle?: string buttonHref?: string | JSX.Element }> export const CardsGridSection = ({ children, className = '', contentSize = SectionContentSize.SMALL, title, buttonTitle, buttonHref, }: CardsGridSectionProps) => ( {title && (

{title}

)}
    {React.Children.map(children, (child: JSX.Element) => ( {child} ))}
{buttonTitle && buttonHref && (
)}
)