mirror of
https://git.kescher.at/CatCatNya/catstodon.git
synced 2024-11-26 19:31:36 +01:00
Display mentions prepended to the content warning
This commit is contained in:
parent
d4d3a10c25
commit
af007f2def
1 changed files with 7 additions and 1 deletions
|
@ -102,8 +102,14 @@ const StatusContent = React.createClass({
|
|||
const spoilerContent = { __html: emojify(escapeTextContentForBrowser(status.get('spoiler_text', ''))) };
|
||||
|
||||
if (status.get('spoiler_text').length > 0) {
|
||||
const mentionLinks = status.get('mentions').map(item => <Permalink to={`/accounts/${item.get('id')}`} href={item.get('url')} key={item.get('id') className='mention'>@<span>{item.get('username')}</span></Permalink>}</span>) };
|
||||
const mentionLinks = status.get('mentions').map(item => (
|
||||
<Permalink to={`/accounts/${item.get('id')}`} href={item.get('url')} key={item.get('id')} className='mention'>
|
||||
@<span>{item.get('username')}</span>
|
||||
</Permalink>
|
||||
)).reduce((aggregate, item) => [...aggregate, item, ' '], [])
|
||||
|
||||
const toggleText = hidden ? <FormattedMessage id='status.show_more' defaultMessage='Show more' /> : <FormattedMessage id='status.show_less' defaultMessage='Show less' />;
|
||||
|
||||
return (
|
||||
<div className='status__content' style={{ cursor: 'pointer' }} onMouseDown={this.handleMouseDown} onMouseUp={this.handleMouseUp}>
|
||||
<p style={{ marginBottom: hidden ? '0px' : '' }} >
|
||||
|
|
Loading…
Reference in a new issue