This repository has been archived on 2025-01-19. You can view files and clone it, but cannot push or open issues or pull requests.
oliverdavies.uk-old-sculpin/source/_includes/talks-table.html.twig

83 lines
3.2 KiB
Twig

<div class="overflow-auto">
<table class="w-100 ba b--black-20">
<thead>
<tr class="striped--near-white">
<th class="w-20-l pa2 tl bg-white">Date</th>
{% if not talk_page %}
<th class="w-40-l pa2 tl bg-white">Talk</th>
{% endif %}
<th class="pa2 tl bg-white">Event</th>
{% if not upcoming %}
<th class="w4 pa2 tl bg-white">Feedback</th>
{% endif %}
</tr>
</thead>
<tbody>
{% set today = 'today'|date('Y-m-d') %}
{% for row in events %}
<tr class="striped--near-white">
<td class="pa2">
{{ row.date.date|date(row.date.fuzzy_date ? 'F Y' : 'j F Y') }}
{% if row.date.time is defined %}
<small class="db black-70">
{{ row.date.time }}
</small>
{% endif %}
</td>
{% if not talk_page %}
<td class="pa2">
{% if row.date.talk_title is not defined %}
{% for talk in data.talks if talk.talk_id == row.date.talk_id %}
<a href="{{ talk.url }}">
{{ talk.title }}
</a>
{% endfor %}
{% else %}
{{ row.date.talk_title }}
{% endif %}
<small class="db black-70">
{{ row.date.type|default('Talk') }}
</small>
</td>
{% endif %}
<td class="pa2">
{% if row.event.website is not empty %}
<a href="{{ row.event.website }}">
{{ row.event.name }}
</a>
{% else %}
{{ row.event.name }}
{% endif %}
{% if row.event.location is defined %}
<small class="db black-70">
{{ row.event.location }}
</small>
{% endif %}
</td>
{% if not upcoming %}
<td class="ph2">
{% if row.date.feedback and row.date.date <= today %}
<a
href="{{ row.date.feedback }}"
class="button"
title="Read or leave feedback for this talk">
<i class="fa fa-comment-o"></i> joind.in
</a>
{% endif %}
</td>
{% endif %}
</tr>
{% endfor %}
</tbody>
</table>
</div>