From 61b6c193203082f1a681963ffb840ff488ba6f37 Mon Sep 17 00:00:00 2001 From: Sean Yesmunt Date: Thu, 27 Aug 2020 00:25:03 -0400 Subject: [PATCH] add empty comments message --- ui/component/commentsList/view.jsx | 2 ++ ui/scss/themes/dark.scss | 16 ++++++++-------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/ui/component/commentsList/view.jsx b/ui/component/commentsList/view.jsx index f30ab4f9e..ee775931b 100644 --- a/ui/component/commentsList/view.jsx +++ b/ui/component/commentsList/view.jsx @@ -34,6 +34,7 @@ function CommentList(props: Props) { const [start] = React.useState(0); const [end, setEnd] = React.useState(9); const totalComments = comments && comments.length; + const hasNoComments = totalComments === 0; const moreBelow = totalComments - end > 0; // todo: implement comment_list --mine in SDK so redux can grab with selectCommentIsMine @@ -93,6 +94,7 @@ function CommentList(props: Props) { actions={ <> {commentingEnabled && } + {!isFetchingComments && hasNoComments &&
{__('Be the first to comment!')}
}