Skip to content

Commit

Permalink
Update main.css
Browse files Browse the repository at this point in the history
Changed cover to contain for images
  • Loading branch information
brendanbabb authored Dec 3, 2024
1 parent 0dced04 commit 6b1c041
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions assets/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,6 @@ article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
display: block;}

.carousel .image img {
width: 100%; /* Ensures the image scales to the width of its container */
height: auto; /* Maintains the image's aspect ratio */
object-fit: contain; /* Ensures the image fits without cropping */
max-width: 100%; /* Prevents the image from exceeding container width */
max-height: 100%; /* Prevents the image from exceeding container height */
}



body {
Expand Down Expand Up @@ -4387,10 +4379,10 @@ input, select, textarea {
}

.carousel article .image img {
-moz-object-fit: cover;
-webkit-object-fit: cover;
-ms-object-fit: cover;
object-fit: cover;
-moz-object-fit: contain;
-webkit-object-fit: contain;
-ms-object-fit: contain;
object-fit: contain;
position: absolute;
top: 0;
left: 0;
Expand Down

0 comments on commit 6b1c041

Please sign in to comment.