Merge branch 'card-title-truncate' into 'develop'

CardTitle: truncate too long text

See merge request soapbox-pub/soapbox-fe!1286
This commit is contained in:
Alex Gleason 2022-05-01 18:45:50 +00:00
commit e2cbc449ad

View file

@ -81,8 +81,8 @@ interface ICardTitle {
}
/** A card's title. */
const CardTitle = ({ title }: ICardTitle): JSX.Element => (
<Text size='xl' weight='bold' tag='h1' data-testid='card-title'>{title}</Text>
const CardTitle: React.FC<ICardTitle> = ({ title }): JSX.Element => (
<Text size='xl' weight='bold' tag='h1' data-testid='card-title' truncate>{title}</Text>
);
/** A card's body. */