Generalized the infinite scrollable list (#4697)

This commit is contained in:
abcang authored and Eugen Rochko committed 2017-08-28 22:23:44 +02:00
1 parent 938cd2875b
commit 0827c09c44
8 files changed
+376 -320

No files matched your search

+11 -1
View File
@@ -26,6 +26,7 @@ export default class Account extends ImmutablePureComponent {
onBlock: PropTypes.func.isRequired,
onMute: PropTypes.func.isRequired,
intl: PropTypes.object.isRequired,
hidden: PropTypes.bool,
};
handleFollow = () => {
@@ -41,12 +42,21 @@ export default class Account extends ImmutablePureComponent {
}
render () {
const { account, me, intl } = this.props;
const { account, me, intl, hidden } = this.props;
if (!account) {
return <div />;
}
if (hidden) {
return (
<div>
{account.get('display_name')}
{account.get('username')}
</div>
);
}
let buttons;
if (account.get('id') !== me && account.get('relationship', null) !== null) {