Skip to content

Commit 09a898e

Browse files
authored
fix: Improve the layout of the photo pages (ietf-tools#3807)
1 parent f98cb8a commit 09a898e

4 files changed

Lines changed: 16 additions & 9 deletions

File tree

ietf/static/css/ietf.scss

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ table tbody.meta {
151151

152152
// Style the photo cards
153153
.photo {
154-
width: 13em;
154+
width: 12em;
155155

156156
.card-img-top {
157157
object-fit: cover;
@@ -160,7 +160,11 @@ table tbody.meta {
160160

161161
.photo-placeholder {
162162
height: 15em;
163-
font-size: 12em;
163+
164+
.bi {
165+
font-size: 10em;
166+
color: $gray-300;
167+
}
164168
}
165169
}
166170

ietf/templates/group/all_photos.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@ <h1>{{ group_type | upper }} {{ role }} photos</h1>
1010
{% for letter in alphabet_blocks %}
1111
<h2 class="mt-4" id="{{ letter.grouper }}">{{ letter.grouper }}</h2>
1212
{% regroup letter.list by person as person_groups %}
13-
<div class="mt-0 row row-cols-1 row-cols-sm-2 row-cols-md-2 row-cols-lg-2 row-cols-xl-3 row-cols-xxl-3 g-3">
13+
{# keep in sync with group_photos.html #}
14+
<div class="mt-0 row row-cols-2 row-cols-sm-2 row-cols-md-3 row-cols-lg-4 row-cols-xl-4 row-cols-xxl-5 g-2">
1415
{% for person_with_groups in person_groups %}
1516
<div class="col">{% include "person/photo.html" with person=person_with_groups.grouper groups=person_with_groups.list%}</div>
1617
{% endfor %}
1718
</div>
1819
{% endfor %}
19-
{% endblock %}
20+
{% endblock %}

ietf/templates/group/group_photos.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ <h2 class="my-3">{{ group }} ({{ group.acronym }}) photos</h2>
1111
<div class="row" id="{{ role_name.grouper|urlencode }}">
1212
<h3 class="mt-4">{{ role_name.grouper }}{{ role_name.list|pluralize }}</h3>
1313
{% regroup role_name.list by person as person_groups %}
14-
<div class="mt-0 row row-cols-1 row-cols-sm-2 row-cols-md-2 row-cols-lg-2 row-cols-xl-3 row-cols-xxl-3 g-3">
14+
{# keep in sync with all_photos.html #}
15+
<div class="mt-0 row row-cols-2 row-cols-sm-2 row-cols-md-3 row-cols-lg-4 row-cols-xl-4 row-cols-xxl-5 g-2">
1516
{% for person_with_groups in person_groups %}
1617
<div class="col">
1718
{% include "person/photo.html" with person=person_with_groups.grouper groups=person_with_groups.list %}
@@ -20,4 +21,4 @@ <h3 class="mt-4">{{ role_name.grouper }}{{ role_name.list|pluralize }}</h3>
2021
</div>
2122
</div>
2223
{% endfor %}
23-
{% endblock %}
24+
{% endblock %}

ietf/templates/person/photo.html

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,20 @@
1111
alt="Photo of {{ person.name }}">
1212
{% else %}
1313
<div class="photo-placeholder">
14-
<i class="bi bi-person text-muted"></i>
14+
<i class="bi bi-person"></i>
1515
</div>
1616
{% endif %}
1717
{% if name or email %}</a>{% endif %}
1818
<div class="card-body">
19-
<p class="lead mb-1">
19+
<p class="mb-1">
2020
{% person_link person with_email=False %}
2121
</p>
2222
{% for role in groups %}
2323
<a title="{{ role.group.name }} {{ role.group.type | upper }}"
24+
class="small"
2425
href="{% url 'ietf.group.views.group_home' acronym=role.group.acronym %}">
2526
{{ role.group.acronym }}
2627
</a>
2728
{% endfor %}
2829
</div>
29-
</div>
30+
</div>

0 commit comments

Comments
 (0)