1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-07-30 02:21:17 +03:00

Fix crash when drawing blurHash for portrait videos PSB-139 (#8855)

This commit is contained in:
Andy Balaam
2022-06-17 12:03:29 +01:00
committed by GitHub
parent 8cceda66ee
commit 0a90674e89
4 changed files with 93 additions and 1 deletions

View File

@ -38,5 +38,9 @@ describe("ImageSize", () => {
const size = suggestedSize(ImageSize.Normal, { w: 642, h: 350 }); // does not divide evenly
expect(size).toStrictEqual({ w: 324, h: 176 });
});
it("returns integer values for portrait images", () => {
const size = suggestedSize(ImageSize.Normal, { w: 720, h: 1280 });
expect(size).toStrictEqual({ w: 182, h: 324 });
});
});
});