Closed hems closed 3 years ago
I just fixed the problem with the image scaling by swapping 100% 100%
by contain
on the image.
One thing i noticed is that the JPG is 2500x1562 but the container has max-width: 1200px
so we need to re-export that image with 1200px width as it will be the max size of the image.
Same applies to farmplants.jpg
which currently is 3262x1875, it should be resized to 1200px width while keeping the aspect ratio.
just keep the aspect ratio and resize the images to 2400px width, apply compression as needed
farm.jpg resized to 2400w and file size from 475KB to 295KB farmplants.jpg resized to 2400w and file size from 1.2MB to 423KB
I believe it should have fixed size and aspect ratio otherwise it will get distorted based on the user viewport.
Here are two examples of the image getting distorted depending on the browser size: