Add setting to manage visibility of vote count, vote button and decide root page (#197)

This commit is contained in:
Riccardo Graziosi
2023-02-05 11:55:38 +01:00
committed by GitHub
parent d4242dd78e
commit e7335f5622
35 changed files with 246 additions and 48 deletions

View File

@@ -12,7 +12,9 @@ interface Props {
title: string;
description?: string;
postStatus: IPostStatus;
likesCount: number;
likeCount: number;
showLikeCount: boolean;
showLikeButtons: boolean;
liked: number;
commentsCount: number;
@@ -25,7 +27,9 @@ const PostListItem = ({
title,
description,
postStatus,
likesCount,
likeCount,
showLikeCount,
showLikeButtons,
liked,
commentsCount,
@@ -35,7 +39,9 @@ const PostListItem = ({
<div onClick={() => window.location.href = `/posts/${id}`} className="postListItem">
<LikeButton
postId={id}
likesCount={likesCount}
likeCount={likeCount}
showLikeCount={showLikeCount}
showLikeButton={showLikeButtons}
liked={liked}
isLoggedIn={isLoggedIn}
authenticityToken={authenticityToken}