From f0eda1510880f79f23fcc6c6c45702b0dafc2cb7 Mon Sep 17 00:00:00 2001 From: Jeremy Kersten Date: Fri, 16 Oct 2020 15:45:01 +0000 Subject: [PATCH] [FIX] web_editor: fix width of SVG images in media dialog This solves an issue with svg images from Isometric for example. The media dialog assigns width to its displayed images thanks to the flex-basis and flex-grow properties of their container, based on the aspect ratio of each image. This was done correctly for SVG images too. However, after assigning a nice space for a specific SVG image, the image itself was not made to fill that assigned space... it only worked if the natural width of the image was higher than the assigned space. This was of course more obvious with SVG files with no intrinsic width as they would simply not appear. closes odoo/odoo#60305 X-original-commit: 585aed8b49b98d014db1e06c11e42b0d38a0b8c6 Signed-off-by: Quentin Smetz (qsm) Co-authored-by: qsm-odoo --- addons/web_editor/static/src/scss/wysiwyg.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/web_editor/static/src/scss/wysiwyg.scss b/addons/web_editor/static/src/scss/wysiwyg.scss index 8bb78a8fefd..ba92fde2409 100644 --- a/addons/web_editor/static/src/scss/wysiwyg.scss +++ b/addons/web_editor/static/src/scss/wysiwyg.scss @@ -224,7 +224,7 @@ body .modal { @extend %o-preview-alpha-background; &, > img { - max-width: 100%; + width: 100%; } }