diff --git a/public/images/1.jpg b/public/images/1.jpg new file mode 100644 index 0000000..1a1f3d2 Binary files /dev/null and b/public/images/1.jpg differ diff --git a/public/images/12.jpg b/public/images/12.jpg new file mode 100644 index 0000000..8251277 Binary files /dev/null and b/public/images/12.jpg differ diff --git a/public/images/123.jpg b/public/images/123.jpg new file mode 100644 index 0000000..72085b0 Binary files /dev/null and b/public/images/123.jpg differ diff --git a/public/images/1234.jpg b/public/images/1234.jpg new file mode 100644 index 0000000..3ba8969 Binary files /dev/null and b/public/images/1234.jpg differ diff --git a/src/components/About.astro b/src/components/About.astro index 11ea700..efc7885 100644 --- a/src/components/About.astro +++ b/src/components/About.astro @@ -4,10 +4,10 @@ const about = { title: "О НАС", paragraph1: "Наша компания занимается производством продукции из драгоценных металлов.", imageUrls: [ - "/images/hero.webp", - "/images/hero.webp", - "/images/hero.webp", - "/images/hero.webp" + "/images/1.jpg", + "/images/12.jpg", + "/images/123.jpg", + "/images/1234.jpg" ] }; --- @@ -56,11 +56,11 @@ const about = {
{ about.imageUrls.map((imageUrl, index) => ( -
+
{`О
@@ -75,8 +75,55 @@ const about = { line-height: 1.8; } - img { - max-width: 100%; - max-height: 100%; + /* Фиксированные размеры для изображений в сетке */ + .grid img { + aspect-ratio: 4/3; + object-fit: cover; + object-position: center; + width: 100%; + height: 100%; + } + + /* Дополнительные адаптивные стили для изображений */ + @media (max-width: 320px) { + .grid > div { + height: 7rem !important; + } + } + + @media (min-width: 321px) and (max-width: 479px) { + .grid > div { + height: 8rem !important; + } + } + + @media (min-width: 480px) and (max-width: 639px) { + .grid > div { + height: 9rem !important; + } + } + + @media (min-width: 640px) and (max-width: 767px) { + .grid > div { + height: 10rem !important; + } + } + + @media (min-width: 768px) and (max-width: 1023px) { + .grid > div { + height: 11rem !important; + } + } + + @media (min-width: 1024px) and (max-width: 1279px) { + .grid > div { + height: 12rem !important; + } + } + + @media (min-width: 1280px) { + .grid > div { + height: 13rem !important; + } }