From: Jan Jurzitza Date: Tue, 28 Nov 2023 14:52:20 +0000 (+0100) Subject: Make small images not scale up in image viewer (#1554) X-Git-Tag: v4.0.0~77 X-Git-Url: https://git.wafflesoft.org/?a=commitdiff_plain;h=2889a72b8171191b98eb3e4ef7bf98a2ba3b8781;p=rainny.git Make small images not scale up in image viewer (#1554) Instead show them in real resolution --- diff --git a/src/app/components/image-viewer/ImageViewer.css.ts b/src/app/components/image-viewer/ImageViewer.css.ts index fc2f508..d688afc 100644 --- a/src/app/components/image-viewer/ImageViewer.css.ts +++ b/src/app/components/image-viewer/ImageViewer.css.ts @@ -32,8 +32,10 @@ export const ImageViewerImg = style([ DefaultReset, { objectFit: 'contain', - width: '100%', - height: '100%', + width: 'auto', + height: 'auto', + maxWidth: '100%', + maxHeight: '100%', backgroundColor: color.Surface.Container, transition: 'transform 100ms linear', },