]> Untitled Git - lemmy-ui.git/blobdiff - src/shared/components/post/post-listing.tsx
Merge branch 'main' into fix-button-click-area
[lemmy-ui.git] / src / shared / components / post / post-listing.tsx
index e5117425378ac86f8b04d1c19487eb58255d39eb..7eb289c81d1704399e24002dba78d64997e1118d 100644 (file)
@@ -649,29 +649,27 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
   get commentsButton() {
     const post_view = this.props.post_view;
     return (
-      <button className="btn btn-link text-muted py-0 pl-0">
-        <Link
-          className="text-muted"
-          title={i18n.t("number_of_comments", {
+      <Link
+        className="btn btn-link text-muted py-0 pl-0 text-muted"
+        title={i18n.t("number_of_comments", {
+          count: Number(post_view.counts.comments),
+          formattedCount: Number(post_view.counts.comments),
+        })}
+        to={`/post/${post_view.post.id}?scrollToComments=true`}
+      >
+        <Icon icon="message-square" classes="mr-1" inline />
+        <span className="mr-2">
+          {i18n.t("number_of_comments", {
             count: Number(post_view.counts.comments),
-            formattedCount: Number(post_view.counts.comments),
+            formattedCount: numToSI(post_view.counts.comments),
           })}
-          to={`/post/${post_view.post.id}?scrollToComments=true`}
-        >
-          <Icon icon="message-square" classes="mr-1" inline />
-          <span className="mr-2">
-            {i18n.t("number_of_comments", {
-              count: Number(post_view.counts.comments),
-              formattedCount: numToSI(post_view.counts.comments),
-            })}
+        </span>
+        {this.unreadCount && (
+          <span className="small text-warning">
+            ({this.unreadCount} {i18n.t("new")})
           </span>
-          {this.unreadCount && (
-            <span className="small text-warning">
-              ({this.unreadCount} {i18n.t("new")})
-            </span>
-          )}
-        </Link>
-      </button>
+        )}
+      </Link>
     );
   }