From 32f892f24c64c45705b20795a9e6088c25cbc591 Mon Sep 17 00:00:00 2001 From: Andrey Novikov Date: Mon, 16 May 2016 16:10:59 +0300 Subject: [PATCH] Fix width of article images that a smaller than content --- static/assets/css/main.css | 5 +++-- static/assets/sass/main.scss | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/static/assets/css/main.css b/static/assets/css/main.css index 597ea95..77f55be 100644 --- a/static/assets/css/main.css +++ b/static/assets/css/main.css @@ -1333,11 +1333,12 @@ article { content: ""; } article img { display: block; - width: 100%; } + max-width: 100%; } article img.featured { margin: 0 0 2em 0; max-height: 400px; - object-fit: cover; } + object-fit: cover; + width: 100%; } article img.left { float: left; margin: 0 2em 2em 0; } diff --git a/static/assets/sass/main.scss b/static/assets/sass/main.scss index 5054858..728c52a 100644 --- a/static/assets/sass/main.scss +++ b/static/assets/sass/main.scss @@ -228,12 +228,13 @@ img { display: block; - width: 100%; + max-width: 100%; &.featured { margin: 0 0 2em 0; max-height: 400px; object-fit: cover; + width: 100%; } &.left {