Skip to content

Commit

Permalink
Add HTML lang attribute to preview card descriptions (mastodon#27503)
Browse files Browse the repository at this point in the history
  • Loading branch information
srapilly authored and vmstan committed Dec 14, 2023
1 parent 5b111a0 commit 1aac128
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ export default class Card extends PureComponent {

<strong className='status-card__title' title={card.get('title')} lang={language}>{card.get('title')}</strong>

{card.get('author_name').length > 0 ? <span className='status-card__author'><FormattedMessage id='link_preview.author' defaultMessage='By {name}' values={{ name: <strong>{card.get('author_name')}</strong> }} /></span> : <span className='status-card__description'>{card.get('description')}</span>}
{card.get('author_name').length > 0 ? <span className='status-card__author'><FormattedMessage id='link_preview.author' defaultMessage='By {name}' values={{ name: <strong>{card.get('author_name')}</strong> }} /></span> : <span className='status-card__description' lang={language}>{card.get('description')}</span>}
</div>
);

Expand Down

0 comments on commit 1aac128

Please sign in to comment.