fix(web): add aspect-ratio fallback for bare GIF URL messages

This commit is contained in:
Jannis Braun
2026-03-25 01:56:08 +01:00
parent 234ee9cd23
commit 995c71367e
+5 -2
View File
@@ -340,11 +340,14 @@ export function Message({ message, isCompact, isFirstInGroup, previousMessageId
) : ( ) : (
<div className="flex flex-col gap-1"> <div className="flex flex-col gap-1">
{isGifOnly ? ( {isGifOnly ? (
<div className="mt-1 max-w-[250px] rounded-lg overflow-hidden"> <div
className="mt-1 max-w-[250px] rounded-lg overflow-hidden bg-surface-input"
style={{ aspectRatio: '4/3', maxHeight: 250 }}
>
<img <img
src={message.content!.trim()} src={message.content!.trim()}
alt="GIF" alt="GIF"
className="max-w-full max-h-[250px] object-contain rounded-lg" className="w-full h-full object-contain rounded-lg"
loading="lazy" loading="lazy"
/> />
</div> </div>