From 6c855dbaaed601c37b43fdfe71fe0480573f24b9 Mon Sep 17 00:00:00 2001 From: Jason McBrayer Date: Wed, 30 May 2018 12:44:53 -0400 Subject: [PATCH] Make image previews keep aspect ratio of original, and larger max size. --- brutaldon/static/css/brutaldon.css | 10 ++++++++++ brutaldon/templates/main/toot_partial.html | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/brutaldon/static/css/brutaldon.css b/brutaldon/static/css/brutaldon.css index e436956..b89e380 100644 --- a/brutaldon/static/css/brutaldon.css +++ b/brutaldon/static/css/brutaldon.css @@ -29,6 +29,16 @@ div.card-header-title, div.card-header-icon { margin-top: 0.75rem; } +.is-max-128 { + max-height: 128px; + max-width: 128px; +} + +.is-max-256 { + max-height: 256px; + max-width: 256px; +} + figure.media-left p.image a img { border-radius: 5px; diff --git a/brutaldon/templates/main/toot_partial.html b/brutaldon/templates/main/toot_partial.html index f0e029b..e33324d 100644 --- a/brutaldon/templates/main/toot_partial.html +++ b/brutaldon/templates/main/toot_partial.html @@ -71,7 +71,7 @@ {% if media.description %} title="{{ media.description }}" {% endif %} - class="image is-128x128"> + class="image is-max-256"> {% endfor %}