feat(UI): Always put post body behind togggle on post listings (home/community) #1595

This commit is contained in:
Jay Sitter 2023-06-25 16:21:58 -04:00
parent 973bab1313
commit a92dd541a7

View file

@ -1368,18 +1368,6 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
); );
} }
showBodyPreview() {
const { body, id } = this.postView.post;
return !this.showBody && body ? (
<Link className="text-body mt-2 d-block" to={`/post/${id}`}>
<div className="md-div mb-1 preview-lines">{body}</div>
</Link>
) : (
<></>
);
}
listing() { listing() {
return ( return (
<> <>
@ -1392,9 +1380,6 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
{/* If it has a thumbnail, do a right aligned thumbnail */} {/* If it has a thumbnail, do a right aligned thumbnail */}
{this.mobileThumbnail()} {this.mobileThumbnail()}
{/* Show a preview of the post body */}
{this.showBodyPreview()}
{this.commentsLine(true)} {this.commentsLine(true)}
{this.userActionsLine()} {this.userActionsLine()}
{this.duplicatesLine()} {this.duplicatesLine()}
@ -1424,7 +1409,6 @@ export class PostListing extends Component<PostListingProps, PostListingState> {
<div className="col-12"> <div className="col-12">
{this.postTitleLine()} {this.postTitleLine()}
{this.createdLine()} {this.createdLine()}
{this.showBodyPreview()}
{this.commentsLine()} {this.commentsLine()}
{this.duplicatesLine()} {this.duplicatesLine()}
{this.userActionsLine()} {this.userActionsLine()}