import cx from 'classnames';
import React from 'react';

import css from './message-link.module.css';

// -- TYPES

interface IMessageLinkProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
  isOwner?: boolean;
}

// -- MAIN

function MessageLink({ isOwner, ...rest }: IMessageLinkProps) {
  const cn = cx(isOwner ? css.own : css.normal);

  return <a {...rest} className={cn} />;
}

export default MessageLink;
