mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-02-09 08:22:11 -05:00
* Remove option to have media outside of CWs Upstream adopted the media-in-CW design glitch-soc originally had. * Move poll to StatusContent * Refactor status media icons * Rename `forceFilter` to `showDespiteFilter` for consistency with upstream * Change media and status content markup to match upstream's * Add mention placeholders back
29 lines
775 B
JavaScript
29 lines
775 B
JavaScript
import ImmutablePropTypes from 'react-immutable-proptypes';
|
|
|
|
import { Permalink } from 'flavours/glitch/components/permalink';
|
|
|
|
export const MentionsPlaceholder = ({ status }) => {
|
|
if (status.get('spoiler_text').length === 0 || !status.get('mentions')) {
|
|
return null;
|
|
}
|
|
|
|
return (
|
|
<div className='status__content'>
|
|
{status.get('mentions').map(item => (
|
|
<Permalink
|
|
to={`/@${item.get('acct')}`}
|
|
href={item.get('url')}
|
|
key={item.get('id')}
|
|
className='mention'
|
|
>
|
|
@<span>{item.get('username')}</span>
|
|
</Permalink>
|
|
)).reduce((aggregate, item) => [...aggregate, item, ' '], [])}
|
|
</div>
|
|
);
|
|
};
|
|
|
|
MentionsPlaceholder.propTypes = {
|
|
status: ImmutablePropTypes.map.isRequired,
|
|
};
|
|
|