import React, { useEffect } from 'react' import cc from 'classcat' import { animationDelay, animationDuration, StyledPushInfo, StyledPushInfoWrapper, } from './PushInfo.style' export type PushInfoProps = Readonly<{ className?: string icon?: React.ReactNode headline: string content?: string onAnimationEnd?: Function }> export const PushInfo = ({ className, icon, headline, content, onAnimationEnd, }: PushInfoProps): JSX.Element => { useEffect(() => { if (onAnimationEnd) { setTimeout(onAnimationEnd, animationDuration + animationDelay) } }, [onAnimationEnd]) return ( {icon &&
{icon}
}

{headline}

{content &&

{content}

}
) }