-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
57 lines (52 loc) · 2.13 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
---
layout: default
---
<div id='table-of-contents-container'>
<h3>Session Descriptions (and slides <i class='fa fa-slideshare'></i>)</h3>
<ol class='leaders' id='table-of-contents'>
{% assign sortedSessions = site.sessions | sort: 'number' | reverse %}
{% for session in sortedSessions %}
{% assign slug = session.date | date:"%-d %B %Y" | slugify %}
{% if session.title != null %}
<li>
<a class='title-link' href='#{{ slug }}'><span>{{ session.title }}</span></a><a href='./sessions/{{ session.number }}'><span><i class='fa fa-slideshare'></i></span></a>
</li>
{% endif %}
{% endfor %}
</ol>
</div>
{% if site.sessions | size > 0 %}
<hr>
<section id='weeks'>
<h3>Weekly session summaries</h3>
{% assign sortedSessions = site.sessions | sort: 'number' | reverse %} {% for session in sortedSessions %} {% assign slug = session.date | date:"%-d %B %Y" | slugify %} {% if session.title != null %}
<section id="{{ slug }}" class='week'>
<h2>
<div class='session-title'>{{ session.number }}: {{ session.title }}</div>
<div class='meta'>
<a class='date' href='#{{ slug }}'>{{ session.date | date:"%-d %B %Y" }}</a> <br>
<i class='fa fa-external-link'></i> <a class='slides' href='./sessions/{{ session.number }}'>Slides for Session {{ session.number }}</a>
</div>
</h2> {{ session.content | markdownify }}
</section>
{% endif %} {% endfor %}
</section>
<script>
window.onload = function() {
var weeks = Array.prototype.slice.call(document.querySelectorAll('section.week'));
weeks.forEach(function(week) {
var weekDate = new Date(week.id);
var today = new Date();
if (weekDate >= today) {
week.classList.add('upcoming');
} else if (weekDate < today) {
week.classList.add('past');
}
});
var nextWeek = document.querySelectorAll('section.upcoming')[0];
if (nextWeek) {
nextWeek.classList.add('active');
}
};
</script>
{% endif %}