Aspect ratio conflict Chrome vs Edge

Hello, I have an issue with the aspect ratio CSS property. The images look okay in Chrome and Firefox, but in Microsoft Edge ( screenshots attached ), they look terrible and zoomed. Is there any solution to solve this, or any other alternative CSS that can achieve the same result in both browsers? I'm using an aspect ratio of 3.8 in the parent div, which has a display grid to achieve the masonry display of the images Here is my full css/html codepen example : https://codepen.io/captainAkuma/pen/ZEZRXBM
No description
No description
8 Replies
ἔρως
ἔρως7mo ago
🤔
No description
ἔρως
ἔρως7mo ago
how's it rendering with 12+k pixels of width? 🤔
No description
clevermissfox
clevermissfox7mo ago
Do you have an object-fit: cover; max-inline-size:100%; declared on the images?
ἔρως
ἔρως7mo ago
he doesn't have the max-size
SvenSplynter
SvenSplynter7mo ago
You have both your width and height to 100%. Set your width to 100% and the height to auto.
SvenSplynter
SvenSplynter7mo ago
No description
Soufiane IB
Soufiane IB7mo ago
Hi Sven, Thanks for your reply. Yes, setting the height to auto fixed the image height, but the ratio still isn't okay; there is a huge white space under the images
SvenSplynter
SvenSplynter7mo ago
Hi Soufiane, I'm sorry but it's not very clear to me what you are trying to do. The spacing has to do with the way your grid is set up. You have the same height for all rows with your grid-auto-rows calculation. Could you show an example of what you're trying to achieve, with your approach explained?
Want results from more Discord servers?
Add your server