Skip check aspect ratio if > 1 media

pull/904/head
Lim Chee Aun 2024-10-25 23:06:20 +08:00
rodzic 25b98d477f
commit e19dcf7558
2 zmienionych plików z 3 dodań i 1 usunięć

Wyświetl plik

@ -74,6 +74,7 @@ function Media({
showCaption,
allowLongerCaption,
altIndex,
checkAspectRatio = true,
onClick = () => {},
}) {
let {
@ -354,7 +355,7 @@ function Media({
}
// Check natural aspect ratio vs display aspect ratio
if ($media) {
if (checkAspectRatio && $media) {
const {
clientWidth,
clientHeight,

Wyświetl plik

@ -2220,6 +2220,7 @@ function Status({
}
: undefined
}
checkAspectRatio={mediaAttachments.length === 1}
/>
))}
</div>