diff options
author | Dessalines <tyhou13@gmx.com> | 2020-04-10 16:55:57 -0400 |
---|---|---|
committer | Dessalines <tyhou13@gmx.com> | 2020-04-10 16:55:57 -0400 |
commit | bb287cbd076940bd09f6afb61b642370d020f91e (patch) | |
tree | f3fe3afa29b6445fbb2232a8c5a9133b8d691a91 /ui/src/components/post-listing.tsx | |
parent | ed264aba3c12243352f68c2de6a5f21f23778bd0 (diff) |
Adding an admin settings page.
- Fixes #620
- Adding a UserListing component. Fixes #627
Diffstat (limited to 'ui/src/components/post-listing.tsx')
-rw-r--r-- | ui/src/components/post-listing.tsx | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/ui/src/components/post-listing.tsx b/ui/src/components/post-listing.tsx index 101d1807..d0efa043 100644 --- a/ui/src/components/post-listing.tsx +++ b/ui/src/components/post-listing.tsx @@ -19,6 +19,7 @@ import { import { MomentTime } from './moment-time'; import { PostForm } from './post-form'; import { IFramelyCard } from './iframely-card'; +import { UserListing } from './user-listing'; import { md, mdToHtml, @@ -27,8 +28,6 @@ import { isImage, isVideo, getUnixTime, - pictshareAvatarThumbnail, - showAvatars, pictshareImage, setupTippy, previewLines, @@ -417,20 +416,12 @@ export class PostListing extends Component<PostListingProps, PostListingState> { <ul class="list-inline mb-0 text-muted small"> <li className="list-inline-item"> <span>{i18n.t('by')} </span> - <Link - className="text-body font-weight-bold" - to={`/u/${post.creator_name}`} - > - {post.creator_avatar && showAvatars() && ( - <img - height="32" - width="32" - src={pictshareAvatarThumbnail(post.creator_avatar)} - class="rounded-circle mr-1" - /> - )} - <span>{post.creator_name}</span> - </Link> + <UserListing + user={{ + name: post.creator_name, + avatar: post.creator_avatar, + }} + /> {this.isMod && ( <span className="mx-1 badge badge-light"> {i18n.t('mod')} |