From a7e2d1706327e29cf5454ebff34b3560084cd3f7 Mon Sep 17 00:00:00 2001 From: Edward Betts Date: Sun, 24 Sep 2023 08:51:34 +0100 Subject: [PATCH] Show photos next to speaker name. --- templates/top_speakers.html | 32 ++++++++++++++++++++++++++++---- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/templates/top_speakers.html b/templates/top_speakers.html index ff3b533..b8ed59d 100644 --- a/templates/top_speakers.html +++ b/templates/top_speakers.html @@ -26,10 +26,30 @@ .container { position: relative; } + + + .person { + display: flex; + align-items: top; + margin-bottom: 10px; + } + + .info { + flex: 1; /* Allow text to take remaining space */ + padding-right: 10px; /* Add spacing between text and image */ + } + + img.photo { + max-width: 120px; /* Set max width for images */ + height: auto; /* Maintain image aspect ratio */ + } + + + {% endblock %} -{% set show_images = True %} +{% set show_images = False %} {% block title %}Conference archive{% endblock %} @@ -88,16 +108,20 @@ {% if loop.first or loop.previtem[1] != count %}

{{ count }} conferences

{% endif %} -
- +
+ {% set photo = person.photo_filename() %} + 👤 - {{ person.name }} + {{ person.name }}
({{ count }} conferences, {{ person.event_count }} talks) {% if person.photo_filename() %}📷{% endif %} {% if person.wikidata_qid %} Wikidata {% endif %}
+ {% if photo %} + {{ person.name }} + {% endif %}
{% endfor %}