import { Card, __experimentalVStack as VStack, __experimentalHStack as HStack, __experimentalText as Text, Icon, } from '@wordpress/components'; import { forwardRef } from 'react'; import type { CalloutProps } from './types'; import './styles.scss'; function UnforwardedCallout( { title, titleAs: TitleComponent = Text, icon, image, imageAlt, imageVariant = 'default', description, actions, variant = 'default', }: CalloutProps, ref: React.ForwardedRef< HTMLElement > ) { return ( { icon && } { title } { description } { actions } { image && ( { typeof image === 'string' ? { : image } ) } ); } /** * The Callout component is a visually prominent layout element used to * highlight a key feature, message, or promotional content. It typically * includes a title, supporting description, image and/or icon, and a * single call-to-action (CTA) button or link. */ export const Callout = forwardRef( UnforwardedCallout );