Skip to content

Commit 5997d6e

Browse files
committed
Update events layout
- Add `cover_image_caption` (which uses figcaption under the hood) - Change event details from a list to a table (more semantic and looks better)
1 parent b4552b6 commit 5997d6e

File tree

3 files changed

+76
-21
lines changed

3 files changed

+76
-21
lines changed

_includes/events/events-list.html

Lines changed: 31 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -72,26 +72,43 @@
7272
<h3>{{ event.name }}</h3>
7373

7474
{% unless event.cover_image == empty %}
75-
<img src="{{ event.cover_image }}" alt="{{ event.name }} event banner">
75+
<figure>
76+
<img src="{{ event.cover_image }}" alt="{{ event.name }} event banner">
77+
<figcaption>
78+
{{ event.cover_image_caption }}
79+
</figcaption>
80+
</figure>
7681
{% endunless %}
7782

7883
{{ event.content }}
7984

8085
<h4>Event details</h4>
8186

82-
<ul class="event-details">
83-
<li><strong>Date:</strong> {{ event.dates }}</li>
84-
<li><strong>Location:</strong> {{ event.location | markdownify }}{% unless event.location_map == empty %} (<a href="{{ event.location_map }}">Show on map</a>){% endunless %}</li>
85-
{% if event.entrance_fee %}
86-
<li><strong>Entrance fee:</strong> {{ event.entrance_fee | markdownify }}</li>
87-
{% endif %}
88-
{% if event.registration %}
89-
<li><strong>Registration:</strong> {{ event.registration | markdownify }}</li>
90-
{% endif %}
91-
{% if event.website %}
92-
<li><strong>Website:</strong> <a href="{{ event.website }}">{{ event.website }}</a></li>
93-
{% endif %}
94-
</ul>
87+
<table class="event-details">
88+
<tbody>
89+
<tr>
90+
<th>Date:</th><td>{{ event.dates }}</td>
91+
</tr>
92+
<tr>
93+
<th>Location:</th><td>{{ event.location | markdownify }}{% unless event.location_map == empty %} (<a href="{{ event.location_map }}">Show on map</a>){% endunless %}</td>
94+
</tr>
95+
{% if event.entrance_fee %}
96+
<tr>
97+
<th>Entrance fee:</th><td>{{ event.entrance_fee | markdownify }}</td>
98+
</tr>
99+
{% endif %}
100+
{% if event.registration %}
101+
<tr>
102+
<th>Registration:</th><td>{{ event.registration | markdownify }}</td>
103+
</tr>
104+
{% endif %}
105+
{% if event.website %}
106+
<tr>
107+
<th>Website:</th><td><a href="{{ event.website }}">{{ event.website }}</a></td>
108+
</tr>
109+
{% endif %}
110+
</tbody>
111+
</table>
95112
</div>
96113

97114
{% endcapture %}

assets/css/events.css

Lines changed: 44 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,11 @@
6363
max-width: 640px;
6464
}
6565

66+
.events .events-fulllist .card figure img {
67+
margin-bottom: 0;
68+
max-width: none;
69+
}
70+
6671
.events .events-fulllist .events-empty {
6772
background-color: var(--background-color);
6873
border: none;
@@ -72,10 +77,24 @@
7277
box-shadow: none;
7378
}
7479

75-
.event-details > li p {
80+
.event-details {
81+
border-spacing: 0.25em;
82+
}
83+
84+
.event-details p {
7685
display: inline;
77-
margin-left: 0.3em;
78-
margin-right: 0.3em;
86+
}
87+
88+
.event-details p::after {
89+
content: " ";
90+
}
91+
92+
.event-details p:last-child::after {
93+
content: "";
94+
}
95+
96+
.event-details tr th {
97+
text-align: left;
7998
}
8099

81100
@media screen and (max-width: 900px) {
@@ -93,3 +112,25 @@
93112
padding-left: 2rem;
94113
}
95114
}
115+
116+
figure {
117+
margin: 0;
118+
border-radius: 4px;
119+
background-color: var(--base-color);
120+
margin-inline-start: auto;
121+
}
122+
123+
figure figcaption {
124+
padding: 1em;
125+
opacity: 0.8;
126+
font-size: 80%;
127+
font-style: italic;
128+
}
129+
130+
figure figcaption:empty {
131+
display: none;
132+
}
133+
134+
figure img {
135+
display: block;
136+
}

collections/_event/gamescom-2025.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,8 @@ registration: "[https://lu.ma/tpd4ks9a](https://lu.ma/tpd4ks9a) (register to rec
2020
entrance_fee: "Free, but a gamescom ticket is needed to access the venue"
2121

2222
cover_image: "/storage/blog/gamescom-cologne-2025/gamescom-cover.webp"
23-
23+
cover_image_caption: "Cover image: 2024 Koelnmesse GmbH/Marvin Ruppert"
2424
---
25-
26-
<p style="opacity: 0.7; font-style: italic;">Cover image: 2024 Koelnmesse GmbH/Marvin Ruppert</p>
27-
2825
A small community meetup at gamescom to connect, share experiences, and discuss all things Godot. We do not have a booth, so we will meet somewhere near the IndieArenaBooth in hall 10. Details will be announced on the luma [event page](https://lu.ma/tpd4ks9a) once we know the exact place.
2926

3027
​​Whether you’re a seasoned developer or just exploring the engine, everyone is welcome!

0 commit comments

Comments
 (0)