First run at adding thumbnailing to images

This commit is contained in:
2023-03-28 14:22:38 -04:00
parent 84070d2806
commit c00343abfe
10 changed files with 84 additions and 41 deletions

View File

@ -2,6 +2,7 @@
{% load mathfilters %}
{% load static %}
{% load naturalduration %}
{% load thumbnail %}
{% block title %}{{object.title}}{% endblock %}
@ -10,9 +11,11 @@
<div class="row">
{% if object.cover%}
<p style="float:left; width:402px; padding:0; border: 1px solid #ccc">
<img src="{{object.cover.url}}" width=400 />
{% thumbnail object.cover "400" as im %}
<p style="float:left; width:{{im.width}}px; padding:0; border: 1px solid #ccc">
<img src="{{im.url}}" width={{im.width}} height={{im.height}}/>
</p>
{% endthumbnail %}
{% endif %}
<div style="float:left; width:600px; margin-left:10px; ">
{% if object.summary %}