Prevent skewing of resized images in editor (#2488)

* Unset inline size when shrinking images

to prevent skewing (https://forums.ankiweb.net/t/is-there-a-way-to-prevent-the-squish-skew-of-the-image-in-the-browser-editor/29925)

* Unset inline width/height for all images when shrinking is enabled
This commit is contained in:
Matthias Metelka 2023-05-05 11:16:06 +02:00 committed by GitHub
parent a5bf6126bb
commit dc4a915de1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -33,6 +33,9 @@ img:not(.mathjax) {
:host-context(.shrink-image) & {
max-width: var(--editor-default-max-width);
max-height: var(--editor-default-max-height);
// prevent inline width/height from skewing aspect ratio
width: unset;
height: unset;
}
}