Skip to content

Commit b260315

Browse files
committed
Style past-events with no photo to take up full width of slider
* When there's no photo, add no-photo class to past-event article * Style past-event details to take up full width when there is no photo
1 parent 168e19a commit b260315

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

pythonkc_site/static/screen.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,9 @@ h3{
125125
width: 400px;
126126
float: left;
127127
}
128+
.past-event.no-photo .details {
129+
width: 910px;
130+
}
128131
.past-event .event-photo {
129132
float: left;
130133
width: 500px;

pythonkc_site/templates/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ <h1>Past Events</h1>
5353
</div>
5454
<div id="evt-wrapper">
5555
{% for event in past_events %}
56-
<article class="past-event">
56+
<article class="past-event{% if not event.photos.0.url %} no-photo{% endif %}">
5757
<div class="details">
5858
<header>
5959
<h1><time datetime>{{ event.time|date:"F j, Y" }}</time></h1>

0 commit comments

Comments
 (0)