Web Page: Fix document with photo layout (#5089)
This commit is contained in:
parent
f3668b50ee
commit
6049090857
@ -136,7 +136,7 @@ const WebPage: FC<OwnProps> = ({
|
||||
const truncatedDescription = trimText(description, MAX_TEXT_LENGTH);
|
||||
const isArticle = Boolean(truncatedDescription || title || siteName);
|
||||
let isSquarePhoto = Boolean(stickers);
|
||||
if (isArticle && webPage?.photo && !webPage.video) {
|
||||
if (isArticle && webPage?.photo && !webPage.video && !webPage.document) {
|
||||
const { width, height } = calculateMediaDimensions({
|
||||
media: webPage.photo,
|
||||
isOwn: message.isOutgoing,
|
||||
@ -193,7 +193,7 @@ const WebPage: FC<OwnProps> = ({
|
||||
{isStory && (
|
||||
<BaseStory story={story} isProtected={isProtected} isConnected={isConnected} isPreview />
|
||||
)}
|
||||
{photo && !video && (
|
||||
{photo && !video && !document && (
|
||||
<Photo
|
||||
photo={photo}
|
||||
isOwn={message.isOutgoing}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user