From ee84634a73e2904f39bc7bb1b46fc102778ca156 Mon Sep 17 00:00:00 2001 From: Jay Sitter Date: Mon, 26 Jun 2023 21:05:50 -0400 Subject: [PATCH 1/2] fix: Fix alignment of preview mini-overlay buttons on thumbs --- src/shared/components/post/post-listing.tsx | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/src/shared/components/post/post-listing.tsx b/src/shared/components/post/post-listing.tsx index f80cb970..3d373ee0 100644 --- a/src/shared/components/post/post-listing.tsx +++ b/src/shared/components/post/post-listing.tsx @@ -49,7 +49,7 @@ import { PurgeType, VoteContentType, } from "../../interfaces"; -import { mdNoImages, mdToHtml, mdToHtmlInline } from "../../markdown"; +import { mdToHtml, mdToHtmlInline } from "../../markdown"; import { I18NextService, UserService } from "../../services"; import { setupTippy } from "../../tippy"; import { Icon, PurgeWarning, Spinner } from "../common/icon"; @@ -328,16 +328,19 @@ export class PostListing extends Component { if (!this.props.hideImage && url && isImage(url) && this.imageSrc) { return ( - {this.imgThumb(this.imageSrc)} - - + + ); } else if (!this.props.hideImage && url && thumbnail && this.imageSrc) { return ( @@ -348,7 +351,10 @@ export class PostListing extends Component { title={url} > {this.imgThumb(this.imageSrc)} - + ); } else if (url) { From 3439512a1cd1eba7db5a8b9e7e718d3b3b414869 Mon Sep 17 00:00:00 2001 From: Jay Sitter Date: Mon, 26 Jun 2023 21:12:43 -0400 Subject: [PATCH 2/2] fix: Restore mdNoImages import --- src/shared/components/post/post-listing.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/components/post/post-listing.tsx b/src/shared/components/post/post-listing.tsx index 3d373ee0..f1d0dcab 100644 --- a/src/shared/components/post/post-listing.tsx +++ b/src/shared/components/post/post-listing.tsx @@ -49,7 +49,7 @@ import { PurgeType, VoteContentType, } from "../../interfaces"; -import { mdToHtml, mdToHtmlInline } from "../../markdown"; +import { mdNoImages, mdToHtml, mdToHtmlInline } from "../../markdown"; import { I18NextService, UserService } from "../../services"; import { setupTippy } from "../../tippy"; import { Icon, PurgeWarning, Spinner } from "../common/icon";