diff --git a/desktop/src/shared/ui/rich-link-preview-attachment.tsx b/desktop/src/shared/ui/rich-link-preview-attachment.tsx index c9937c557..f2728cfa9 100644 --- a/desktop/src/shared/ui/rich-link-preview-attachment.tsx +++ b/desktop/src/shared/ui/rich-link-preview-attachment.tsx @@ -102,6 +102,27 @@ function LinkPreviewImage({ ); } +function LinkPreviewDescription({ + className, + description, +}: { + className?: string; + description: string; +}) { + return ( +
+ {description.split(/\n{2,}/).map((paragraph) => ( +

+ {paragraph} +

+ ))} +
+ ); +} + function TweetPreview({ className, onRemove, @@ -141,12 +162,10 @@ function TweetPreview({ {preview.title} {contentExpanded && preview.description ? ( -
- {preview.description} -
+ ) : null} {contentExpanded && reserveImage ? ( {preview.title} {contentExpanded && preview.description ? ( -
- {preview.description} -
+ ) : null} {contentExpanded && reserveImage ? ( - -
- {showImage ? ( - {`Preview - ) : ( -
- )} -
-
+ ) : null} {hasExpandableContent ? (