From d60b7527b087da74fa0af2c7559059f91dec953d Mon Sep 17 00:00:00 2001 From: nzambello Date: Tue, 11 Jun 2024 10:54:27 +0300 Subject: [PATCH] refactor: media items grid smaller size --- src/components/MediaWidget/LinkItemWidget.css | 4 ++-- src/components/MediaWidget/MediaItemWidget.css | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/components/MediaWidget/LinkItemWidget.css b/src/components/MediaWidget/LinkItemWidget.css index 22f10528..41216600 100644 --- a/src/components/MediaWidget/LinkItemWidget.css +++ b/src/components/MediaWidget/LinkItemWidget.css @@ -3,7 +3,7 @@ padding: 1rem; grid-auto-flow: dense; grid-gap: 1rem; - grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); + grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); } .memori-link-item--card { @@ -33,4 +33,4 @@ a.memori-link-item--link { .memori-link-item--icon { width: 50%; height: 50%; -} +} \ No newline at end of file diff --git a/src/components/MediaWidget/MediaItemWidget.css b/src/components/MediaWidget/MediaItemWidget.css index 0f8b145c..8fbf541c 100644 --- a/src/components/MediaWidget/MediaItemWidget.css +++ b/src/components/MediaWidget/MediaItemWidget.css @@ -3,7 +3,7 @@ padding: 1rem; grid-auto-flow: dense; grid-gap: 1rem; - grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); + grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); } .memori-media-item--card { @@ -32,7 +32,7 @@ display: flex; width: 100%; height: 100%; - max-height: 300px; + max-height: 150px; flex-direction: column; align-items: center; justify-content: center; @@ -41,13 +41,13 @@ .memori-media-item--figure img { min-width: 100%; min-height: 100%; - object-fit: contain; + object-fit: cover; object-position: center; } .memori-media-item--figure-caption { - padding: 0.5rem 1rem; - margin: 0.5rem 0; + padding: 0.25rem 1rem; + margin: 0.25rem 0; color: #666; font-size: 0.875rem; font-style: italic; @@ -131,4 +131,4 @@ a.memori-media-item--link { .memori-media-item--modal .memori-modal--close button { border-color: #fff; color: #fff; -} +} \ No newline at end of file