From a79d0613ec7fce36ddf1f3121533404542239171 Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Tue, 11 Jun 2024 14:53:12 +0800 Subject: [PATCH] One more experimental magic --- src/components/status.css | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/components/status.css b/src/components/status.css index 1b43933e..5e0be6ac 100644 --- a/src/components/status.css +++ b/src/components/status.css @@ -1025,6 +1025,10 @@ background-color: var(--average-color, var(--bg-faded-color)); background-clip: padding-box; } + + &[data-has-small-dimension] img { + object-fit: scale-down; + } } .status .media-container:not(.media-eq1) .media { aspect-ratio: auto !important; @@ -1074,11 +1078,6 @@ &[data-has-natural-aspect-ratio] { --media-radius: 4px; } - - &[data-has-small-dimension] img { - object-fit: contain; - image-rendering: pixelated; - } } .status .media-container.media-eq1 .media[data-orientation='portrait'] { /* width: auto; @@ -1365,7 +1364,7 @@ body:has(#modal-container .carousel) .status .media img:hover { flex-wrap: wrap; .media[data-has-small-dimension] { - width: auto !important; + width: var(--width, auto) !important; } figure {