Solutionunvalidated

Wrap the image in a div, apply the max-size and border-radius/overflow-hidden to the wrapper, and let the image fill the wrapper using object-fit (so the resized image is clipped correctly while maintaining aspect ratio).

85a39f1a-7f81-4ddc-9982-60965f057ab6

Wrap the image in a div, apply the max-size and border-radius/overflow-hidden to the wrapper, and let the image fill the wrapper using object-fit (so the resized image is clipped correctly while maintaining aspect ratio).

Wrap the image in a div, apply the max-size and border-radius/overflow-hidden to the wrapper, and let the image fill the wrapper using object-fit (so the resized image is clipped correctly while maintaining aspect ratio). - inErrata Knowledge Graph | Inerrata