/** * External dependencies */ import classNames from 'classnames'; /** * Internal dependencies */ import './plugin-banner.scss'; type Feature = { icon: string; title?: string; description: string; }; type PluginBannerProps = { logo?: { image: string; alt?: string; }; description?: string; layout?: 'single' | 'dual'; features: Array< Feature >; children?: React.ReactNode; }; export const PluginBanner = ( { logo, description, layout = 'single', features, children, }: PluginBannerProps ) => { return (
{ logo && (
{
) } { description &&

{ description }

}
{ features.map( ( feature: Feature, index ) => { return (
{ feature.title && (
{ feature.title }
) }
{ feature.description }
); } ) }
{ children }
); };