From 84887b6feb93e13e5a0b87e0db5af917f6c73884 Mon Sep 17 00:00:00 2001 From: Jay Sitter Date: Sat, 17 Jun 2023 12:32:12 -0400 Subject: [PATCH 1/3] fix: Only post title should be inside h5, not the additional metadata icons --- src/shared/components/post/post-listing.tsx | 148 +++++++++----------- 1 file changed, 70 insertions(+), 78 deletions(-) diff --git a/src/shared/components/post/post-listing.tsx b/src/shared/components/post/post-listing.tsx index b9d41250..40b8ff27 100644 --- a/src/shared/components/post/post-listing.tsx +++ b/src/shared/components/post/post-listing.tsx @@ -519,88 +519,80 @@ export class PostListing extends Component { return (
-
- {url ? ( - this.props.showBody ? ( - -
- - ) : ( - this.postLink - ) +
+ {url && this.props.showBody ? ( + ) : ( this.postLink )} - {(url && isImage(url)) || - (post.thumbnail_url && ( - - ))} - {post.removed && ( - - {i18n.t("removed")} - - )} - {post.deleted && ( - - - - )} - {post.locked && ( - - - - )} - {post.featured_community && ( - - - - )} - {post.featured_local && ( - - - - )} - {post.nsfw && ( - - {i18n.t("nsfw")} - - )}
+ {(url && isImage(url)) || + (post.thumbnail_url && ( + + ))} + {post.removed && ( + + {i18n.t("removed")} + + )} + {post.deleted && ( + + + + )} + {post.locked && ( + + + + )} + {post.featured_community && ( + + + + )} + {post.featured_local && ( + + + + )} + {post.nsfw && ( + + {i18n.t("nsfw")} + + )}
); } From cd0a5a60c671626c1415ef45e51c79ed64ed7390 Mon Sep 17 00:00:00 2001 From: Jay Sitter Date: Sun, 18 Jun 2023 00:41:47 -0400 Subject: [PATCH 2/3] fix: Fix display inline of post title --- src/shared/components/post/post-listing.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/shared/components/post/post-listing.tsx b/src/shared/components/post/post-listing.tsx index 40b8ff27..942c7651 100644 --- a/src/shared/components/post/post-listing.tsx +++ b/src/shared/components/post/post-listing.tsx @@ -497,7 +497,7 @@ export class PostListing extends Component { const post = this.postView.post; return ( { to={`/post/${post.id}`} title={i18n.t("comments")} > -
From 3f800104340ca4b6f9eb55b373f3fc2942c97bad Mon Sep 17 00:00:00 2001 From: sunaurus Date: Sun, 18 Jun 2023 14:02:49 +0300 Subject: [PATCH 3/3] Always allow users to control whether they see NSFW content --- src/shared/components/home/signup.tsx | 33 ++++++++++------------- src/shared/components/person/settings.tsx | 29 +++++++++----------- 2 files changed, 27 insertions(+), 35 deletions(-) diff --git a/src/shared/components/home/signup.tsx b/src/shared/components/home/signup.tsx index 16a3cc6d..71398a8d 100644 --- a/src/shared/components/home/signup.tsx +++ b/src/shared/components/home/signup.tsx @@ -298,27 +298,22 @@ export class Signup extends Component { )} {this.renderCaptcha()} - {siteView.local_site.enable_nsfw && ( -
-
-
- - -
+
+
+
+ +
- )} +
{ />
- {enableNsfw(this.state.siteRes) && ( -
-
- - -
+
+
+ +
- )} +