diff --git a/src/components/account-block.jsx b/src/components/account-block.jsx
index c8c2e54b..84d3792b 100644
--- a/src/components/account-block.jsx
+++ b/src/components/account-block.jsx
@@ -1,6 +1,7 @@
import './account-block.css';
import emojifyText from '../utils/emojify-text';
+import niceDateTime from '../utils/nice-date-time';
import states from '../utils/states';
import Avatar from './avatar';
@@ -12,6 +13,7 @@ function AccountBlock({
instance,
external,
onClick,
+ showActivity = false,
}) {
if (skeleton) {
return (
@@ -26,8 +28,17 @@ function AccountBlock({
);
}
- const { acct, avatar, avatarStatic, displayName, username, emojis, url } =
- account;
+ const {
+ acct,
+ avatar,
+ avatarStatic,
+ displayName,
+ username,
+ emojis,
+ url,
+ statusesCount,
+ lastStatusAt,
+ } = account;
const displayNameWithEmoji = emojifyText(displayName, emojis);
return (
@@ -58,6 +69,23 @@ function AccountBlock({
{username}
)}
@{acct}
+ {showActivity && (
+ <>
+
+
+ Posts: {statusesCount}
+ {!!lastStatusAt && (
+ <>
+ {' '}
+ · Last posted:{' '}
+ {niceDateTime(lastStatusAt, {
+ hideTime: true,
+ })}
+ >
+ )}
+
+ >
+ )}
);