diff --git a/ui/component/comment/view.jsx b/ui/component/comment/view.jsx index f955599f7..d81498b9c 100644 --- a/ui/component/comment/view.jsx +++ b/ui/component/comment/view.jsx @@ -19,6 +19,8 @@ type Props = { channelIsBlocked: boolean, }; +const LENGTH_TO_COLLAPSE = 300; + function Comment(props: Props) { const { author, @@ -40,7 +42,6 @@ function Comment(props: Props) { resolveUri(authorUri); } }, [isResolvingUri, shouldFetch, author, authorUri, resolveUri]); - return (
  • @@ -59,11 +60,13 @@ function Comment(props: Props) {
    - -
    + {message.length >= LENGTH_TO_COLLAPSE ? ( + -
    -
    + + ) : ( + + )}
  • diff --git a/ui/component/commentsList/view.jsx b/ui/component/commentsList/view.jsx index 76fdfca23..d01aa133e 100644 --- a/ui/component/commentsList/view.jsx +++ b/ui/component/commentsList/view.jsx @@ -10,7 +10,6 @@ type Props = { function CommentList(props: Props) { const { fetchComments, uri, comments } = props; - useEffect(() => { fetchComments(uri); }, [fetchComments, uri]);