import cx from 'classnames'; import React, { useMemo } from 'react'; import Message, { IMessageProps } from '../message'; import css from './message-image.module.css'; // -- TYPES interface IMessageImageProps extends Omit { downloadUrl: string; actions?: React.ReactNode; } // -- MAIN function MessageImage({ downloadUrl, actions, className, ...msgProps }: IMessageImageProps) { const cnMessage = useMemo( () => ({ wrapper: className.wrapper, body: cx(className.body, css.body), }), [className], ); return (
{actions}
); } MessageImage.defaultProps = { className: {}, }; export default MessageImage;