Improve media placeholders, avatar caching, and jumbo emoji layout.

Reserve image/video box size from info.w/h, fade in over blurhash blobs, cache dimensions/blurhashes and authenticated media blobs so avatars don't refetch every remount, and throttle TitleBar/DM reorder during sync catchup.
This commit is contained in:
2026-07-22 14:35:07 +10:00
parent 5c0c5e3758
commit 821724b594
22 changed files with 828 additions and 278 deletions

View File

@@ -59,10 +59,14 @@ export const getImageMsgContent = async (
[MATRIX_SPOILER_PROPERTY_NAME]: metadata.markedAsSpoiler,
};
if (imgEl) {
const blurHash = encodeBlurHash(imgEl, 512, scaleYDimension(imgEl.width, 512, imgEl.height));
const naturalW = imgEl.naturalWidth || imgEl.width;
const naturalH = imgEl.naturalHeight || imgEl.height;
const blurHash = encodeBlurHash(imgEl, 512, scaleYDimension(naturalW, 512, naturalH));
content.info = {
...getImageInfo(imgEl, file),
w: naturalW,
h: naturalH,
[MATRIX_BLUR_HASH_PROPERTY_NAME]: blurHash,
};
}