fix: show description if accountId i/o author_name

This commit is contained in:
Arnaud Ligny 2025-08-23 04:25:32 +02:00
parent f6e822e1f5
commit 3aa1554d52

View File

@ -149,7 +149,15 @@ export default class Card extends PureComponent {
<strong className='status-card__title' title={card.get('title')} lang={language}>{card.get('title')}</strong> <strong className='status-card__title' title={card.get('title')} lang={language}>{card.get('title')}</strong>
{!showAuthor && (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>)} {!showAuthor && 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> </div>
); );