image scaling and styling

This commit is contained in:
Christoph J. Scherr 2023-10-02 11:16:23 +02:00
parent e8c332fce4
commit d287b3291d
2 changed files with 29 additions and 31 deletions

View File

@ -23,6 +23,12 @@
<div class="jumbotron my-5">
<div class="row">
<div class="col">
<picture>
<img src="{{ post.thumbnail.url }}" alt="thumbnail" class="img-fluid">
</picture>
</div>
<div class="col">
<div class="row py-5">
{% if LANGUAGE_CODE == "de" %}
<h1 class="">
{{ post.title_de }}
@ -46,15 +52,7 @@
<br>
{% endif %}
</div>
</div>
<div class="row align-items-center text-center">
<div class="col">
<picture>
<img src="{{ post.thumbnail.url }}" alt="thumbnail" class="img-fluid">
</picture>
</div>
<div class="row px-3">
<div class="">
<div class="row py-5">
{% if LANGUAGE_CODE == "de" %}
<p class="lead">{{ post.desc_de }}</p>
{% elif LANGUAGE_CODE == "en" %}
@ -63,7 +61,7 @@
<p class="lead">{{ post.desc_en }}</p>
{% endif %}
</div>
<div class="">
<div class="row py-5">
<p>
<b>{{ post.category.name }}<b>
</p>

View File

@ -9,8 +9,8 @@
<a class="text-reset link-offset-2 link-underline link-underline-opacity-0"
href=" {% url 'blog:post' post.category.slug post.slug %}">
<img src="{{ post.thumbnail.url }}"
class="card-img-top img-fluid"
style="max-height: 150px"
class="card-img-top img-fluid mx-auto d-block"
style="max-height: 150px; width: auto; padding-top: 8px;"
alt="thumbnail" />
<div class="card-body" style="height: 100px">
{% if LANGUAGE_CODE == "de" %}